JavaScript
const options = { method: 'POST', headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'}, body: JSON.stringify({name: '<string>', expiresAt: '2023-11-07T05:31:56Z'}) }; fetch('https://blackbox.dasha.ai/api/v1/web-integrations/{integrationId}/tokens', options) .then(res => res.json()) .then(res => console.log(res)) .catch(err => console.error(err));
{ "tokenId": "<string>", "token": "<string>", "name": "<string>", "createdAt": "2023-11-07T05:31:56Z", "expiresAt": "2023-11-07T05:31:56Z" }
UUID of the integration to add the token to
Token creation parameters including name and optional expiration
1
Returns the created token details
Was this page helpful?