Google_Service_Iam_Resource_OrganizationsRoles
extends Google_Service_Resource
in package
The "roles" collection of methods.
Typical usage is:
$iamService = new Google_Service_Iam(...);
$roles = $iamService->roles;
Table of Contents
- $client : Google_Client
- $methods : array<string|int, mixed>
- $resourceName : string
- $rootUrl : string
- $serviceName : string
- $servicePath : string
- $stackParameters : mixed
- __construct() : mixed
- call() : Google_Http_Request|expectedClass
- TODO: This function needs simplifying.
- create() : Google_Service_Iam_Role
- Creates a new custom Role. (roles.create)
- createRequestUri() : string
- Parse/expand request parameters and create a fully qualified request uri.
- delete() : Google_Service_Iam_Role
- Deletes a custom Role. When you delete a custom role, the following changes occur immediately: * You cannot bind a member to the custom role in an IAM Policy. * Existing bindings to the custom role are not changed, but they have no effect. * By default, the response from ListRoles does not include the custom role. You have 7 days to undelete the custom role. After 7 days, the following changes occur: * The custom role is permanently deleted and cannot be recovered. * If an IAM policy contains a binding to the custom role, the binding is permanently removed. (roles.delete)
- get() : Google_Service_Iam_Role
- Gets the definition of a Role. (roles.get)
- listOrganizationsRoles() : Google_Service_Iam_ListRolesResponse
- Lists every predefined Role that IAM supports, or every custom role that is defined for an organization or project. (roles.listOrganizationsRoles)
- patch() : Google_Service_Iam_Role
- Updates the definition of a custom Role. (roles.patch)
- undelete() : Google_Service_Iam_Role
- Undeletes a custom Role. (roles.undelete)
- convertToArrayAndStripNulls() : mixed
Properties
$client
private
Google_Client
$client
$methods
private
array<string|int, mixed>
$methods
$resourceName
private
string
$resourceName
$rootUrl
private
string
$rootUrl
$serviceName
private
string
$serviceName
$servicePath
private
string
$servicePath
$stackParameters
private
mixed
$stackParameters
= array('alt' => array('type' => 'string', 'location' => 'query'), 'fields' => array('type' => 'string', 'location' => 'query'), 'trace' => array('type' => 'string', 'location' => 'query'), 'userIp' => array('type' => 'string', 'location' => 'query'), 'quotaUser' => array('type' => 'string', 'location' => 'query'), 'data' => array('type' => 'string', 'location' => 'body'), 'mimeType' => array('type' => 'string', 'location' => 'header'), 'uploadType' => array('type' => 'string', 'location' => 'query'), 'mediaUpload' => array('type' => 'complex', 'location' => 'query'), 'prettyPrint' => array('type' => 'string', 'location' => 'query'))
Methods
__construct()
public
__construct(mixed $service, mixed $serviceName, mixed $resourceName, mixed $resource) : mixed
Parameters
- $service : mixed
- $serviceName : mixed
- $resourceName : mixed
- $resource : mixed
Return values
mixed —call()
TODO: This function needs simplifying.
public
call( $name, $arguments[, $expectedClass = null ]) : Google_Http_Request|expectedClass
Parameters
Tags
Return values
Google_Http_Request|expectedClass —create()
Creates a new custom Role. (roles.create)
public
create(string $parent, Google_Service_Iam_CreateRoleRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_Role
Parameters
- $parent : string
-
The
parentparameter's value depends on the target resource for the request, namelyprojectsororganizations. Each resource type'sparentvalue format is described below: *projects.roles.create():projects/{PROJECT_ID}. This method creates project-level custom roles. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles*organizations .roles.create():organizations/{ORGANIZATION_ID}. This method creates organization-level custom roles. Example request URL:https://iam.googleapis.com/v1/organizations/{ORGANIZATION_ID}/rolesNote: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID. - $postBody : Google_Service_Iam_CreateRoleRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Iam_Role —createRequestUri()
Parse/expand request parameters and create a fully qualified request uri.
public
createRequestUri(string $restPath, array<string|int, mixed> $params) : string
Parameters
- $restPath : string
- $params : array<string|int, mixed>
Tags
Return values
string —$requestUrl
delete()
Deletes a custom Role. When you delete a custom role, the following changes occur immediately: * You cannot bind a member to the custom role in an IAM Policy. * Existing bindings to the custom role are not changed, but they have no effect. * By default, the response from ListRoles does not include the custom role. You have 7 days to undelete the custom role. After 7 days, the following changes occur: * The custom role is permanently deleted and cannot be recovered. * If an IAM policy contains a binding to the custom role, the binding is permanently removed. (roles.delete)
public
delete(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_Role
Parameters
- $name : string
-
The
nameparameter's value depends on the target resource for the request, namelyprojectsororganizations. Each resource type'snamevalue format is described below: *projects.roles.delete():projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}. This method deletes only custom roles that have been created at the project level. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}- [
organizations.roles.delete()](/iam/reference/rest/v1/organizations.roles /delete):organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}. This method deletes only custom roles that have been created at the organization level. Example request URL:https://ia m.googleapis.com/v1/organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}Note: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID.
- [
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Iam_Role —get()
Gets the definition of a Role. (roles.get)
public
get(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_Role
Parameters
- $name : string
-
The
nameparameter's value depends on the target resource for the request, namelyroles,projects, ororganizations. Each resource type'snamevalue format is described below: *roles.get():roles/{ROLE_NAME}. This method returns results from all [predefined roles](/iam/docs/understanding- roles#predefined_roles) in Cloud IAM. Example request URL:https://iam.googleapis.com/v1/roles/{ROLE_NAME}*projects.roles.get():projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}. This method returns only custom roles that have been created at the project level. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}- [
organizations.roles.get()](/iam/reference/rest/v1/organizations.roles/ge t):organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}. This method returns only custom roles that have been created at the organization level. Example request URL:https://iam.goo gleapis.com/v1/organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}Note: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID.
- [
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Iam_Role —listOrganizationsRoles()
Lists every predefined Role that IAM supports, or every custom role that is defined for an organization or project. (roles.listOrganizationsRoles)
public
listOrganizationsRoles(string $parent[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_ListRolesResponse
Parameters
- $parent : string
-
The
parentparameter's value depends on the target resource for the request, namelyroles,projects, ororganizations. Each resource type'sparentvalue format is described below: *roles.list(): An empty string. This method doesn't require a resource; it simply returns all predefined roles in Cloud IAM. Example request URL:https://iam.googleapis.com/v1/roles*projects.roles.list():projects/{PROJECT_ID}. This method lists all project-level custom roles. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles*organizations .roles.list():organizations/{ORGANIZATION_ID}. This method lists all organization-level custom roles. Example request URL:https://iam.googleapis.com/v1/organizations/{ORGANIZATION_ID}/rolesNote: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID. - $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Iam_ListRolesResponse —patch()
Updates the definition of a custom Role. (roles.patch)
public
patch(string $name, Google_Service_Iam_Role $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_Role
Parameters
- $name : string
-
The
nameparameter's value depends on the target resource for the request, namelyprojectsororganizations. Each resource type'snamevalue format is described below: *projects.roles.patch():projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}. This method updates only custom roles that have been created at the project level. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}- [
organizations.roles.patch()](/iam/reference/rest/v1/organizations.roles/ patch):organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}. This method updates only custom roles that have been created at the organization level. Example request URL:https://iam.goo gleapis.com/v1/organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}Note: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID.
- [
- $postBody : Google_Service_Iam_Role
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Tags
Return values
Google_Service_Iam_Role —undelete()
Undeletes a custom Role. (roles.undelete)
public
undelete(string $name, Google_Service_Iam_UndeleteRoleRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Iam_Role
Parameters
- $name : string
-
The
nameparameter's value depends on the target resource for the request, namelyprojectsororganizations. Each resource type'snamevalue format is described below: *projects.roles.undelete():projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}. This method undeletes only custom roles that have been created at the project level. Example request URL:https://iam.googleapis.com/v1/projects/{PROJECT_ID}/roles/{CUSTOM_ROLE_ID}- [
organizations.roles.undelete()](/iam/reference/rest/v1/organizations.rol es/undelete):organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_ID}. This method undeletes only custom roles that have been created at the organization level. Example request URL:https ://iam.googleapis.com/v1/organizations/{ORGANIZATION_ID}/roles/{CUSTOM_ROLE_I D}Note: Wildcard (*) values are invalid; you must specify a complete project ID or organization ID.
- [
- $postBody : Google_Service_Iam_UndeleteRoleRequest
- $optParams : array<string|int, mixed> = array()
-
Optional parameters.
Return values
Google_Service_Iam_Role —convertToArrayAndStripNulls()
protected
convertToArrayAndStripNulls(mixed $o) : mixed
Parameters
- $o : mixed