Get Order
curl --request GET \
--url https://{apiBaseUrl}/v1/{sessionId}/Order \
--header 'X-API-KEY: <api-key>'const url = 'https://{apiBaseUrl}/v1/{sessionId}/Order';
const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));import requests
url = "https://{apiBaseUrl}/v1/{sessionId}/Order"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{apiBaseUrl}/v1/{sessionId}/Order",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}using RestSharp;
var options = new RestClientOptions("https://{apiBaseUrl}/v1/{sessionId}/Order");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-API-KEY", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.get("https://{apiBaseUrl}/v1/{sessionId}/Order")
.header("X-API-KEY", "<api-key>")
.asString();{
"shopper": {
"firstName": "<string>",
"lastName": "<string>",
"email": "jsmith@example.com",
"countryCode": "<string>",
"address": "<string>",
"postalCode": "<string>",
"city": "<string>",
"phone": "<string>",
"phoneCode": "<string>"
},
"payment": {
"providerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"providerName": "<string>",
"card": {
"type": "<string>",
"holder": "<string>",
"number": "<string>",
"expiry": "2023-11-07T05:31:56Z"
}
},
"amount": {
"amount": 99.99,
"currency": "EUR"
},
"totalAmount": {
"amount": 99.99,
"currency": "EUR"
},
"reference": "<string>",
"creationDateUtc": "2023-11-07T05:31:56Z",
"culture": "<string>",
"id": 123,
"owner": {
"groupId": 123,
"hotelId": 123
},
"items": [
{
"productId": 123,
"code": "<string>",
"name": "<string>",
"description": "<string>",
"usage": "Direct",
"amount": {
"amount": 99.99,
"currency": "EUR"
},
"expiryDateUtc": "2023-11-07T05:31:56Z",
"internalName": "<string>",
"id": 123,
"status": "Active",
"consumedDateUtc": "2023-11-07T05:31:56Z",
"consumedDate": "2023-11-07T05:31:56Z",
"expiryDate": "2023-11-07T05:31:56Z",
"hotelId": 123,
"comment": "<string>",
"sendTo": "Shopper",
"hidePrice": true,
"taxes": [
{
"name": "<string>",
"calculationMode": "Percentage",
"value": 123,
"included": true,
"amount": {
"amount": 99.99,
"currency": "EUR"
}
}
],
"sentFrom": "<string>",
"beneficiary": {
"firstName": "<string>",
"lastName": "<string>",
"email": "jsmith@example.com"
}
}
],
"creationDate": "2023-11-07T05:31:56Z",
"taxAmount": {
"amount": 99.99,
"currency": "EUR"
}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Order
Get the order
Gets the order from a session
GET
/
v1
/
{sessionId}
/
Order
Get Order
curl --request GET \
--url https://{apiBaseUrl}/v1/{sessionId}/Order \
--header 'X-API-KEY: <api-key>'const url = 'https://{apiBaseUrl}/v1/{sessionId}/Order';
const options = {method: 'GET', headers: {'X-API-KEY': '<api-key>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));import requests
url = "https://{apiBaseUrl}/v1/{sessionId}/Order"
headers = {"X-API-KEY": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://{apiBaseUrl}/v1/{sessionId}/Order",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-KEY: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}using RestSharp;
var options = new RestClientOptions("https://{apiBaseUrl}/v1/{sessionId}/Order");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("X-API-KEY", "<api-key>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.get("https://{apiBaseUrl}/v1/{sessionId}/Order")
.header("X-API-KEY", "<api-key>")
.asString();{
"shopper": {
"firstName": "<string>",
"lastName": "<string>",
"email": "jsmith@example.com",
"countryCode": "<string>",
"address": "<string>",
"postalCode": "<string>",
"city": "<string>",
"phone": "<string>",
"phoneCode": "<string>"
},
"payment": {
"providerId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"providerName": "<string>",
"card": {
"type": "<string>",
"holder": "<string>",
"number": "<string>",
"expiry": "2023-11-07T05:31:56Z"
}
},
"amount": {
"amount": 99.99,
"currency": "EUR"
},
"totalAmount": {
"amount": 99.99,
"currency": "EUR"
},
"reference": "<string>",
"creationDateUtc": "2023-11-07T05:31:56Z",
"culture": "<string>",
"id": 123,
"owner": {
"groupId": 123,
"hotelId": 123
},
"items": [
{
"productId": 123,
"code": "<string>",
"name": "<string>",
"description": "<string>",
"usage": "Direct",
"amount": {
"amount": 99.99,
"currency": "EUR"
},
"expiryDateUtc": "2023-11-07T05:31:56Z",
"internalName": "<string>",
"id": 123,
"status": "Active",
"consumedDateUtc": "2023-11-07T05:31:56Z",
"consumedDate": "2023-11-07T05:31:56Z",
"expiryDate": "2023-11-07T05:31:56Z",
"hotelId": 123,
"comment": "<string>",
"sendTo": "Shopper",
"hidePrice": true,
"taxes": [
{
"name": "<string>",
"calculationMode": "Percentage",
"value": 123,
"included": true,
"amount": {
"amount": 99.99,
"currency": "EUR"
}
}
],
"sentFrom": "<string>",
"beneficiary": {
"firstName": "<string>",
"lastName": "<string>",
"email": "jsmith@example.com"
}
}
],
"creationDate": "2023-11-07T05:31:56Z",
"taxAmount": {
"amount": 99.99,
"currency": "EUR"
}
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}{
"type": "<string>",
"title": "<string>",
"status": 123,
"detail": "<string>",
"instance": "<string>"
}Response
Return
Was this page helpful?