Booking · Bookings
List bookings
Returns a list of bookings for a given mandate
Permissions
Send an API key of the organization in the path, using the X-API-Key header.
Permission checks in detail
Required permissions
mandate.readbooking.read
Also checked, depending on the request and the records it touches
user.readapiKey.readcontact:member.readcontact:address.readcontact:customer.readcontact:sponsor.readcontact:contributor.readcontact:employee.readcontact:supplier.readcontact.read
Request
Path parameters
-
organizationIdidrequired -
mandateIdidrequired
Body
Content-Type: application/json
-
sortobject of stringascdescKeys: one of 64 values or 1 pattern
_idmandatetypebookingNumberbuyer.typebuyer.namebuyer.nameNormalizedbuyer.nameSortbuyer.emailbuyer.phonebuyer.address.countrybuyer.address.statebuyer.address.zipbuyer.address.citybuyer.address.addressLinebuyer.address.details1buyer.address.details2buyer.userIdbuyer.accountbuyer.contact.namebuyer.contact.typebuyer.contact.nameNormalizedbuyer.contact.nameSortbuyer.contact.contactbuyer.contact.image.resourcebuyer.contact.image.fileNamebuyer.contact.image.contentTypebuyer.contact.image.fileSizeBytesbuyer.contact.user.namebuyer.contact.user.typebuyer.contact.user.userIdbuyer.contact.user.image.resourcebuyer.contact.user.image.fileNamebuyer.contact.user.image.contentTypebuyer.contact.user.image.fileSizeBytesbuyer.payment.paymentMethodbuyer.payment.sepaDirectDebit.ibanbuyer.payment.sepaDirectDebit.bicbuyer.payment.online.paymentIntentbuyer.payment.online.providerbuyer.payment.online.paymentModebuyer.payment.online.onlineDebitCollectionbuyer.personNamebuyer.receiptModereceiptsformResult.schematotalPricetotalPointsusedPunchCardNumbersdiscountCodestatuspaymentStatuscancelationsrecordscreatedAtevent.eventevent.eventTitleevent.eventDateevent.seriesIdevent.qrPassesevent.refundPoliciesevent.invitationCoderesource.resourcesresource.resourceNamespattern
^formResult\.data\.[\s\S]{0,}$ -
limitinteger0–100 · default
50 -
offsetintegerat least 0 · default
0 -
returnCountbooleandefault
false -
typestringeventresource -
contactIdid -
searchTermstring -
userFilterstringnullableA stringified json object representing a property filter
curl --fail-with-body --silent --show-error --max-time 30 --globoff \
--request POST 'https://cloud.campai.com/api/YOUR_ORGANIZATION_ID/YOUR_MANDATE_ID/booking/bookings/list' \
--header 'X-API-Key: YOUR_API_KEY'const response = await fetch("https://cloud.campai.com/api/YOUR_ORGANIZATION_ID/YOUR_MANDATE_ID/booking/bookings/list", {
method: "POST",
headers: {
"X-API-Key": "YOUR_API_KEY"
},
redirect: 'error',
signal: AbortSignal.timeout(30_000),
});
if (!response.ok) throw new Error(`campai HTTP ${response.status}`);
const text = await response.text();
const result = text ? JSON.parse(text) : null;
console.log(JSON.stringify(result, null, 2));<?php
$context = stream_context_create(['http' => [
'method' => 'POST',
'header' => [
'X-API-Key: YOUR_API_KEY',
],
'timeout' => 30,
'follow_location' => 0,
'ignore_errors' => true,
]]);
$text = @file_get_contents('https://cloud.campai.com/api/YOUR_ORGANIZATION_ID/YOUR_MANDATE_ID/booking/bookings/list', false, $context);
preg_match('/^HTTP\/\S+ (\d{3})/', $http_response_header[0] ?? '', $match);
$status = (int) ($match[1] ?? 0);
if ($text === false || $status < 200 || $status >= 300) {
throw new RuntimeException("campai HTTP $status (0 means no response)");
}
$result = $text === '' ? null : json_decode($text, true, 512, JSON_THROW_ON_ERROR);
echo json_encode($result, JSON_PRETTY_PRINT | JSON_THROW_ON_ERROR), PHP_EOL;
No request that worked has been recorded yet, so the body is not shown.
Response
200 Successful response
Content-Type: application/json
-
countintegerat least 0
-
bookingsobject[]18 properties
-
_idid -
mandateid -
typestringeventresource -
bookingNumberstringexactly 7 characters
-
buyerobject13 properties
-
typestringbusinessperson -
namestring1–81 characters
-
nameNormalizedstringat least 1 characters
-
nameSortstring1–81 characters
-
emailstring -
phonestring | string · phone -
addressobjectnullable7 properties
-
countrystring -
statestring -
zipstring -
citystring -
addressLinestring -
details1string -
details2string
-
-
userIdstringat most 24 characters
-
accountinteger1–999999999
-
contactobjectnullable7 properties
-
namestring -
typestring -
nameNormalizedstring -
nameSortstring -
contactidnullable -
imageobjectnullable4 properties
-
resourcestringat least 1 characters
-
fileNamestringat most 128 characters
-
contentTypestringat most 75 characters
-
fileSizeBytesintegerat least 0
-
-
userobjectnullable4 properties
-
namestring -
typestring -
userIdstring -
imageobjectnullable4 properties
-
resourcestringat least 1 characters
-
fileNamestringat most 128 characters
-
contentTypestringat most 75 characters
-
fileSizeBytesintegerat least 0
-
-
-
-
paymentobjectnullable3 properties
-
paymentMethodstringsepaCreditTransfersepaDirectDebitcashonline -
sepaDirectDebitobjectnullable2 properties
-
ibanstring · iban -
bicstringnullable
-
-
onlineobjectnullable4 properties
-
paymentIntentidnullable -
providerstringnullablestripepaypal -
paymentModestringnullablemanualautomatic -
onlineDebitCollectionidnullable
-
-
-
personNamestring1–81 characters
-
receiptModestringgrossnet
-
-
receiptsobject[]8 properties
-
receiptid -
receiptNumberstringat most 30 characters
-
paymentStatusstringunpaidpartialpaid -
paymentTermsstringat most 2000 characters
-
paymentDueDatestring · date-timenullable -
paymentTotalAmountLeftToPayintegernullable0–9999999999
-
canceledAtstring · date-timenullable -
externalRefundobjectnullable2 properties
-
providerstringstripepaypal -
amountintegerat most 9999999999
-
-
-
formResultobjectnullable2 properties
-
schemaobject[]5 properties
-
pageIdstring -
idstring -
labelstring -
itemCaptionstring -
fieldsobject[]9 properties
-
idstring -
keystring1–24 characters · pattern
^[A-Za-z_$][A-Za-z0-9_$]*$ -
typestring20 values
placeholderhtmlspacertextselectmultiSelectdatetimedateTimenumberfilesignatureratingmatrixbooleanaddresscalculatedinfotermsPrivacypaymentMethod -
labelstring1–140 characters
-
bindPropertyPathstring -
textobject1 property
-
formatstringtextmultilineregexemailphoneurlibanbic
-
-
dateobject1 property
-
formatstring
-
-
calculatedobject2 properties
-
resultTypestringnumberstringbooleandateOnlydateTimeoption -
optionsobject[]at most 1000 items
4 properties
-
idstring1–140 characters
-
valuestring1–140 characters
-
labelstring1–140 characters
-
hintstringat most 200 characters
-
-
-
matrixobject3 properties
-
rowsobject[]4 properties
-
idstring1–140 characters
-
valuestring1–140 characters
-
labelstring1–140 characters
-
hintstringat most 200 characters
-
-
columnsobject[]4 properties
-
idstring1–140 characters
-
valuestring1–140 characters
-
labelstring1–140 characters
-
hintstringat most 200 characters
-
-
multiSelectboolean
-
-
-
-
dataobject of one of 7 types | object of one of 7 types | object (recursive)[] | (one of 7 types)[][]The answers of a form, by the ID of each field. A repeating group holds a list of its entries under its own ID.
-
-
totalPriceinteger0–9999999999
-
totalPointsintegerat least 0
-
usedPunchCardNumbersstring[] -
discountCodestringnullable -
statusstringconfirmedpartialCancelationcanceled -
paymentStatusstringnullableunpaidpartialpaid -
cancelationsobject[]8 properties
-
recordNumberstringexactly 10 characters
-
canceledAtstring · date-time -
reasonstringat most 240 characters
-
priceRefundintegernullable0–9999999999
-
pointsRefundintegernullableat least 0
-
partialboolean -
refundPayoutobject -
refundReceiptBreakdownobject[]2 properties
-
receiptid -
amountintegerat most 9999999999
-
-
-
recordsinteger -
createdAtstring · date-timenullable -
eventobject7 properties
-
eventid -
eventTitlestring -
eventDatestring · date-time -
seriesIdstring -
qrPassesobject[]nullable3 properties
-
kindstring -
targetobject -
qrPassTokenstring
-
-
refundPoliciesobject[]nullableat most 8 items
3 properties
-
refundUntilobject2 properties
-
valuenumberat least 0
-
unitstringhoursdaysweeksmonthsyears
-
-
priceModifierobject2 properties
-
valueinteger0–9999999999
-
typestring%amount
-
-
pointModifierobject2 properties
-
valueinteger0–9999999999
-
typestring%amount
-
-
-
invitationCodestringnullableat most 32 characters
-
-
resourceobject2 properties
-
resourcesid[] -
resourceNamesstring[]
-
-
{
"count": 0,
"bookings": [
{
"_id": "000000000000000000000001",
"mandate": "000000000000000000000001",
"type": "event",
"bookingNumber": "string",
"buyer": {
"type": "business",
"name": "string",
"nameNormalized": "string",
"nameSort": "string",
"email": "",
"phone": "",
"address": {
"country": "string",
"state": "string",
"zip": "string"
},
"userId": "string",
"contact": {
"name": "string",
"type": "contact",
"nameNormalized": "string",
"nameSort": "string",
"contact": "000000000000000000000001",
"image": {
"resource": "string"
},
"user": {
"name": "string",
"type": "user",
"userId": "string",
"image": {
"resource": "string"
}
}
},
"payment": {
"paymentMethod": "sepaCreditTransfer",
"sepaDirectDebit": {
"iban": "string",
"bic": "string"
},
"online": {
"paymentIntent": "000000000000000000000001",
"provider": null
}
}
},
"receipts": [
{
"receipt": "000000000000000000000001",
"receiptNumber": "string",
"paymentStatus": "unpaid",
"paymentTerms": "string",
"paymentDueDate": null,
"paymentTotalAmountLeftToPay": null,
"canceledAt": null
}
],
"formResult": {
"schema": [
{
"id": "string",
"label": "string",
"fields": [
{
"id": "string",
"type": "placeholder"
}
]
}
],
"data": {
"key": "2026-10-22T12:00:00Z"
}
},
"totalPrice": 0,
"totalPoints": 0,
"usedPunchCardNumbers": [
"string"
],
"discountCode": "string",
"status": "confirmed",
"paymentStatus": "unpaid",
"cancelations": [
{
"recordNumber": "string",
"canceledAt": "2026-06-15T22:30:00Z",
"reason": "string",
"priceRefund": 0,
"pointsRefund": 0
}
],
"records": 1
}
]
}
Errors
No errors of its own are known for this endpoint.
Errors nearly every request can meet are listed under Errors.