Versions Compared
Key
- This line was added.
- This line was removed.
- Formatting was changed.
Usage
Excerpt |
---|
Retrieves a token and a URL which allows you to redirect the customer to a form to process a real-time casual payment. |
At the end of the operation, the user will be redirected to the call back URL provided in the request message and the status of the operation will be returned as a URL parameter. The token has a lifespan of 10 minutes. This will mean that the customer needs to access the payment form URL within 10 minutes of the token being issued. The token is for one-time usage. Once the operation has started (link is clicked), it cannot be reused.
Parameters
Name | Data Type | Length | Description | |
---|---|---|---|---|
User | ||||
| String | Required | Provided by Debitsuccess | |
| String | Required | Provided by Debitsuccess | |
ContractPrefix | String | Required | Provided by Debitsuccess | |
Amount | Decimal (10,2) | Required | Amount to pay | |
PaymentNote | String | 30 | Optional | Any notes to be recorded against the payment |
PaymentRef | String | 50 | Optional | PaymentRef if provided must be unique at ContractPrefix level (i.e. Facility Account level). If PaymentRef provided has already been used before by the same Facility Account, it is rejected. Note: PaymentRef can be re-cycled if the token has expired before being used. |
CallbackURL | String | 256 | Required | The URL the customer needs to be redirected to after the operation |
Response
Name | Data Type | Description | Maximum Length |
---|---|---|---|
DateCreated | DateTime | Date/time message was processed | |
Id | String | Unique ID for the message | |
ResponseNotes () | Collection of validation messages | ||
| String | ||
| String | ||
| Enum | Error, Warning, Info | |
Status | Enum | Failed, Succeed, Unknown | |
Token | String | Auto-generated token | 16 Characters |
WebhookToken | String | Auto-generated webhook token | 16 Characters |
ValidTo | Datetime | Expiry date of the token | |
PaymentFormURL | String | URL where customer can make a payment or update payment details. It will have the token appended |
Webhook URL
For each facility, you can provide a Webhook URL which, after approval, we will store in our database. We will post the transaction details to this Webhook URL once as a JSON object. The transaction details are the same as what we send back for CallbackURL - the WebhookToken, PaymentFormToken, Status, Message, ResponseCode.
We recommend that you store the WebhookToken we provide in the response securely to authenticate the information received through the WebhookURL is from Debitsuccess.
Info | ||
---|---|---|
| ||
The webhook URL must be registered in the facility.CasualPaynowWebHookUrl column |
When a customer is redirected to the call back URL, the following response fields will be appended in the URL:
Scenario | Response Fields | Status Description | Example |
---|---|---|---|
Payment declined | Token, Status, Message | Declined | http://www.debitsuccess.com/?Status=Declined&Token=QyqqjL0G&Message=DO%20NOT%20HONOUR |
Payment successful | Token, Status, Message (blank) | Success | http://www.debitsuccess.com/?Status=Success&Token=TGhZfWjb&Message= |
Payment failed | Error | http://www.debitsuccess.com/?Status=Error&Token=TGhZfWjb&Message= | |
Contract Prefix validation field | ContractPrefixInvalid | http://www.debitsuccess.com/?Status=ContractPrefixInvalid&Token=TGhZfWjb&Message= | |
Load of payment details successful | Success | http://www.debitsuccess.com/?Status=Success&Token=TGhZfWjb&Message= | |
Load of payment details failed | Failure | http://www.debitsuccess.com/?Status=Failure&Token=TGhZfWjb&Message= | |
Token expired | Token, Status, Message (blank) | TokenExpired | http://www.debitsuccess.com/?Status=TokenExpired&Token=TGhZfWjb&Message= |
Error Messages
Type | Error Code | Error Message |
---|---|---|
Error | 02 | Invalid user credentials |
Error | 13001 | Invalid Contract Prefix |
Error | 13151 | Multiple contracts found for given contract prefix |
Error | 14119 | Cannot find commission details configured for this business. Please contact Debitsuccess. |
Error | 14039 | Missing required CallBackUrl. |
Error | 14043 | Invalid CallBackUrl - Ensure URL is correctly formatted. Example: https://www.debitsuccess.com |
Error | 14040 | CallBackUrl cannot exceed 256 characters |
Error | 14042 | PaymentNote cannot exceed 30 characters. |
Error | 14116 | PaymentRef cannot exceed 50 characters. |
Error | 14118 | The Amount provided is more than the maximum amount allowed for this contract prefix. Please ensure amount is between {0} and {1} |
Error | 14117 | The Amount provided is less than the minimum amount allowed for this contract prefix. Please ensure amount is between {0} and {1} |
Info | 00 | Success |
Error | 13060 | Transaction identifier is not unique |
Related Pages
Filter by label (Content by label) | ||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|