https://sandbox-sts.ddp.akoya.com/oauth2/token
Use the service token endpoint to generate an access token which will last for 24-hours.
The header must contain Basic Auth (your clientId and secret base64 encoded), and the body of the request requires the scope specifying the service. After the token expires, use this endpoint to generate a new one.
Set the parameters used for your service token. Indicate "grant_type = client credentials" and specify the scope of the token for the Akoya service you're using. For instance, for the Akoya Management API, scope=app_management_v2 or for the Notifications API, notifications_subscriptions advisory.
grant_type*
client_credentials
Defaults to `client_credentials`, your `clientId` and `clientSecret`.
scope*
app_management_v2
The Akoya service accessed by provided credentials.
200
Token
Response
access_token
string
expires_in
integer
scope
string
token_type
string
404
Not Found
const options = {
"method": "POST",
"headers": {
"accept": "application/x-www-form-urlencoded",
"content-type": "application/x-www-form-urlencoded"
},
"body": new URLSearchParams({
"grant_type": "client_credentials",
"scope": "app_management_v2"
})
}};
fetch('https://sandbox-sts.ddp.akoya.com/oauth2/token', options)
.then(response => response.json())
.catch(err => console.error(err));