PaymentSessionInitializationRequest
Id of the point of sale to associate the payment with.
01924737-9c18-71c0-ab1a-88698eaceabfThis is the transaction reference, similar to an order ID.
The reference SHOULD be unique for each payment, as some acquirers enforce per-payment uniqueness.
Using a duplicate reference may result in failed payments or make reconciliation difficult.
Only ASCII alphanumeric characters and dashes are allowed.
Worldline specific: - is removed if present and if the value is longer than 12 position, the left most part is used.
Possible values: non-empty and <= 36 characters, Value must match regular expression ^[A-Za-z0-9-]{1,36}$
reference-1The amount must be defined in minor units. E.g. 2,50 DKK must be set as 250. If amount is set to 0 a token will be created only and returned to the integrator.
100The currency code of the payment. For Danish Kroner defined as DKK. ISO 4217 alpha-3 (e.g., DKK)
Possible values: Value must match regular expression ^[A-Z]{3}$
DKKIf the payment should be captured instantly or not.
-
OFFindicates that the payment should not be captured instantly. -
VOIDindicates that the payment should be captured instantly and if somehow the instant capture fails the payment is voided. -
NO_VOIDindicates that the payment should be captured instantly and if the capture fails the authorization is kept (no void is made)
Possible values: [OFF, VOID, NO_VOID]
OFFList of processors to use. This is the routing of the payment. The value can be shift4, clearhaus and nets.
Processor priority follows the order in the list. If the first processor fails or declines, the next processor in the list will be attempted, and so on until all processors have been tried. Note that the actual processing order is not guaranteed and may depend on external factors, such as the specific payment card used by the cardholder.
Possible values: [shift4, clearhaus, nets, worldline]
["shift4"]This is the text set on the transaction in the bank viewed by the card holder. That can be e.g. "order 123". Defaults to the ePay transaction id. Some providers does not support long texts, ePay will automatically cut the text to fit the providers requirements.
Possible values: non-empty and <= 39 characters
order 123attributes objectnullable
A list of pass through attributes that is sent back to the merchant on webhooks. Max size is 1kb.
An optional merchant defined customer id used to uniquely identify a user in the merchant system. This field is required to enable stored payment methods and enhanced age verification.
User159customer object
Customer info. These data points are used during SCA/3DS and is required for some schemes. These data may also be sent to the specific payment provider, if required to complete the payment such as Klarna. It is recommended to send all the info that is available to improve the approval rate.
The first name of the paying customer.
Possible values: non-empty
PeterThe last name of the paying customer.
Possible values: non-empty
NielsenThe date of birth of the cardholder in YYYY-MM-DD format.
2000-07-25The email of the paying customer.
Possible values: non-empty
email@example.comE.164 phone number format with a single space between country code and local number. No additional spaces allowed.
Format: "+[countryCode] [number]".
Possible values: Value must match regular expression ^\+\d{1,3} \d+$
+45 12345678shippingAddress objectnullable
The shipping address of the purchase. If no wares are shipped, leave this empty. If billing and shipping address is the same, then fill both properties with identical information.
ISO 3166-1 alpha-2 country code
Possible values: >= 2 characters and <= 2 characters
DKThe local postal code of the address
Possible values: non-empty and <= 16 characters
1400The city
Possible values: non-empty and <= 50 characters
KøbenhavnThe first address line. Most address only has a singular line.
Possible values: non-empty and <= 50 characters
Torvegade 45Second address line. Only use if address contains multiple lines. Always start with line1.
Possible values: non-empty and <= 50 characters
2. th.Third address line. Only use if address contains multiple lines. Always start with line1 and line2.
Possible values: non-empty and <= 50 characters
ChristianshavnbillingAddress objectnullable
The billing address of the customer. Often the personal address of the customer or the business address of paying company. If billing and shipping address is the same, then fill both properties with identical information.
ISO 3166-1 alpha-2 country code
Possible values: >= 2 characters and <= 2 characters
DKThe local postal code of the address
Possible values: non-empty and <= 16 characters
1400The city
Possible values: non-empty and <= 50 characters
KøbenhavnThe first address line. Most address only has a singular line.
Possible values: non-empty and <= 50 characters
Torvegade 45Second address line. Only use if address contains multiple lines. Always start with line1.
Possible values: non-empty and <= 50 characters
2. th.Third address line. Only use if address contains multiple lines. Always start with line1 and line2.
Possible values: non-empty and <= 50 characters
ChristianshavnIf not null then pre-authorization webhook are enabled for all transaction attempts for the session. Max length is 1024.
Possible values: non-empty and <= 1024 characters
https://example.com/preAuthsubscription object
An optional subscription ID can be used to update an existing active subscription with new payment details, such as a new card or a completely different payment method.
An optional amount in minor units (e.g., 1095 = 10.95 DKK) that can be used to differentiate the recurring subscription amount from the current transaction amount. This is useful if customers are not expected to pay today, but must pay a monthly fee going forward - In this case set amount=0 and subscription.amount=XXX. Defaults to the transaction amount if not given.
The type of subscription.
UNSCHEDULEDPay-as-you-go type subscriptions with no fixed interval for charges.SCHEDULEDFixed interval charges like a subscription paid monthly.
Possible values: [UNSCHEDULED, SCHEDULED]
SCHEDULEDAn optional merchant defined reference for the subscription. If none is given, then the session reference will be used as a fallback.
subscription-1An optional field indicating the expiry of the subscription. This date is used during 3DS, and may improve conversion rates. ePay does not reject payments after this date.
interval object
An optional subscription schedule for SCHEDULED type subscriptions. Must be omitted for UNSCHEDULED type subscriptions. Is required by some payment methods such as Vipps Mobilepay. Is used during 3DS - May improve conversion rates.
The period unit between charges
Possible values: [DAY, WEEK, MONTH, YEAR]
The number of period units between each charge. 1-31. Example: Frequency: 3, Period: DAY One charge every 3 days.
The type of transaction to process. Most merchants should use PAYMENT unless they have specific use cases.
PAYMENTis for ordinary purchases and the standard type to use for most merchants.MOTOis short for Mail Order & Telephone Order and is typically used by travel agencies who receive payment info over the phone or email. MOTO is exempt from SCA but requires a special acquirer agreement to use.
Possible values: [PAYMENT, MOTO]
PAYMENTHow 3D secure is handled:
SKIP3DS is not tried and full liability is put at merchant.NORMAL3DS flow is attempted as normal guidelines suggests - Both challenge and frictionless can occur.FORCEA challenge flow is forced. Note: Third parties in the 3DS flow might ignore this instruction.
Possible values: [SKIP, NORMAL, FORCE]
NORMALThe session is valid for the specified number of minutes. If a timeout occurs, the session expires and no more payment attempts are possible.
Possible values: >= 1 and <= 120
120List of exemptions to apply when applicable. Supports [TRA, LVT]. Note: Using exemptions may shift liability for fraud from the issuer to the merchant.
Possible values: [TRA, LVT]
[]The maximum allowed number of payment attempts for the session.
Possible values: >= 1 and <= 25
25If true: Enables webhooks to the notificationUrl for failed transactions. Otherwise only successful transactions are reported.
falseIf true: Enables the cardholder to define the transaction amount. Otherwise, the amount from the session is used for transactions. Can be used in conjunction with pre-auth webhooks to reject transactions with unacceptable amounts. NOTE: This gives client side control over the payment amount. Only use if necessary.. Must be enabled by ePay support.
falseThe URL to where ePay notifies about payment statuses. Max length is 1024.
All URL properties support dynamic templating with session and transaction data, allowing merchants to define URLs that include ePay-generated resource ID's.
This feature can be particularly helpful for some merchants, especially with success and failure URLs, as it simplifies fetching order information upon transaction completion.
Unknown template keys will be rejected during request validation.
${transaction.id}: The primary id of the associated transaction.${transaction.reference}: The merchant supplied reference from session init.${session.id}: The primary id of the associated session.
Possible values: non-empty and <= 1024 characters
https://example.com/notificationThe URL the client is redirected to on a successful payment. Max length is 1024.
Possible values: non-empty and <= 1024 characters
https://example.com/successThe URL the client is redirected to when no more payment attempts are allowed. Max length is 1024.
Possible values: non-empty and <= 1024 characters
https://example.com/failureAn optional URL the client is redirected to when a payment attempt fails but more attempts are still allowed. If the retryUrl is not provided then the client will be redirected to the failureUrl. Max length is 1024.
Possible values: non-empty and <= 1024 characters
https://example.com/retryageVerification object
Specifies age verification requirements for the purchase.
- If not provided or set to null, no age verification will be performed.
- If provided, the customer must verify their age to be at least the value specified in the
minimumAgeproperty. For danish customers this id verified using MitID. Session.minimumAge will be set; transactions may be rejected if age not verified.
Possible values: >= 0 and <= 99
Country code for the delivery country (ISO 3166 alpha-2 country codes). This code determines which electronic ID (eID) is presented to the user (e.g., MitID in Denmark).
Possible values: [DK]
{
"pointOfSaleId": "01924737-9c18-71c0-ab1a-88698eaceabf",
"reference": "reference-1",
"amount": 100,
"currency": "DKK",
"instantCapture": "OFF",
"processor": [
"shift4"
],
"textOnStatement": "order 123",
"attributes": {},
"customerId": "User159",
"customer": {
"firstName": "Peter",
"lastName": "Nielsen",
"birthdate": "2000-07-25",
"email": "email@example.com",
"phoneNumber": "+45 12345678",
"shippingAddress": {
"countryCode": "DK",
"postalCode": "1400",
"city": "København",
"line1": "Torvegade 45",
"line2": "2. th.",
"line3": "Christianshavn"
},
"billingAddress": {
"countryCode": "DK",
"postalCode": "1400",
"city": "København",
"line1": "Torvegade 45",
"line2": "2. th.",
"line3": "Christianshavn"
}
},
"preAuthUrl": "https://example.com/preAuth",
"subscription": {
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"amount": 0,
"type": "SCHEDULED",
"reference": "subscription-1",
"expiryDate": "2024-07-29",
"interval": {
"period": "DAY",
"frequency": 0
}
},
"transactionType": "PAYMENT",
"scaMode": "NORMAL",
"timeout": 120,
"exemptions": [],
"maxAttempts": 25,
"reportFailure": false,
"dynamicAmount": false,
"notificationUrl": "https://example.com/notification",
"successUrl": "https://example.com/success",
"failureUrl": "https://example.com/failure",
"retryUrl": "https://example.com/retry",
"ageVerification": {
"minimumAge": 0,
"country": "DK"
}
}