---
title: "JSON-RPC endpoint"
method: POST
path: "/"
---

# JSON-RPC endpoint

`POST /`

All RPC commands are sent as POST requests to this endpoint. The `route`
field in the request body determines which command is executed.

See the individual route descriptions below for details on each command.

## Request body

- RPCRequest
  - `type` 1, required — Message type (1 = request).
  - `route` string, required — The RPC command route name.
  - `id` integer, required — Request ID for matching responses.
  - `payload` unknown

## Response `200`

JSON-RPC response

- RPCResponse
  - `type` 2 — Message type (2 = response).
  - `id` integer — ID matching the request.
  - `payload` object
    - `result` unknown
    - `error` object, nullable
      - `code` integer
      - `message` string

## Other responses

- `401` — Authentication failed

---

[API](https://skmtc.dev/decred/apis/bison-wallet-rpc-api.md) · [All operations](https://skmtc.dev/decred/apis/bison-wallet-rpc-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/decred/bison-wallet-rpc-api/revisions/4c0e58d684f8/schema)
