Options
All
  • Public
  • Public/Protected
  • All
Menu

Class GetBucketCorsCommand

Returns the cors configuration information set for the bucket.

To use this operation, you must have permission to perform the s3:GetBucketCORS action. By default, the bucket owner has this permission and can grant it to others.

For more information about cors, see Enabling Cross-Origin Resource Sharing.

The following operations are related to GetBucketCors:

example

Use a bare-bones client and the command you need to make an API call.

import { S3Client, GetBucketCorsCommand } from "@aws-sdk/client-s3"; // ES Modules import
// const { S3Client, GetBucketCorsCommand } = require("@aws-sdk/client-s3"); // CommonJS import
const client = new S3Client(config);
const command = new GetBucketCorsCommand(input);
const response = await client.send(command);
see

GetBucketCorsCommandInput for command's input shape.

see

GetBucketCorsCommandOutput for command's response shape.

see

config for S3Client's config shape.

Hierarchy

Implements

Index

Constructors

Properties

Constructors

constructor

Properties

Readonly input

input: GetBucketCorsCommandInput

Readonly middlewareStack

middlewareStack: IMiddlewareStack<GetBucketCorsCommandInput, GetBucketCorsCommandOutput>