API reference · Owned cards

Reveal an invoice

POST/v1/wallets/{walletId}/invoices/{invoiceId}/cards/reveal

Shows the codes of every card on an invoice — all of them or none, up to 100. Sends no body.

Permissioncards:reveal
AuthenticationSigned change
Staff-set limits it counts towardAll requests, Reveals
.NET SDKanis.OwnedCards.RevealInvoiceAsync(walletId, invoiceId)

Parameters

NameInTypeNotes
walletIdrequiredpathUUIDA UUID, lower-case with hyphens.
invoiceIdrequiredpathUUIDA UUID, lower-case with hyphens.

Request

Signed with your key, with a one-time nonce and a digest of the body.

Headers: Signature-Input, Signature, Content-Digest, Nonce, X-Anis-Date, Accept-Language (optional). The SDKs set all of them for you.

Body: No body at all — not even {}. Any byte is refused with validation_failed. The signature still covers the digest of the empty body.

Responses

StatusMeaningBody
200Success.RevealedCredentialCollection
401Refused: not authenticated.Problem
403Refused: not allowed.Problem
404Refused: not found, or not yours.Problem
409Refused: conflicts with the current state.Problem
422Refused: the request breaks a rule.Problem
429Refused: a limit was reached.Problem
503No decision: a dependency was unavailable.Problem

Every answer is signed by Anis; the SDKs check it before you see it.

Refusals

Every refusal is a signed problem. Branch on its code; each links to what it means and what to do.

ErrorCodeStatus
Invalid credentialsinvalid_credentials401
Insufficient scopeinsufficient_scope403
Source address not allowedsource_ip_not_allowed403
Rate limitedrate_limited429
Replay detectedreplay_detected409
Account not authorisedbinding_not_authorized403
Account inactiveaccount_inactive403
Wallet not grantedwallet_not_granted404
Not foundresource_not_found404
Validation failedvalidation_failed422
Reveal not allowedreveal_not_allowed409
Invoice too large to revealinvoice_reveal_limit_exceeded409
Business subscription requiredbusiness_subscription_required409
Wallet disabledwallet_disabled409
Wallet expiredwallet_expired409
Service unavailabledependency_unavailable503
Request timeoutrequest_timeout504
Internal errorinternal_error500

Types

RevealedCredentialCollection

FieldTypeNotes
itemsalways presentlist of RevealedCredentialEvery card on the invoice with its codes — all of them or none, at most 100.

RevealedCredential

FieldTypeNotes
soldCardIdalways presentUUIDThe sold card these codes belong to.
serialNumberstringThe card’s serial number. A secret: store it where you keep secrets and never log it.
voucherstringThe card’s voucher code. A secret: store it where you keep secrets and never log it.
revealedAtstring (date-time)When it was revealed.