Skip to main content
Migo Docs

QuickPay QR — El Salvador, Honduras and Costa Rica

QuickPay QR is the only rail wired on the alternative-payments /payments endpoint for these three countries. The integration is identical in all three — only the phone prefix and the merchant currency change. (In Guatemala the same rail runs alongside others; see Guatemala.)

CountryE.164 prefixCurrency
El Salvador+503USD
Honduras+504HNL
Costa Rica+506CRC

Setup​

Set these variables in your shell before running any curl. The host (sb-mw.migopayments.com) and the path (/api/v1/integrations/...) are the public sandbox reachable by external integrators. The Alternative Payments routes accept the 64-char merchant token as a Bearer token.

export MIGO_BASE="https://sb-mw.migopayments.com"
export MIGO_CLIENT="<your-client-slug>"
export MIGO_TOKEN="<your-64-char-merchant-token>" # 64 hex chars
export MIGO_USER_ID="+50600000000" # use your country's prefix

export UID=$(
curl -s -X POST "$MIGO_BASE/api/v1/integrations/transactions" \
-H "Authorization: Bearer $MIGO_TOKEN" \
-H "Content-Type: application/json" \
-d "{
\"amount\": 250000,
\"channel\": \"web\",
\"client\": \"$MIGO_CLIENT\",
\"userId\": \"$MIGO_USER_ID\",
\"customKeys\": { \"orderId\": \"recipe-test\" }
}" | jq -r '.data.uid'
)

Inspect the returned paymentMethods to confirm which rails your client has enabled; they are resolved at runtime from clientConfig.processors.

Process the payment (quickPayQR)​

Interbank QR aggregator. It needs no pre-call to payment-intents and returns a json payload.

curl -X POST "$MIGO_BASE/api/v1/integrations/transactions/$UID/payments" \
-H "Authorization: Bearer $MIGO_TOKEN" \
-H "Content-Type: application/json" \
-d '{ "processor": "quickPayQR", "data": {} }'

The response type and data come straight from the processor's paymentRequest:

{
"success": true,
"message": "Success",
"data": {
"transaction_id": "…",
"type": "<paymentRequest.type>",
"data": "<paymentRequest.data>",
"cancelAt": null
}
}

Render the QR payload from data.data. The payment status arrives later through the merchant callback configured in clientConfig.callback — see Merchant Generic Callback.

quickPayQR supports revert via POST $MIGO_BASE/revert with body {"transactionUid":"$UID","processor":"quickPayQR"}. That surface uses the JWT-Bearer scheme, separate from the merchant token used here.

Errors​

The alternative-payments middleware returns 4-digit codes in error.code, not the ALI Gateway 7xxx catalog:

HTTPerror.codeWhen
4005000Missing or invalid params (amount, channel, client, userId, customKeys, processor)
400—processor not allowed for this client
4005004Client config not found
4002002Transaction create failed
4002003Amount outside the allowed range

See the Error catalog for the full description of each code.