Skip to main content
Version: Hosted

Log in to Mender

POST 

/api/management/v1/useradm/auth/login

Accepts user credentials via standard Basic Auth, and returns a JWT token to be used for authentication in subsequent requests.

Request

Responses

Authentication successful - a new JWT is issued and returned with content type application/jwt. The JWT is signed with the API's private key ('RS256' signing algorithm), and contains the following standard claims:

  • 'iss' - issuer
  • 'exp' - expiry date
  • 'sub' - unique, autogenerated user ID
  • 'scp' - 'mender.*', allows access to all APIs/methods.

If the login process requires SSO, the content type will be application/json and the body will contain a JSON document containing the following properties:

  • 'id' - the SSO integration ID
  • 'kind' - the SSO kind, e.g., 'sso/saml' or 'sso/oidc'

Example response: {"id": "1a97b53f-9b84-5048-8874-df01f4f58f78", "kind": "sso/saml"}