---
title: "A2A 0.3.0 JSON-RPC or legacy task/goal: synchronous metadata decision."
method: POST
path: "/api/a2a/task"
tags: ["Agent Docs"]
---

# A2A 0.3.0 JSON-RPC or legacy task/goal: synchronous metadata decision.

`POST /api/a2a/task`

## Request

- Base URL: `https://huggingbay.xyz`
- URL: `https://huggingbay.xyz/api/a2a/task`
- Auth: none declared

message/send takes the first text part and optional data.constraints. Both legacy and RPC input have a 16384 raw-byte cap, depth 12, 256 keys and 128 array items; duplicate keys are refused. tasks/get reads a bounded process-local result; replay requires one fresh primary visibility batch (at most 128 IDs, two concurrent reads, a two-second deadline from route entry, canceled on disconnect). No discovery fallback; unavailable authority fails closed. tasks/cancel returns -32002 for terminal tasks, -32001 when absent. Other methods return -32601. No execution, admission, streaming, push or context continuation. Keep anonymous task IDs private; authenticated results require the same caller. Decision signatures are available only with a configured signing key.

**Inputs.** No path or query fields are required. The request body schema lists accepted fields and required values.

**Outputs.** See each status below for its media type, schema and headers. A missing record or unavailable capability is not a successful empty result.

**Errors.** API JSON failures use the documented response schema. Read code, message and next; retry only when the response allows it. Auth, invalid input and missing records need a caller change.

**Rate limits.** Write and protocol operations can have separate route-specific limits. Read Retry-After and retry_after_s when present; do not infer a write allowance from the public read budget.

**Example setup.** This example is not executed by documentation checks. Review the operation and obtain any required user consent before sending it.

## Request body

- union
  - union
    - unknown
    - unknown
  - object
    - `jsonrpc` '2.0', required
    - `id` union
      - string
      - number
    - `method` 'message/send' | 'tasks/get' | 'tasks/cancel', required
    - `params` object: message/send: message {kind:message, role:user, messageId, parts:[{kind:text,text}, {kind:data,data:{constraints}}]}; tasks/get or tasks/cancel: {id}; optional historyLength on tasks/get.

## Response `200`

Legacy decision or JSON-RPC Task/error envelope

- object: Legacy decision or JSON-RPC Task/error envelope. Fields can vary; no stronger field guarantee is specified for this operation.

## Other responses

- `204`: JSON-RPC notification; no response body
- `400`: Legacy input refusal

---

[API](https://skmtc.dev/huggingbay/apis/hugging-bay-public-api.md) · [All operations](https://skmtc.dev/huggingbay/apis/hugging-bay-public-api/llms.txt) · [OpenAPI document](https://skmtc.dev/huggingbay/apis/hugging-bay-public-api/revisions/865eb0f1b6ef?raw)
