get-access-point-public-access-block

更新时间:
复制 MD 格式

Retrieves the Block Public Access settings of an access point.

Permissions

By default, an Alibaba Cloud account has the permission to query the Block Public Access configurations of a bucket. To run this command as a RAM user or with Security Token Service (STS) credentials, grant the oss:GetAccessPointPublicAccessBlock permission. For more information, see Attach a custom policy to a RAM user.

Syntax

ossutil api get-access-point-public-access-block --bucket <value> --access-point-name <value> [flags]

Parameters

ParameterTypeDescription
--bucketstringName of the bucket.
--access-point-namestringName of the access point.

For supported global flags, see Command-line options.

This command maps to the GetAccessPointPublicAccessBlock API operation.

Examples

All examples query the Block Public Access settings of access point ap-01 in examplebucket.

Query and display the output in the default format:

ossutil api get-access-point-public-access-block --bucket examplebucket --access-point-name ap-01

Query and display the output in JSON format:

ossutil api get-access-point-public-access-block --bucket examplebucket --access-point-name ap-01 --output-format json

Query and display the output in YAML format:

ossutil api get-access-point-public-access-block --bucket examplebucket --access-point-name ap-01 --output-format yaml