Authentication and login with API Key

HTTP Request login

This API call allows you to login to the application via your API key. As a response your personal token will be returned, it will have to be used in subsequent calls as authorization.

POST https://app.dedit.io/api/v2/auth/login 

Headers

NameValueDescription

Content-Type

application/json

The content type of the request body

Request body

NameTypeDescription

API key

string

code used to authenticate and authorize access to the API

Example of a valid request body:

{
"apiKey":"0af8b170cxxxxxxxxcb63cd129cc16f"
}

The above command returns a JSON structured as follows:

{
"token":"eyJ0eXAiOiJKV1QiLCJhbxxxxxxxUzI1NiJ9.eyJmaXJzdE5hbWUiOiJTaW1vbmUiLCJsYXN0TmFtZSI6IlNwYWdub2xvIiwicGFzc3dvcmQiOiI5ZTI0MTg4MzE4MGY4M2NiYzcxNzRiMmQzYTllZjJlOTBjZGY2Y2JhMDg5Yzc1YTFlZDRhZDM2YzcwMzZkZjQ2IiwibmJmIjoxNjgzNTUzOTE0LCJpc3MiOiJCQ0kiLCJleHAiOjE2ODM1ODk5MTQsImlhdCI6MTY4MzU1MzkxNCwidXNlcklkIjoxMzkwLCJlbWFpbCI6InNpbW9uZXNwYWdub2xvQGJsb2NrY2hhaW5pdGFsaWEuaW8ifQ.77C12_QOAhAFwX2OVQSjnYJDv71uYNKYvN2QJjMuSq"
}

Dedit depends on JWTs to allow access to its RESTful API offering blockchain services.

The service expects the JWT token to be included in all API requests (except the open verification endpoint) in a header that looks like:

Authorization: Bearer $TOKEN

You must replace $TOKEN with your personal JWT.

After you get your personal token, you’ll need to put it in your API call headers.

Request Headers example:

Authorization:
Bearer eyJ0eXAiOiJKV1QiLCJhbxxxxxxxUzI1NiJ9.eyJmaXJzdE5hbWUiOiJTaW1vbmUiLCJsYXN0TmFtZSI6IlNwYWdub2xvIiwicGFzc3dvcmQiOiI5ZTI0MTg4MzE4MGY4M2NiYzcxNzRiMmQzYTllZjJlOTBjZGY2Y2JhMDg5Yzc1YTFlZDRhZDM2YzcwMzZkZjQ2IiwibmJmIjoxNjgzNTUzOTE0LCJpc3MiOiJCQ0kiLCJleHAiOjE2ODM1ODk5MTQsImlhdCI6MTY4MzU1MzkxNCwidXNlcklkIjoxMzkwLCJlbWFpbCI6InNpbW9uZXNwYWdub2xvQGJsb2NrY2hhaW5pdGFsaWEuaW8ifQ.77C12_QOAhAFwX2OVQSjnYJDv71uYNKYvN2QJjMuSq

Content-Type:
application/json

Last updated