curl --request POST \
--url https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"line": {
"product_id": "<string>",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 2,
"variants": [
{
"variant_id": "<string>",
"quantity": 50
}
],
"extras": [],
"metadata": {},
"assigned_staff_id": "<string>",
"external_id": "<string>"
},
"source": "OTHER",
"comment": "<string>",
"tags": [
"<string>"
],
"prescriber_id": "<string>",
"audience": "public",
"payment": "none",
"external_payment_reference": "<string>",
"send_payment_link": true,
"bypass_availability": false,
"bypass_approval": false,
"send_client_notifications": true,
"send_staff_notifications": true
}
'import requests
url = "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities"
payload = {
"line": {
"product_id": "<string>",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 2,
"variants": [
{
"variant_id": "<string>",
"quantity": 50
}
],
"extras": [],
"metadata": {},
"assigned_staff_id": "<string>",
"external_id": "<string>"
},
"source": "OTHER",
"comment": "<string>",
"tags": ["<string>"],
"prescriber_id": "<string>",
"audience": "public",
"payment": "none",
"external_payment_reference": "<string>",
"send_payment_link": True,
"bypass_availability": False,
"bypass_approval": False,
"send_client_notifications": True,
"send_staff_notifications": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
line: {
product_id: '<string>',
start_at: '2023-11-07T05:31:56Z',
party_size: 2,
variants: [{variant_id: '<string>', quantity: 50}],
extras: [],
metadata: {},
assigned_staff_id: '<string>',
external_id: '<string>'
},
source: 'OTHER',
comment: '<string>',
tags: ['<string>'],
prescriber_id: '<string>',
audience: 'public',
payment: 'none',
external_payment_reference: '<string>',
send_payment_link: true,
bypass_availability: false,
bypass_approval: false,
send_client_notifications: true,
send_staff_notifications: true
})
};
fetch('https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'line' => [
'product_id' => '<string>',
'start_at' => '2023-11-07T05:31:56Z',
'party_size' => 2,
'variants' => [
[
'variant_id' => '<string>',
'quantity' => 50
]
],
'extras' => [
],
'metadata' => [
],
'assigned_staff_id' => '<string>',
'external_id' => '<string>'
],
'source' => 'OTHER',
'comment' => '<string>',
'tags' => [
'<string>'
],
'prescriber_id' => '<string>',
'audience' => 'public',
'payment' => 'none',
'external_payment_reference' => '<string>',
'send_payment_link' => true,
'bypass_availability' => false,
'bypass_approval' => false,
'send_client_notifications' => true,
'send_staff_notifications' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities"
payload := strings.NewReader("{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"external_id": "<string>",
"payment_url": "<string>",
"activities": [
{
"id": "<string>",
"cart_id": "<string>",
"external_id": "<string>",
"cart_external_id": "<string>",
"status": "PENDING",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 1,
"source": "WALK_IN",
"product": {
"id": "<string>",
"name": "<string>"
},
"variant": {
"id": "<string>",
"name": "<string>"
},
"variants": [
{
"id": "<string>",
"name": "<string>",
"quantity": 1
}
],
"assigned_staff": {
"id": "<string>",
"name": "<string>"
},
"prescriber": {
"id": "<string>",
"name": "<string>",
"phone_number": "<string>"
},
"customer": {
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone_number": "<string>",
"lang": "FR"
},
"hotel_guest": {
"room_number": "<string>",
"pms_reference": {
"stay_id": "<string>"
}
},
"additional_comment": "<string>",
"metadata": {},
"attached_files": [
"<string>"
],
"tags": [
"<string>"
],
"cancellation_reason": "<string>",
"payment_summary": {
"currency": "MAD",
"total_amount": 123,
"paid_amount": 123,
"gift_card_amount": 123,
"authorized_amount": 123,
"pending_amount": 123,
"refunded_amount": 123,
"statuses": [
"FREE"
]
},
"payments": [
{
"id": "<string>",
"provider_id": "<string>",
"payment_type": "DEPOSIT",
"payment_mode": "SOFT_PREAUTH",
"provider": "PAYZONE",
"status": "FREE",
"amount": 123,
"gift_card_amount": 123,
"quantity": 123,
"unit_price": 123,
"percent_of_total": 123,
"currency": "MAD",
"is_refundable": true,
"external_reference": "<string>",
"expiration_date": "2023-11-07T05:31:56Z",
"max_cancellation_date": "2023-11-07T05:31:56Z",
"authorized_at": "2023-11-07T05:31:56Z",
"capture_deadline": "2023-11-07T05:31:56Z",
"captured_at": "2023-11-07T05:31:56Z",
"voided_at": "2023-11-07T05:31:56Z",
"linked_product": {
"id": "<string>",
"name": "<string>"
},
"linked_variant": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"sensitive_data_included": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}{
"data": {
"id": "<string>",
"external_id": "<string>",
"payment_url": "<string>",
"activities": [
{
"id": "<string>",
"cart_id": "<string>",
"external_id": "<string>",
"cart_external_id": "<string>",
"status": "PENDING",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 1,
"source": "WALK_IN",
"product": {
"id": "<string>",
"name": "<string>"
},
"variant": {
"id": "<string>",
"name": "<string>"
},
"variants": [
{
"id": "<string>",
"name": "<string>",
"quantity": 1
}
],
"assigned_staff": {
"id": "<string>",
"name": "<string>"
},
"prescriber": {
"id": "<string>",
"name": "<string>",
"phone_number": "<string>"
},
"customer": {
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone_number": "<string>",
"lang": "FR"
},
"hotel_guest": {
"room_number": "<string>",
"pms_reference": {
"stay_id": "<string>"
}
},
"additional_comment": "<string>",
"metadata": {},
"attached_files": [
"<string>"
],
"tags": [
"<string>"
],
"cancellation_reason": "<string>",
"payment_summary": {
"currency": "MAD",
"total_amount": 123,
"paid_amount": 123,
"gift_card_amount": 123,
"authorized_amount": 123,
"pending_amount": 123,
"refunded_amount": 123,
"statuses": [
"FREE"
]
},
"payments": [
{
"id": "<string>",
"provider_id": "<string>",
"payment_type": "DEPOSIT",
"payment_mode": "SOFT_PREAUTH",
"provider": "PAYZONE",
"status": "FREE",
"amount": 123,
"gift_card_amount": 123,
"quantity": 123,
"unit_price": 123,
"percent_of_total": 123,
"currency": "MAD",
"is_refundable": true,
"external_reference": "<string>",
"expiration_date": "2023-11-07T05:31:56Z",
"max_cancellation_date": "2023-11-07T05:31:56Z",
"authorized_at": "2023-11-07T05:31:56Z",
"capture_deadline": "2023-11-07T05:31:56Z",
"captured_at": "2023-11-07T05:31:56Z",
"voided_at": "2023-11-07T05:31:56Z",
"linked_product": {
"id": "<string>",
"name": "<string>"
},
"linked_variant": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"sensitive_data_included": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}Add an activity to a cart
Books one more activity for the cart’s guest. With line.external_id, the same body sent again answers the cart (200). A guest blacklisted since is refused. The guest is booked as on the booking portal — the day, the slot and the capacity are checked, a product the restaurant approves becomes a request (PENDING) — without the portal having to be open. party_size must be what the units cover. Times are start_at instants of /activity-availability. Forcing options need their scope. Requires ACTIVITIES_WRITE.
curl --request POST \
--url https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"line": {
"product_id": "<string>",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 2,
"variants": [
{
"variant_id": "<string>",
"quantity": 50
}
],
"extras": [],
"metadata": {},
"assigned_staff_id": "<string>",
"external_id": "<string>"
},
"source": "OTHER",
"comment": "<string>",
"tags": [
"<string>"
],
"prescriber_id": "<string>",
"audience": "public",
"payment": "none",
"external_payment_reference": "<string>",
"send_payment_link": true,
"bypass_availability": false,
"bypass_approval": false,
"send_client_notifications": true,
"send_staff_notifications": true
}
'import requests
url = "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities"
payload = {
"line": {
"product_id": "<string>",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 2,
"variants": [
{
"variant_id": "<string>",
"quantity": 50
}
],
"extras": [],
"metadata": {},
"assigned_staff_id": "<string>",
"external_id": "<string>"
},
"source": "OTHER",
"comment": "<string>",
"tags": ["<string>"],
"prescriber_id": "<string>",
"audience": "public",
"payment": "none",
"external_payment_reference": "<string>",
"send_payment_link": True,
"bypass_availability": False,
"bypass_approval": False,
"send_client_notifications": True,
"send_staff_notifications": True
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
line: {
product_id: '<string>',
start_at: '2023-11-07T05:31:56Z',
party_size: 2,
variants: [{variant_id: '<string>', quantity: 50}],
extras: [],
metadata: {},
assigned_staff_id: '<string>',
external_id: '<string>'
},
source: 'OTHER',
comment: '<string>',
tags: ['<string>'],
prescriber_id: '<string>',
audience: 'public',
payment: 'none',
external_payment_reference: '<string>',
send_payment_link: true,
bypass_availability: false,
bypass_approval: false,
send_client_notifications: true,
send_staff_notifications: true
})
};
fetch('https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'line' => [
'product_id' => '<string>',
'start_at' => '2023-11-07T05:31:56Z',
'party_size' => 2,
'variants' => [
[
'variant_id' => '<string>',
'quantity' => 50
]
],
'extras' => [
],
'metadata' => [
],
'assigned_staff_id' => '<string>',
'external_id' => '<string>'
],
'source' => 'OTHER',
'comment' => '<string>',
'tags' => [
'<string>'
],
'prescriber_id' => '<string>',
'audience' => 'public',
'payment' => 'none',
'external_payment_reference' => '<string>',
'send_payment_link' => true,
'bypass_availability' => false,
'bypass_approval' => false,
'send_client_notifications' => true,
'send_staff_notifications' => true
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities"
payload := strings.NewReader("{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.eat-now.io/api/partner/v1/activity-carts/{id}/activities")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"line\": {\n \"product_id\": \"<string>\",\n \"start_at\": \"2023-11-07T05:31:56Z\",\n \"party_size\": 2,\n \"variants\": [\n {\n \"variant_id\": \"<string>\",\n \"quantity\": 50\n }\n ],\n \"extras\": [],\n \"metadata\": {},\n \"assigned_staff_id\": \"<string>\",\n \"external_id\": \"<string>\"\n },\n \"source\": \"OTHER\",\n \"comment\": \"<string>\",\n \"tags\": [\n \"<string>\"\n ],\n \"prescriber_id\": \"<string>\",\n \"audience\": \"public\",\n \"payment\": \"none\",\n \"external_payment_reference\": \"<string>\",\n \"send_payment_link\": true,\n \"bypass_availability\": false,\n \"bypass_approval\": false,\n \"send_client_notifications\": true,\n \"send_staff_notifications\": true\n}"
response = http.request(request)
puts response.read_body{
"data": {
"id": "<string>",
"external_id": "<string>",
"payment_url": "<string>",
"activities": [
{
"id": "<string>",
"cart_id": "<string>",
"external_id": "<string>",
"cart_external_id": "<string>",
"status": "PENDING",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 1,
"source": "WALK_IN",
"product": {
"id": "<string>",
"name": "<string>"
},
"variant": {
"id": "<string>",
"name": "<string>"
},
"variants": [
{
"id": "<string>",
"name": "<string>",
"quantity": 1
}
],
"assigned_staff": {
"id": "<string>",
"name": "<string>"
},
"prescriber": {
"id": "<string>",
"name": "<string>",
"phone_number": "<string>"
},
"customer": {
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone_number": "<string>",
"lang": "FR"
},
"hotel_guest": {
"room_number": "<string>",
"pms_reference": {
"stay_id": "<string>"
}
},
"additional_comment": "<string>",
"metadata": {},
"attached_files": [
"<string>"
],
"tags": [
"<string>"
],
"cancellation_reason": "<string>",
"payment_summary": {
"currency": "MAD",
"total_amount": 123,
"paid_amount": 123,
"gift_card_amount": 123,
"authorized_amount": 123,
"pending_amount": 123,
"refunded_amount": 123,
"statuses": [
"FREE"
]
},
"payments": [
{
"id": "<string>",
"provider_id": "<string>",
"payment_type": "DEPOSIT",
"payment_mode": "SOFT_PREAUTH",
"provider": "PAYZONE",
"status": "FREE",
"amount": 123,
"gift_card_amount": 123,
"quantity": 123,
"unit_price": 123,
"percent_of_total": 123,
"currency": "MAD",
"is_refundable": true,
"external_reference": "<string>",
"expiration_date": "2023-11-07T05:31:56Z",
"max_cancellation_date": "2023-11-07T05:31:56Z",
"authorized_at": "2023-11-07T05:31:56Z",
"capture_deadline": "2023-11-07T05:31:56Z",
"captured_at": "2023-11-07T05:31:56Z",
"voided_at": "2023-11-07T05:31:56Z",
"linked_product": {
"id": "<string>",
"name": "<string>"
},
"linked_variant": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"sensitive_data_included": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}{
"data": {
"id": "<string>",
"external_id": "<string>",
"payment_url": "<string>",
"activities": [
{
"id": "<string>",
"cart_id": "<string>",
"external_id": "<string>",
"cart_external_id": "<string>",
"status": "PENDING",
"start_at": "2023-11-07T05:31:56Z",
"party_size": 1,
"source": "WALK_IN",
"product": {
"id": "<string>",
"name": "<string>"
},
"variant": {
"id": "<string>",
"name": "<string>"
},
"variants": [
{
"id": "<string>",
"name": "<string>",
"quantity": 1
}
],
"assigned_staff": {
"id": "<string>",
"name": "<string>"
},
"prescriber": {
"id": "<string>",
"name": "<string>",
"phone_number": "<string>"
},
"customer": {
"id": "<string>",
"name": "<string>",
"email": "jsmith@example.com",
"phone_number": "<string>",
"lang": "FR"
},
"hotel_guest": {
"room_number": "<string>",
"pms_reference": {
"stay_id": "<string>"
}
},
"additional_comment": "<string>",
"metadata": {},
"attached_files": [
"<string>"
],
"tags": [
"<string>"
],
"cancellation_reason": "<string>",
"payment_summary": {
"currency": "MAD",
"total_amount": 123,
"paid_amount": 123,
"gift_card_amount": 123,
"authorized_amount": 123,
"pending_amount": 123,
"refunded_amount": 123,
"statuses": [
"FREE"
]
},
"payments": [
{
"id": "<string>",
"provider_id": "<string>",
"payment_type": "DEPOSIT",
"payment_mode": "SOFT_PREAUTH",
"provider": "PAYZONE",
"status": "FREE",
"amount": 123,
"gift_card_amount": 123,
"quantity": 123,
"unit_price": 123,
"percent_of_total": 123,
"currency": "MAD",
"is_refundable": true,
"external_reference": "<string>",
"expiration_date": "2023-11-07T05:31:56Z",
"max_cancellation_date": "2023-11-07T05:31:56Z",
"authorized_at": "2023-11-07T05:31:56Z",
"capture_deadline": "2023-11-07T05:31:56Z",
"captured_at": "2023-11-07T05:31:56Z",
"voided_at": "2023-11-07T05:31:56Z",
"linked_product": {
"id": "<string>",
"name": "<string>"
},
"linked_variant": {
"id": "<string>",
"name": "<string>"
},
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"sensitive_data_included": true,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
]
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}{
"error": {
"code": "AUTHENTICATION_REQUIRED",
"message": "<string>",
"request_id": "<string>",
"details": {}
}
}Authorizations
Body
none: everything is paid on site. payment_link: the lines owed online are left for the guest to pay; the activity awaits its payment, and the cart gives payment_url. paid_elsewhere: you took the money; each line is recorded paid at the catalog price (provider PARTNER), requires PAYMENTS_WRITE and external_payment_reference. Refused on a product to approve without bypass_approval.
none, payment_link, paid_elsewhere