> ## Documentation Index
> Fetch the complete documentation index at: https://docs.trysoma.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Handle JSON-RPC

> Handle JSON-RPC requests for agent-to-agent communication (tasks, messages, etc.)



## OpenAPI

````yaml api-reference/openapi.json post /api/a2a/v1
openapi: 3.1.0
info:
  title: soma
  version: v1
servers: []
security: []
tags:
  - name: task
    description: >-
      Task management endpoints for creating, listing, and managing tasks and
      their messages
  - name: secret
    description: Secret management endpoints for storing and retrieving encrypted secrets
  - name: encryption
    description: >-
      Encryption key management endpoints for envelope keys, data encryption
      keys, and aliases
  - name: bridge
    description: >-
      Bridge endpoints for managing providers, credentials, functions, and MCP
      protocol communication
  - name: _internal
    description: >-
      Internal endpoints for health checks, runtime configuration, and SDK code
      generation
  - name: a2a
    description: >-
      Agent-to-agent communication endpoints for agent cards, definitions, and
      JSON-RPC requests
  - name: v1
    description: API version v1 endpoints
paths:
  /api/a2a/v1:
    post:
      tags:
        - a2a
        - v1
      summary: Handle JSON-RPC
      description: >-
        Handle JSON-RPC requests for agent-to-agent communication (tasks,
        messages, etc.)
      operationId: handle-jsonrpc-request
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/JsonrpcRequest'
        required: true
      responses:
        '200':
          description: Successful response
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    JsonrpcRequest:
      type: object
    Error:
      type: object
      required:
        - message
      properties:
        data: {}
        message:
          type: string

````