

本文為英文版的機器翻譯版本，如內容有任何歧義或不一致之處，概以英文版為準。

# 使用 REST API 擷取 requestPayment 組態
<a name="BucketPayerValues"></a>

您可以要求資源 `Payer`，決定在儲存貯體上設定的 `requestPayment` 值。

**傳回 requestPayment 資源**
+ 使用 GET 要求以取得 `requestPayment` 資源，如下列要求所示。

  ```
  1. GET ?requestPayment HTTP/1.1
  2. Host: [BucketName].s3.amazonaws.com
  3. Date: Wed, 01 Mar 2009 12:00:00 GMT
  4. Authorization: AWS [Signature]
  ```

如果請求成功，Amazon S3 會傳回類似如下的回應。

```
 1. HTTP/1.1 200 OK
 2. x-amz-id-2: [id]
 3. x-amz-request-id: [request_id]
 4. Date: Wed, 01 Mar 2009 12:00:00 GMT
 5. Content-Type: [type]
 6. Content-Length: [length]
 7. Connection: close
 8. Server: AmazonS3
 9. 
10. <?xml version="1.0" encoding="UTF-8"?>
11. <RequestPaymentConfiguration xmlns="http://s3.amazonaws.com/doc/2006-03-01/">
12. <Payer>Requester</Payer>
13. </RequestPaymentConfiguration>
```

此回應顯示 `payer` 值設成 `Requester`。