createLocation
POST
/api/v1/locations
const url = 'https://example.com/api/v1/locations';const options = { method: 'POST', headers: {'Content-Type': 'application/json'}, body: '{"name":"example","addressLine1":"example","addressLine2":"example","city":"example","state":"example","postalCode":"example","country":"example","latitude":1,"longitude":1}'};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request POST \ --url https://example.com/api/v1/locations \ --header 'Content-Type: application/json' \ --data '{ "name": "example", "addressLine1": "example", "addressLine2": "example", "city": "example", "state": "example", "postalCode": "example", "country": "example", "latitude": 1, "longitude": 1 }'Create location. Requires an authenticated dashboard user.
Request Bodyrequired
Section titled “Request Bodyrequired”Media typeapplication/json
object
name
required
string
addressLine1
string
addressLine2
string
city
string
state
string
postalCode
string
country
string
latitude
number | null
longitude
number | null
Examplegenerated
{ "name": "example", "addressLine1": "example", "addressLine2": "example", "city": "example", "state": "example", "postalCode": "example", "country": "example", "latitude": 1, "longitude": 1}Responses
Section titled “ Responses ”Location created
Media typeapplication/json
object
data
required
object
id
required
string format: uuid
name
required
string
addressLine1
required
string
addressLine2
required
string
city
required
string
state
required
string
postalCode
required
string
country
required
string
latitude
number
longitude
number
screenCount
required
integer
createdAt
required
string format: date-time
updatedAt
required
string format: date-time
Examplegenerated
{ "data": { "id": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "name": "example", "addressLine1": "example", "addressLine2": "example", "city": "example", "state": "example", "postalCode": "example", "country": "example", "latitude": 1, "longitude": 1, "screenCount": 1, "createdAt": "2026-04-15T12:00:00Z", "updatedAt": "2026-04-15T12:00:00Z" }}Owner or Administrator required
A case-insensitive matching location already exists