RecordPayment
The RecordPayment web service
XML- or JSON-based information exchange systems that use the Internet for direct application-to-application interaction. These systems can include programs, objects, messages, or documents. allows an external system to record details of one-off card payments taken via a TPPI in CMP
Converged Monetisation Platform. The MDS Global product that supports customer care and billing for digital service providers..
If the payment completed successfully, the successful payment element can be included in the request to supply the payment provider's authorisation code.
RecordPayment Request
The RecordPayment tag instructs the Payment Service to record a card payment. This request contains the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
ExternalReference |
String69 |
Used by a client application to correlate request and response. |
Optional |
|
PaymentDetails |
Container |
Contains one or more Payment. See PaymentDetails Request Container for details. |
Mandatory |
|
PaymentOutcome |
Container |
Choice of:
|
Mandatory |
|
AuditRecord |
Container |
See AuditRecord Request Container for details. |
Optional |
PaymentDetails Request Container
The PaymentDetails request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
AccountNumber |
Integer8 |
The unique system generated reference number for the account. |
Mandatory |
|
TransactionReference |
String20 |
This is used to store the Transaction Reference of the payment. |
Optional |
|
PaymentReference |
String40 |
Third Party payment reference, normally this is set with the payment reference returned from the payment provider. |
Optional |
|
CardReference |
String30 |
The tokenised string representing the card. |
Optional |
|
TransactionDateTime |
dateTime |
Transaction date. Defaults to current date/time. |
Mandatory |
|
Amount |
Decimal9,2 |
Payment amount. |
Mandatory |
|
CurrencyCode |
String3 |
ISO 4217 Currency code (e.g. GBP, EUR, USD) |
Mandatory |
|
PaymentType |
String6 |
Indicates nature of payment e.g. credit card, direct debit, cheque. |
Mandatory |
|
CardNumber |
String20 |
The final 4 digits of the number of the credit card used to make the payment. |
Optional |
|
StartDate |
Container |
See StartDate Container for details. |
Optional |
|
ExpiryDate |
Container |
See ExpiryDate Container for details. |
Optional |
|
NameOnCard |
String20 |
Cardholder Name. |
Optional |
|
AVSHouseStreetNumber |
String25 |
The Address of the payment cardholder. |
Optional |
|
PostCode |
String10 |
Postcode of the payment cardholder. |
Optional |
|
CountryCode |
String2 |
The Number Code for the country where the payment cardholder resides. |
Optional |
|
ReasonCode |
String4 |
Reason Codes are four-character reason identifiers which are used in conjunction with Reason Types for the initiation of any workflow within CMP. |
Optional |
|
ProductService |
String30 |
This allows the payment description to be captured. |
Optional |
StartDate Request Container
The StartDate request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
Month |
String6 |
Valid Month Start Date on the card. MM |
Mandatory |
|
Year |
Integer2 |
Valid Year Start Date on the card. YY |
Mandatory |
ExpiryDate Request Container
The ExpiryDate request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
Month |
String6 |
Valid Month Start Date on the card. MM |
Mandatory |
|
Year |
Integer2 |
Valid Year Start Date on the card. YY |
Mandatory |
PaymentOutcome Request Container
The PaymentOutcome response container contains a choice of the following two elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
SuccessfulPayment |
Container |
See SuccessfulPayment request container for details. |
Optional |
|
FailedPayment |
Container |
See FailedPayment request container for details. |
Optional |
SuccessfulPayment
The SuccessfulPayment request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
AuthorisationCode |
String6 |
Obtained by the client application from the payment provider to indicate the payment was approved. |
Optional |
|
Status |
String25 |
Currently only CAPTURED is accepted. |
Mandatory |
FailedPayment
The FailedPayment request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
ErrorCode |
String50 |
The error code returned by the payment provider if the payment failed. |
Optional |
|
ErrorDescription |
String60 |
If the payment failed, a description of the error can be supplied in this element. |
Optional |
AuditRecord Request Container
The AuditRecord request container has the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
UserID |
String10 |
User ID associated with the profile. This is the ID which the calling program adds to the records that are created. |
Mandatory |
|
Program |
String10 |
The Program Name should be hard coded in the calling application to uniquely identify that application. |
Mandatory |
Sample RecordPayment Request
RecordCardPayment Response
The RecordPayment response is the response to the Record Payment Request. This contains the following elements:
|
Element Name |
Content Type |
Description |
Required? |
|---|---|---|---|
|
ExternalReference |
String69 |
Returned unmodified in the response. The client may use this identifier to correlate the request and the response. |
Optional |
|
TransactionReference |
String20 |
If this is not supplied then a unique transaction reference is created. This must be a unique value. It is recommended to leave this field blank unless specifically advised to populate it. |
Optional |