Skip to main content

Customer Decisions Schemas

API endpoints for monitoring customer authorization decisions and billing permissions.

Endpoints

MethodEndpointDescription
GET/v1/merchant/customer-decisionsGet customer decisions with filters
GET/v1/customer-decisions/:idGet specific customer decision by ID

GET /v1/merchant/customer-decisions

Retrieve customer decisions with optional filtering parameters.

Query Parameters

ParameterTypeRequiredDescription
agreementPhrasestringNoFilter by agreement phrase
customerIdstringNoFilter by customer ID
lookupPhrasestringNoFilter by lookup phrase
limitnumberNoNumber of results to return
skipnumberNoNumber of results to skip

Response Schema

{
  "statusCode": 200,
  "success": true,
  "data": [
    {
      "id": "string",
      "customerId": "string",
      "entityId": "string",
      "agreementPhrase": "string",
      "decision": "approve_once | approve_recurring | deny | suspended",
      "spendingLimits": {
        "single": 5000,
        "daily": 8000,
        "weekly": 20000,
        "monthly": 60000
      },
      "blockMerchant": false,
      "createdAt": "string",
      "lastUsed": "string"
    }
  ],
  "total": 1
}

Customer Decision Schema

FieldTypeDescription
idstringDecision identifier
customerIdstringCustomer identifier
entityIdstringMerchant identifier
agreementPhrasestringEncrypted agreement phrase
decisionstringCustomer decision type
spendingLimitsobjectCustomer spending limits
spendingLimits.singlenumberSingle transaction limit
spendingLimits.dailynumberDaily spending limit
spendingLimits.weeklynumberWeekly spending limit
spendingLimits.monthlynumberMonthly spending limit
blockMerchantbooleanWhether merchant is blocked
createdAtstringDecision creation timestamp
lastUsedstringLast usage timestamp

GET /v1/customer-decisions/:id

Get detailed information about a specific customer decision.

Path Parameters

ParameterTypeRequiredDescription
idstringYesCustomer decision ID

Response Schema

{
  "statusCode": 200,
  "success": true,
  "data": {
    "id": "string",
    "customerId": "string",
    "entityId": "string",
    "agreementPhrase": "string",
    "lookupPhrase": "string",
    "decision": "approve_once | approve_recurring | deny | suspended",
    "spendingLimits": {
      "single": 5000,
      "daily": 8000,
      "weekly": 20000,
      "monthly": 60000
    },
    "blockMerchant": false,
    "createdAt": "string",
    "lastUpdated": "string",
    "lastUsed": "string"
  }
}

Decision Types

DecisionDescription
approve_onceCustomer approves each transaction individually
approve_recurringAutomatic approval for future transactions
denyCustomer declined billing agreement
suspendedDecision is temporarily suspended

Error Responses

404 Not Found

{
  "statusCode": 404,
  "success": false,
  "message": "Customer decision not found"
}

400 Bad Request

{
  "statusCode": 400,
  "success": false,
  "message": "Invalid query parameters"
}