Amazon Simple Storage Service
API Reference (API Version 2006-03-01)
Print this pageEmail this pageGo to the ForumsView the PDFShare this page on TwitterShare this page on FacebookBookmark this page on DeliciousSubmit this page to RedditSubmit this page to DiggDid this page help you?  Yes  No   Tell us about it...

Common Request Headers

Amazon S3 REST requests include headers that contain basic information about the request. The following table describes headers that can be used by all Amazon S3 REST requests.

Header NameDescriptionRequired
Authorization

The information required for request authentication.

Type: String

Default: None

Yes
Content-Length

Length of the message (without the headers) according to RFC 2616.

Type: String

Default: None

Condition: Required for PUTs and operations that load XML, such as logging and ACLs.

Conditional
Content-Type

The content type of the resource. Example: text/plain

Type: String

Default: None

No
Date

The current date and time according to the requester. Example: Wed, 01 Mar 2009 12:00:00 GMT

Type: String

Default: None

Yes
Host

For path-style requests, the value is s3.amazonaws.com. For virtual-style requests, the value is BucketName.s3.amazonaws.com. For more information, go to Virtual Hosting in the Amazon Simple Storage Service Developer Guide .

Type: String

Default: None

Condition: Required for HTTP 1.1 (most toolkits add this header automatically); optional for HTTP/1.0 requests.

Conditional
x-amz-security-token

This header can be used in the following scenarios:

  • Provide security tokens for Amazon DevPay operations—Each request that uses Amazon DevPay requires two x-amz-security-token headers: one for the product token and one for the user token. When Amazon S3 receives an authenticated request, it compares the computed signature with the provided signature. Improperly formatted multi-value headers used to calculate a signature can cause authentication issues
  • Provide security token when using temporary security credentials—When making requests using temporary security credentials you obtained from IAM you must provide a security token using this header. To learn more about temporary security credentials, go to Making Requests.

Type: String

Default: None

Condition: Required for requests that use Amazon DevPay and requests that are signed using temporary security credentials.

Conditional