Testing Credentials

This section contains information related to Testing Environment (Staging) and how to test Decentro APIs.

What are Testing credentials?

These are credentials provided to each platform based on their requirements and the module they opt to test out. You can access the APIs of the respective modules that you're interested in and have a discussion with our business team.

With the credentials, you can test our APIs in the same way as your live credentials and check out how our APIs provide responses on a test environment called 'Staging'. These credentials are designed to work in this environment only and production credentials will be shared separately post-closure of formalities.

How do I test the APIs?

While you are onboarded on the test environment ('Staging') by our team, you will receive the credentials for the modules you've chosen to go with. If you haven't got your testing credentials yet, you can get them by signing up here.

You'll get the below important credentials for each module that you choose -

NameDescription
client_idThis is a unique id assigned to each client
client_secretThis is a client-specific password/secret_key to access the account
module_secretThis is a module secret that is used to access certain APIs from a module.
provider_secret (In some modules)This is a provider secret that is used to access certain APIs from a module.

Please note that the credentials are unique to a platform and should not be shared within the organization without consent or with any external partners.

2. JWT

JWT stands for JSON Web Token. It is an open standard (RFC 7519) that defines a compact and self-contained way for securely transmitting information between parties as a JSON object.

  • Customers can generate JWT using our Auth API with various grant types in the request body.
  • Customers can pass the grant_type as
    • client_credentials
    • refresh_token
    • user_credentials
  • The JWT token is valid for 15 minutes by default

Generate JWT with Client Credentials

Customers can generate JWT with Client Credentials -

Request ParameterDescription
grant_typeTo generate JWT with client credentials, customers need to pass grant_type as client_credentials
client_idThe client id generated for the customer at Decentro
client_secretThe client secret generated for the customer at Decentro

Generate JWT with Refresh Token

Customers can generate JWT with Refresh Token -

Request ParameterDescription
grant_typeTo generate JWT with refresh token, customers need to pass grant_type as refresh_token
refresh_tokenThe refresh token that was generated while creating JWT

Generate JWT with User Credentials

Customers can generate JWT with User Credentials -

Request ParameterDescription
grant_typeTo generate JWT with user credentials, customers need to pass grant_type as user_credentials
emailThe email ID registered against the customer at Decentro
passwordThe password for the dashboard is associated with the registered email ID at Decentro

How to use JWT in Decentro APIs?

Once customers generate JWT, they can use this instead of client_id and client_secret in API Authorization.

  • Customers can pass JWT in headers instead of client_id and client_secret to access the API
  • All our APIs will work with both the methods, Client Credentials, and JWT

👍

Postman API Collection

Decentro's APIs are best tested on Postman. You can export the API collection here.