Yandex Cloud
Search
Discuss with expertTry it for free
  • Customer Stories
  • Documentation
  • Blog
  • All Services
    • Cloud Interconnect
    • Cloud Backup
    • Cloud Registry
    • Yandex AI Studio
    • Compute Cloud
    • Object Storage
    • Managed Service for Kubernetes®
    • Yandex BareMetal
    • Smart Web Security
    • Security Deck
    • Managed Service for PostgreSQL
    • Managed Service for ClickHouse®
    • Monium
    • Cloud CDN
    • Network Load Balancer
    • Virtual Private Cloud
    • Cloud DNS
    • Application Load Balancer
    • Yandex Cloud Video
    • Stackland
    • Yandex Cloud Router
    • Yandex Managed Service for Trino
    • Managed Service for MySQL®
    • Managed Service for Valkey™
    • Managed Service for Apache Spark™
    • Yandex StoreDoc
    • Managed Service for OpenSearch
    • Managed Service for Apache Kafka®
    • Data Transfer
    • Yandex MPP Analytics Engine for PostgreSQL
    • Yandex Managed Service for Apache Airflow®
    • Data Processing
    • Yandex MetaData Hub
    • Managed Service for YDB
    • Managed Service for Sharded PostgreSQL
    • Managed Service for YTsaurus
    • Yandex WebSQL
    • DataLens
    • Yandex Search API
    • SpeechSense
    • SpeechKit
    • DataSphere
    • Vision OCR
    • Translate
    • Yandex Identity Hub
    • Key Management Service
    • Certificate Manager
    • Yandex Lockbox
    • Audit Trails
    • SmartCaptcha
    • Cloud Desktop
    • Yandex SIEM
    • SourceCraft Code Assistant
    • Container Registry
    • Managed Service for GitLab
    • Managed Service for Prometheus®
    • Cloud Functions
    • API Gateway
    • Yandex Cloud Postbox
    • Message Queue
    • Serverless Integrations
    • IoT Core
    • Data Streams
    • Serverless Containers
    • Cloud Notification Service
    • Yandex Query
    • Identity and Access Management
    • Yandex Cloud Console
    • Resource Manager
    • Yandex Cloud Billing
    • Yandex Cloud Quota Manager
    • Cloud Apps
  • System Status
  • Marketplace
    • Featured
    • Infrastructure & Network
    • Data Platform
    • AI for business
    • Security
    • DevOps tools
    • Serverless
    • Monitoring & Resources
  • All Solutions
    • By industry
    • By use case
    • Economics and Pricing
    • Security
    • Technical Support
    • Start testing with double trial credits
    • Cloud credits to scale your IT product
    • Gateway to Russia
    • Cloud for Startups
    • Center for Technologies and Society
    • Yandex Cloud Partner program
    • Price calculator
    • Pricing plans
  • Customer Stories
  • Documentation
  • Blog
© 2026 Direct Cursus Technology L.L.C.
Yandex Object Storage
  • Pricing policy
  • Terraform reference
    • API authentication
      • How to use the API
      • Signing requests
      • Getting started with the S3 API
        • All services and methods
          • All methods
          • GetBucketPolicy
          • PutBucketPolicy
          • DeleteBucketPolicy
          • Data schema
          • Actions
          • Conditions
        • Common request headers
        • Common response headers
        • Responses
  • Monitoring metrics
  • Audit Trails events
  • Bucket logs
  • Release notes
  • FAQ
  1. API reference
  2. AWS S3 REST
  3. REST
  4. Bucket Policy
  5. Data schema

Data schema

Written by
Yandex Cloud
Updated at July 13, 2026
View in Markdown

Data schema in JSON format:

{
  "Version" : "string",
  "Id" : "string",
  "Statement" : [
    {
      "Sid" : "string",
      ("Principal" | "NotPrincipal") : ("*" | "CanonicalUser" : [
        "string",
        ...
      ]),
      "Effect" : ("Allow" | "Deny"),
      "Action" : ("*" | [
        "string",
        ...
      ]),
      "Resource" : ("*" | [
        "string",
        ...
      ]),
      "Condition" : {
        "condition_type_string" : {
          "condition_key_string" : [[("string" | "number" | "Boolean"),...]...]
        },
        ...
      }  
    },
    ...
  ]
}

A schema may include up to 10,240 characters.

Description of schema parameters:

Parameter Description
Version string (optional)
Access policy description version.
Examples: 2012-10-17.
Id string (optional)
General info on the policy. Some Yandex Cloud services require a unique value.
This is a user-defined parameter.
Examples: test-policy, Anonymous access policy, hrtk43sau2s8gqkaje06.
Statement[]. array
Access policy rules.
If a no-rule bucket policy is applied to the bucket, access will be denied to all users. To disable request verification for a bucket policy, delete it.
Statement[].Sid string
Rule ID (optional).
This is a user-defined parameter.
Examples: test-rule, Statement Allow, Statement Deny.
Statement[].Principal string
ID of the subject of the requested permission (optional). You can request permissions for a user, or service account.
Possible values:
  • "*"
  • "CanonicalUser": "<subject_ID>"
Statement[].NotPrincipal string
ID of the subject that will not get the requested permission (optional). The possible subjects are: user, or service account.
Possible value: "CanonicalUser": "<subject_ID>".
Statement[].Effect string
Denies or allows the requested action.
The possible values are Allow and Deny.
Statement[].Action string
Action if the policy triggers.
The possible values are s3:GetObject and s3:PutObject.
Statement[].Resource string
Resource the action will be performed on.
The possible values are:
  • arn:aws:s3:::<bucket_name>: Bucket.
  • arn:aws:s3:::<bucket_name>/<object_key>: Bucket object.
  • arn:aws:s3:::<bucket_name>/<object_key_prefix>*: All objects in the bucket whose keys start with a prefix, e.g., arn:aws:s3:::samplebucket/some/path/*. A prefix can be empty, e.g., arn:aws:s3:::samplebucket/*, in which case the rule will apply to all bucket objects.
A bucket resource does not include resources of all its objects. To make sure a bucket policy rule refers to the bucket and all the objects, specify them as separate resources, e.g., arn:aws:s3:::samplebucket and arn:aws:s3:::samplebucket/*.
Statement[].Condition{}. string
Condition to check (optional).
If several conditions are set for the rule at the same time, they will apply using the AND logic, i.e., to be executed, the rule must satisfy all the specified conditions at the same time.

For the aws:sourceip condition, a special procedure for checking IP addresses of reverse proxy servers is supported. If you only need to check the original IP address while ignoring proxies, use the yc:originip condition.
Statement[].Condition{}.
condition_type_string{}.
string
Condition type.
The possible values are StringEquals and Bool. For a full list of values, see Comparison operators.
Statement[].Condition{}.
condition_type_string{}.
condition_key_string
string
Condition key.

Defines the condition to check.
The possible values are: aws:PrincipalType, true.

If several keys are specified for one condition at the same time, these will be checked with using the AND logic, i.e., to be executed, the rule must satisfy all the specified properties at the same time.

If several values are specified for one condition key at the same time, these will be checked with the logical OR, i.e., for the rule to be executed, the condition key may satisfy any of the specified values.

Related articlesRelated articles

  • Bucket policy

Useful linksUseful links

  • Getting started with the AWS S3 API in Yandex Object Storage

  • Debugging requests using the AWS CLI

  • Example of sending a signed request using curl

  • Code example for generating a signature

Was the article helpful?

Previous
DeleteBucketPolicy
Next
Actions
© 2026 Direct Cursus Technology L.L.C.