Update Event Ticket Type
PATCH /event-ticket-types/:eventTicketTypeId
You can update the following fields, described under Create Event Ticket Type: name, description, masterLanguage, translations, price, maxQuantity, addOn, published.
Fields you leave out stay as they are. null removes the description, makes the ticket type free (price), or removes its own limit (maxQuantity).
translations only changes the languages you send. In each of them, the fields you send are updated, those you leave out stay, and null clears one. Languages you don't send stay as they are.
The response is the updated Event Ticket Type.
To raise the price to 175.00 and allow 150 tickets:
{ "price": 17500, "maxQuantity": 150 }
To add a German name and keep the other translations as they are:
{ "translations": [ { "language": "de", "name": "Erwachsene" } ] }
Series
A change to a main event's ticket type is copied to its copies on the event's dates. A copy on a date can't be changed on its own: its id gives SET_ON_MAIN_EVENT, so change the ticket type on the main event.
Errors
Errors are returned as { "errors": [{ "message": "EVENT_TICKET_TYPE_NOT_FOUND" }] }.
| Status | Message | When |
|---|---|---|
400 | EVENT_TICKET_TYPE_NAME_REQUIRED | name is blank |
400 | EVENT_TICKET_TYPE_INVALID_PRICE | price is below 0 |
400 | EVENT_TICKET_TYPE_INVALID_MAX_QUANTITY | maxQuantity is below 1 |
400 | SET_ON_MAIN_EVENT | The ticket type is a copy on a date in a series: change it on the main event |
400 | LANGUAGE_NOT_SUPPORTED | masterLanguage or the language of a translation isn't a language Loby supports |
400 | FIELD_NOT_ALLOWED: <field> | The body holds a field that isn't listed above. For a field in a translation, <field> is translations.<field> |
400 | INVALID_BODY | The body isn't a JSON object, a translation has no language, a field has the wrong JSON type (price and maxQuantity are whole numbers), or a field that may not be null is null |
404 | EVENT_TICKET_TYPE_NOT_FOUND | The ticket type doesn't exist, was deleted, or its event was deleted, belongs to another museum, or has the other mode (live or test) than your API key |