v1

latestOpenAPI 3.0.0Apache 2.0 License2026-07-142381,278956.3 KB

Creates an IoT policy.

The created policy is the default version for the policy. This operation creates a policy version with a version identifier of 1 and sets 1 as the policy's default version.

Requires permission to access the CreatePolicy action.

post/policies/{policyName}

Path parameters

policyNamestring required

The policy name.

Request body

policyDocumentstring required

The JSON document that describes the policy. <b>policyDocument</b> must have a minimum length of 1, with a maximum length of 2048, excluding whitespace.

Response

Success

policyNamestring

The policy name.

policyArnstring

The policy ARN.

policyDocumentstring

The JSON document that describes the policy.

policyVersionIdstring

The policy version ID.