AerScheduler

Locations

Bases of operation.

5 endpoints · base URL https://api.aerscheduler.com

get/locations

List locations

Every location in your organization.

Responses

200OKThe locations.{ data: Location[] }
401UnauthorizedNo token, an expired token, or a malformed one. Sign in again.
403ForbiddenAuthenticated, but not allowed to do this.
429Too Many RequestsRate limited. Retry-After says how long to wait.
Example request
curl https://api.aerscheduler.com/locations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/locations

Create a location

Adds a location to your organization. Requires the admin role.

Request body

The new location. The address is geocoded on the way in and is rejected if it cannot be resolved.

namerequiredstring
addressrequiredAddress

Responses

201CreatedThe location that was created.{ data: Location }
400Bad RequestThe body failed validation. message says which field.
401UnauthorizedNo token, an expired token, or a malformed one. Sign in again.
403ForbiddenAuthenticated, but not allowed to do this.
429Too Many RequestsRate limited. Retry-After says how long to wait.
Example request
curl -X POST https://api.aerscheduler.com/locations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…","address":"…"}'
get/locations/{id}

Get a location

Fetches one location by id.

Path parameters

idrequiredintegerThe location id.

Responses

200OKSuccess.{ data: Location }
401UnauthorizedNo token, an expired token, or a malformed one. Sign in again.
403ForbiddenAuthenticated, but not allowed to do this.
404Not FoundNo such location, or it belongs to another organization.
429Too Many RequestsRate limited. Retry-After says how long to wait.
Example request
curl https://api.aerscheduler.com/locations/:id \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
patch/locations/{id}

Update a location

Changes the fields you send and leaves the rest alone. Requires the admin role.

Path parameters

idrequiredintegerThe location id.

Request body

Fields to change.

namestring
timeZonestring
addressAddress

Responses

200OKThe updated location.{ data: Location }
400Bad RequestThe body failed validation.
401UnauthorizedNo token, an expired token, or a malformed one. Sign in again.
403ForbiddenAuthenticated, but not allowed to do this.
429Too Many RequestsRate limited. Retry-After says how long to wait.
Example request
curl -X PATCH https://api.aerscheduler.com/locations/:id \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…","timeZone":"…"}'
delete/locations/{id}

Delete a location

Removes the location. Requires the admin role.

Path parameters

idrequiredintegerThe location id.

Responses

204No ContentSuccess. No body.
400Bad RequestThe location could not be deleted — usually because something still references it.
401UnauthorizedNo token, an expired token, or a malformed one. Sign in again.
403ForbiddenAuthenticated, but not allowed to do this.
429Too Many RequestsRate limited. Retry-After says how long to wait.
Example request
curl -X DELETE https://api.aerscheduler.com/locations/:id \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"