---
title: "Linkrra Pearl Pool and Synap402 API documentation"
description: "The inference base URL is https://pool.linkrra.com/v1. Read OpenAPI before calling write operations. Pool API metadata describes mining endpoints separately. MCP setup provides the same inference discovery and chat capab"
canonical: "https://pool.linkrra.com/api"
last-updated: "2026-12-04"
---

# Linkrra Pearl Pool and Synap402 API documentation

## Discover
The inference base URL is https://pool.linkrra.com/v1. Read [OpenAPI](/openapi.json) before calling write operations. [Pool API metadata](/api/openapi.json) describes mining endpoints separately. [MCP setup](/mcp-guide.md) provides the same inference discovery and chat capabilities through tools.

## Authentication
Public model discovery and the three read-only MCP tools require no credentials. For billed inference, sign in at https://synap402.com and create an API key in your account. Send it as `Authorization: Bearer YOUR_API_KEY`. Never place keys in URLs, public code, or tool arguments. See [authentication](/auth.md).

## List models without spending
```sh
curl https://pool.linkrra.com/v1/models
```
The JSON object contains a `data` array. Use a returned model `id`; inspect its current pricing and capabilities. This endpoint is read-only and returns the current catalogue in one response; no pagination is required.

## Run a completion
```sh
curl https://pool.linkrra.com/v1/chat/completions \
  -H 'Content-Type: application/json' \
  -H 'Authorization: Bearer YOUR_API_KEY' \
  -d '{"model":"MODEL_ID_FROM_CATALOGUE","messages":[{"role":"user","content":"Hello"}],"max_tokens":256}'
```
Successful non-streaming responses contain `choices` and `usage`. Setting `stream:true` requests OpenAI-compatible server-sent events. This is a synchronous streaming operation, not an asynchronous job queue.

## Pay per request
Agents with a supported wallet can use the [x402 discovery document](/.well-known/x402). An unpaid request returns a payment challenge; inspect that exact quote and supported network before authorizing payment. Do not automatically pay, retry a charged operation or assume the same quote remains valid indefinitely.

## Errors and retries
Inspect the HTTP status and JSON error. A missing/invalid key requires authentication; a payment challenge requires explicit funding; an unavailable service should be retried with backoff. Respect `Retry-After` when supplied. Never blindly retry non-idempotent paid calls after an ambiguous disconnect; a timeout does not prove the call was not processed. No general Idempotency-Key guarantee is advertised.

## Versioning and deprecation
The OpenAI-compatible interface uses `/v1`. Additive fields may be introduced; clients should ignore unknown fields. Breaking revisions are published under a new version with migration guidance before the old version is retired. No end-of-life date for `/v1` is currently scheduled. Model availability is dynamic: refresh `/v1/models` instead of hardcoding a catalogue.

## Safe integration checks
Use the public catalogue and free MCP tools to test connectivity without a payment or side effect. There is no separate production-equivalent sandbox. Never interpret these read-only checks as proof that a paid completion or payout succeeded.

## Safe integration testing

The [API sandbox](/sandbox.md) uses the separate `/sandbox/v1` base URL and the synthetic model `pool-sandbox-synthetic`. It cannot reach models, accounts or billing. JSON and SSE responses let you test a client without production calls; it is not a model-quality or payment test.

## Search this documentation

Use `GET /ask?query=API%20keys` or NLWeb v0.55 `POST /ask` with `{"query":{"text":"API keys"},"prefer":{"mode":"list","response_format":"conversational_search","streaming":false},"meta":{"version":"0.55"}}`. This returns `_meta` and ranked excerpts from public documentation, not generated advice. Set `prefer.streaming: true` for standard SSE `start`, `result`, `error` and `complete` framing. Only list/retrieval mode is supported. The separate documentation MCP server is at `/docs/mcp`.

## Asynchronous batch jobs and safe retries

The production Batch API requires a private API key. Upload a JSONL input with `POST /v1/files` using multipart fields `file` and `purpose=batch`, then submit `POST /v1/batches` with `input_file_id`, `endpoint: "/v1/chat/completions"`, `completion_window: "24h"`, and optional metadata (up to 16 string pairs). Creating a batch authorizes inference and can incur charges; the synthetic sandbox does not run batches.

Job creation returns HTTP 200 by default for OpenAI SDK compatibility. To use HTTP asynchronous semantics, send `Prefer: respond-async`: the server returns HTTP 202 with `Preference-Applied: respond-async`. Both responses include `Location: /v1/batches/<id>` and a job identifier/status in the body. Replays honor the current preference without creating another job. Poll `GET /v1/batches/<id>`, retrieve result content using `GET /v1/files/<id>/content`, and cancel remaining work with `POST /v1/batches/<id>/cancel`. Cancelling does not undo completed work or settled charges.

For `POST /v1/batches` only, send `Idempotency-Key` with 1–128 visible ASCII characters. Identical canonical parameters under the same API key return the same durable job; `Idempotency-Replayed: true` identifies a replay. Reusing the key with changed parameters returns HTTP 409 `idempotency_conflict`. The deduplication record survives process restart and is isolated per API key, not across all keys of an account. Invalid keys return HTTP 400 `invalid_idempotency_key`. Calls without this header retain ordinary create behavior.

This guarantee does not apply to streaming inference, swaps, file upload or arbitrary POST routes. After an ambiguous paid-inference timeout, inspect state rather than retrying a chargeable request blindly.

## Rate-limit response headers

Public `GET /v1/models` has its own allowance of 120 requests per minute per client IP, separate from API-key inference limits and the edge burst guard. Read `RateLimit`, `RateLimit-Remaining` and `RateLimit-Reset` on actual responses; per-key limits are determined from the key record. A consumed allowance returns HTTP 429 with `Retry-After`. Wait that long before retrying. Capacity errors use HTTP 503 rather than falsely claiming a client used its quota.
