Permissions

Create team permissions

Changed on

Creates the permission set for one team, named "<team name> Permissions" (fixed from then on), links it to the team and stores its initial permissions. A team can have one active set. Send name (and optionally teamIds) instead of teamId to create a named role that can be given to any number of teams; each listed team's current custom role is replaced. You can only turn on permissions you have yourself. Requires permissions.manage (only the owner has it by default), and a recent sign-in.

post/v1/permissions/sets

Request

  • Base URL
    https://api.openworklabs.com
  • Auth
    • API key in header x-api-key
    • or HTTP bearer

Request body

CreatePermissionSetBody required
teamId, string typeid

The one team this set applies to, named "<team name> Permissions". A team can have one active permission set. Required unless Shared roles is on and name is given.

name, string

Shared roles: the role's name. Required when teamId is left out.

teamIds, string[]

Shared roles: teams that get this role now. Each team's current custom role is replaced. Left out or empty, the role starts with no team.

memberIds, string[]

People who get this role directly now, without a team. Each person's current directly given role is replaced. Needs members.update as well, and can't include yourself. Only with name.

permissions, object[] required

Initial status per key. Keys left out, or set to deny, start denied.

Response

Team permission set created.

PermissionSetResponse required
set, PermissionSetDetail required

Changes

    • warning

      added the new billing_manager_default enum value to the set/kind response property for the response status

    • warning

      added the new own_role enum value to the anyOf[#/components/schemas/PermissionEditError]/error response property for the response status

    • warning

      added the new own_role enum value to the anyOf[#/components/schemas/PermissionEditError]/error response property for the response status

    4 more changes in this revision