Agentic Endpoints Once Key API
The Once Key API from Agentic Endpoints — 3 operation(s) for once key.
The Once Key API from Agentic Endpoints — 3 operation(s) for once key.
Every API here is available over the APIs.io API and to AI agents over MCP.
One button, every client — Claude, Cursor, VS Code and the rest.
https://apis.io/mcp
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.curl "https://apis.io/api/v1/apis/agentic-endpoints-com:agentic-endpoints-com-once-key-api"
curl "https://apis.io/api/v1/apis?limit=25"
Discovery needs no key. Ratings and market analysis are Pro.
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. See our Privacy Policy and Terms.
A second provider on the same verified email joins the account you already have.
openapi: 3.2.0
info:
title: agentic-endpoints Once Key API
version: 1.0.0
license:
name: MIT
identifier: MIT
description: 'Pay-per-call utilities for autonomous agents. No signup, no API keys, no invoices: every endpoint answers HTTP 402 with a price and serves the request once payment is signed.'
servers:
- url: https://agentic-endpoints.com
tags:
- name: Once Key
paths:
/once-key:
post:
summary: Atomic idempotency witness — claim an action exactly once, record its result…
description: Atomic idempotency witness — claim an action exactly once, record its result, and replay that result to every later caller. Costs $0.010, paid per call with x402 (USDC on Base), or debited from a prepaid balance by sending an X-Credit-Token header.
operationId: once_key
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
namespace:
type: string
description: Isolation scope for the claimed key
action_key:
type: string
description: Unique key to claim exactly once
payload_sha256:
type: string
description: Optional hash of the payload for conflict detection
ttl:
type: number
description: Claim lifetime in seconds (default 86400)
namespace_token:
type: string
description: Owner token issued on the first claim in a namespace; required on every later request
lease_ttl:
type: number
description: Seconds you have to call /once-key/complete before the claim is treated as abandoned and another caller may take it over. Omit to hold the claim for its full ttl.
required:
- namespace
- action_key
example:
namespace: invoices-4f9c2b1e8d7a
action_key: charge-order-1042
ttl: 86400
lease_ttl: 300
responses:
'200':
description: Success
content:
application/json:
example:
status: claimed
namespace: my-app-4f9c2b1e8d7a
action_key: order-12345
claimed_at: '2026-01-01T00:00:00.000Z'
lease_expires_at: '2026-01-01T00:05:00.000Z'
expires_at: '2026-01-02T00:00:00.000Z'
receipt: abc123...
'402':
description: Payment required. The body names the price and all three ways to pay, including the free trial that needs no wallet. The `payment-required` response header carries the same challenge base64-encoded, which is where x402 v2 clients read it.
content:
application/json:
schema:
$ref: '#/components/schemas/PaymentRequired'
'429':
description: Rate limited.
security:
- creditToken: []
- x402Payment: []
- {}
tags:
- Once Key
/once-key/complete:
post:
summary: Record the outcome of a claimed action_key
description: 'Stores the result of work performed under a claim. Later claims of the same action_key return status "duplicate" together with this result, so the caller that lost the race can continue instead of repeating the side effect. Free: the claim price covers the whole lifecycle. Completion is final and cannot be overwritten.'
operationId: once_key_complete
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
namespace:
type: string
action_key:
type: string
namespace_token:
type: string
result:
description: Any JSON value, up to 16 KB once serialized.
ttl:
type: number
description: How long to retain the result, in seconds. Default 86400.
required:
- namespace
- action_key
example:
namespace: invoices-4f9c2b1e8d7a
action_key: charge-order-1042
namespace_token: the token issued on your first claim
result:
charge_id: ch_abc123
amount: 4200
responses:
'200':
description: Success, or a settled refusal. Paid routes answer 200 with a machine-readable `status` (e.g. "forbidden", "not_found", "precondition_failed", "conflict") rather than a 4xx, because any status >=400 cancels x402 settlement and would give the answer away for free. Always branch on `status`, not on the HTTP code.
'400':
description: Malformed request.
'404':
description: No such record.
'429':
description: Rate limited.
security: []
tags:
- Once Key
/once-key/release:
post:
summary: Surrender a claim whose work failed
description: Frees a claimed action_key so a retry can proceed immediately rather than waiting out the lease. Free. Refuses with 409 if the key was already completed, since releasing it would discard the recorded result and permit a second side effect.
operationId: once_key_release
requestBody:
required: true
content:
application/json:
schema:
type: object
properties:
namespace:
type: string
action_key:
type: string
namespace_token:
type: string
required:
- namespace
- action_key
example:
namespace: invoices-4f9c2b1e8d7a
action_key: charge-order-1042
namespace_token: the token issued on your first claim
responses:
'200':
description: Success, or a settled refusal. Paid routes answer 200 with a machine-readable `status` (e.g. "forbidden", "not_found", "precondition_failed", "conflict") rather than a 4xx, because any status >=400 cancels x402 settlement and would give the answer away for free. Always branch on `status`, not on the HTTP code.
'400':
description: Malformed request.
'404':
description: No such record.
'429':
description: Rate limited.
security: []
tags:
- Once Key
components:
schemas:
PaymentRequired:
type: object
description: Body of a 402. Every field is derived from the same challenge the caller is asked to sign, so it cannot quote a different price or recipient.
properties:
error:
type: string
const: payment_required
price:
type: string
description: List price in dollars, e.g. $0.005
resource:
type: string
description: The URL being charged for
ways_to_pay:
type: object
description: The three routes in, cheapest first. free_trial needs no wallet, no signature, no account and no email.
properties:
free_trial:
type: object
prepaid_credit:
type: object
per_call_x402:
type: object
accepts:
type: array
description: The x402 challenge, echoed here for v1 clients that read it from the body rather than the payment-required header.
items:
type: object
x402Version:
type: number
required:
- error
- ways_to_pay
securitySchemes:
creditToken:
type: apiKey
in: header
name: X-Credit-Token
description: A prepaid or trial balance. Get one free with no wallet and no account at POST https://agentic-endpoints.com/credits/trial, or buy credit at POST https://agentic-endpoints.com/credits/buy. Each call is debited at the route's list price and nothing is signed per request.
x402Payment:
type: apiKey
in: header
name: X-PAYMENT
description: A signed x402 payment authorising this one call, built from the challenge returned with HTTP 402. Requires a funded wallet on Base; the credit token does not.