Using Bearer Tokens
Agencies will create a Bearer Token that should be used on all RESTful requests. Add in an Authentication header that looks like the below.Authentication: Bearer <TOKEN>
Creating a Bearer Token
To create a Bearer token you will need to login into the GovWorx administration area with System Administration privileges.Step 1: Role Privileges to Manage Bearer Tokens
Configure a user role inSettings → Roles that will be able to manage API bearer tokens - there are 3 permissions associated with the viewing, creation, and deletion of tokens:
API Token Management
-
Create API Tokens- Enables the user to access the dialog to create new API tokens -
Delete API Tokens- Enables the user to access the dialog to delete existing API tokens -
View API Tokens- “Parent” permission enabling API Bearer Tokens settings page
Step 2: Role Permissions - Token:
You can tie various permissions to the Bearer Token to restrict access to various parts of the API.Step 3 - API Bearer Tokens Page
Provided that the user is now in a role that is capable of managing API Bearer Tokens (at least has the permission toView API Tokens), the user can now access the page to manage tokens by navigating to Settings → Security → API Bearer Tokens:
The screenshot above is the view for a user that has full permissions (Create API Tokens, Delete API Tokens, View API Tokens). There is a “Create Token” button in the top right to open the dialog for creating a new token (this button being present is dependent on the permission - Create API Tokens). There is also a small red trash icon on the far right column of the “Delete Me” example token (this icon being present is dependent on the permission - Delete API Tokens).

