public
UserRole

Adds a User or a Group to an Application with a Role

Changed on
post/orgs/{orgId}/apps/{appId}/users

Request

  • Base URL
    https://api.humanitec.io
  • URL
    https://api.humanitec.io/orgs/{orgId}/apps/{appId}/users
  • Auth
    none declared

Path parameters

orgIdstring required

The Organization ID

appIdstring required

The Application ID

Request body

idstring required

The User or Group Id

rolestring required

The role that this User or Group holds

Example request

{
  "id": "730c1f96-8ee5-4bff-8c22-898e0530b924",
  "role": "manager"
}

Response

The User or Group ID and the associated role.

created_atstring required

The time the user or the group was first registered with Humanitec

emailstring

The email address of the user from the profile

idstring required

The User or Group Id

invitestring

The status of an invitation (If applicable)

namestring required

The name the User or Group goes by

rolestring required

The role that this User or Group holds

typestring required

The type of the account. Could be user, service, group or system

idp_idstring

The IdP id the group is registered for. Empty if user is not a group.

Example response

{
  "created_at": "2020-12-19T09:32:46Z",
  "email": "jo.trigg@awesomecorp.com",
  "id": "730c1f96-8ee5-4bff-8c22-898e0530b924",
  "invite": "accepted",
  "name": "Jo Trigg",
  "role": "manager",
  "type": "user"
}

Changes

    • breaking

      added the pattern ^[a-z0-9](?:-?[a-z0-9]+)+$ to the path request parameter appId

    • breaking

      the request property became required

    • breaking

      the request property became required

    • breaking

      added the pattern ^[a-z0-9](?:-?[a-z0-9]+)+$ to the request property

    • warning

      for the path request parameter appId, the maxLength was set to 50

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the request property

    • warning

      removed the optional property from the response with the status

    • info

      added the media type application/json for the response with the status

    • info

      added the non-success response with the status

    • info

      added the optional property to the response with the status