Pangolin icon

Pangolin

Interact with the Pangolin API

Actions142

User → Grant users access to a resource, replacing any existing ones.

AI-generated

Summary

Replace all existing access users for a specified resource by granting access exclusively to the users provided.

Inputs

  • resourceId (required) — The ID of the resource for which user access is to be granted.
  • body (required) — A JSON object containing the array of user IDs to grant access to the resource, e.g., { "userIds": ["string"] }.
  • options.rawResponse — Optional boolean to return the full raw response instead of splitting arrays into individual items.

Output shape

A JSON object representing the response from the API, which may either be a single object or a list of users granted access depending on the raw response option.

If 'Raw Response' option is true, the full JSON response is returned as is; otherwise, arrays in the response are split into individual items. Errors will halt execution unless 'Continue On Fail' is enabled, in which case error messages are returned per item.

Examples

Example 1: Grant access to users with IDs 'user1' and 'user2' to a resource with ID 'resource123', replacing any existing user access.

Set 'Resource ID' to 'resource123', provide a body JSON with 'userIds' property as ['user1', 'user2'], and leave 'Raw Response' unset or false.

Discussion