AerScheduler

Organizations

The flight school itself: membership, invitations, and settings.

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

get/invitations

List pending invitations

Requires the admin role.

Responses

200OKSuccess.{ data: object[] }
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/invitations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
get/joinRequests

List join requests

People asking to join a private organization. Requires the admin role.

Responses

200OKSuccess.{ data: object[] }
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/joinRequests \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
get/organizations

List your organizations

Every organization the signed-in account belongs to.

Responses

200OKThe organizations.{ data: Organization[] }
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/organizations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations

Create an organization

Creates an organization, makes you its owner, and returns a token scoped to it. Its first location is created at the same time.

Request body

The new organization.

namerequiredstring
organizationTypestring
aboutstring
showInDirectoryboolean
detailsrequiredobject
locationrequiredobject

Responses

201CreatedCreated.
400Bad RequestValidation failed.
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/organizations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…","details":{},"location":{}}'
patch/organizations

Update your organization

Requires the admin role.

Request body

Fields to change.

namestring
aboutstring
showInDirectoryboolean

Responses

200OKSuccess.{ data: Organization }
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/organizations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…","about":"…"}'
delete/organizations

Delete your organization

Irreversible, and takes every record in it. Requires the owner role.

Responses

204No ContentSuccess. No body.
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/organizations \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
delete/joinRequests/{id}

Delete a join request

Requires the admin role.

Path parameters

idrequiredintegerThe join request id.

Responses

204No ContentSuccess. No body.
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/joinRequests/:id \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
get/organizations/{orgId}

Get an organization

Public detail for one organization.

Path parameters

orgIdrequiredintegerThe organization id.

Responses

200OKSuccess.{ data: Organization }
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/organizations/:orgId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
get/organizations/guests

List guests

Non-members who have appeared on bookings.

Responses

200OKThe guests.{ data: User[] }
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/organizations/guests \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/invite

Invite someone

Emails an invitation with the roles they will get on acceptance. Requires the admin role.

Request body

Who to invite and as what.

emailrequiredstring
adminboolean
instructorboolean
studentboolean
renterboolean
technicianboolean
dispatcherboolean
orgUserGroupIdsinteger[]

Responses

204No ContentSuccess. No body.
400Bad RequestAlready invited, or already a member.
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/organizations/invite \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"email":"you@yourschool.com"}'
get/organizations/ratings

List ratings

The certificates and ratings your organization teaches.

Responses

200OKSuccess.{ data: object[] }
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/organizations/ratings \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/ratings

Create a rating

Requires the admin role.

Request body

The rating.

namerequiredstring
anyInstructorCanTeachrequiredboolean
defaultInstructorRaterequiredintegerHourly rate in cents.

Responses

200OKSuccess.{ data: object }
400Bad RequestValidation failed.
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/organizations/ratings \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…","anyInstructorCanTeach":true,"defaultInstructorRate":1}'
post/joinRequests/{id}/accept

Accept a join request

Requires the admin role.

Path parameters

idrequiredintegerThe join request id.

Responses

200OKSuccess.{ data: object }
204No ContentSuccess. No body.
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/joinRequests/:id/accept \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/joinRequests/{id}/decline

Decline a join request

Requires the admin role.

Path parameters

idrequiredintegerThe join request id.

Responses

200OKSuccess.{ data: object }
204No ContentSuccess. No body.
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/joinRequests/:id/decline \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/join/{orgCode}

Join an organization by code

Joins using the six-character code. If the organization is private this raises a join request for an administrator to approve instead, and answers 201.

Path parameters

orgCoderequiredstringThe organization's join code.

Responses

200OKJoined.
201CreatedA request to join was raised and is awaiting approval.{ data: object }
400Bad RequestYou already belong to this organization.
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/organizations/join/:orgCode \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/leave/{orgId}

Leave an organization

Removes yourself. The last owner cannot leave.

Path parameters

orgIdrequiredintegerThe organization to leave.

Responses

200OKSuccess.{ data: object }
204No ContentSuccess. No body.
400Bad RequestYou cannot leave — you are the last owner or administrator.
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/organizations/leave/:orgId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
patch/organizations/ratings/{ratingId}

Update a rating

Requires the admin role.

Path parameters

ratingIdrequiredintegerThe rating id.

Request body

Fields to change.

namestring

Responses

200OKSuccess.{ data: object }
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/organizations/ratings/:ratingId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"name":"…"}'
delete/organizations/ratings/{ratingId}

Delete a rating

Requires the admin role.

Path parameters

ratingIdrequiredintegerThe rating id.

Responses

204No ContentSuccess. No body.
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/organizations/ratings/:ratingId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/removeUser/{userId}

Remove a member

Removes someone from your organization. Requires the admin role.

Path parameters

userIdrequiredintegerThe user to remove.

Responses

204No ContentSuccess. No body.
400Bad RequestThey cannot be removed — the last owner or administrator, for instance.
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/organizations/removeUser/:userId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"
post/organizations/switch/{orgId}

Switch active organization

Returns a NEW token scoped to the given organization. Because a token carries exactly one organization, this is how a multi-organization integration moves between them — the old token keeps working and stays pointed at the old one.

Path parameters

orgIdrequiredintegerThe organization to switch to.

Responses

200OKSwitched.
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/organizations/switch/:orgId \
  -H "Authorization: Bearer $AERSCHEDULER_TOKEN"