Partner Token
The Organization and User Management Partner API provides endpoints to create and manage organizations and their users.
Authentication
The Partner API only accepts JSON Web Token (JWT) based access token issued to a partner and obtained using the client credential grant type. To become a partner and get a partner OAuth client, please contact us via our API Contact Form. If you already have an OAuth client, you can use the Authorization API and the client credential grant type to get a JWT.
Example request to get a partner JWT by using oauth client credential grant type: Note that the authorization header is composed of the oauth client id and the client secret and is base64 encoded.
Authorization: Basic base64(client_id:client_secret)
POST https://account.ezeep.com/oauth/access_token/
Supported attributes:
Attribute | Type | Required | Description |
---|---|---|---|
Authorization |
HTTP Header | yes | Basic {{base_64_encoded_client_id}} |
Content-Type |
HTTP Header | yes | application/x-www-form-urlencoded |
grant_type |
string | yes | client_credentials |
scope |
string | yes |
printing (space sperated scope list) |
If successful, returns HTTP status code and the following response attributes:
Attribute | Type | Description |
---|---|---|
access_token |
string | the access token that is required in Authorization header of API requests |
token_type |
string | for ezeep Blue always “Bearer”, has to be passed in Authorization header |
expires_in |
int | validity time in seconds of the access token |
scope |
string | scope(s) of token |
Example Request
curl -L -X POST "https://account.ezeep.com/oauth/access_token/" \
--header "Authorization: Basic Y1ppTVozSjlWRWtkc1lVdURpR3JKNVFTNVZvVDk2TDB1NWpVbEtEcjo==" \
--header "Content-Type: application/x-www-form-urlencoded" \
--data "grant_type=client_credentials" \
--data "scope=printing"
Example Response
{
"access_token": "eyJ0eXAiO...",
"token_type": "Bearer",
"expires_in": 3600,
"scope": ""
}
The access_token
will be valid for 3600 seconds (i.e. 1 hour) and after that duration you have to request new access token using the same request.
The response contains the access_token
(JWT). For all requests of the partner API, the JWT is sent in the Authorization
header for authentication.