Authentication
Blue API (BETA) authentication is now available here. Check it out.
Authentication for Wave (OpenAPI) is separated at the moment. We will be unifying all logins for all our APIs going forward. An announcement will be made once it's done.
Before you can access Alphaus API services, you need to get an access token first. You will then use this token in your succeeding calls to the API using the Authorization: Bearer {token} HTTP header. Alphaus API tokens are JSON Web Tokens (JWT).
Use the following endpoints to acquire product-specific access tokens. Tokens are not compatible between the two. Ripple access tokens can only be used for Ripple endpoints; Wave access tokens are only valid on Wave endpoints.
1
# Ripple
2
https://login.mobingi.com/ripple/access_token
3
4
# Wave
5
https://login.mobingi.com/access_token
Copied!
Request
To obtain an access token, send a POST message to the access token endpoint using the format described below.
1
POST {access-token-url} HTTP1.1
2
Content-Type: multipart/form-data
3
4
{body formdata}
Copied!
The following table describes the formdata you need to supply as your POST body.
Name
Value
grant_type
Valid values: password, client_credentials
client_id
The client id you received from Alphaus or from API.
client_secret
The client secret you received from Alphaus or from API.
username
You account username. Required if grant_type is set to password.
password
You account password. Required if grant_type is set to password.
scope
Valid values: openid
Response
1
HTTP/1.1 200 OK
2
3
{
4
"id_token": "eyJ0eXAiOiJKV1Q...",
5
"token_type": "Bearer",
6
"expires_in": 86400,
7
"access_token": "eyJ0eXAiOiJKV1Q...",
8
"refresh_token": "def50200..."
9
}
Copied!
Using bluectl
You can also use our bluectl CLI tool to generate access tokens. It is designed to work with the client_credentials grant type, although it supports the password grant type as well. To set the required environment variables for authentication, check out this document.
1
# Simple version:
2
$ bluectl access-token
3
4
# You can also access our beta (next) environment:
5
$ bluectl access-token --beta
6
7
# Use with other commands (example):
8
$ curl -H "Authorization: Bearer $(bluectl access-token)" \
9
https://some-ripple-endpoint/...
Copied!
Last modified 5mo ago
Copy link