import type { MetadataBearer as __MetadataBearer } from "@smithy/types"; import type { PutPolicyRequest } from "../models/models_0"; /** * @public */ export type { __MetadataBearer }; /** * @public * * The input for {@link PutPolicyCommand}. */ export interface PutPolicyCommandInput extends PutPolicyRequest { } /** * @public * * The output of {@link PutPolicyCommand}. */ export interface PutPolicyCommandOutput extends __MetadataBearer { } declare const PutPolicyCommand_base: { new (input: PutPolicyCommandInput): import("@smithy/core/client").CommandImpl; new (input: PutPolicyCommandInput): import("@smithy/core/client").CommandImpl; getEndpointParameterInstructions(): import("@smithy/types").EndpointParameterInstructions; }; /** *

Attaches a resource-based policy to a private CA.

A policy can also be applied by sharing a private CA through Amazon Web Services Resource Access Manager (RAM). For more information, see Attach a Policy for Cross-Account Access.

The policy can be displayed with GetPolicy and removed with DeletePolicy.

About Policies

* @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { ACMPCAClient, PutPolicyCommand } from "@aws-sdk/client-acm-pca"; // ES Modules import * // const { ACMPCAClient, PutPolicyCommand } = require("@aws-sdk/client-acm-pca"); // CommonJS import * // import type { ACMPCAClientConfig } from "@aws-sdk/client-acm-pca"; * const config = {}; // type is ACMPCAClientConfig * const client = new ACMPCAClient(config); * const input = { // PutPolicyRequest * ResourceArn: "STRING_VALUE", // required * Policy: "STRING_VALUE", // required * }; * const command = new PutPolicyCommand(input); * const response = await client.send(command); * // {}; * * ``` * * @param PutPolicyCommandInput - {@link PutPolicyCommandInput} * @returns {@link PutPolicyCommandOutput} * @see {@link PutPolicyCommandInput} for command's `input` shape. * @see {@link PutPolicyCommandOutput} for command's `response` shape. * @see {@link ACMPCAClientResolvedConfig | config} for ACMPCAClient's `config` shape. * * @throws {@link ConcurrentModificationException} (client fault) *

A previous update to your private CA is still ongoing.

* * @throws {@link InvalidArnException} (client fault) *

The requested Amazon Resource Name (ARN) does not refer to an existing resource.

* * @throws {@link InvalidPolicyException} (client fault) *

The resource policy is invalid or is missing a required statement. For general information about IAM policy and statement structure, see Overview of JSON Policies.

* * @throws {@link InvalidStateException} (client fault) *

The state of the private CA does not allow this action to occur.

* * @throws {@link LockoutPreventedException} (client fault) *

The current action was prevented because it would lock the caller out from performing subsequent actions. Verify that the specified parameters would not result in the caller being denied access to the resource.

* * @throws {@link RequestFailedException} (client fault) *

The request has failed for an unspecified reason.

* * @throws {@link ResourceNotFoundException} (client fault) *

A resource such as a private CA, S3 bucket, certificate, audit report, or policy cannot be found.

* * @throws {@link ACMPCAServiceException} *

Base exception class for all service exceptions from ACMPCA service.

* * * @public */ export declare class PutPolicyCommand extends PutPolicyCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: PutPolicyRequest; output: {}; }; sdk: { input: PutPolicyCommandInput; output: PutPolicyCommandOutput; }; }; }