APISettings
Create API key
Mint a new API key with the scopes you name. The key itself is returned once and is never retrievable again. Requires the admin scope.
POST
/settings/api-keyscurl -X POST "https://productlane.com/api/v2/settings/api-keys" \
-H "Authorization: Bearer $PRODUCTLANE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"label": "string",
"scopes": [
"string"
]
}'Authorization
AuthorizationstringheaderrequiredBearer authentication header of the form
Bearer <token>, where<token>is your auth token.
Body
application/json
labelstringrequiredscopesstring[]requiredexpires_atstring<date-time> | null
Response
application/json
Successful response
idstringrequiredlabelstringrequiredkey_previewstringrequiredscopesstring[]requiredlast_used_atstring | nullrequiredexpires_atstring | nullrequiredrevoked_atstring | nullrequiredcreated_atstringrequiredkeystringrequiredShown once; store it now.
{
"id": "string",
"label": "string",
"key_preview": "string",
"scopes": [
"string"
],
"last_used_at": "string",
"expires_at": "string",
"revoked_at": "string",
"created_at": "string",
"key": "string"
}