Hosted Payments Page

Create a Hosted Payments Page session #

Create a Hosted Payments Page session and pass through all the payment information, like the amount, currency, country and reference.

Authorizations

bearer

#
HTTP: bearer #

HTTP Authorization Scheme: bearer

Bearer format: JWT

header Parameters #
AuthorizationrequiredstringBearer token (API Key).
Request Body schema: application/json #

Request body for creating a Hosted Payments Page session.

currencyrequiredstring = 3 characters The three-letter ISO currency code of the payment.
billingrequiredobjectThe billing details.
success_urlrequiredstring <= 255 characters Overrides the default success redirect URL for redirect payment methods.
cancel_urlrequiredstring <= 255 characters The URL to which the customer should be directed if they cancel the payment.
failure_urlrequiredstring <= 255 characters Overrides the default failure redirect URL for redirect payment methods.
amountnumber >= 0 The payment amount. The exact format depends on the currency.
payment_typestring Default: “Regular” Enum:”Regular””Recurring”This must be specified for card payments where the cardholder is not present.
payment_ipstring <= 45 characters The customer’s IP address. Only IPv4 and IPv6 addresses are accepted.
billing_descriptorobjectAn optional description that is displayed on the customer’s statement identifying a purchase.
referencestring <= 50 characters A reference you can use to identify the payment (max 50 chars, Amex: 30, iDEAL: 35, Benefit: unique alphanumeric).
descriptionstring <= 100 characters A description of the payment (max 100 chars).
display_namestringThe merchant name to display to customers on the checkout page.
processing_channel_idstring^(pc)_(\w{26})$The processing channel to be used for the payment.
amount_allocationsArray of objectsThe sub-entities that the payment is being processed on behalf of.
customerobjectThe customer’s details.
shippingobjectThe address any products are being sent to.
recipientobjectInformation about the recipient of the payment’s funds.
processingobjectUse the processing object to influence or override the data sent during card processing.
allow_payment_methodsArray of stringsSpecifies which payment method options to present to the customer.
disabled_payment_methodsArray of stringsSpecifies which payment method options to not present to the customer.
productsArray of objectsContains details about the products in the order.
riskobjectConfigures the risk assessment performed during payment processing.
customer_retryobjectConfigures the parameters for customer retries.
senderobjectThe sender of the payment.
metadataobjectAllows you to store additional information about the transaction. Only one level of depth is allowed.
localestring Default: “en-GB”Creates a translated version of the page in the specified language.
3dsobjectInformation required for 3D Secure payments.
capturebooleanWhether to capture the payment (if applicable).
capture_onstringA timestamp (ISO 8601 code) that determines when the payment should be captured. Providing this field will automatically set capture to true.
instructionobjectDetails about the payment instruction.
payment_method_configurationobjectConfiguration options for specific payment methods.
Responses #
201 Created Hosted Payments Page
Response Schema: application/json #
idrequiredstringThe unique identifier for a Hosted Payments Page.
_linksrequiredobjectThe links related to the hosted payment.
referencerequiredstringA reference you can later use to identify this payment, such as an order number.
warningsArray of objectsWarnings related to the allow_payment_methods object in the request.

401 Unauthorized

422 Invalid data was sent.
Response Schema: application/json #
request_idrequiredstringThe unique request identifier.
error_typerequiredstringThe error type.
error_codesrequiredArray of stringsThe error codes.

#

Get Hosted Payments Page details #

Retrieve details about a specific Hosted Payments Page using the ID returned when it was created. In the response, you will see the status of the Hosted Payments Page.

Authorizations

bearer

#
HTTP: bearer #

HTTP Authorization Scheme: bearer

Bearer format: JWT

path Parameters #
idrequiredstring = 16 characters ^hpp_[A-Za-z0-9_-]{12}$The unique identifier for a Hosted Payments Page.
header Parameters #
Authorization requiredstring
Responses #
200 Hosted Payments Page details retrieved successfully
Response Schema: application/json #
idrequiredstringThe unique identifier for a Hosted Payments Page.
statusrequiredstring Enum:”Payment Pending””Payment Received””Expired”The status of the Hosted Payments Page.
amountrequirednumberThe original payment amount.
currencyrequiredstringThe three-letter ISO currency code of the payment.
billingrequiredobjectThe billing details.
success_urlrequiredstringThe provided URL your customer will be redirected to upon a successful payment.
cancel_urlrequiredstringThe provided URL your customer will be redirected to if the payment is cancelled.
failure_urlrequiredstringThe provided URL your customer will be redirected to upon a failed payment.
_linksrequiredobjectThe links related to the Hosted Payments Page.
payment_idstringUnique identifier for an in progress or completed payment for this Payment Link.
referencestringYour reference for the payment.
descriptionstringA description of the payment.
customerobjectThe customer’s details.
productsArray of objectsContains details about the products in the order.
metadataobjectAny additional information stored at the point of creation.
amount_allocationsArray of objectsThe sub-entities that the payment is being processed on behalf of.

401 Unauthorized

404 Hosted Payments Page not found
Response Schema: application/json #
request_id requiredstringThe unique request identifier.
error_type requiredstringThe error type.
error_codes requiredArray of stringsThe error codes.

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to Top