Function: createPermissionGrant()
ts
function createPermissionGrant(
client,
parameters,
options?
): Promise<{
[key: string]: unknown;
holder?: {
[key: string]: unknown;
expand?: string;
parameter?: string;
type: string;
value?: string;
};
id?: number;
permission?: string;
self?: string;
}>;Defined in: src/cloud/api/permissionSchemes.ts:285
Creates a permission grant in a permission scheme.
Permissions required:Administer Jira global permission.
Parameters
| Parameter | Type | Description |
|---|---|---|
client | Client | - |
parameters | { expand?: | "all" | "user" | "group" | "field" | string & object | "permissions" | "projectRole" | ( | "all" | "user" | "group" | "field" | string & object | "permissions" | "projectRole")[]; holder?: { expand?: string; parameter?: string; type: string; value?: string; }; id?: number; permission?: string; schemeId: number; self?: string; } | - |
parameters.expand? | | "all" | "user" | "group" | "field" | string & object | "permissions" | "projectRole" | ( | "all" | "user" | "group" | "field" | string & object | "permissions" | "projectRole")[] | Use expand to include additional information in the response. This parameter accepts a comma-separated list. Note that permissions are always included when you specify any value. Expand options include: - permissions Returns all permission grants for each permission scheme. - user Returns information about the user who is granted the permission. - group Returns information about the group that is granted the permission. - projectRole Returns information about the project role granted the permission. - field Returns information about the custom field granted the permission. - all Returns all expandable information. |
parameters.holder? | { expand?: string; parameter?: string; type: string; value?: string; } | - |
parameters.holder.expand? | string | Expand options that include additional permission holder details in the response. |
parameters.holder.parameter? | string | As a group's name can change, use of value is recommended. The identifier associated withthe type value that defines the holder of the permission. |
parameters.holder.type? | string | The type of permission holder. |
parameters.holder.value? | string | The identifier associated with the type value that defines the holder of the permission. |
parameters.id? | number | The ID of the permission granted details. |
parameters.permission? | string | The permission to grant. This permission can be one of the built-in permissions or a custom permission added by an app. See Built-in permissions in Get all permission schemes for more information about the built-in permissions. See the project permission and global permission module documentation for more information about custom permissions. |
parameters.schemeId? | number | The ID of the permission scheme in which to create a new permission grant. |
parameters.self? | string | The URL of the permission granted details. |
options? | RequestOptions | - |
Returns
Promise<{ [key: string]: unknown; holder?: { [key: string]: unknown; expand?: string; parameter?: string; type: string; value?: string; }; id?: number; permission?: string; self?: string; }>