Basic Auth
Access Aidbox API from your Service
Basic Auth
The simplest way to programmatically interact with Aidbox API is to use Basic Access Authentication. In this scheme you provide client credentials with every HTTP request in the special header - Authorization: Basic <credentials>
, where <credentials>
is the base64 encoding of Client.id and Client.secret joined by a colon:
Register Client
The first step is to create resource Client with id & secret and add 'basic'
to it's grant_types
collection:
By default, your client does not have any permissions to access Aidbox REST API. So you probably want to configure some using Aidbox Access Policy. Access Policy can be linked to the specific client by providing the reference to clients in link
collection. For more sophisticated configuration, see Access Policies documentation.
Making Requests with Basic Auth
Now you can make HTTP requests with Authorization
header set to 'Basic ' + base64(client.id +':' + client.secret):
Example with curl:
Most HTTP clients will do Authorization
header construction for you:
Test Basic in Auth Sandbox
Last updated