Skip to content
Orillion logo
Soramitsu logo

Authorizing a user in the system

Protocol: HTTP

EncodingJSON

Endpoint/auth/api/v1/authentication-management/session

MethodPOST

Parameters: —

Input/request structure:

Show
json5
{
  email: 'string', //The user’s email address
  signature: 'string', //The encoded signature of a user’s email address
  publicKey: 'string' //The public key of the authentication key pair
}
{
  email: 'string', //The user’s email address
  signature: 'string', //The encoded signature of a user’s email address
  publicKey: 'string' //The public key of the authentication key pair
}

Note

For instructions on how to generate signature and publicKey strings, see Generating key pairs and Signing user email addresses.

Output/response structure:

Show
json5
{
  status: {
    code: 0, //integer($int32)
    name: 'string',
    message: 'string'
  },
  data: {
    accessToken: 'string',
    refreshToken: 'string',
    expirationTime: 0 //integer($int64)
  }
}
{
  status: {
    code: 0, //integer($int32)
    name: 'string',
    message: 'string'
  },
  data: {
    accessToken: 'string',
    refreshToken: 'string',
    expirationTime: 0 //integer($int64)
  }
}

Responses

Response CodeDescription
200User authorization has been successful.
401User signature is incorrect or failed to be decoded.
404User not found.
422User signature either could not be decoded or verified, or the publicKey string is not valid.
500Internal server error.