Skip to main content

Archive Booking

Archive a booking so it is hidden from the bookings list. It also leaves the portal calendar. It still appears in manifests, reports, customer detail, and search. Archiving does not free stock or seats; cancel the booking to do that.

POST /v1/bookings/{id}/archive
POST /v1/bookings/{id}/unarchive

Authentication​

Requires a valid API key with bookings:write scope.

Eligibility​

A booking archives straight away when either:

  • Its status is cancelled, returned or completed, or
  • Its end_date is in the past (in the supplier's timezone).

Any other booking is upcoming or not finished yet. By default the request returns 422 Unprocessable Entity with error code archive_failed. To archive it anyway, send even_if_unfinished: true. The supplier portal asks the owner to confirm before it does the same.

Request Body​

FieldTypeRequiredDescription
even_if_unfinishedbooleanNoArchive the booking even though it is upcoming or not finished. Default false.

Default behaviour change on GET /v1/bookings​

The GET /v1/bookings index endpoint now excludes archived bookings by default to mirror the supplier portal UI. To opt back in, pass the archived query parameter:

ValueResult
(none) or activeReturns only non-archived bookings (default)
archivedReturns only archived bookings
allReturns both

Path Parameters​

ParameterTypeDescription
idintegerBooking ID

Archive — request example​

curl -X POST "https://app.equipdash.com/api/v1/bookings/123/archive" \
-H "Authorization: Bearer eqd_live_your_api_key"

Archive an upcoming booking:

curl -X POST "https://app.equipdash.com/api/v1/bookings/124/archive" \
-H "Authorization: Bearer eqd_live_your_api_key" \
-H "Content-Type: application/json" \
-d '{"even_if_unfinished": true}'

Archive — success response​

Returns 200 OK with the updated booking:

{
"data": {
"id": 123,
"status": "cancelled",
"archived_at": "2026-04-25T10:30:00+00:00"
},
"meta": {
"request_id": "req_abc123",
"timestamp": "2026-04-25T10:30:00+00:00"
}
}

Archive — error: not eligible​

{
"error": {
"code": "archive_failed",
"message": "Only finished or past bookings can be archived."
},
"meta": { "request_id": "req_abc123" }
}

Unarchive​

Restore an archived booking so it appears in the /bookings list again:

curl -X POST "https://app.equipdash.com/api/v1/bookings/123/unarchive" \
-H "Authorization: Bearer eqd_live_your_api_key"

Returns 200 OK with the booking, where archived_at is now null. If the booking was not archived, returns 422 with error.code = unarchive_failed.

Listing archived bookings​

# Active only (default)
curl "https://app.equipdash.com/api/v1/bookings" \
-H "Authorization: Bearer eqd_live_your_api_key"

# Archived only
curl "https://app.equipdash.com/api/v1/bookings?archived=archived" \
-H "Authorization: Bearer eqd_live_your_api_key"

# Both
curl "https://app.equipdash.com/api/v1/bookings?archived=all" \
-H "Authorization: Bearer eqd_live_your_api_key"

Errors​

StatusCodeDescription
404resource_not_foundThe booking does not exist
403forbiddenThe booking does not belong to the API key's supplier
403insufficient_scopeThe API key is missing bookings:write
422archive_failedThe booking is upcoming or not finished and even_if_unfinished was not sent, or it is already archived
422unarchive_failedThe booking is not currently archived