setIamPolicy
Note: This is an admin API.
Set a specified resource’s IAM policy.
Required permission
To call this endpoint, you must have the following permission:
cloudiot.registries.setIamPolicy
HTTP request
PUT /api/v/4/webhook/execute/{adminSysKey}/policy?method=setIamPolicy
Query parameters
Parameters | |
---|---|
|
The project’s ID for which you want to set the policy. |
| (optional) The registry’s ID for which you want to set the policy. |
| (optional) The registry’s region for which you want to set the policy. |
If registry_id and region are included, the request will assign the roles at that registry’s level. If those optional parameters are not included, the request will assign the roles at the project’s level.
Request body
The request body contains data with this structure, containing a CbPolicy:
JSON representation |
---|
{
"policy": CbPolicy
} |
Response body
If successful, the response body contains the CbPolicy assigned to the resource.
Example
https://iot.clearblade.com/api/v/4/webhook/execute/aae9b9b30c8aa4e49081c7eeb9bb07/policy?method=setIamPolicy&project_area=myProject123®ion=us-central1®istry_id=myRegistry123