POST CompleteSecurePayment by context, contextId

Overview

Request

POST /[context]/[contextId]/CompleteSecurePayment

Request Information

Request Parameters

Name
Type
Requirement
Description
context
String
Mandatory
Context in Request URI should be 'bookings' or 'customers'
contextId
Integer
Mandatory
ContextId in Request URI should be Booking ID or Customer ID
paymentDetails
IEnumerable`1
Mandatory
Response from the POST request received on the RedirectUrl. Mapped to a list of key, value pairs.
paymentData
String
Mandatory
The paymentData value that you received in the original payment response.
paymentProcessAuditId
Integer
Mandatory
The paymentPaymentProcessAuditId value that you received in the original payment response.

Request Example

{
  "paymentDetails": "[{ \"key\": \"MD\", \"value\": \"Ab02b4c0!BQABAgCW5sxB4e/==..\"}, { \"key\": \"PaRes\", \"value\": \"eNrNV0mTo7gS..\" }]",
  "paymentData": "Ab02b4c0!BQABAgCJN1wRZuGJmq8dMncmypvknj9s7l5Tj...",
  "paymentProcessAuditId": "42"
}

Response Information

Response Properties

Name
Type
Description
paymentReference
String
PaymentReference
isSuccessfulPayment
Boolean
Is Successful Payment
amountPaid
Decimal
Amount Paid
currencyCode
String
Currency code
transactionDate
String
Transaction date
errorCode
String
Error Code
message
String
Message
paymentId
String
Payment Id
paymentProcessAuditId
String
Payment Process Audit Id
actionRequired
String
Action Required. Sent if payment is Adyen. "Redirect" if redirect is required, "None" if not.
redirectRequest
RedirectRequest
Redirect Request. The object that is sent if "actionRequired" is "Redirect". Should be passed to the Adyen component as per their documentation.
bookingId
Integer
Txn Id

Redirectrequest

Name
Type
Description
data
IEnumerable`1
Redirect Request data

Response Codes

HTTP status code
Description
200 OK
The resource was updated successfully
201 Created
The resource was created
400 Bad Request
The resource was malformed
401 Unauthorized
Missing or invalid API key
500 Internal Server Error
An unexpected error occurred on the API server
202 Accepted
The request was accepted
404 Not Found
The specified resource was not found
403 Forbidden
One or more parameters has already been set on the resource record and cannot be updated

Response Example

{
  "paymentReference": "4357886618",
  "isSuccessfulPayment": true,
  "amountPaid": 2500.0,
  "currencyCode": "USD",
  "transactionDate": "2019-01-29 21:50:15",
  "errorCode": "22053",
  "message": "Transaction accepted",
  "paymentId": "1379227",
  "paymentProcessAuditId": "369100",
  "actionRequired": "Redirect",
  "redirectRequest": {
    "data": "[{ \"key\": \"MD\", \"value\": \"Ab02b4c0!BQABAgCW5sxB4e/==..\"}, { \"key\": \"PaReq\", \"value\": \"eNrNV0mTo7gS..\" }]"
  },
  "bookingId": "6174439"
}