You will need your API Key and API Secret before you can start. If you do not have these, please go through step 1 of Setup Credly on Praxio

To request an access token, send a POST request to /authenticate with a basic authentication header. For example:

curl \
 -H "X-Api-Key: <your API key>" \
 -H "X-Api-Secret: <your API secret>" \
 --user "<email address>:<password>" \
 --data "" \
 https://api.credly.com/v1.1/authenticate

If authentication succeeds, you will receive a response as follows:


{
  "meta": {
    "status_code": 200,
    "status": "OK",
    "message": "",
    "more_info": null
  },
  "data": {
    "token": "<access_token>",
    "refresh_token": "<refresh_token>"
  }
}

Access tokens are specific to your app and will expire three years after they're issued. For most use cases, you will only need to store the access token in your app's session for signing future requests. To sign requests with an access token, simply pass it as the access_token parameter. For example:

curl \
 -H "X-Api-Key: <your API key>" \
 -H "X-Api-Secret: <your API secret>" \
 "https://api.credly.com/v1.1/me?access_token=<your access token>"

If you need to persist user sessions longer than 3 years, instructions for renewing an access token using a refresh token is available in the User Management documentation.

Did this answer your question?