Delete Event
DELETE /events/:eventId
Deletes the event. Returns 204 with no body.
An event can only be deleted while no tickets are issued for it, that is while its numberOfIssuedTickets is 0. A main event can only be deleted once it has no dates left: delete its dates first, each on its own id.
Deleting works as in the back office: Loby keeps the event's record, but the event is no longer sold or returned, and its id answers 404 from then on.
Errors
Errors are returned as { "errors": [{ "message": "EVENT_HAS_TICKETS" }] }.
| Status | Message | When |
|---|---|---|
404 | EVENT_NOT_FOUND | The event doesn't exist, was already deleted, belongs to another museum, or has the other mode (live or test) than your API key |
409 | EVENT_HAS_TICKETS | Tickets are issued for the event: its numberOfIssuedTickets is above 0 |
409 | EVENT_HAS_DATES | The event is the main event of a series and still has dates |