Amazon.IoT.AmazonIoTClient.CreatePolicyVersion C# (CSharp) Метод

CreatePolicyVersion() публичный Метод

Creates a new version of the specified AWS IoT policy. To update a policy, create a new policy version. A managed policy can have up to five versions. If the policy has five versions, you must use DeletePolicyVersion to delete an existing version before you create a new one.

Optionally, you can set the new version as the policy's default version. The default version is the operative version (that is, the version that is in effect for the certificates to which the policy is attached).

/// An unexpected error has occurred. /// /// The request is not valid. /// /// The policy documentation is not valid. /// /// The specified resource does not exist. /// /// The service is temporarily unavailable. /// /// The rate exceeds the limit. /// /// You are not authorized to perform this operation. /// /// The number of policy versions exceeds the limit. ///
public CreatePolicyVersion ( string policyName, string policyDocument ) : Amazon.IoT.Model.CreatePolicyVersionResponse
policyName string The policy name.
policyDocument string The JSON document that describes the policy. Minimum length of 1. Maximum length of 2048, excluding whitespaces
Результат Amazon.IoT.Model.CreatePolicyVersionResponse
        public CreatePolicyVersionResponse CreatePolicyVersion(string policyName, string policyDocument)
        {
            var request = new CreatePolicyVersionRequest();
            request.PolicyName = policyName;
            request.PolicyDocument = policyDocument;
            return CreatePolicyVersion(request);
        }

Same methods

AmazonIoTClient::CreatePolicyVersion ( CreatePolicyVersionRequest request ) : Amazon.IoT.Model.CreatePolicyVersionResponse
AmazonIoTClient::CreatePolicyVersion ( string policyName, string policyDocument, bool setAsDefault ) : Amazon.IoT.Model.CreatePolicyVersionResponse
AmazonIoTClient