Assign roles to a user endpoint

Anyone knows how is the request body for Assign roles to a user endpoint

My body request

{
 "roles": [
        "admin"
    ]
}

Response HTTP: 400

{
  "statusCode": 400,
  "error": "Bad Request",
  "message": "Invalid request payload input"
}

get roles response

[
  {
    "id": "rol_vJ8LvtkaBizBowVd",
    "name": "admin",
    "description": "admin's role"
  },
  {
    "id": "rol_n5ecegE12SByX7Oo",
    "name": "user",
    "description": "user's group"
  }
]

found it … It’s role id … not role name.

1 Like

Wohoo glad you have figured it out!

1 Like

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.