Generate a Key
API keys are generated by making a POST
request to the API key endpoint. Authentication via a bearer token is required to access this endpoint.
After generation a key cannot be retrieved in full, please ensure you make a copy of the key.
Create a new API Key
POST
https://api.olisystems.com/user/api-key
Headers
Name
Value
Content-Type
application/json
Authorization*
Bearer <token>
Body (Optional)
Name
Optional
Type
Description
name
string
A custom name for the API key (max 50 characters).
expiry
number
The expiration date of the API key, specified as an epoch timestamp in milliseconds.
Example Request
{
"name": "My API Key",
"expiry": 1735689600000
}
Example Response
{
"code": 200,
"data": {
"apiKey": "gAAAAABnP7fAh9VNmiIkHlpLRMmDNduOCDls4rgdngQpqA0GDNQXipd2ljo4YmNec9K56kvPP5u6zfsEIVrQXD9C_ZInRmH7XZ9BpguHJgd2W2xJVqdZL_Rp6xHR6nb-T",
"apiKeyId": "d0e13388-c3b8-4bd4-8361-4b699828cde6"
},
"message": "User API KEY. PLEASE make a copy. This key can not be retrieved again.",
"status": "success"
}
Last updated
Was this helpful?