Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Info
  • The token is validity can be specified in the url in minutes, valid values are between 1 and 1440 minutes

  • The token is returned in a json structure with token as key (Ā https://jwt.io/Ā ) and can be handled as a plain string on the client side.

  • New token should be obtained after expiry by calling this endpoint again, not each time an other another endpoint/service is used

Environments / endpoints

...

Code Block
curl -X POST \
  https://ws.di.no/ws/json/auth/v-3/login/1440 \
  -H 'Content-Type: application/json' \
  -dĀ "{\"username\": \"myname\", \"password\": \"secret\"}"

Response object

...

The endpoint replies with a response object in JSON format, containing the following data

Field

Description

Example

Data type

Count

token

The JWT token to be used in subsequent requests

aVeryLongString

String1

The security token should be placed in theĀ Authorization header like this:

...