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

> ## Agent Instructions
> Authenticate every request with `Authorization: ApiKey {jwt}`: an ES256 JWT signed with the user's private API key, whose header carries `kid` (the API key ID) and whose payload carries `iat` (Unix time in seconds) and `message`, the hex SHA-256 of `{iat}\n{METHOD}\n{PATH}\n{BODY}`. METHOD is uppercase, PATH includes the query string, BODY is the exact JSON sent or an empty string. Full steps: https://developer.bron.org/api-reference/authentication
> Prefer the official SDKs or the CLI, which sign every request: TypeScript `npm install @bronlabs/bron-sdk`, Go `go get github.com/bronlabs/bron-sdk-go`, Python `pip install git+https://github.com/bronlabs/bron-sdk-python.git`, CLI `brew install bronlabs/apps/bron`. Hand-write JWT signing only for a language without an SDK.
> The base URL is https://api.bron.org. Workspace data lives under `/workspaces/{workspaceId}/...`, and `/dictionary/...` serves reference data such as assets, networks and prices. Timestamps are milliseconds since the Unix epoch. Numeric values, amounts included, are strings: never parse them as floats.
> Never ask the user to paste their API key (the private JWK) into a chat and never hard-code it: read it from an environment variable or a secret store.

# Create Intent request

> Creates an intent for swaps between two assets. [More details](/intents/about).

Answers 404 `pair-not-available` when the pair is not tradable through Intents.

<sup>API Key permissions: Transaction Operator, Full Access</sup>



## OpenAPI

````yaml /bron-open-api-public.json post /workspaces/{workspaceId}/intents
openapi: 3.1.1
info:
  description: >-
    Bron API is based on the RESTish interface provided for data exchange
    between a client and a server with the use of HTTPS requests and responses.
  title: Bron API
  version: latest
  x-bron-formats:
    bigint: Arbitrary-precision integer encoded as a JSON string.
    date-time-millis: >-
      Epoch milliseconds (UTC) encoded as a JSON string. Convert with `new
      Date(parseInt(value))` or equivalent.
    decimal: Arbitrary-precision decimal encoded as a JSON string.
    int32: 32-bit integer encoded as a JSON string.
    int64: >-
      Long integer encoded as a JSON string to preserve precision (e.g. account
      IDs).
servers:
  - description: app.bron.org
    url: https://api.bron.org
security: []
tags:
  - name: intents
  - name: addresses
  - name: transactions
  - name: stake
  - name: balances
  - name: assets
  - name: transaction-limits
  - name: canton
  - name: address-book
  - name: workspaces
  - name: accounts
  - name: hyperliquid
paths:
  /workspaces/{workspaceId}/intents:
    post:
      tags:
        - intents
      summary: Create Intent request
      description: >-
        Creates an intent for swaps between two assets. [More
        details](/intents/about).


        Answers 404 `pair-not-available` when the pair is not tradable through
        Intents.


        <sup>API Key permissions: Transaction Operator, Full Access</sup>
      parameters:
        - in: path
          name: workspaceId
          required: true
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateIntent'
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Intent'
          description: OK
        '400':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - bad-request
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Bad Request
        '403':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - forbidden
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Forbidden
        '409':
          content:
            application/json:
              schema:
                properties:
                  error:
                    description: The machine-readable error code
                    examples:
                      - conflict
                    type: string
                  message:
                    description: >-
                      A human-readable message providing more details about the
                      error
                    type: string
                type: object
          description: Conflict
components:
  schemas:
    CreateIntent:
      properties:
        accountId:
          description: The id of the account where the intent transaction should be placed
          examples:
            - kqftx9zd3g6qdp09or
          type: string
        fromAmount:
          description: >-
            The amount of asset that will be sent. Optional, one of `fromAmount`
            or `toAmount` must be specified.
          examples:
            - '120.015'
          format: decimal
          type: string
        fromAssetId:
          examples:
            - '2'
          type: string
        fromTokenId:
          description: >-
            Token ID of the from-asset. Required when the from-asset is a
            tokenized asset (NFT or Bron Lock).
          type: string
        intentId:
          description: >-
            Unique intent identifier from client (should be unique per the
            account)
          examples:
            - w2u573pjj5wl975z4a9
          type: string
        toAmount:
          examples:
            - '117500.03'
          format: decimal
          type: string
        toAssetId:
          examples:
            - '5002'
          type: string
        toTokenId:
          description: >-
            Token ID of the to-asset. Required when the to-asset is a tokenized
            asset (NFT or Bron Lock).
          type: string
      required:
        - accountId
        - intentId
        - fromAssetId
        - toAssetId
      type: object
    Intent:
      properties:
        createdAt:
          description: Creation timestamp of the intent (epoch millis)
          examples:
            - '1794678400000'
          format: date-time-millis
          type: string
        expiresAt:
          description: Expiration timestamp of the intent (epoch millis)
          examples:
            - '1758188560749'
          format: date-time-millis
          type: string
        fromAmount:
          description: Amount of the from-asset specified by the user
          examples:
            - '100.50'
          format: decimal
          type: string
        fromAssetId:
          description: ID of the asset being sent
          examples:
            - '2'
          type: string
        fromTokenId:
          description: Token ID of the from-asset for a tokenized asset (NFT or Bron Lock)
          type: string
        intentId:
          description: Unique user-generated ID of the intent
          examples:
            - rzsdziq1iknnzszmmtqz
          type: string
        price:
          description: Execution price of the swap (quote/base)
          examples:
            - '101.2312'
          format: decimal
          type: string
        status:
          $ref: '#/components/schemas/IntentOrderStatus'
          description: >-
            Current status of the intent order. [See
            details](/enums/IntentOrderStatus)
          examples:
            - auction-in-progress
        toAmount:
          description: Amount of the to-asset requested or estimated
          examples:
            - '0.0025'
          format: decimal
          type: string
        toAssetId:
          description: ID of the asset to receive
          examples:
            - '5002'
          type: string
        toTokenId:
          description: Token ID of the to-asset for a tokenized asset (NFT or Bron Lock)
          type: string
        updatedAt:
          description: Last update timestamp of the intent (epoch millis)
          examples:
            - '1794764800000'
          format: date-time-millis
          type: string
        userSettlementDeadline:
          description: Deadline timestamp for user settlement (epoch millis)
          examples:
            - '1759188567456'
          format: date-time-millis
          type: string
      required:
        - intentId
        - status
        - fromAssetId
        - toAssetId
        - updatedAt
        - createdAt
      type: object
    IntentOrderStatus:
      enum:
        - not-exist
        - user-initiated
        - auction-in-progress
        - wait-for-user-tx
        - wait-for-oracle-confirm-user-tx
        - wait-for-solver-tx
        - wait-for-oracle-confirm-solver-tx
        - completed
        - liquidated
        - cancelled
      type: string

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.