Loading...
To voida loan sale, program the POS to send a PUT request to the relevant endpoint.
| Scenario | Merchant uses the POS to: |
|---|---|
| Customer wants to return an item that they used a loan to pay for. | Void the loan sale. |
The endpoint you use depends on whether you identify the loan sale using the loansale_id or the reference_id.
Using a loansale_id
| Environment | HTTP Method | URL |
|---|---|---|
| Test | PUT | https://api.pit.paygateway.com/transactions/loansales/{loansale_id}/voids |
| Production | PUT | https://api.paygateway.com/transactions/loansales/{loansale_id}/voids |
Using a reference_id
| Object | Field | Type | Description |
|---|---|---|---|
| N/A | loansale_id | String | Unique identifier that our gateway generated for the loan sale. Note: This is the loansale_id that you can include in the endpoint URL for follow-on transactions. |
| N/A | status | String | Indicates the status of the loan sale. The value is voided. |
| N/A | processor_response | String | Response from the processor that describes the status of the loan sale. |
| N/A | reference_id | String | Unique identifier that the merchant created for the loan sale. Note: This is the reference_id that you can include in the endpoint URL for follow-on transactions. |
| payment | amount | String | Total loan amount that is voided. |
| currency_code | String | ISO currency code for the loan sale. For a list of possible values, see the currency code enumeration | |
| invoice_number | String | Alphanumeric invoice number or order number that the merchant created and assigned to the loan sale. | |
| type | String | Type of payment for the loan sale. The value is loan. | |
| transaction | country_code | String | Code that represents the country where the loan sale originated. For a list of possible values, see the country code enumeration |
| language | String | Language for the text that is displayed on your payment page and the merchant's receipts. For a list of possible values, see the language enumeration. | |
| links | loansale_id | Object | Object that includes HATEOAS links for follow-on transactions using the loansale_id. For a list of fields, see the loansale_id object. |
| reference_id | Object | Object that includes HATEOAS links for follow-on transactions using the reference_id. For a list of fields, see the reference_id object. |
loansale_id object
| Field | Type | Description |
|---|---|---|
| href | String | Endpoint URL for follow-on transactions using the loansale_id. |
| relation | String | Relationship between the endpoint you sent the original request to and the endpoint for the follow-on transaction. The value is one of the following:• return - The transaction uses the returns endpoint.• self - The transaction uses the same type of endpoint as the original request.• void - The transaction uses the void endpoint. |
| method | String | HTTP method for sending the request. The value is one of the following:• GET• PATCH• POST• PUT |
| description | String | Text that describes how to use the endpoint URL our gateway provided in the href field. For example, Use this endpoint to retrieve a previous loan sale transaction using a loansale_id. |
reference_id object
| Field | Type | Description |
|---|---|---|
| href | String | Endpoint URL for follow-on transactions using the reference_id. |
| relation | String | Relationship between the endpoint you sent the original request to and the endpoint for the follow-on transaction. The value is one of the following:• return - The transaction uses the returns endpoint.• self - The transaction uses the same type of endpoint as the original request.• void - The transaction uses the void endpoint. |
| method | String | HTTP method for sending the request. The value is one of the following:• GET• PATCH• POST• PUT |
| description | String | Text that describes how to use the endpoint URL our gateway provided in the href field. For example, Use this endpoint to retrieve a previous loan sale transaction using a reference_id. |