获取对象 (GET Object)
客户端使用该接口获取指定对象 (Object) 的内容,该接口支持通过 URL 请求参数 (Query String) 指定 HTTP 响应头 (Response Headers)。
请求定义
GET /<BucketName>/<ObjectName> HTTP/1.1
Host: api-s3.qiniu.com
Date: <date>
Range: <lower>-<upper>
Authorization: <YourAuthenticatingString>
请求参数
该接口定义了以下请求参数:
名称 | 描述 | 要求 |
---|---|---|
response-content-type | 指定 HTTP 响应头 Content-Type | N |
response-content-disposition | 指定 HTTP 响应头 Content-Disposition,如 attachment; filename=myfilename.png |
N |
response-cache-control | 指定 HTTP 响应头 Cache-Control | N |
response-expires | 指定 HTTP 响应头 Expires,使用 ISO8601 格式 | N |
请求头
除 请求头 (HTTP Request Header) 外,该接口定义了以下请求头:
名称 | 描述 | 要求 |
---|---|---|
Range | 仅返回对象指定范围的字节,关于 Range 定义可参考 RFC2616 | N |
If-Modified-Since | 仅当对象的最后修改时间大于指定的时间时返回,否则服务器端返回 HTTP 状态码 304 | N |
If-Unmodified-Since | 仅当对象的最后修改时间小于指定的时间时返回,否则服务器端返回 HTTP 状态码 412 | N |
If-Match | 仅当对象的 ETag 等于指定的值时返回,否则服务器端返回 HTTP 状态码 412 | N |
If-None-Match | 仅当对象的 ETag 不定义指定的值时返回,否则服务器端返回 HTTP 状态码 304 | N |
请求数据
该接口未定义请求数据
响应定义
- 服务器端正确处理请求时返回指定对象的字节序列