Docs/API/Response

Response

What moat returns when you create or query a transaction — response codes, AVS and CVV responses, and the correlation ID for support.

Every transaction response carries a consistent envelope and a set of specific fields that tell you how the transaction was handled. This page is the reference for interpreting those fields.

Envelope

{
  "status": "success",
  "msg": "success",
  "data": {
    "id": "txn_abc123",
    "response": "approved",
    "response_code": 100,
    "amount": 1299,
    "amount_authorized": 1299,
    ...
  }
}
FieldDescription
statussuccess or failed. Reflects whether the API accepted and processed the request, not whether the issuer approved it.
msgHuman-readable summary. Safe to log; not safe to show to cardholders verbatim.
dataThe transaction record, populated on success.
Status vs. response

status: "success" means the request was processed. The issuer's decision lives in data.response and data.response_code. A declined card returns status: "success" with response: "declined" — that is a successful API call with a declined outcome.

Response codes

The response_code field indicates how the processor handled the transaction. Codes fall into four ranges.

RangeMeaning
100Approved
200–299Declined by the issuer
300–399Gateway / processor error (not a decline — a problem reaching the issuer)
400+Miscellaneous and extended codes (see full reference below)

Common codes

CodeMeaningCustomer action
100ApprovedNone
200DeclinedTry a different card
201Declined — call issuerContact card-issuing bank
202Insufficient fundsTry a different card or fund the account
203Over limitTry a different card
204Transaction not allowedUse a different card or method
220Incorrect payment dataVerify card number, expiration, CVV
221No such card issuerCheck the card number
222No card number on fileTry a different card
223Expired cardUpdate the card
224Invalid expiration dateCorrect the expiration
225Invalid card security codeRe-enter CVV
240Call issuer for further informationContact card-issuing bank
250Pick up cardDo not reattempt; possible fraud
251Lost cardDo not reattempt
252Stolen cardDo not reattempt
253Fraudulent cardDo not reattempt
260Declined with further instructionsRead msg field
261Declined — stop recurringHalt any recurring schedule
262Declined — stop recurring for twoHalt recurring, retry a limited number of times
263Declined — updated cardholder data availableTry Account Updater
264Declined — retry in a few daysRetry with backoff
300Gateway errorRetry with exponential backoff
400Transaction error returned by processorInspect msg
410Invalid merchant configurationContact support
411Merchant account inactiveContact support
420Communication error with processorRetry
Reading declines

Use the response_code to drive behavior: retry, pause recurring, or stop permanently. Use the msg field for human-readable logs. Do not show raw processor messages to the cardholder — most are confusing and some imply information you shouldn't share.

AVS response

Address Verification System checks your submitted billing address against what the issuing bank has on file. The avs_response_code field in the response tells you the result.

CodeMeaningRecommended action
MFull match (address + postal code)Proceed
NNo matchElevate fraud risk; consider declining
UUnavailableUse other fraud signals
SNot supported by issuerUse other fraud signals
IAddress not providedConsider requiring billing address

CVV response

CodeMeaningRecommended action
MMatchProceed
NNo matchConsider declining; possible fraud
UNot verifiedUse other fraud signals
SNot supported by issuerUse other fraud signals
ICVV not providedConsider requiring CVV

Partial authorization

When you submitted allow_partial_payment: true and the issuer partially approved the transaction, compare amount_authorized to amount. They will differ. Your integration should either accept the partial amount and collect the rest another way, or void the authorization and prompt for a different payment method.

Correlation ID

Each response carries an x-correlation-id header. This is the one value support asks for first. Log it alongside the rest of the response — especially on failures — and include it when you open a ticket.

3DS response fields

If 3D Secure was used, the response includes the ECI indicator, CAVV, and version fields. See 3D Secure for what each field means.