Skip to main content
POST
/
api-identity
/
auth
/
local
/
login
Generate authorization token for local user
curl --request POST \
  --url https://prod01-apigw.{customer_name}.fabric.zone/api-identity/auth/local/login \
  --header 'Content-Type: application/json' \
  --header 'x-site-context: <x-site-context>' \
  --data '{
  "accountId": 4781348886,
  "username": "[email protected]",
  "password": "joHn@123456789!"
}'
{
  "_id": "60c3a2c476f9c21239d836ca",
  "account": {
    "accountId": 8739392294
  },
  "roles": [
    "Admin"
  ],
  "permissions": [
    "read:user"
  ],
  "refreshToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVC.eyJpZCI6IjYwYzNhMmM0....",
  "accessToken": "eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVC.eyJpZCI6IjYwYzNhMmM0...."
}

Headers

x-site-context
object
required

Body

application/json
accountId
number
Example:
username
string
Example:
password
string
Example:

Response

_id
string
Example:
account
object
roles
string[]
permissions
string[]
refreshToken
object
Example:
accessToken
object
Example: