DengiOnline

2019-03-22 17:33:20

Protected Payments

When transferring funds, the payment can be secured with a protection code. In essence, it is a password required for receiving the transfer.

Payment with protection has the status processing, until:

  • the recipient enters the protection code;
  • the protection period expires.

At present we support payments protection for the following services:

Request Parameters

Apart from the PAY action parameters the request for protected payment should contain the additional tag in the node <params>:

Parameter

Description

Format

Mandatory

protection_period

Maximum protection period (days)

integer

Yes

If protection_period is specified, then the GSG System generates 10-digit protection_code and sends to the Service a set of data includes protection_code and protection_period.

Response Parameters

The GSG System response in XML format, apart from the Pay action parameters, contains the following nodes:

Parameter

Description

Format

protection_code Protection code of the payment string (10)

Partner should transfer protection_code to the recipient independently

Request example (XML)

<request>
    <project>1290</project>
    <timestamp>1360928333</timestamp>
    <action>pay</action>
    <params>
        <paysystem>1000</paysystem>
        <account>R123123123123</account>
        <amount>10.00</amount>
        <protection_period>3</protection_period>
    </params>
</request>

Request example (JSON)

{
  "request": {
    "project": "1290",
    "timestamp": "1360928333",
    "action": "pay",
    "params": {
      "paysystem": "1000",
      "account": "R123123123123",
      "amount": "10.00",
      "protection_period": "3"
    }
  }
}

Response example (success) (XML)

<response>
    <status>1</status>
    <reference>501583</reference>
    <timestamp>1360928334</timestamp>
    <invoice>30876</invoice>
    <income>12.34</income>
    <rate>1</rate>
    <amount>12.34</amount>
    <outcome>12.34</outcome>
    <fee>-0.617</fee>
    <extra>
        <protection_code>12345abcde</protection_code>
    </extra>
</response>

Response example (success) (JSON)

{
  "response": {
    "status": "1",
    "reference": "501583",
    "timestamp": "1360928334",
    "invoice": "30876",
    "income": "12.34",
    "rate": "1",
    "amount": "12.34",
    "outcome": "12.34",
    "fee": "-0.617",
    "extra": { "protection_code": "12345abcde" }
  }
}