The CloudAhoy account endpoint allows 3rd-parties to create CloudAhoy accounts. To request access to the APIs, contact team@cloudahoy.com.
Accessing the Account endpoint
The account endpoint is available at the following:
https://www.cloudahoy.com/integration/v1/account
All requests to OAuth-secured endpoints must include an Authorization header, which provides an appropriate access token:
Authorization: Bearer <application access token>
The application access token will be provided to the application developer by CloudAhoy.
Creating a CloudAhoy account
Executing an HTTP POST on the account endpoint, providing the appropriate access token and payload, will create a new CloudAhoy account. Any new account will be given a 35-day free trial of CloudAhoy Pro.
CloudAhoy will send an email to the address specified, which contains a temporary password allowing the user to log in to the new CloudAhoy account.
The 3rd-party application will be able to immediately interact with the new account (e.g., upload flights, list flights) using the returned OAuth token.
POST requests to the /account endpoint require the account:create OAuth scope
The following properties must be provided in the POST JSON payload:
Parameter | Value | Notes |
---|---|---|
email |
email address of the user for which the account will be created | |
name |
name of the user for which the account will be created | Must be at least two words |
Return value
Successful POST requests to the account endpoint will return a 200 status code, with the following JSON payload:
Parameter | Type | Description |
---|---|---|
token |
string | An OAuth token authorizing the application creating the account to access the account. The token will allow the OAuth scopes required by the client application (e.g. flights:read flights:import ) |
The token returned is identical to the token that would have been returned via the OAuth authorization flow of a CloudAhoy subscriber.
Unsuccessful POST requests will return the following statuses:
- 400: Missing required field
- 400: Invalid email address
- 400: Invalid name
- 401: Authorization header not present
- 401: The provided authorization token is not valid
- 401: Insufficient scope
- 409: Account with email address already exists
- 500: Error occurred processing the request
Last Updated: