Prisma

Assign roles

Assign roles to a user.

POST
/api/v1/admin/roles/{user_id}

Authorization

HTTPBearer
AuthorizationBearer <token>

In: header

Path Parameters

user_id*User Id

User ID

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X post "http://localhost:8000/api/v1/admin/roles/string" \  -H "Content-Type: application/json" \  -d '{    "role_keys": [      "string"    ]  }'
Empty
{
  "detail": [
    {
      "loc": [
        "string"
      ],
      "msg": "string",
      "type": "string"
    }
  ]
}