JWT

Generate Credentials

https://in.staging.decentro.tech/v2/auth/token

Clients can use this API to generate a JSON Web Token (JWT) for secure access to all Decentro Fabric APIs as an alternative to using client_id and client_secret.

Decentro APIs can be accessed using either of the following methods:

  • Client Credentials
  • JWT Tokens

1. Client Credentials

During onboarding, clients receive credentials specific to the selected modules. If you have not received your credentials, please sign up here.

The credentials provided include:

NameDescription
client_idA unique ID assigned to each client
client_secretA secret key assigned to access your Decentro account
⚠️

Credentials are platform-specific. Do not share them internally or externally without appropriate authorization.


2. JWT (JSON Web Token)

JWT (JSON Web Token) is a compact and self-contained mechanism (as per RFC 7519) for securely transmitting information as a JSON object.

JWTs can be generated using the Decentro Auth API with one of the following grant_type values:

  • client_credentials
⏳

JWT tokens are valid for 15 minutes by default.

How to Use JWT for API Authentication

Once a JWT token is generated using the Decentro Auth API, it can be used to authenticate subsequent requests to supported Decentro Fabric APIs.

To authenticate an API request using JWT, pass the generated token in the Authorization header using the Bearer scheme:

Authorization: Bearer <JWT_TOKEN>

Replace <JWT_TOKEN> with the JWT returned by the Generate Credentials API.

JWT tokens are valid for 15 minutes by default. Once the token expires, generate a new token before making further API requests.

Alternatively, supported APIs can be authenticated using the client_id and client_secret credentials provided by Decentro.

Body Params
string
required

Required. Values: client_credentials

string
required

Required for client_credentials grant type

string
required

Required for client_credentials grant type

apis
array of objects
required

List of specific endpoints to access

apis*
Responses

Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json