PUThttps://api.spotinst.io/setup/access/policy/{POLICY_ID}?accountId={ACCOUNT_ID}

Updates an access policy settings.

URL Parameters

Parameter Type Description
ACCOUNT_ID * String

The Spotinst account ID

Example: act-1234cds
POLICY_ID * String

The access policy ID to delete

Example: pol-2344nn
Request

Headers
{
    "Content-Type": "application/json",
    "Authorization": "Bearer ${token}"
}
Body
Copied!
Downloaded!
{
	"policy": {
    	"name": "A wonderful policy"
	}
}
Attribute Type Description
policy * String

Set access policy settings

policy.name String

Set access policy name

policy.description String

Set access policy description

policy.policyContent Object

Set permissions objects list

policy.policyContent.statements Array<Object>

List of permissions statements

policy.policyContent.statements.effect String

Valid values: "ALLOW", "DENY"

Example: ALLOW
policy.policyContent.statements.actions Array<String>

Set a list of required actions for this permissions statement. full list of actions can be found here.

Example: emr:scale
policy.policyContent.statements.resources Array<String>

Set a list of resources IDs. In order to include all resources in this statement - use "*"

Response - 200

Headers
{
    "Content-Type": "application/json"
}
Body
Copied!
Downloaded!
{
   "status": {
     "code": 200,
     "message": "OK"
   }
}