Automated API Token Renewal

Note: Ardexa hosts clouds in multiple regions as subdomains of ardexa.com. Where you see a reference to mycloud in this document, replace it with the appropriate subdomain for your cloud, eg: mycloud.ardexa.com -> app.ardexa.com or eur1.ardexa.com

When you are issued an API token, there's a good chance it will be a "self-renewing" token. So rather than manually generating a new token (or having one sent to you) each time your existing token expires, instead you can use your existing token to fetch a new token with an updated expiry date. This article will explain the procedure to automate the process.

Using your existing, non-expired token, send a GET request to https://[mycloud].ardexa.com/api/v1/token/renew. This will return an object with a token property containing your new token.

API token renewal

GET https://[mycloud].ardexa.com/api/v1/token/renew

Headers

NameTypeDescription

authorization

string

Your existing token in the form bearer $TOKEN

{"token":"eyJhb..."}

For example, using curl:

curl -H "authorization: bearer $TOKEN" https://[mycloud].ardexa.com/api/v1/token/renew

If your token has already expired, you will NOT be able to use the auto-renewal system. Please manually generate a new token or contact the workgroup owner.

Last updated