Testing with Postman

Testing with Postman



Postman collection

Postman collection and preconfigured environment can be downloaded from the following link: Installment Loans Postman Collection

📘

INFO:

After testing has been completed successfully, please send one COMPLETE and one CANCELED order sessionId by email to [email protected] to check on our side also.

🚧

NOTE:

In the service body, the Id field of the JSON object will always return a null value. Status code 200 is enough to identify success. Please ignore the data in the body.

Instruction

  1. Add you apiKey, apiSecret and merchantKey to the Postman configuration environment:
901

Configure environment

  1. To get your access token (Request Access Token) call /oauth/token endpoint (necessary parameters will be filled automatically).
899

Get access token

📘

Received access_token is required to perform the next steps. This parameter will be automatically saved in the configuration.

  1. To Initiate the application, use /v1/online-installments/applications endpoint.
    Fill the parameters in the body and add your merchantKey value:
913

Initiate application

  1. In the response body you will see the sessionId:
832

Get sessionId

📘

session_id is needed to cancel or confirm the order

To Cancel the order use

/v1/online-installments/applications/{{session-id}}/cancel

1462

Cancel order

To Confirm the order use

/v1/online-installments/applications/{{session-id}}/confirm

1034

Confirm order

  1. In the Location Header you will receive an address to which you must redirect the user to fill out the installment application:
1145

callback URL

Here you can find some request examples:


Example of successful request, status code: 200 OK

  • Successful request
1482

200 OK

📘

In the service body, the Id field of the JSON object will always return a null value. Status code 200 is enough to identify success. Please ignore the data in the body.

Example of successful request, status code: 201

Body:

1501

Status Code: 201

Redirect URL is in Headers > Location:

1504

Redirect URL

Example of rejected request, status code: 404 Not Found

  • Merchant was not found - if your MerchantKey is incorrect or was not found
1474

Merchant was not found

  • Merchant is deactivated
1479

Merchant is deactivated

Example of rejected request, status code: 400 Bad Request

  • FullPriceInCoins is missing - if priceTotal is not provided
1492

FullPriceInCoins is missing

  • FullPriceInCoins is invalid. Value must be greater than zero.
1489

FullPriceInCoins is invalid

  • Product(s) was not specified
1493

Product(s) was not specified

  • Product price is missing
1481

Product price is missing

  • Product quantity is missing
1480

Product quantity is missing

  • Product quantity is invalid. Value must be 1 or more.
1481

Product quantity is invalid.

  • Product price and full prices does not match.
1476

Product price and full prices does not match.

Example of rejected request, status code: 401 Unauthorized

  • Active installment with sesseionId not exists
1485

Active installment with sesseionId not exists

  • Cannot confirm installment. Expired confirmation date.
1492

Cannot confirm installment. Expired confirmation date.