put_vector_bucket_policy
async
¶
put_vector_bucket_policy(
policy: VectorBucketPolicy,
*,
config_overrides: Optional[AsyncS3VectorsClientConfig] = None,
vector_bucket_name: Optional[VectorBucketName] = None,
vector_bucket_arn: Optional[VectorBucketArn] = None,
) -> PutVectorBucketPolicyOutput
Creates a bucket policy for a vector bucket. To specify the bucket, you must use either the vector bucket name or the vector bucket Amazon Resource Name (ARN).
- Permissions
-
You must have the
s3vectors:PutVectorBucketPolicypermission to use this operation.
Parameters:
-
vector_bucket_name(Optional[VectorBucketName], default:None) –The name of the vector bucket.
-
vector_bucket_arn(Optional[VectorBucketArn], default:None) –The Amazon Resource Name (ARN) of the vector bucket.
-
policy(VectorBucketPolicy) –The
JSONthat defines the policy. For more information about bucket policies for S3 Vectors, see Managing vector bucket policies in the Amazon S3 User Guide.
Raises:
-
AccessDeniedException–Access denied.
-
InternalServerException–The request failed due to an internal server error.
-
RequestTimeoutException–The request timed out. Retry your request.
-
TooManyRequestsException–The request was denied due to request throttling.
-
ValidationException–The requested action isn't valid.
-
NotFoundException–The request was rejected because the specified resource can't be found.
-
ServiceUnavailableException–The service is unavailable. Wait briefly and retry your request. If it continues to fail, increase your waiting time between retries.
-
UnknownServiceError–The service returned an error code this client does not model.