📨Payment message

Methods described on this page:

  • POST /create_payment_message

  • GET /payment_message_status

After the client confirms payment, the bank sends a request to the DCM platform in JWT format using the POST/payment_message method to create a Payment Message.

POST/create_payment_message

Endpoint: POST/api/v1/p2p/payment-messages Request format:

Payload:

{ 
  "jti": "T12fa2213", 
  "payment_message_external_id": "112663", 
  "amount": 5, 
  "currency": "UAH", 
  "debtor_agent_bic": "306500", 
  "debtor": {
  "debtor_name": "encrypted value", (encrypted data)
  "debtor_id": "encrypted value", (encrypted data)
  "debtor_account": "UA761372924114433543273694797",
  "debtor_phone": "+380661234567" 
}, 
  "creditor_agent_bic": "380816", 
  "creditor": { 
    "creditor_name": "encrypted value", (encrypted data)
    "creditor_id": "encrypted value", (encrypted data)
    "creditor_account": "UA761372924114433543273694797",
    },
  "order_id": "bb95a18f-bd52-46ae-bb1e-0e6f42bf48f5", 
  "purpose": "Tesgtft777", 
  "msg_creation_date": "2023-12-10", 
  "msg_creation_time": "14:30:12", 
  "pm_type": "р2р", (enum: trade/ p2p/ return/ aid)
  "sender_account_type": "limit-related"
  "encryption": { 
      "nonce": "A1B2C3D4E5F6G7H8", 
      "encrypted_key": "a1b2c3d4e5f6g7h8i9j0" 
    } 
}
 

Response 200: plain text JWT token

Payload

The DCM platform allows retrieving information about the status of a payment message using the GET /payment_message_status request.

GET/payment_message_status

Endpoint: GET /api/v1/p2p/payment-messages/:guid

Response 2хх OK plain text JWT token

Payload

Response 4хх ERROR

Error list:

Code 400:

  • "INVALID_PAYMENT_MESSAGE_GUID"

Code 401:

  • "AUTHORIZATION_FAILED"

Code 404:

  • "PAYMENT_MESSAGE_NOT_FOUND"

Code 500:

  • "INTERNAL_ERROR"

Last updated