API Keys
API keys are used to authenticate requests to our API. They can be generated with custom user defined or predefined roles, and can be revoked at any time.
Requirements
- A workspace setup with Modernbanc.
Create
- Navigate to the
Settings
tab in the navigation dropdown or by pressingG
and thenS
. - Navigate to the
API Keys
tab in the navigation dropdown or by pressingG
and thenA
. - Click the
Create
button in the upper right corner.
- Enter a name for the API key.
- Select a role for the key.
- Choose an expiration date.
- Click the
Create
button.
Edit
curl --location --request PUT 'https://api.modernbanc.com/v1/api-keys/YOUR_API_KEY_ID' \
--header 'Content-Type: application/json' \
--header 'Authorization: APIKey YOUR_API_KEY' \
--data-raw '{
"name": "APIKey updated name"
}'
Revoke
curl --location --request PUT 'https://api.modernbanc.com/v1/api-keys/YOUR_API_KEY_ID' \
--header 'Content-Type: application/json' \
--header 'Authorization: APIKey YOUR_API_KEY' \
--data-raw '{
"status": "revoked"
}'
Delete
curl --location --request DELETE 'https://api.modernbanc.com/v1/api-keys/YOUR_API_KEY_ID' \
--header 'Content-Type: application/json' \
--header 'Authorization: APIKey YOUR_API_KEY' \