Documentation

Build with Trezalink without losing the thread.

Structured guides for Solana checkout, payment links, webhooks, security boundaries, operations, and diagnostics.

Integrate

Checkout API

Operate

Security + status

Guide

Error Reference

Machine-readable API error codes and diagnostics contract for checkout, auth, and merchant endpoints.

Error responses follow one contract: error.code, message, requestId, retryable,docsUrl, and optional details.

Use error.code as the primary integration key in your backend logic, then map retryable and HTTP status to retry/alert behavior.

Diagnostics flow: log requestId on every failed request, branch retry behavior using retryable, and surfacedocsUrl in internal tooling so operators can jump directly to the relevant error anchor.

Checkout

AUTH_MISSING_BEARER_TOKEN

HTTP 401

Send `Authorization: Bearer <API_KEY>` from backend.

AUTH_INVALID_API_KEY

HTTP 401

Regenerate API key and verify account active state.

MERCHANT_WALLET_NOT_LINKED

HTTP 400

Link settlement wallet before creating checkout session.

CHECKOUT_VALIDATION_FAILED

HTTP 400

Inspect `error.details` and fix payload fields.

CHECKOUT_DUPLICATE_ORDER_ID

HTTP 409

Use unique orderId per business.

MAINTENANCE_MODE_ACTIVE

HTTP 503

Respect `Retry-After` and retry after maintenance.

INTERNAL_SERVER_ERROR

HTTP 500

Retry if safe and share requestId with support.

Auth

AUTH_MISSING_REQUIRED_FIELDS

HTTP 400

Provide all required payload fields for the auth endpoint.

AUTH_INVALID_CREDENTIALS

HTTP 401

Re-check email/password pair and try again.

AUTH_EMAIL_NOT_VERIFIED

HTTP 403

Verify account email before login.

AUTH_PROFILE_SETUP_REQUIRED

HTTP 403

Complete profile setup before password login.

AUTH_ACTIVATION_TOKEN_MISSING

HTTP 400

Submit activation token in request payload.

AUTH_ACTIVATION_TOKEN_INVALID

HTTP 400

Request a new activation link and retry.

AUTH_WALLET_SIGNATURE_INVALID

HTTP 401

Re-sign challenge message from the same wallet.

AUTH_PROFILE_EMAIL_CONFLICT

HTTP 409

Use a different email address for this account.

AUTH_MERCHANT_NOT_FOUND

HTTP 404

Confirm businessId mapping and account existence.

AUTH_EMAIL_ALREADY_VERIFIED

HTTP 400

Skip resend flow because verification is complete.

Merchant

MERCHANT_UNAUTHORIZED

HTTP 401

Authenticate first and ensure auth-token cookie is valid.

MERCHANT_EXPORT_VALIDATION_FAILED

HTTP 400

Use valid export query values (`status`, `from`, `to`) with ISO date format.

MERCHANT_INVALID_ACTION

HTTP 400

Use supported action values (`link` or `unlink`).

MERCHANT_MISSING_CRYPTO_PROOFS

HTTP 400

Provide `publicKey`, `signature`, and `message` for wallet linking.

MERCHANT_WALLET_SIGNATURE_INVALID

HTTP 401

Regenerate wallet signature and retry with matching key.

MERCHANT_WALLET_ALREADY_LINKED

HTTP 409

Use a wallet not owned by another merchant account.

Internal Ops

INTERNAL_CONFIRMATION_MISSING_FIELDS

HTTP 400

Send both `transactionId` and `signature` in confirmation payload.

INTERNAL_CONFIRMATION_REJECTED

HTTP 400

Inspect transaction state and signature validity before retrying confirmation.

INTERNAL_RPC_TELEMETRY_INVALID_PAYLOAD

HTTP 400

Include `operation`, `endpoint`, and `primaryEndpoint` when sending telemetry events.

INTERNAL_CRON_UNAUTHORIZED

HTTP 401

Pass valid cron secret via `x-cron-secret` or `Authorization: Bearer <secret>`.