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

# What an agent can buy

> Machine-readable prices for the pay-per-link rail, and which payment protocols this API speaks. Fetch this rather than hard-coding a price.



## OpenAPI

````yaml /openapi.json get /api/pricing
openapi: 3.1.0
info:
  title: kealink API
  version: '2026-08-21'
  description: >-
    Permanent link shortening and dynamic QR codes.


    **A code we issue never stops resolving.** Not when the destination changes,
    not

    when a subscription lapses, not when the link is archived. Customers print
    these

    on physical materials, so a dead redirect is a reprint bill. Every design

    decision below follows from that.


    ### Authentication


    Send an API key as `Authorization: Bearer klk_...`. Mint one with

    `POST /api/billing/claim`. Keys are stored hashed and shown exactly once.


    ### Paying as an agent


    You do not need an account. `POST /api/links` with no credentials answers

    `402` with a machine-payment challenge — MPP (`WWW-Authenticate: Payment`)
    and

    x402 (`PAYMENT-REQUIRED`) on the same response. Pay either one, retry, and
    you

    get a permanent link plus an API key to repoint it with later.


    ### Errors


    Always `{ "error": "a sentence" }` with a real status code. `402` means this

    action needs payment — never that existing links stopped working.
  contact:
    name: kealink support
    url: https://kealinks.com
servers:
  - url: https://api.kealinks.com
    description: Production
security: []
tags:
  - name: Links
    description: Create and repoint permanent codes.
  - name: QR codes
    description: Print-ready artwork for a link.
  - name: Analytics
    description: Scans and clicks, by day, country, device or referrer.
  - name: Domains
    description: Serve your codes on your own hostname.
  - name: Account
    description: Tier, quota and what this account may do.
  - name: Billing
    description: Subscription lifecycle.
  - name: Team
    description: Workspaces and members.
  - name: Machine payments
    description: Buy a permanent link with no account, over MPP or x402. Built for agents.
  - name: Meta
    description: Discovery and health.
paths:
  /api/pricing:
    get:
      tags:
        - Machine payments
      summary: What an agent can buy
      description: >-
        Machine-readable prices for the pay-per-link rail, and which payment
        protocols this API speaks. Fetch this rather than hard-coding a price.
      operationId: getPricing
      responses:
        '200':
          description: Current machine-payment prices.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Pricing'
      security: []
components:
  schemas:
    Pricing:
      type: object
      properties:
        protocols:
          type: array
          items:
            type: string
          description: Machine-payment protocols this API speaks.
          examples:
            - - mpp
              - x402
        prices:
          type: array
          items:
            $ref: '#/components/schemas/MachinePrice'
        subscription:
          type: string
          description: >-
            The human plan, for agents acting on behalf of a person who would
            rather subscribe.
      required:
        - protocols
        - prices
        - subscription
      additionalProperties: false
      description: >-
        What an agent can buy without a human. Fetch this before you pay — the
        price is authoritative here, not in the docs.
    MachinePrice:
      type: object
      properties:
        product:
          type: string
          examples:
            - permanent_link
        amount:
          type: string
          description: Decimal string, so no float rounding. Pair it with `currency`.
          examples:
            - '2.00'
        currency:
          type: string
          examples:
            - usd
        description:
          type: string
      required:
        - product
        - amount
        - currency
        - description
      additionalProperties: false

````