Rivaire Drafts API

The Drafts API from Rivaire — 2 operation(s) for drafts.

GitHub OpenAPI

Operations 4

GET /v1/drafts List drafts #
POST /v1/drafts Create a draft #
GET /v1/drafts/{draftId} Get a draft #
DELETE /v1/drafts/{draftId} Delete a draft #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/rivaire-pro:rivaire-pro-drafts-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. By signing up you are subscribing to the APIs.io and API Evangelist newsletters — you can unsubscribe from any issue. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

rivaire-pro-drafts-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Rivaire Drafts API
  version: '1'
  description: 'Create a token in Settings → API


    Send it as `Authorization: Bearer rvr_...`


    Spec: openapi.json


    ## Workspaces


    Pass `?workspaceId=` to pick a workspace; get IDs from `GET /v1/workspaces`. Without it, requests about a

    transaction, wallet or recurring series use its workspace, and everything else uses your Main workspace.


    ## Amounts


    Amounts are decimal strings like `"12.50"`. Send a string or a number with up to two decimals.


    What a token sees is set when you create it:


    - **Show amounts**: plain amounts in and out. The server encrypts them and updates balances.

    - **Keep them locked** (default): amounts are `null`, with the stored values in `encrypted`. Decrypt them with

    `GET /v1/keys` and your 12-word phrase. To write money, encrypt it yourself and send the new wallet balances in

    `walletBalanceUpdates`.


    Errors look like `{"error": "message"}`.'
servers:
- url: https://api.rivaire.pro
security:
- apiToken: []
tags:
- name: Drafts
paths:
  /v1/drafts:
    get:
      tags:
      - Drafts
      summary: List drafts
      parameters:
      - name: workspaceId
        in: query
        required: false
        description: Workspace to use. Defaults to the workspace of the transaction or wallet in the request, otherwise Main.
        schema:
          type: string
          format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  drafts:
                    type: array
                    items:
                      $ref: '#/components/schemas/Draft'
                required:
                - drafts
        '400':
          description: Invalid request. The message says what is wrong.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: The token is missing, invalid or expired.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Too many requests. Wait and retry.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: getV1Drafts
      x-operation-id-source: derived
    post:
      tags:
      - Drafts
      summary: Create a draft
      description: 'An expense to finish later. Any token can create one: the server encrypts `amount` and `location` right away, so only your devices and tokens that show amounts can read them.'
      parameters:
      - name: workspaceId
        in: query
        required: false
        description: Workspace to use. Defaults to the workspace of the transaction or wallet in the request, otherwise Main.
        schema:
          type: string
          format: uuid
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                createdAt:
                  type: string
                  format: date-time
                amount:
                  description: 'Positive, up to two decimals: `"12.50"` or `12.5`. Requires a token that shows amounts.'
                  anyOf:
                  - type: string
                  - type: number
                currencyId:
                  type: string
                  pattern: ^[A-Z]{3}$
                  description: Currency code, e.g. `USD`.
                note:
                  type: string
                  maxLength: 1000
                location:
                  type: object
                  properties:
                    latitude:
                      type: number
                      minimum: -90
                      maximum: 90
                    longitude:
                      type: number
                      minimum: -180
                      maximum: 180
                    accuracyMeters:
                      anyOf:
                      - type: number
                        minimum: 0
                      - type: 'null'
                  required:
                  - latitude
                  - longitude
                sealedDetails:
                  description: 'Instead of `amount` and `location`: encrypt them yourself for your public key from `GET /v1/keys`.'
                  $ref: '#/components/schemas/SealedDetails'
                id:
                  description: The draft ID `sealedDetails` was encrypted for. Only with `sealedDetails`.
                  type: string
                  format: uuid
      responses:
        '201':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  draft:
                    $ref: '#/components/schemas/Draft'
                required:
                - draft
        '400':
          description: Invalid request. The message says what is wrong.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: The token is missing, invalid or expired.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: 'Not allowed: a read-only token, a viewer, or plain amounts from a token that keeps them locked.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: 'Conflict: a duplicate name, an item in use, an outdated wallet `version`, or a limit reached.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Too many requests. Wait and retry.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: postV1Drafts
      x-operation-id-source: derived
  /v1/drafts/{draftId}:
    get:
      tags:
      - Drafts
      summary: Get a draft
      parameters:
      - name: draftId
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: workspaceId
        in: query
        required: false
        description: Workspace to use. Defaults to the workspace of the transaction or wallet in the request, otherwise Main.
        schema:
          type: string
          format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  draft:
                    $ref: '#/components/schemas/Draft'
                required:
                - draft
        '400':
          description: Invalid request. The message says what is wrong.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: The token is missing, invalid or expired.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Too many requests. Wait and retry.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: getV1DraftsByDraftId
      x-operation-id-source: derived
    delete:
      tags:
      - Drafts
      summary: Delete a draft
      parameters:
      - name: draftId
        in: path
        required: true
        schema:
          type: string
          format: uuid
      - name: workspaceId
        in: query
        required: false
        description: Workspace to use. Defaults to the workspace of the transaction or wallet in the request, otherwise Main.
        schema:
          type: string
          format: uuid
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                type: object
                properties:
                  ok:
                    type: boolean
                    const: true
                required:
                - ok
        '400':
          description: Invalid request. The message says what is wrong.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: The token is missing, invalid or expired.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: 'Not allowed: a read-only token, a viewer, or plain amounts from a token that keeps them locked.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '404':
          description: Not found.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: 'Conflict: a duplicate name, an item in use, an outdated wallet `version`, or a limit reached.'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '429':
          description: Too many requests. Wait and retry.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      operationId: deleteV1DraftsByDraftId
      x-operation-id-source: derived
components:
  schemas:
    SealedDetails:
      type: object
      properties:
        algorithm:
          type: string
          const: ECDH-P256+HKDF-SHA256+AES-GCM
        ephemeralPublicKey:
          type: string
          minLength: 1
          maxLength: 256
        iv:
          type: string
          minLength: 1
          maxLength: 64
        ciphertext:
          type: string
          minLength: 1
          maxLength: 1024
      required:
      - algorithm
      - ephemeralPublicKey
      - iv
      - ciphertext
      description: A draft's amount and location, encrypted for your account's public key.
    Error:
      type: object
      properties:
        error:
          type: string
      required:
      - error
    Location:
      type: object
      properties:
        latitude:
          type: number
        longitude:
          type: number
        accuracyMeters:
          anyOf:
          - type: number
          - type: 'null'
      required:
      - latitude
      - longitude
      - accuracyMeters
    Draft:
      type: object
      properties:
        id:
          type: string
          format: uuid
        createdAt:
          type: string
          format: date-time
        amount:
          anyOf:
          - type: string
          - type: 'null'
          description: Decimal string like `"12.50"`. `null` if the token keeps amounts locked; see `encrypted`.
        currencyId:
          anyOf:
          - type: string
          - type: 'null'
        note:
          anyOf:
          - type: string
          - type: 'null'
        location:
          anyOf:
          - $ref: '#/components/schemas/Location'
          - type: 'null'
        createdBy:
          type: string
          format: uuid
        sealedDetails:
          description: The encrypted amount and location, for tokens that keep amounts locked.
          anyOf:
          - $ref: '#/components/schemas/SealedDetails'
          - type: 'null'
      required:
      - id
      - createdAt
      - amount
      - currencyId
      - note
      - location
      - createdBy
  securitySchemes:
    apiToken:
      type: http
      scheme: bearer
      bearerFormat: rvr_...