---
title: "Error codes — Anis Developers"
description: "Every refusal the Anis Partner API can return, what it means and what to do."
url: https://developers.anis.ly/errors/
language: en
---

> Every page of this documentation: https://developers.anis.ly/llms.txt

# Error codes

Every refusal is a signed problem with a machine `code`, an HTTP status and a `type` link to its page here. Branch on the `code` — never on the title or detail, which are worded for people and change with the language you ask for.

The last column answers the first question to ask when an **order** is refused: did the purchase happen? *This request bought nothing*: fix the cause, then place a new order with a new operation id — but if you were **resuming** an order whose outcome was unknown, a refusal not marked `Idempotency-Replayed` says nothing about that order: keep resuming it. *May still complete*: send the same order again with the **same** operation id — never a new one, which could buy twice. *Never returned when buying*: the error only comes from other calls.

## Keys and signatures

Anis could not accept how the call was signed.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Invalid credentials](https://developers.anis.ly/errors/invalid-credentials.md) | `invalid_credentials` | 401 | This request bought nothing |
| [Signature expired](https://developers.anis.ly/errors/signature-expired.md) | `signature_expired` | 401 | This request bought nothing |
| [Invalid content digest](https://developers.anis.ly/errors/invalid-content-digest.md) | `invalid_content_digest` | 400 | This request bought nothing |
| [Replay detected](https://developers.anis.ly/errors/replay-detected.md) | `replay_detected` | 409 | May still complete — resume with the same id |

## Permissions and account

The call was signed correctly but is not allowed right now.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Source address not allowed](https://developers.anis.ly/errors/source-ip-not-allowed.md) | `source_ip_not_allowed` | 403 | This request bought nothing |
| [Insufficient scope](https://developers.anis.ly/errors/insufficient-scope.md) | `insufficient_scope` | 403 | This request bought nothing |
| [Account not authorised](https://developers.anis.ly/errors/binding-not-authorized.md) | `binding_not_authorized` | 403 | This request bought nothing |
| [Wallet disabled](https://developers.anis.ly/errors/wallet-disabled.md) | `wallet_disabled` | 409 | This request bought nothing |
| [Wallet expired](https://developers.anis.ly/errors/wallet-expired.md) | `wallet_expired` | 409 | This request bought nothing |
| [Business subscription required](https://developers.anis.ly/errors/business-subscription-required.md) | `business_subscription_required` | 409 | This request bought nothing |
| [Account inactive](https://developers.anis.ly/errors/account-inactive.md) | `account_inactive` | 403 | This request bought nothing |

## The request itself

Something in the request does not exist or breaks a rule.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Not found](https://developers.anis.ly/errors/resource-not-found.md) | `resource_not_found` | 404 | This request bought nothing |
| [Card not found](https://developers.anis.ly/errors/card-not-found.md) | `card_not_found` | 404 | This request bought nothing |
| [Wallet not granted](https://developers.anis.ly/errors/wallet-not-granted.md) | `wallet_not_granted` | 404 | This request bought nothing |
| [Validation failed](https://developers.anis.ly/errors/validation-failed.md) | `validation_failed` | 422 | This request bought nothing |
| [Currency not supported](https://developers.anis.ly/errors/currency-not-supported.md) | `currency_not_supported` | 422 | This request bought nothing |

## Orders

Answers only a purchase can receive.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Operation id already used](https://developers.anis.ly/errors/idempotency-conflict.md) | `idempotency_conflict` | 409 | This request bought nothing |
| [Order still processing](https://developers.anis.ly/errors/operation-processing.md) | `operation_processing` | 202 | May still complete — resume with the same id |
| [Allowed-debt consent required](https://developers.anis.ly/errors/allowed-debt-consent-required.md) | `allowed_debt_consent_required` | 402 | This request bought nothing |
| [Insufficient balance](https://developers.anis.ly/errors/insufficient-balance.md) | `insufficient_balance` | 409 | This request bought nothing |
| [Purchase not allowed](https://developers.anis.ly/errors/purchase-not-allowed.md) | `purchase_not_allowed` | 403 | This request bought nothing |
| [Order refused](https://developers.anis.ly/errors/order-refused.md) | `purchase_not_allowed` | 409 | This request bought nothing |
| [Card unavailable](https://developers.anis.ly/errors/card-unavailable.md) | `card_unavailable` | 409 | This request bought nothing |
| [Quantity unavailable](https://developers.anis.ly/errors/quantity-unavailable.md) | `quantity_unavailable` | 409 | This request bought nothing |
| [Price changed](https://developers.anis.ly/errors/price-changed.md) | `price_changed` | 409 | This request bought nothing |

## Limits

A limit on requests or on spending was reached.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Spending allowance used up](https://developers.anis.ly/errors/owner-limit-exceeded.md) | `owner_limit_exceeded` | 409 | This request bought nothing |
| [Daily limit reached](https://developers.anis.ly/errors/daily-limit-exceeded.md) | `daily_limit_exceeded` | 429 | This request bought nothing |
| [Rate limited](https://developers.anis.ly/errors/rate-limited.md) | `rate_limited` | 429 | This request bought nothing |

## Revealing cards

A card’s codes could not be shown.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Reveal not allowed](https://developers.anis.ly/errors/reveal-not-allowed.md) | `reveal_not_allowed` | 409 | Never returned when buying |
| [Invoice too large to reveal](https://developers.anis.ly/errors/invoice-reveal-limit-exceeded.md) | `invoice_reveal_limit_exceeded` | 409 | Never returned when buying |

## Enrolling a key

A step of turning an invitation into a working key was refused.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Invitation invalid](https://developers.anis.ly/errors/invitation-invalid.md) | `invitation_invalid` | 401 | Never returned when buying |
| [Challenge replaced](https://developers.anis.ly/errors/challenge-expired.md) | `challenge_expired` | 409 | Never returned when buying |
| [Public key invalid](https://developers.anis.ly/errors/key-proof-invalid.md) | `key_proof_invalid` | 422 | Never returned when buying |
| [Invitation already used](https://developers.anis.ly/errors/key-duplicate.md) | `key_duplicate` | 409 | Never returned when buying |

## No decision reached

Anis could not finish the call. On an order, the outcome is unknown.

| Error | Code | Status | If this was an order |
| --- | --- | --- | --- |
| [Service unavailable](https://developers.anis.ly/errors/dependency-unavailable.md) | `dependency_unavailable` | 503 | May still complete — resume with the same id |
| [Request timeout](https://developers.anis.ly/errors/request-timeout.md) | `request_timeout` | 504 | May still complete — resume with the same id |
| [Internal error](https://developers.anis.ly/errors/internal-error.md) | `internal_error` | 500 | May still complete — resume with the same id |
