UNPKG

@aws-sdk/client-s3-control

Version:

AWS SDK for JavaScript S3 Control Client for Node.js, Browser and React Native

118 lines (117 loc) 5.76 kB
import { Command as $Command } from "@smithy/smithy-client"; import { MetadataBearer as __MetadataBearer } from "@smithy/types"; import { CreateAccessPointRequest, CreateAccessPointResult } from "../models/models_0"; import { S3ControlClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../S3ControlClient"; /** * @public */ export type { __MetadataBearer }; export { $Command }; /** * @public * * The input for {@link CreateAccessPointCommand}. */ export interface CreateAccessPointCommandInput extends CreateAccessPointRequest { } /** * @public * * The output of {@link CreateAccessPointCommand}. */ export interface CreateAccessPointCommandOutput extends CreateAccessPointResult, __MetadataBearer { } declare const CreateAccessPointCommand_base: { new (input: CreateAccessPointCommandInput): import("@smithy/smithy-client").CommandImpl<CreateAccessPointCommandInput, CreateAccessPointCommandOutput, S3ControlClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>; new (__0_0: CreateAccessPointCommandInput): import("@smithy/smithy-client").CommandImpl<CreateAccessPointCommandInput, CreateAccessPointCommandOutput, S3ControlClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>; getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions; }; /** * <note> * <p>This operation is not supported by directory buckets.</p> * </note> * <p>Creates an access point and associates it with the specified bucket. For more information, see * <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/access-points.html">Managing * Data Access with Amazon S3 Access Points</a> in the * <i>Amazon S3 User Guide</i>.</p> * <p></p> * <note> * <p>S3 on Outposts only supports VPC-style access points. </p> * <p>For more information, see <a href="https://docs.aws.amazon.com/AmazonS3/latest/userguide/S3onOutposts.html"> Accessing Amazon S3 on Outposts using * virtual private cloud (VPC) only access points</a> in the * <i>Amazon S3 User Guide</i>.</p> * </note> * <p>All Amazon S3 on Outposts REST API requests for this action require an additional parameter of <code>x-amz-outpost-id</code> to be passed with the request. In addition, you must use an S3 on Outposts endpoint hostname prefix instead of <code>s3-control</code>. For an example of the request syntax for Amazon S3 on Outposts that uses the S3 on Outposts endpoint hostname prefix and the <code>x-amz-outpost-id</code> derived by using the access point ARN, see the <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_control_CreateAccessPoint.html#API_control_CreateAccessPoint_Examples">Examples</a> section.</p> * <p></p> * <p>The following actions are related to <code>CreateAccessPoint</code>:</p> * <ul> * <li> * <p> * <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_control_GetAccessPoint.html">GetAccessPoint</a> * </p> * </li> * <li> * <p> * <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_control_DeleteAccessPoint.html">DeleteAccessPoint</a> * </p> * </li> * <li> * <p> * <a href="https://docs.aws.amazon.com/AmazonS3/latest/API/API_control_ListAccessPoints.html">ListAccessPoints</a> * </p> * </li> * </ul> * @example * Use a bare-bones client and the command you need to make an API call. * ```javascript * import { S3ControlClient, CreateAccessPointCommand } from "@aws-sdk/client-s3-control"; // ES Modules import * // const { S3ControlClient, CreateAccessPointCommand } = require("@aws-sdk/client-s3-control"); // CommonJS import * const client = new S3ControlClient(config); * const input = { // CreateAccessPointRequest * AccountId: "STRING_VALUE", * Name: "STRING_VALUE", // required * Bucket: "STRING_VALUE", // required * VpcConfiguration: { // VpcConfiguration * VpcId: "STRING_VALUE", // required * }, * PublicAccessBlockConfiguration: { // PublicAccessBlockConfiguration * BlockPublicAcls: true || false, * IgnorePublicAcls: true || false, * BlockPublicPolicy: true || false, * RestrictPublicBuckets: true || false, * }, * BucketAccountId: "STRING_VALUE", * }; * const command = new CreateAccessPointCommand(input); * const response = await client.send(command); * // { // CreateAccessPointResult * // AccessPointArn: "STRING_VALUE", * // Alias: "STRING_VALUE", * // }; * * ``` * * @param CreateAccessPointCommandInput - {@link CreateAccessPointCommandInput} * @returns {@link CreateAccessPointCommandOutput} * @see {@link CreateAccessPointCommandInput} for command's `input` shape. * @see {@link CreateAccessPointCommandOutput} for command's `response` shape. * @see {@link S3ControlClientResolvedConfig | config} for S3ControlClient's `config` shape. * * @throws {@link S3ControlServiceException} * <p>Base exception class for all service exceptions from S3Control service.</p> * * @public */ export declare class CreateAccessPointCommand extends CreateAccessPointCommand_base { /** @internal type navigation helper, not in runtime. */ protected static __types: { api: { input: CreateAccessPointRequest; output: CreateAccessPointResult; }; sdk: { input: CreateAccessPointCommandInput; output: CreateAccessPointCommandOutput; }; }; }