A GET location request operation using a bucket URI lists the location constraint of the bucket.
To view the location constraint of a bucket, you must be the bucket owner.
GET /?location HTTP/1.1 Host:destinationBucket.s3.amazonaws.com Date:dateAuthorization:signature
This operations uses standard request headers.
HTTP/1.1 200 OK x-amz-id-2: id x-amz-request-id: request_id Date: date Content-Type: type Content-Length: length Connection: close Server: AmazonS3 <?xml version="1.0" encoding="UTF-8"?> <LocationConstraint xmlns="http://s3.amazonaws.com/doc/2006-03-01/">constraint</LocationConstraint>
| Name | Description |
|---|---|
LocationConstraint
|
Location constraint of the bucket. Type: String Ancestor: None |
There are no special errors for this operation. For information about general Amazon S3 errors, see List of Error Codes.
This example lists the bucket location constraint of the quotes bucket.
GET /?location HTTP/1.1 Host: quotes.s3.amazonaws.com Date: Tue, 09 Oct 2007 20:26:04 +0000 Authorization: AWS 1ATXQ3HHA59CYF1CVS02:JUtd9kkJFjbKbkP9f6T/tAxozYY=
<?xml version="1.0" encoding="UTF-8"?> <LocationConstraint xmlns="http://s3.amazonaws.com/doc/2006-03-01/">EU</LocationConstraint>