/locations:
name- Location name (max 30 characters)latitude- Geographical latitude (-90 to 90)longitude- Geographical longitude (-180 to 180)address- Postal address (max 300 characters)country- ISO 3166-1 alpha-2 country code (e.g. “US”, “CA”)
languages- Languages available at this location (see below). Defaults to["en"]if omitted.inputFields- Custom input fields for the location (see below). If omitted, three default fields are created (first name, last name, phone number).lines- Custom lines (queues) for the location (see below). If omitted, two default lines are created (“Main Service” and “Information”).openingHours- Opening hours configuration (see below). If omitted, the location defaults to 24/7 (00:00-23:59 every day).
Languages
You can configure which languages are available at a location by providing an array of ISO 639 / BCP 47 language codes:- The list must include
"en"(English) - No duplicate codes allowed
- All codes must be supported (e.g.
en,et,fr,de,zh,zh-TW,fr-CA,pt-PT) - Order is preserved — the first language is the primary display language
- If omitted, defaults to
["en"]
Input Fields
You can specify custom input fields to create with the location by providing aninputFields array. If omitted, three default fields are created: first name, last name, and phone number.
Each field uses the same schema as the standalone Creating an Input Field endpoint, with these differences:
location— must not be provided (automatically set to the created location)visibleForLines— must be omitted or empty (lines don’t exist yet at creation time)id— required (client-generated UUID)
- Must include at least one
FIRST_NAMEand oneLAST_NAMEfield - Maximum 50 fields
FIRST_NAME,LAST_NAME,EMAIL, andPHONE_NUMBERare singleton types (only one of each allowed)FIRST_NAMEandLAST_NAMEcannot haveisMandatoryBeforeAddedorisMandatoryBeforeServedset totrue- All field and option IDs must be unique within the request and globally
- If fields include translations, the referenced language codes must be declared in the
languagesfield
Lines
You can specify custom lines (queues) to create with the location by providing alines array. If omitted, two default lines are created: “Main Service” (TEAL) and “Information” (YELLOW).
Each line object uses the same schema as the standalone Creating a Line endpoint, with the following difference:
appointmentSettings— not supported in location creation
name(string, required) - Line name (max 30 characters, trimmed)color(string, required) - Line color. One of:VIOLET,LAVENDER,MARSHMALLOW,TEAL,MINT,CORAL,YELLOW,ROSE,INDIGO,BLUEdisabled(boolean, optional) - Whether the line starts disabled (default:false)translations(array, optional) - Name translations for multi-language support
languageCode(string, required) - Language code (e.g. “fr”, “es”)name(string, optional) - Translated line name (max 30 characters). Can benullas a placeholder.
- Between 1 and 50 lines
- No duplicate line names (after trimming, case-sensitive)
- If lines include translations, the referenced language codes must be declared in the
languagesfield
Opening Hours
You can set regular weekly hours and date-specific exceptions:regular can have either:
businessHours- An array of time ranges withopensandcloses(each withhours0-23 andminutes0-59)closed: true- The location is closed that day
exceptions requires a date (ISO 8601 format) and can include:
closedand optionalclosedReason- Mark the date as closedbusinessHours- Custom hours for that specific date
Error Responses
| Status | Description | Example |
|---|---|---|
| 400 | Name is blank | {"code": "parameter_invalid_blank", "message": "...", "param": "name"} |
| 400 | Name too long (>30 chars) | {"code": "parameter_invalid_size", "message": "...", "param": "name"} |
| 400 | Invalid coordinates | {"code": "parameter_too_large", "message": "...", "param": "latitude"} |
| 400 | Invalid country code | {"code": "parameter_invalid_country_code", "message": "...", "param": "country"} |
| 400 | Invalid opening hours | {"code": "parameter_invalid", "message": "...", "param": "openingHours"} |
| 400 | Languages missing “en” | {"code": "parameter_invalid", "message": "languages must include 'en'", "param": "languages"} |
| 400 | Duplicate language codes | {"code": "parameter_invalid", "message": "languages must not contain duplicates", "param": "languages"} |
| 400 | Unsupported language code | {"code": "language_code_not_supported", "message": "Language with the code 'xx' is not supported."} |
| 400 | Invalid input field | {"code": "parameter_invalid", "message": "...", "param": "inputFields"} |
| 400 | Missing FIRST_NAME or LAST_NAME | {"code": "parameter_invalid", "message": "...", "param": "inputFields"} |
| 400 | More than 50 input fields | {"code": "parameter_invalid", "message": "...", "param": "inputFields"} |
| 400 | Duplicate field or option IDs | {"code": "duplicate_items_in_request", "message": "..."} |
| 400 | Duplicate singleton type | {"code": "input_field_duplicate", "message": "..."} |
| 400 | Translation language not in languages | {"code": "parameter_invalid", "message": "...", "param": "inputFields"} |
| 409 | Field or option ID already exists | {"code": "input_field_duplicate", "message": "..."} |
| 400 | Lines array empty or exceeds 50 | {"code": "parameter_invalid_size", "message": "size must be between 1 and 50", "param": "lines"} |
| 400 | Line name is blank | {"code": "parameter_invalid_blank", "message": "must not be blank", "param": "lines[0].name"} |
| 400 | Line name too long (>30 chars) | {"code": "parameter_invalid_size", "message": "size must be between 0 and 30", "param": "lines[0].name"} |
| 400 | Line color missing | {"code": "parameter_invalid_null", "message": "must not be null", "param": "lines[0].color"} |
| 400 | Invalid line color name | {"code": "parameter_invalid", "message": "Invalid color name", "param": "lines[0].color"} |
| 400 | Duplicate line names | {"code": "duplicate_items_in_request", "message": "Duplicate line names in request"} |
| 400 | Line translation language not in languages | {"code": "parameter_invalid", "message": "Line translations reference languages not included in 'languages': ...", "param": "languages"} |