Create Session for Reservation
With the Create Session for Reservation API, developers can transform reservations into fully functional payment sessions, delivering ready-to-use checkout links for customers.
What you’ll accomplish:
- Export a reservation from your system to Front Payment Go.
- Receive a checkout URL to redirect customers for payment.
- Define payment parameters—due dates, notification preferences, callback URLs, and more.
Why this matters:
- Efficiency: A unified API call handles reservation, payment method, and session creation.
- Consistency: Use existing reservation data rather than re-entering details.
- Control & Feedback: Capture status events—Reserved, Captured, Charged—via callbacks to maintain end-to-end visibility.
From here, you’ll find the endpoint details, request/response examples, validation rules, and all the settings to configure checkout sessions to your needs.
Step 1: Submit Reservation
Third-party systems can create a reservation and generate a payment link by calling the following endpoint.
Endpoint:
POST https://demo-api.frontpayment.no/api/v1/connect/reservations/create
Authentication
Include a Bearer Token in the Authorization
header. You can obtain this token from Front Payment.
Example:
Authorization: Bearer YOUR_FRONTPAYMENT_BEARER_TOKEN
Request Payload Example
{
"customerDetails": {
"type": "private",
"countryCode": "+47",
"msisdn": "46567468",
"email": "[email protected]",
"name": "Nafees",
"preferredLanguage": "en",
"personalNumber": null,
"organizationId": null,
"address": {
"street": "Dhaka",
"zip": "3500",
"city": "Cumilla",
"country": "NO"
}
},
"orderDate": "20 Aug, 2024",
"dueDateForPaymentLink": "1724294524",
"referenceNo": null,
"customerReference": null,
"sendOrderBy": {
"sms": false,
"email": false
},
"products": {
"0": {
"name": "Test",
"productId": null,
"rate": 1000,
"tax": "0",
"amount": 1000
}
},
"orderSummary": {
"subTotal": 1000.00,
"totalTax": 0,
"grandTotal": 1000.00
},
"chargeValidity": "55",
"customerNotes": null,
"tnc": null,
"submitPayment": {
"via": "visa"
},
"callback": {
"callbackUrl": "https://wp.frontpayment.no/?order_identifier=rRbl1FWZG59o&order_status=success",
"success": "https://wp.frontpayment.no/?order_identifier=rRbl1FWZG59o&order_status=success",
"failure": "https://frontpayment.no/?order_identifier=rRbl1FWZG59o&order_status=failed"
},
"settings": {
"secureDetails": false,
"isChargePartiallyRefundable": true
}
}
Validation Rules
Field | Type | Description |
---|---|---|
customerDetails.type | string | Required. Customer type (private or corporate). |
customerDetails.countryCode | string | Required. Country dialing code (e.g., +47). |
customerDetails.msisdn | string | Required. Mobile phone number without country code. |
customerDetails.email | email | Required. Valid customer email address. |
customerDetails.name | string | Required. Full name of the customer. |
customerDetails.preferredLanguage | string | Required. Preferred language (e.g., en, no). |
customerDetails.personalNumber | string | Optional. Must be exactly 11 digits if provided. |
customerDetails.organizationId | string | Required if type=corporate . Alphanumeric only. |
customerDetails.address | array | Required. Customer address details. |
customerDetails.address.street | string | Required. Street name. |
customerDetails.address.zip | string | Required. Postal code. |
customerDetails.address.city | string | Required. City name. |
customerDetails.address.country | string | Required. Country code (ISO). |
orderDate | string | Required. Order date (validated by custom rule). |
dueDateForPaymentLink | string | Required. Timestamp for payment link validity. |
referenceNo | string | Optional. Reference number. |
customerReference | string | Optional. Customer reference ID. |
sendOrderBy | array | Required. Notification preferences. |
sendOrderBy.sms | boolean | Required. Whether to send order by SMS. |
sendOrderBy.email | boolean | Required. Whether to send order by email. |
products | array | Required. List of product items. |
products.*.name | string | Required. Product name. |
products.*.productId | string | Optional. Product identifier (max: 25 chars). |
products.*.rate | numeric | Required. Product rate. |
products.*.tax | numeric | Required. Product tax. |
products.*.amount | numeric | Required. Total product amount. |
orderSummary.subTotal | numeric | Required. Order subtotal. |
orderSummary.totalTax | numeric | Required. Total tax. |
orderSummary.grandTotal | numeric | Required. Grand total amount. |
customerNotes | string | Optional. Notes from customer. |
tnc | string | Optional. Terms and conditions. |
chargeValidity | string | Optional. Validity in minutes (digits only). |
submitPayment | array | Required. Payment submission details. |
submitPayment.via | string | Required. Payment method (visa , mastercard ). |
callback | array | Optional. Callback URLs. |
callback.callbackUrl | url | Optional. General callback URL. |
callback.success | url | Optional. Success redirect URL. |
callback.failure | url | Optional. Failure redirect URL. |
settings | array | Optional. Additional settings. |
settings.secureDetails | boolean | Optional. Whether secure details are enabled. |
settings.isChargePartiallyRefundable | boolean | Optional. Whether partial refunds are allowed. |
Example Success Response
{
"status_code": 201,
"status_message": "OK",
"message": "Reservation Submitted Successfully",
"is_data": true,
"data": {
"customerUuid": "CSRT3463048878",
"reservationUuid": "RES4161996022",
"paymentUrl": "https://v1.checkout.bambora.com/aa7ec3f47b0d45b286bcc595ab0d9613"
}
}
Step 2: Payment Process
-
From the success response in Step 1, the user is redirected to the
paymentUrl
. -
The preselected payment method (
visa
,mastercard
,visa/dankort
) will be shown, but the user can change it. -
After successful payment:
- The third-party system is notified via the provided
callbackUrl
. - The user is redirected to the
success
orfailure
URL provided in the request payload.
- The third-party system is notified via the provided
Notifications via Callback URL
The callbackUrl
is an endpoint on your server that our system will call via an HTTP GET
request whenever the status of the specified order changes from its initial state. For reservation
the callbackUrl
will be triggered for three status changed: Reserved
, Captured
, Charged
.
See the link below to understand how to work with the callback URL on your side and how to verify the request sent from our side.