v12

latestOpenAPI 3.1.0AGPL-3.0raw.githubusercontent.com2026-08-0464108237.1 KB
Score Feedback

Update gateway score

Feed a transaction outcome back into the success-rate model. Call this after every transaction so the engine has accurate SR data for future routing decisions.

A CHARGED status increases the gateway's SR; failure statuses (AUTHENTICATION_FAILED, AUTHORIZATION_FAILED, etc.) decrease it.

post/update-gateway-score

Request body

merchantIdstring required
gatewaystring required
paymentIdstring required
status'STARTED' | 'AUTHENTICATION_FAILED' | 'JUSPAY_DECLINED' | 'PENDING_VBV' | 'VBV_SUCCESSFUL' | 'AUTHORIZED' | 'AUTHORIZATION_FAILED' | 'CHARGED' | 'AUTHORIZING' | 'COD_INITIATED' | 'VOIDED' | 'VOID_INITIATED' | 'NOP' | 'CAPTURE_INITIATED' | 'CAPTURE_FAILED' | 'VOID_FAILED' | 'AUTO_REFUNDED' | 'PARTIAL_CHARGED' | 'TO_BE_CHARGED' | 'PENDING' | 'FAILURE' | 'DECLINED' required

Transaction status. Must be a TxnStatus value - lowercase values such as success are rejected.

gatewayReferenceIdstring nullable
enforceDynamicRoutingFailureboolean nullable
errorInfoobject nullable

Gateway error details for the GSM-based scoring filter. When present and the merchant flag is on, user/issuer-originated failures are skipped so the gateway is not penalised.

isSmartRetryboolean nullable

Set by the orchestrator when this call is a smart-retry attempt.

Example request

{
  "merchantId": "merchant_demo",
  "gateway": "stripe",
  "paymentId": "pay_sr_001",
  "status": "CHARGED",
  "gatewayReferenceId": "stripe_ref_001",
  "txnLatency": {
    "gatewayLatency": 120.5
  }
}

Response

Score updated

messagestring
merchant_idstring
gatewaystring
payment_idstring
gsm_infoobject nullable

GSM lookup result. Present only when errorInfo was supplied and a matching rule was found.