Logo
15_Days_of_Postman_-_for_testers_IvanKo API Documentation

Update a collection's roles

PATCH {{baseUrl}}/collections/{{collectionId}}/roles

Updates the roles of users, groups, or teams in a collection. On success, this returns a 204 No Content response.

Include the following values in the roles array of objects:

  • op — (Required) A string value that contains the operation to perform. Accepts the update value.

  • path — (Required) A string value that contains the resource to perform the action on. Accepts the /user, /group, or /team value.

  • value — (Required) A list of objects that contain the following values:

    • id — (Required) An integer value that contains the user, group, or team ID.
    • role — (Required) A string value that contains the role's type:

      • EDITOR — Can edit collections directly.
      • VIEWER — Can view, fork, and export collections.

Note:

  • Only users assigned the EDITOR [role] in the collection can use this endpoint.
  • This endpoint does not support the external [Partner or Guest roles]

 

Body PARAM

Key Datatype Required Description 



HEADERS

Key Datatype Required Description 




RESPONSES

status





Curl
curl -X PATCH 'https://api.getpostman.com/collections/collectionId/roles'

ENDPOINTS