doc-exports/docs/obs/api-ref/obs_04_0081.html
zhangyue 7d2a7ec198 OBS API DOC
Reviewed-by: Sabelnikov, Dmitriy <dmitriy.sabelnikov@t-systems.com>
Co-authored-by: zhangyue <zhangyue164@huawei.com>
Co-committed-by: zhangyue <zhangyue164@huawei.com>
2024-11-05 16:37:11 +00:00

1418 lines
104 KiB
HTML

<a name="obs_04_0081"></a><a name="obs_04_0081"></a>
<h1 class="topictitle1">Uploading an Object - POST</h1>
<div id="body14481882"><div class="section" id="obs_04_0081__section1534875573"><h4 class="sectiontitle">Functions</h4><p class="msonormal" id="obs_04_0081__p59601668">This API allows you to upload an object to a bucket. This requires the write permission for the bucket.</p>
<div class="note" id="obs_04_0081__note66652971"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p class="text" id="obs_04_0081__p63228075">The name of each object in a bucket must be unique.</p>
</div></div>
<p class="msonormal" id="obs_04_0081__p63005833">If a bucket has versioning disabled, and you upload an object that has the same name as an existing object, the new object overwrites the existing one. You can also use <strong id="obs_04_0081__b1130123461510">Content-MD5</strong> in the form to verify in-transit integrity. OBS calculates an MD5 after the object is uploaded and checks if this MD5 matches the MD5 carried in the form. If they do not match, an error is reported. You can also use <strong id="obs_04_0081__b1461685225154325">x-obs-acl</strong> to control access to objects.</p>
<p class="msonormal" id="obs_04_0081__p30181591">You can also upload an object using the POST method.</p>
<p id="obs_04_0081__p86711039908">A single upload allows at most 5 GB of objects. To upload more than 5 GB of objects, see <a href="obs_04_0096.html">Operations on Multipart Upload</a>.</p>
<p class="msonormal" id="obs_04_0081__p3198871">This API supports server-side encryption.</p>
</div>
<div class="section" id="obs_04_0081__section9125142514612"><h4 class="sectiontitle">Differences Between PUT and POST Methods</h4><p id="obs_04_0081__p154258324469">PUT requests include parameters in the header; POST requests in the form.</p>
<p id="obs_04_0081__p92971585546">In the URL, PUT requests require object names be specified; POST requests only require bucket domain names. Request lines of PUT and POST are as follows:</p>
<pre class="screen" id="obs_04_0081__screen53331759111919">PUT /ObjectName HTTP/1.1</pre>
<pre class="screen" id="obs_04_0081__screen666703202019">POST / HTTP/1.1</pre>
<p id="obs_04_0081__p19165518576">For details about PUT upload, see <a href="obs_04_0080.html">Uploading an Object - PUT</a>.</p>
</div>
<div class="section" id="obs_04_0081__section28789840"><h4 class="sectiontitle">Versioning</h4><p class="msonormal" id="obs_04_0081__p21200411">If versioning is enabled for a bucket, each object uploaded has a unique version ID. If versioning is suspended, the version ID is <strong id="obs_04_0081__b59739617">null</strong>. Version IDs are returned in the <strong id="obs_04_0081__b1053517127487">x-obs-version-id</strong> header of the response. For details about versioning, see <a href="obs_04_0037.html">Configuring Versioning for a Bucket</a>.</p>
</div>
<div class="section" id="obs_04_0081__section1475721115541"><h4 class="sectiontitle">WORM</h4><p id="obs_04_0081__p759131755418">If a bucket has WORM enabled, you can configure WORM for its objects. To do so, use <strong id="obs_04_0081__b2129195454814">x-obs-object-lock-mode</strong> and <strong id="obs_04_0081__b171291954144819">x-obs-object-lock-retain-until-date</strong> in the request when uploading an object. If these two elements are not specified, objects uploaded use the default bucket WORM policy (if any). You can also configure or update WORM after an object was uploaded.</p>
<div class="note" id="obs_04_0081__note7133240105611"><img src="public_sys-resources/note_3.0-en-us.png"><span class="notetitle"> </span><div class="notebody"><p id="obs_04_0081__p1277512964714">If WORM is enabled, versioning is automatically enabled. WORM is based on the object version. Versions of an object not protected by WORM can be deleted. For example, assume version <strong id="obs_04_0081__b15581831722">test.txt 001</strong> of an object is protected by WORM. You upload a new version <strong id="obs_04_0081__b281671813420">test.txt 002</strong> for the same object with no WORM configured. In such case, <strong id="obs_04_0081__b88165181049">test.txt 002</strong> is not protected and can be deleted. If you download an object without specifying a version ID, the latest version — <strong id="obs_04_0081__b15327114162416">test.txt 002</strong> — is downloaded.</p>
</div></div>
</div>
<div class="section" id="obs_04_0081__section57781973"><h4 class="sectiontitle">Request Syntax</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen24019431"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span>
<span class="normal">13</span>
<span class="normal">14</span>
<span class="normal">15</span>
<span class="normal">16</span>
<span class="normal">17</span>
<span class="normal">18</span>
<span class="normal">19</span>
<span class="normal">20</span>
<span class="normal">21</span>
<span class="normal">22</span>
<span class="normal">23</span>
<span class="normal">24</span>
<span class="normal">25</span>
<span class="normal">26</span>
<span class="normal">27</span>
<span class="normal">28</span>
<span class="normal">29</span>
<span class="normal">30</span>
<span class="normal">31</span>
<span class="normal">32</span>
<span class="normal">33</span>
<span class="normal">34</span>
<span class="normal">35</span>
<span class="normal">36</span>
<span class="normal">37</span>
<span class="normal">38</span>
<span class="normal">39</span>
<span class="normal">40</span>
<span class="normal">41</span>
<span class="normal">42</span>
<span class="normal">43</span>
<span class="normal">44</span>
<span class="normal">45</span>
<span class="normal">46</span>
<span class="normal">47</span>
<span class="normal">48</span>
<span class="normal">49</span>
<span class="normal">50</span>
<span class="normal">51</span>
<span class="normal">52</span>
<span class="normal">53</span>
<span class="normal">54</span>
<span class="normal">55</span></pre></div></td><td class="code"><div><pre><span></span>POST<span class="w"> </span>/<span class="w"> </span>HTTP/1.1<span class="w"> </span>
Host:<span class="w"> </span>bucketname.obs.region.example.com
User-Agent:<span class="w"> </span>browser_data
Accept:<span class="w"> </span>file_types
Accept-Language:<span class="w"> </span>Regions
Accept-Encoding:<span class="w"> </span>encoding
Accept-Charset:<span class="w"> </span>character_set
Keep-Alive:<span class="w"> </span>300<span class="w"> </span>
Connection:<span class="w"> </span>keep-alive<span class="w"> </span>
Content-Type:<span class="w"> </span>multipart/form-data;<span class="w"> </span>boundary=9431149156168<span class="w"> </span>
Content-Length:<span class="w"> </span>length
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;key&quot;<span class="w"> </span>
acl<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;success_action_redirect&quot;
<span class="w"> </span>
success_redirect<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;content-Type&quot;<span class="w"> </span>
content_type<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-meta-uuid&quot;<span class="w"> </span>
uuid<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-meta-tag&quot;<span class="w"> </span>
metadata<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;AccessKeyId&quot;<span class="w"> </span>
access-key-id<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;policy&quot;<span class="w"> </span>
encoded_policy<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;signature&quot;<span class="w"> </span>
signature=<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;file&quot;;<span class="w"> </span>filename=&quot;MyFilename&quot;<span class="w"> </span>
Content-Type:<span class="w"> </span>image/jpeg<span class="w"> </span>
file_content<span class="w"> </span>
--9431149156168<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;submit&quot;<span class="w"> </span>
Upload<span class="w"> </span>to<span class="w"> </span>OBS<span class="w"> </span>
--9431149156168--
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section50275709"><h4 class="sectiontitle">Request Parameters</h4><p class="msonormal" id="obs_04_0081__p66525750">This request contains no parameters.</p>
</div>
<div class="section" id="obs_04_0081__section49828203"><h4 class="sectiontitle">Request Headers</h4><p class="msonormal" id="obs_04_0081__p19876694">This request uses common headers. For details, see <a href="obs_04_0007.html#obs_04_0007__table25197309">Table 3</a>.</p>
<p class="msonormal" id="obs_04_0081__p66508399">If you want to get CORS settings, use the headers in <a href="#obs_04_0081__table792925145918">Table 1</a>.</p>
<div class="tablenoborder"><a name="obs_04_0081__table792925145918"></a><a name="table792925145918"></a><table cellpadding="4" cellspacing="0" summary="" id="obs_04_0081__table792925145918" width="100%" frame="border" border="1" rules="all"><caption><b>Table 1 </b>Request headers for obtaining CORS configuration</caption><thead align="left"><tr id="obs_04_0081__row1992917518596"><th align="left" class="cellrowborder" valign="top" width="24.26%" id="mcps1.3.7.4.2.5.1.1"><p id="obs_04_0081__p15929205195912">Header</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="9.19%" id="mcps1.3.7.4.2.5.1.2"><p id="obs_04_0081__p1617713121608"><strong id="obs_04_0081__b10638133053115">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="8.49%" id="mcps1.3.7.4.2.5.1.3"><p id="obs_04_0081__p8365115906"><strong id="obs_04_0081__b93876325018">Mandatory (Yes/No)</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="58.06%" id="mcps1.3.7.4.2.5.1.4"><p id="obs_04_0081__p19929105155917"><strong id="obs_04_0081__b765061912471">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="obs_04_0081__row18929145110596"><td class="cellrowborder" valign="top" width="24.26%" headers="mcps1.3.7.4.2.5.1.1 "><p id="obs_04_0081__p79294516598">Origin</p>
</td>
<td class="cellrowborder" valign="top" width="9.19%" headers="mcps1.3.7.4.2.5.1.2 "><p id="obs_04_0081__p417718121807">String</p>
</td>
<td class="cellrowborder" valign="top" width="8.49%" headers="mcps1.3.7.4.2.5.1.3 "><p id="obs_04_0081__p19365111512017">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="58.06%" headers="mcps1.3.7.4.2.5.1.4 "><p id="obs_04_0081__p4277941144817"><strong id="obs_04_0081__b16860596183813">Explanation</strong>:</p>
<p id="obs_04_0081__p11763148494">Where a cross-domain request is from (usually a domain name), specified in a preflight request</p>
<p id="obs_04_0081__p1900348174816"><strong id="obs_04_0081__b673021844915">Restrictions</strong>:</p>
<p id="obs_04_0081__p120310378811">None</p>
<p id="obs_04_0081__p43471210498"><strong id="obs_04_0081__b41368348384047">Value range</strong>:</p>
<p id="obs_04_0081__p1996254832912">An HTTP-compliant header value</p>
<p id="obs_04_0081__p9427999496"><strong id="obs_04_0081__b101335565784140">Default value</strong>:</p>
<p id="obs_04_0081__p53441311301">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1192913510596"><td class="cellrowborder" valign="top" width="24.26%" headers="mcps1.3.7.4.2.5.1.1 "><p id="obs_04_0081__p1593015112590">Access-Control-Request-Headers</p>
</td>
<td class="cellrowborder" valign="top" width="9.19%" headers="mcps1.3.7.4.2.5.1.2 "><p id="obs_04_0081__p793095125916">String</p>
</td>
<td class="cellrowborder" valign="top" width="8.49%" headers="mcps1.3.7.4.2.5.1.3 "><p id="obs_04_0081__p636519151701">No</p>
</td>
<td class="cellrowborder" valign="top" width="58.06%" headers="mcps1.3.7.4.2.5.1.4 "><p id="obs_04_0081__p101617115494"><strong id="obs_04_0081__b83633217483813">Explanation</strong>:</p>
<p id="obs_04_0081__p299471854911">HTTP headers in a request. Multiple headers can be included.</p>
<p id="obs_04_0081__p85171517103019"><strong id="obs_04_0081__b115171317193015">Restrictions</strong>:</p>
<p id="obs_04_0081__p16517617133018">None</p>
<p id="obs_04_0081__p105171317133012"><strong id="obs_04_0081__b891814023">Value range</strong>:</p>
<p id="obs_04_0081__p19517131733017">An HTTP-compliant header value</p>
<p id="obs_04_0081__p1651771716304"><strong id="obs_04_0081__b185157853">Default value</strong>:</p>
<p id="obs_04_0081__p65179170305">None</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="obs_04_0081__section45800647"><h4 class="sectiontitle">Request Elements</h4><p class="msonormal" id="obs_04_0081__p4135802">This request uses form elements. <a href="#obs_04_0081__table165118491000">Table 2</a> describes the form elements.</p>
<div class="tablenoborder"><a name="obs_04_0081__table165118491000"></a><a name="table165118491000"></a><table cellpadding="4" cellspacing="0" summary="" id="obs_04_0081__table165118491000" frame="border" border="1" rules="all"><caption><b>Table 2 </b>Form elements</caption><thead align="left"><tr id="obs_04_0081__row5522491904"><th align="left" class="cellrowborder" valign="top" width="15.888411158884114%" id="mcps1.3.8.3.2.5.1.1"><p id="obs_04_0081__p0523493013"><strong id="obs_04_0081__b18522491905">Element</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="12.82871712828717%" id="mcps1.3.8.3.2.5.1.2"><p id="obs_04_0081__p580418171117"><strong id="obs_04_0081__b161711815825">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="14.608539146085391%" id="mcps1.3.8.3.2.5.1.3"><p id="obs_04_0081__p771716614112"><strong id="obs_04_0081__b355617194818">Mandatory (Yes/No)</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="56.674332566743324%" id="mcps1.3.8.3.2.5.1.4"><p id="obs_04_0081__p18522049904"><strong id="obs_04_0081__b131711864811">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="obs_04_0081__row1052134910010"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p145219491304">file</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p4804111719113">Binary or text</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p25451453514">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p3219101644911"><strong id="obs_04_0081__b30100750083813">Explanation</strong>:</p>
<p id="obs_04_0081__p1952184912011">Object content to upload. Both the file name and path are ignored and will not be used as the object name. The object name is the value of parameter <strong id="obs_04_0081__b51623644">key</strong>.</p>
<p id="obs_04_0081__p6220161613496"><strong id="obs_04_0081__b1471181725415">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul1853113171517"><li id="obs_04_0081__li198533313158">This parameter must be the last to specify. Otherwise, the parameters that follow it will be discarded.</li><li id="obs_04_0081__li1185318318152">A request can contain only one <strong id="obs_04_0081__b3185199134015">file</strong> parameter.</li></ul>
<p id="obs_04_0081__p1130851817311"><strong id="obs_04_0081__b636962242">Value range</strong>:</p>
<p id="obs_04_0081__p43081018123114">None</p>
<p id="obs_04_0081__p93085185315"><strong id="obs_04_0081__b1802964084">Default value</strong>:</p>
<p id="obs_04_0081__p123081181317">None</p>
</td>
</tr>
<tr id="obs_04_0081__row155219491013"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p11522491708">key</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p1686452217507">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p15545175311116">Yes</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p19847193395017"><strong id="obs_04_0081__b1575842535">Explanation</strong>:</p>
<p id="obs_04_0081__p568755118152">Name of the object to be created. An object is uniquely identified by an object name in a bucket. An object name is a complete path that does not contain the bucket name.</p>
<p id="obs_04_0081__p192389501818"><strong id="obs_04_0081__b45481711911">Restrictions</strong>:</p>
<p id="obs_04_0081__p34555139593">None</p>
<p id="obs_04_0081__p312294513314"><strong id="obs_04_0081__b234214613">Value range</strong>:</p>
<p id="obs_04_0081__p131228458319">1 to 1,024 characters</p>
<p id="obs_04_0081__p1712264520317"><strong id="obs_04_0081__b592893869">Default value</strong>:</p>
<p id="obs_04_0081__p212219458312">None</p>
</td>
</tr>
<tr id="obs_04_0081__row145210493013"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p195294916012">AccessKeyId</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p539992385010">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p854510538110">Yes when the restrictions are met</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p19279102112496"><strong id="obs_04_0081__b179210838083813">Explanation</strong>:</p>
<p id="obs_04_0081__p3425521319">Access key ID (AK) of the requester.</p>
<p id="obs_04_0081__p6279132164917"><strong id="obs_04_0081__b475517186594">Restrictions</strong>:</p>
<p id="obs_04_0081__p180918542018">This parameter is mandatory if there is security policy parameter <strong id="obs_04_0081__b1061012143418">policy</strong> or <strong id="obs_04_0081__b66108143410">signature</strong> in the request.</p>
<p id="obs_04_0081__p37262022193417"><strong id="obs_04_0081__b766542815">Value range</strong>:</p>
<p id="obs_04_0081__p572662263412">AK of a user.</p>
<p id="obs_04_0081__p472672213415"><strong id="obs_04_0081__b596264874">Default value</strong>:</p>
<p id="obs_04_0081__p372618228345">None</p>
</td>
</tr>
<tr id="obs_04_0081__row5521649304"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p7524491108">policy</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p18632182515503">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p35451653510">Yes when the restrictions are met</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p944102412499"><strong id="obs_04_0081__b188425451383813">Explanation</strong>:</p>
<p id="obs_04_0081__p852174918018">A security policy</p>
<p id="obs_04_0081__p1844292414917"><strong id="obs_04_0081__b186111616195914">Restrictions</strong>:</p>
<p id="obs_04_0081__p18286712509">This parameter is mandatory if <strong id="obs_04_0081__b7665357174114">AccessKeyId</strong> or <strong id="obs_04_0081__b16665165744116">signature</strong> is provided in the form.</p>
<p id="obs_04_0081__p157541804353"><strong id="obs_04_0081__b153610812">Value range</strong>:</p>
<p id="obs_04_0081__p67542016351">For the policy format, see <a href="obs_04_0012.html">Authentication of Signature Carried in the Table Uploaded Through a Browser</a>.</p>
<p id="obs_04_0081__p07546019356"><strong id="obs_04_0081__b1190465083">Default value</strong>:</p>
<p id="obs_04_0081__p47548013359">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1052154914020"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p17520494018">signature</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p1120242725015">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p7545155312119">Yes when the restrictions are met</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p102625273498"><strong id="obs_04_0081__b90344979183813">Explanation</strong>:</p>
<p id="obs_04_0081__p1393821904">A signature string calculated based on StringToSign.</p>
<p id="obs_04_0081__p19262727114920"><strong id="obs_04_0081__b15826913135910">Restrictions</strong>:</p>
<p id="obs_04_0081__p9531849206">This parameter is mandatory if <strong id="obs_04_0081__b13749163004811">AccessKeyId</strong> or <strong id="obs_04_0081__b18750113084816">policy</strong> is provided in the form.</p>
<p id="obs_04_0081__p159423914366"><strong id="obs_04_0081__b1524309617">Value range</strong>:</p>
<p id="obs_04_0081__p19421997367">None</p>
<p id="obs_04_0081__p139421919362"><strong id="obs_04_0081__b2014935518">Default value</strong>:</p>
<p id="obs_04_0081__p17942893362">None</p>
</td>
</tr>
<tr id="obs_04_0081__row953114912016"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p17530491009">token</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p176961228135012">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p454695316116">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p2091422933613"><strong id="obs_04_0081__b141171209">Explanation</strong>:</p>
<p id="obs_04_0081__p3914192993614">Specifies the access key, signature, and security policy of the requester all together.</p>
<p id="obs_04_0081__p179141529193620"><strong id="obs_04_0081__b6914829163619">Restrictions</strong>:</p>
<p id="obs_04_0081__p8920102917365">The priority of a token is higher than that of a separately specified AK, signature, or security policy.</p>
<p id="obs_04_0081__p15920172913365">Example:</p>
<p id="obs_04_0081__p79201029103617">In HTML: &lt;input type= "text" name="token" value="ak:signature:policy" /&gt;</p>
<p id="obs_04_0081__p5920132933615"><strong id="obs_04_0081__b1954151103">Value range</strong>:</p>
<p id="obs_04_0081__p792012920364">The value must be in the <em id="obs_04_0081__i11307756184814">ak</em><strong id="obs_04_0081__b1383174174913">:</strong><em id="obs_04_0081__i2283145844812">signature</em><strong id="obs_04_0081__b14951227498">:</strong><em id="obs_04_0081__i166714015498">policy</em> format.</p>
<p id="obs_04_0081__p59206290368"><strong id="obs_04_0081__b262164374">Default value</strong>:</p>
<p id="obs_04_0081__p18920162973610">None</p>
</td>
</tr>
<tr id="obs_04_0081__row85314912020"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p153164915013">x-obs-acl</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p170443214503">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p1454616537112">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p81613474919"><strong id="obs_04_0081__b82528523183813">Explanation</strong>:</p>
<p id="obs_04_0081__p253154919011">Used to set a pre-defined ACL when creating an object</p>
<p id="obs_04_0081__p153144916018">Examples:</p>
<p id="obs_04_0081__p053749602">In POLICY: {"acl": "public-read" }</p>
<p id="obs_04_0081__p45317491902">In HTML: &lt;input type="text" name="acl" value="public-read" /&gt;</p>
<p id="obs_04_0081__p1316534144917"><strong id="obs_04_0081__b1216143414910">Restrictions</strong>:</p>
<p id="obs_04_0081__p1664413416301">None</p>
<p id="obs_04_0081__p1316153416495"><strong id="obs_04_0081__b115067258584047">Value range</strong>:</p>
<ul id="obs_04_0081__ul38161122103012"><li id="obs_04_0081__li1481614221304">private</li><li id="obs_04_0081__li18816922143010">public-read</li><li id="obs_04_0081__li5816122203019">public-read-write</li><li id="obs_04_0081__li1181682214306">public-read-delivered</li><li id="obs_04_0081__li68161922133013">public-read-write-delivered</li></ul>
<p id="obs_04_0081__p1214163215442"></p>
<p id="obs_04_0081__p31733413492"><strong id="obs_04_0081__b153285835384140">Default value</strong>:</p>
<p id="obs_04_0081__p967613438306">private</p>
</td>
</tr>
<tr id="obs_04_0081__row15537492012"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p18535497020">x-obs-grant-read</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p254614348508">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p1454615531113">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p6777153715495"><strong id="obs_04_0081__b101706169783813">Explanation</strong>:</p>
<p id="obs_04_0081__p25310495017">Used to — when creating an object — grant all users in a domain the permissions to read the object and obtain the object metadata</p>
<p id="obs_04_0081__p853104919015">Examples:</p>
<p id="obs_04_0081__p2053149203">In POLICY: {'grant-read': 'id=domainId1' },</p>
<p id="obs_04_0081__p25317493013">In HTML: &lt;input type="text" name="grant-read" value="id=domainId1" /&gt;</p>
<p id="obs_04_0081__p14932224153719"><strong id="obs_04_0081__b813564515540">Restrictions</strong>:</p>
<p id="obs_04_0081__p9932724193714">Use commas (,) to separate multiple domains.</p>
<p id="obs_04_0081__p49327242372"><strong id="obs_04_0081__b1662364928">Value range</strong>:</p>
<p id="obs_04_0081__p1393252418379">The value of <em id="obs_04_0081__i10649103313615">domainId</em> must be valid. For details about how to obtain the ID, see <a href="obs_04_0117.html">Obtaining a Domain ID and a User ID</a>.</p>
<p id="obs_04_0081__p093272413376"><strong id="obs_04_0081__b1306727400">Default value</strong>:</p>
<p id="obs_04_0081__p4932824103710">None</p>
</td>
</tr>
<tr id="obs_04_0081__row115313491906"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p18530491305">x-obs-grant-read-acp</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p1679313356507">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p1054645315110">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p1331411409495"><strong id="obs_04_0081__b170348011983813">Explanation</strong>:</p>
<p id="obs_04_0081__p14531749402">Used to — when creating an object — grant all users in a domain the permission to obtain the object ACL.</p>
<p id="obs_04_0081__p11721849909">Examples:</p>
<p id="obs_04_0081__p1172164911012">In POLICY: {"grant-read-acp": "id=domainId1" },</p>
<p id="obs_04_0081__p177218491509">In HTML: &lt;input type="text" name="grant-read-acp" value="id=domainId1" /&gt;</p>
<p id="obs_04_0081__p1458114135315"><strong id="obs_04_0081__b758171313116">Restrictions</strong>:</p>
<p id="obs_04_0081__p17224121193918">None</p>
<p id="obs_04_0081__p15121157163819"><strong id="obs_04_0081__b1868485802">Value range</strong>:</p>
<p id="obs_04_0081__p21212057173816">The value of <em id="obs_04_0081__i197182029681">domainId</em> must be valid. For details about how to obtain the ID, see <a href="obs_04_0117.html">Obtaining a Domain ID and a User ID</a>.</p>
<p id="obs_04_0081__p1012115575380"><strong id="obs_04_0081__b214120389">Default value</strong>:</p>
<p id="obs_04_0081__p6121657123815">None</p>
</td>
</tr>
<tr id="obs_04_0081__row572184910011"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p117211491407">x-obs-grant-write-acp</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p610713717501">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p154611531111">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p19519430491"><strong id="obs_04_0081__b96639848583813">Explanation</strong>:</p>
<p id="obs_04_0081__p19720491901">Used to — when creating an object — grant all users in a domain the permission to write the object ACL.</p>
<p id="obs_04_0081__p372174918016">Examples:</p>
<p id="obs_04_0081__p472749108">In POLICY: {"grant-write-acp": "id=domainId1" },</p>
<p id="obs_04_0081__p97213493010">In HTML: &lt;input type="text" name="grant-write-acp" value="id=domainId1" /&gt;</p>
<p id="obs_04_0081__p975078399"><strong id="obs_04_0081__b17514711390">Restrictions</strong>:</p>
<p id="obs_04_0081__p1075167183911">None</p>
<p id="obs_04_0081__p1675577391"><strong id="obs_04_0081__b1701993849">Value range</strong>:</p>
<p id="obs_04_0081__p157618773916">The value of <em id="obs_04_0081__i1435114355211">domainId</em> must be valid. For details about how to obtain the ID, see <a href="obs_04_0117.html">Obtaining a Domain ID and a User ID</a>.</p>
<p id="obs_04_0081__p2768733911"><strong id="obs_04_0081__b1446275743">Default value</strong>:</p>
<p id="obs_04_0081__p776177183915">None</p>
</td>
</tr>
<tr id="obs_04_0081__row14721491209"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p127294918013">x-obs-grant-full-control</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p10450638175012">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p154675315110">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p733912468499"><strong id="obs_04_0081__b203285974983813">Explanation</strong>:</p>
<p id="obs_04_0081__p2072449308">When creating an object, you can use this header to grant all users in an account the permissions to read the object, obtain the object metadata and ACL, and write the object ACL.</p>
<p id="obs_04_0081__p147211498011">Examples:</p>
<p id="obs_04_0081__p13726491202">In POLICY: {"grant-full-control": "id=domainId1" },</p>
<p id="obs_04_0081__p572124912012">In HTML: &lt;input type="text" name="grant-full-control" value="id=domainId1" /&gt;</p>
<p id="obs_04_0081__p92611611133911"><strong id="obs_04_0081__b426191120397">Restrictions</strong>:</p>
<p id="obs_04_0081__p426171123916">None</p>
<p id="obs_04_0081__p18261181115393"><strong id="obs_04_0081__b877219480">Value range</strong>:</p>
<p id="obs_04_0081__p15262611103918">The value of <em id="obs_04_0081__i44591024464">domainId</em> must be valid. For details about how to obtain the ID, see <a href="obs_04_0117.html">Obtaining a Domain ID and a User ID</a>.</p>
<p id="obs_04_0081__p1626241153912"><strong id="obs_04_0081__b737248811">Default value</strong>:</p>
<p id="obs_04_0081__p12262151133912">None</p>
</td>
</tr>
<tr id="obs_04_0081__row11723494012"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p177220491205">x-obs-storage-class</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p38880396506">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p105461953412">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p262544913497"><strong id="obs_04_0081__b129285000983813">Explanation</strong>:</p>
<p id="obs_04_0081__p15489134155714">Used to — when creating an object — specify its storage class.</p>
<p id="obs_04_0081__p9731649209">Examples:</p>
<p id="obs_04_0081__p4735491011">In POLICY: {"storage-class": "STANDARD" },</p>
<p id="obs_04_0081__p5731949409">In HTML: &lt;input type="text" name="x-obs-storage-class" value="STANDARD" /&gt;</p>
<p id="obs_04_0081__p9625114924917"><strong id="obs_04_0081__b7625104919494">Restrictions</strong>:</p>
<p id="obs_04_0081__p13835101015327">The value is case-sensitive.</p>
<p id="obs_04_0081__p7625154904913"><strong id="obs_04_0081__b27228064684047">Value range</strong>:</p>
<ul id="obs_04_0081__ul111239624018"><li id="obs_04_0081__li21235644017">STANDARD</li><li id="obs_04_0081__li1512318613406">WARM</li><li id="obs_04_0081__li212396124010">COLD</li></ul>
<p id="obs_04_0081__p16263499498"><strong id="obs_04_0081__b61459841084140">Default value</strong>:</p>
<p id="obs_04_0081__p182355445813">If you do not use this header, the object storage class is the default storage class of the bucket.</p>
</td>
</tr>
<tr id="obs_04_0081__row1873114914013"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p17316490017">Cache-Control</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p4784144115010">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p18546105319111">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p36391438183912"><strong id="obs_04_0081__b1121237897">Explanation</strong>:</p>
<p id="obs_04_0081__p17639123843914">Standard HTTP header, returned in the response if a user downloads the object or makes a Head Object request.</p>
<p id="obs_04_0081__p17640123863918"><strong id="obs_04_0081__b164003883920">Restrictions</strong>:</p>
<p id="obs_04_0081__p116401638153920">None</p>
<p id="obs_04_0081__p7640938143916"><strong id="obs_04_0081__b1719440225">Value range</strong>:</p>
<p id="obs_04_0081__p2640103813393">See the HTTP requirements for the Cache-Control header.</p>
<p id="obs_04_0081__p064083819397"><strong id="obs_04_0081__b1312159877">Default value</strong>:</p>
<p id="obs_04_0081__p10640163813390">None</p>
</td>
</tr>
<tr id="obs_04_0081__row850833612350"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p973134917015">Content-Type</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p887514189382">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p587511189389">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p1882119663610"><strong id="obs_04_0081__b1755003039">Explanation</strong>:</p>
<p id="obs_04_0081__p1169114543617">Standard HTTP header, returned in the response if a user downloads the object or makes a Head Object request.</p>
<p id="obs_04_0081__p382111614363">Example:</p>
<p id="obs_04_0081__p18213612364">In POLICY: ["starts-with", "$Content-Type", "text/"],</p>
<p id="obs_04_0081__p68218683611">In HTML: &lt;input type="text" name="content-type" value="text/plain" /&gt;</p>
<p id="obs_04_0081__p35424388403"><strong id="obs_04_0081__b3542638114015">Restrictions</strong>:</p>
<p id="obs_04_0081__p11542163811403">None</p>
<p id="obs_04_0081__p95421438104011"><strong id="obs_04_0081__b1934606967">Value range</strong>:</p>
<p id="obs_04_0081__p8542133811408">See the HTTP requirements for the Content-Type header.</p>
<p id="obs_04_0081__p95421238124015"><strong id="obs_04_0081__b1813919542">Default value</strong>:</p>
<p id="obs_04_0081__p054212385406">None</p>
</td>
</tr>
<tr id="obs_04_0081__row33166349350"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p3731492018">Content-Disposition</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p105718200380">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p557119205389">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p898317214389"><strong id="obs_04_0081__b1684439076">Explanation</strong>:</p>
<p id="obs_04_0081__p1398319203818">Standard HTTP header, returned in the response if a user downloads the object or makes a Head Object request.</p>
<p id="obs_04_0081__p1710545334013"><strong id="obs_04_0081__b1610525344019">Restrictions</strong>:</p>
<p id="obs_04_0081__p10105105324017">None</p>
<p id="obs_04_0081__p141051453164015"><strong id="obs_04_0081__b1559552847">Value range</strong>:</p>
<p id="obs_04_0081__p310513539409">See the HTTP requirements for the Content-Disposition header.</p>
<p id="obs_04_0081__p71057539406"><strong id="obs_04_0081__b542986516">Default value</strong>:</p>
<p id="obs_04_0081__p210585313405">None</p>
</td>
</tr>
<tr id="obs_04_0081__row14533232153519"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p17734494011">Content-Encoding</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p2306132273816">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p13066229388">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p144937382"><strong id="obs_04_0081__b524945607">Explanation</strong>:</p>
<p id="obs_04_0081__p744338385">Standard HTTP header, returned in the response if a user downloads the object or makes a Head Object request.</p>
<p id="obs_04_0081__p10519151418"><strong id="obs_04_0081__b106191516411">Restrictions</strong>:</p>
<p id="obs_04_0081__p26141534115">None</p>
<p id="obs_04_0081__p166151512416"><strong id="obs_04_0081__b1268877417">Value range</strong>:</p>
<p id="obs_04_0081__p36915124112">See the HTTP requirements for the Content-Encoding header.</p>
<p id="obs_04_0081__p36181564112"><strong id="obs_04_0081__b1174321806">Default value</strong>:</p>
<p id="obs_04_0081__p1569154415">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1649617308351"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p8739491506">Expires</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p188811823183812">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p788111236389">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p690528204111"><strong id="obs_04_0081__b308775650">Explanation</strong>:</p>
<p id="obs_04_0081__p1690152804112">Standard HTTP header, returned in the response if a user downloads the object or makes a Head Object request.</p>
<p id="obs_04_0081__p290172894110"><strong id="obs_04_0081__b1890102818415">Restrictions</strong>:</p>
<p id="obs_04_0081__p290142814116">None</p>
<p id="obs_04_0081__p39015282418"><strong id="obs_04_0081__b282995733">Value range</strong>:</p>
<p id="obs_04_0081__p209062864110">See the HTTP requirements for the Expires header.</p>
<p id="obs_04_0081__p5905283410"><strong id="obs_04_0081__b266501159">Default value</strong>:</p>
<p id="obs_04_0081__p690182874115">None</p>
</td>
</tr>
<tr id="obs_04_0081__row9731049101"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p157354912010">success_action_redirect</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p1473574516505">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p6546753611">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p1340119363914"><strong id="obs_04_0081__b301454836">Explanation</strong>:</p>
<p id="obs_04_0081__p935211311505">Where a successful request is redirected</p>
<ul id="obs_04_0081__ul973134917016"><li id="obs_04_0081__li11737491107">If the value is valid and the request is successful, OBS returns status code 303. <strong id="obs_04_0081__b182142426">Location</strong> contains <strong id="obs_04_0081__b776897794">success_action_redirect</strong> as well as the bucket name, object name, and object ETag.</li><li id="obs_04_0081__li073104914012">If the value is invalid, OBS ignores this parameter. <strong id="obs_04_0081__b1041060807">Location</strong> contains the object address, and OBS returns the response code based on the actual result.</li></ul>
<p id="obs_04_0081__p7737497011">Examples:</p>
<p id="obs_04_0081__p1673649207">In POLICY: {"success_action_redirect": "http://123458.com"},</p>
<p id="obs_04_0081__p7731849403">In HTML: &lt;input type="text" name="success_action_redirect" value="http://123458.com" /&gt;</p>
<p id="obs_04_0081__p163251942174110"><strong id="obs_04_0081__b432524294112">Restrictions</strong>:</p>
<p id="obs_04_0081__p1332514214413">The value must start with <strong id="obs_04_0081__b18402514236">http</strong> or <strong id="obs_04_0081__b5994161710312">https</strong>.</p>
<p id="obs_04_0081__p153252423412"><strong id="obs_04_0081__b1359206608">Value range</strong>:</p>
<p id="obs_04_0081__p632516422417">URL</p>
<p id="obs_04_0081__p10325114264118"><strong id="obs_04_0081__b530226550">Default value</strong>:</p>
<p id="obs_04_0081__p1132594244118">None</p>
</td>
</tr>
<tr id="obs_04_0081__row17747491505"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p4742491804">x-obs-meta-*</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p1421714711504">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p25467534113">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p14980898505"><strong id="obs_04_0081__b67858854783813">Explanation</strong>:</p>
<p id="obs_04_0081__p13744491800">Used when creating an object to define metadata. The defined metadata is returned in the response when you obtain the object or query its metadata. </p>
<p id="obs_04_0081__p197424910016">Examples:</p>
<p id="obs_04_0081__p674104910016">In POLICY: {" x-obs-meta-test ": " test metadata " },</p>
<p id="obs_04_0081__p17741049107">In HTML: &lt;input type="text" name=" x-obs-meta-test " value=" test metadata " /&gt;</p>
<p id="obs_04_0081__p587731212424"><strong id="obs_04_0081__b12877151217420">Restrictions</strong>:</p>
<p id="obs_04_0081__p16877181244219">None</p>
<p id="obs_04_0081__p1787751254212"><strong id="obs_04_0081__b752071348">Value range</strong>:</p>
<p id="obs_04_0081__p13877112194210">For details, see <a href="https://docs.otc.t-systems.com/object-storage-service/umn/obs_console_operation_guide/object_metadata/index.html" target="_blank" rel="noopener noreferrer">Object Metadata</a>.</p>
<p id="obs_04_0081__p3877181234210"><strong id="obs_04_0081__b1547952806">Default value</strong>:</p>
<p id="obs_04_0081__p087731244213">None</p>
</td>
</tr>
<tr id="obs_04_0081__row27694914019"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p1976849408">success_action_status</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p198401750105013">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p155464531614">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p1889111170500"><strong id="obs_04_0081__b112791274583813">Explanation</strong>:</p>
<p id="obs_04_0081__p11770497020">The status code returned for a successful request.</p>
<p id="obs_04_0081__p177144916013">Examples:</p>
<p id="obs_04_0081__p1177114911010">In POLICY: ["starts-with", "$success_action_status", ""],</p>
<p id="obs_04_0081__p1777949802">In HTML: &lt;input type="text" name="success_action_status" value="200" /&gt;</p>
<p id="obs_04_0081__p1891151765017"><strong id="obs_04_0081__b13892101715501">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul1677204910013"><li id="obs_04_0081__li37716491103">If this parameter is set to <strong id="obs_04_0081__b1862490482">200</strong> or <strong id="obs_04_0081__b1650007458">204</strong>, the response body is left blank.</li><li id="obs_04_0081__li3772049707">If this parameter is set to <strong id="obs_04_0081__b768344637">201</strong>, the response message contains an XML document that describes the response.</li><li id="obs_04_0081__li15771496010">If this parameter is not specified or is invalid, the status code is <strong id="obs_04_0081__b568624216">204</strong>.</li></ul>
<p id="obs_04_0081__p1489213173508"><strong id="obs_04_0081__b101549770584047">Value range</strong>:</p>
<ul id="obs_04_0081__ul0872131144918"><li id="obs_04_0081__li16872143144913">200</li><li id="obs_04_0081__li10872133110498">201</li><li id="obs_04_0081__li1987217317491">204</li></ul>
<p id="obs_04_0081__p3892151719505"><strong id="obs_04_0081__b98068494184140">Default value</strong>:</p>
<p id="obs_04_0081__p16518105414412">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1977104918014"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p137717491402">x-obs-website-redirect-location</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p16797105313486">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p654612536117">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p19481420175020"><strong id="obs_04_0081__b117704808483813">Explanation</strong>:</p>
<p id="obs_04_0081__p11946729155515">If a bucket is configured with static website hosting, requests for one object in this bucket can be redirected to another object in the same bucket or to an external URL. OBS stores the value of this header in the object metadata.</p>
<p id="obs_04_0081__p1094862045012"><strong id="obs_04_0081__b163219321558">Restrictions</strong>:</p>
<p id="obs_04_0081__p175931332555">The value must start with a slash (/), <strong id="obs_04_0081__b13601487917">http://</strong>, or <strong id="obs_04_0081__b760178998">https://</strong> and cannot exceed 2K.</p>
<p id="obs_04_0081__p1994818203509"><strong id="obs_04_0081__b202442888384047">Value range</strong>:</p>
<p id="obs_04_0081__p6269182510424">None</p>
<p id="obs_04_0081__p13591132712429"><strong id="obs_04_0081__b1317695827">Default value</strong>:</p>
<p id="obs_04_0081__p29484208507">None</p>
</td>
</tr>
<tr id="obs_04_0081__row15771249300"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p127764915016">x-obs-server-side-encryption</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p167111955145012">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p1554619531119">No. This header is required when SSE-KMS is used.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p169071023145011"><strong id="obs_04_0081__b188063788483813">Explanation</strong>:</p>
<p id="obs_04_0081__p117714911019">Indicates that SSE-KMS is used for server-side encryption.</p>
<p id="obs_04_0081__p157719491005">Example: <strong id="obs_04_0081__b1643178102">x-obs-server-side-encryption:kms</strong></p>
<p id="obs_04_0081__p186754817499"><strong id="obs_04_0081__b867511874920">Restrictions</strong>:</p>
<p id="obs_04_0081__p4675118154917">None</p>
<p id="obs_04_0081__p36750812492"><strong id="obs_04_0081__b1107348361">Value range</strong>:</p>
<ul id="obs_04_0081__ul1213741516499"><li id="obs_04_0081__li11137615124912">kms</li><li id="obs_04_0081__li1713710153498">AES256</li></ul>
<p id="obs_04_0081__p767519874915"><strong id="obs_04_0081__b2022685687">Default value</strong>:</p>
<p id="obs_04_0081__p166751683494">None</p>
</td>
</tr>
<tr id="obs_04_0081__row157714910012"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p37720490014">x-obs-server-side-encryption-kms-key-id</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p14120105518">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p45476537114">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p564255112519"><strong id="obs_04_0081__b182118571589">Explanation</strong>:</p>
<p id="obs_04_0081__p10643115112511">ID of a specified key used for SSE-KMS encryption.</p>
<p id="obs_04_0081__p16644195111511"><strong id="obs_04_0081__b882981415">Restrictions</strong>:</p>
<p id="obs_04_0081__p196445511752">This header can only be used when you specify <strong id="obs_04_0081__b25323597125113">kms</strong> for the <strong id="obs_04_0081__b192491203225113">x-obs-server-side-encryption</strong> header.</p>
<p id="obs_04_0081__p116441751359"><strong id="obs_04_0081__b1499609760">Default value</strong>:</p>
<p id="obs_04_0081__p126443511556">If you specify <strong id="obs_04_0081__b72692020625113">kms</strong> for encryption but do not specify a key ID, the default master key will be used. If there is not a default master key, OBS will create one and use it.</p>
</td>
</tr>
<tr id="obs_04_0081__row197816493016"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p37884918017">x-obs-server-side-encryption-customer-algorithm</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p2023415219519">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p19547115317114">No. This header is required when SSE-C is used.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p998183512506"><strong id="obs_04_0081__b19158218183813">Explanation</strong>:</p>
<p id="obs_04_0081__p17814494018">The algorithm used for encryption.</p>
<p id="obs_04_0081__p17788491806">Example: <strong id="obs_04_0081__b1049143430">x-obs-server-side-encryption-customer-algorithm:AES256</strong></p>
<p id="obs_04_0081__p139823513508"><strong id="obs_04_0081__b298193555017">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul10811850104513"><li id="obs_04_0081__li16811950114511">This header is used only when SSE-C is used.</li><li id="obs_04_0081__li281205034517">This header must be used with <strong id="obs_04_0081__b42271334151317">x-obs-server-side-encryption-customer-key</strong> and <strong id="obs_04_0081__b162272034151314">x-obs-server-side-encryption-customer-key-MD5</strong>.</li></ul>
<p id="obs_04_0081__p154591515011"><strong id="obs_04_0081__b1963862224">Value range</strong>:</p>
<p id="obs_04_0081__p745191513509">AES256</p>
<p id="obs_04_0081__p8459156509"><strong id="obs_04_0081__b919735338">Default value</strong>:</p>
<p id="obs_04_0081__p134571555013">None</p>
</td>
</tr>
<tr id="obs_04_0081__row178134910010"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p3782495017">x-obs-server-side-encryption-customer-key</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p361820365110">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p16547205314114">No. This header is required when SSE-C is used.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p570413711509"><strong id="obs_04_0081__b177120070683813">Explanation</strong>:</p>
<p id="obs_04_0081__p37816491301">The key used for encrypting an object.</p>
<p id="obs_04_0081__p117894917014">Example: <strong id="obs_04_0081__b1329360379">x-obs-server-side-encryption-customer-key:K7QkYpBkM5+hca27fsNkUnNVaobncnLht/rCB2o/9Cw=</strong></p>
<p id="obs_04_0081__p1170443717507"><strong id="obs_04_0081__b6704103735015">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul2296161317461"><li id="obs_04_0081__li4296151374615">This header is used only when SSE-C is used.</li><li id="obs_04_0081__li829619135462">This header is a Base64-encoded 256-bit key. It must be used with <strong id="obs_04_0081__b15587811131410">x-obs-server-side-encryption-customer-algorithm</strong> and <strong id="obs_04_0081__b13587811141411">x-obs-server-side-encryption-customer-key-MD5</strong>.</li></ul>
<p id="obs_04_0081__p913013288504"><strong id="obs_04_0081__b1139127611">Value range</strong>:</p>
<p id="obs_04_0081__p51307288501">None</p>
<p id="obs_04_0081__p1613032855019"><strong id="obs_04_0081__b228187222">Default value</strong>:</p>
<p id="obs_04_0081__p1813032845010">None</p>
</td>
</tr>
<tr id="obs_04_0081__row8781649809"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p57816491507">x-obs-server-side-encryption-customer-key-MD5</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p16153151512">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p0547195320115">No. This header is required when SSE-C is used.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p1384254015503"><strong id="obs_04_0081__b141125421183813">Explanation</strong>:</p>
<p id="obs_04_0081__p7781149606">The MD5 value of the key used for encryption. Used to check whether any error occurs during the key transmission.</p>
<p id="obs_04_0081__p11783491406">Example: <strong id="obs_04_0081__b799747708">x-obs-server-side-encryption-customer-key-MD5:4XvB3tbNTN+tIEVa0/fGaQ==</strong></p>
<p id="obs_04_0081__p58429404500"><strong id="obs_04_0081__b1384314005015">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul164151520475"><li id="obs_04_0081__li134110154478">This header is used only when SSE-C is used.</li><li id="obs_04_0081__li1541191584718">This header is a Base64-encoded 128-bit MD5 value. It must be used with <strong id="obs_04_0081__b124661925111413">x-obs-server-side-encryption-customer-algorithm</strong> and <strong id="obs_04_0081__b5467825151416">x-obs-server-side-encryption-customer-key</strong>.</li></ul>
<p id="obs_04_0081__p174451353195010"><strong id="obs_04_0081__b379519335">Value range</strong>:</p>
<p id="obs_04_0081__p194451053165012">MD5 value of the key.</p>
<p id="obs_04_0081__p6445145355018"><strong id="obs_04_0081__b955634428">Default value</strong>:</p>
<p id="obs_04_0081__p13445153135020">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1578104913015"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p37811491007">x-obs-expires</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p920813440529">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p195471153318">No</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p977118434503"><strong id="obs_04_0081__b52579305083813">Explanation</strong>:</p>
<p id="obs_04_0081__p167812492019">When an object expires and is deleted (how many days after the last update).</p>
<p id="obs_04_0081__p1117611345115">You can configure this parameter when uploading an object. You can also modify it after the object is uploaded by using the metadata modification API.</p>
<p id="obs_04_0081__p01762013145110">Example: <strong id="obs_04_0081__b509780669">x-obs-expires:3</strong></p>
<p id="obs_04_0081__p41761113165115"><strong id="obs_04_0081__b617612138516">Restrictions</strong>:</p>
<p id="obs_04_0081__p61761113135118">The value must be greater than the number of days that have passed since the object was created. For example, if the object was uploaded 10 days ago, you must specify a value greater than 10.</p>
<p id="obs_04_0081__p1117621335119"><strong id="obs_04_0081__b1389180482">Value range</strong>:</p>
<p id="obs_04_0081__p1517651305113">The value is an integer greater than 0.</p>
<p id="obs_04_0081__p7176161311516"><strong id="obs_04_0081__b1723333545">Default value</strong>:</p>
<p id="obs_04_0081__p19176181335119">None</p>
</td>
</tr>
<tr id="obs_04_0081__row137811495020"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p17818492009">x-obs-object-lock-mode</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p4498788515">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p165470532015">No, but required when <strong id="obs_04_0081__b28362124534">x-obs-object-lock-retain-until-date</strong> is present.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p58291846195017"><strong id="obs_04_0081__b20586863183813">Explanation</strong>:</p>
<p id="obs_04_0081__p15434415135212">WORM mode applied to the object.</p>
<p id="obs_04_0081__p8795492013">Example: <strong id="obs_04_0081__b5490115111611">x-obs-object-lock-mode:COMPLIANCE</strong></p>
<p id="obs_04_0081__p10829746185018"><strong id="obs_04_0081__b88292046125016">Restrictions</strong>:</p>
<p id="obs_04_0081__p1728720114913">Currently, only COMPLIANCE (compliance mode) is supported.</p>
<p id="obs_04_0081__p285042913521">This parameter must be used with <strong id="obs_04_0081__b0820112071619">x-obs-object-lock-retain-until-date</strong>.</p>
<p id="obs_04_0081__p18810232165118"><strong id="obs_04_0081__b1102386678">Value range</strong>:</p>
<p id="obs_04_0081__p181073285111">COMPLIANCE</p>
<p id="obs_04_0081__p1781018327517"><strong id="obs_04_0081__b42301561">Default value</strong>:</p>
<p id="obs_04_0081__p78101632185113">None</p>
</td>
</tr>
<tr id="obs_04_0081__row37964916013"><td class="cellrowborder" valign="top" width="15.888411158884114%" headers="mcps1.3.8.3.2.5.1.1 "><p id="obs_04_0081__p167913491508">x-obs-object-lock-retain-until-date</p>
</td>
<td class="cellrowborder" valign="top" width="12.82871712828717%" headers="mcps1.3.8.3.2.5.1.2 "><p id="obs_04_0081__p117700915114">String</p>
</td>
<td class="cellrowborder" valign="top" width="14.608539146085391%" headers="mcps1.3.8.3.2.5.1.3 "><p id="obs_04_0081__p135477536117">No, but required when <strong id="obs_04_0081__b34351173533">x-obs-object-lock-mode</strong> is present.</p>
</td>
<td class="cellrowborder" valign="top" width="56.674332566743324%" headers="mcps1.3.8.3.2.5.1.4 "><p id="obs_04_0081__p7134184955020"><strong id="obs_04_0081__b57396013983813">Explanation</strong>:</p>
<p id="obs_04_0081__p47984920017">When the WORM policy of the object expires.</p>
<p id="obs_04_0081__p47944920016">Example: <strong id="obs_04_0081__b1918391334">x-obs-object-lock-retain-until-date:2015-07-01T04:11:15Z</strong></p>
<p id="obs_04_0081__p3134134945010"><strong id="obs_04_0081__b18273175815557">Restrictions</strong>:</p>
<p id="obs_04_0081__p21581556144914">The value must be a UTC time that complies with the ISO 8601 standard. Example: <strong id="obs_04_0081__b9690172815174">2015-07-01T04:11:15Z</strong></p>
<p id="obs_04_0081__p3138103135218">This parameter must be used with <strong id="obs_04_0081__b974511393175">x-obs-object-lock-mode</strong>.</p>
<p id="obs_04_0081__p1573764711510"><strong id="obs_04_0081__b6594385">Value range</strong>:</p>
<p id="obs_04_0081__p673854715513">The time must be later than the current time.</p>
<p id="obs_04_0081__p7738134795118"><strong id="obs_04_0081__b191265960">Default value</strong>:</p>
<p id="obs_04_0081__p1273884719518">None</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="obs_04_0081__section9552642"><h4 class="sectiontitle">Response Syntax</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen35771416105"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
<span class="normal">2</span>
<span class="normal">3</span>
<span class="normal">4</span>
<span class="normal">5</span></pre></div></td><td class="code"><div><pre><span></span>HTTP/1.1<span class="w"> </span>status_code
Content-Type:<span class="w"> </span>application/xml<span class="w"> </span>
Location:<span class="w"> </span>location
Date:<span class="w"> </span>date
ETag:<span class="w"> </span>etag
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section18864917"><h4 class="sectiontitle">Response Headers</h4><p class="msonormal" id="obs_04_0081__p1512332591013">The response to the request uses common headers. For details, see <a href="obs_04_0013.html#obs_04_0013__d0e686">Table 1</a>.</p>
<p class="msonormal" id="obs_04_0081__p15525038">In addition to the common response headers, the headers listed in <a href="#obs_04_0081__table6575145423">Table 3</a> may be used.</p>
<div class="tablenoborder"><a name="obs_04_0081__table6575145423"></a><a name="table6575145423"></a><table cellpadding="4" cellspacing="0" summary="" id="obs_04_0081__table6575145423" frame="border" border="1" rules="all"><caption><b>Table 3 </b>Additional response headers</caption><thead align="left"><tr id="obs_04_0081__row13575445429"><th align="left" class="cellrowborder" valign="top" width="25.009999999999998%" id="mcps1.3.10.4.2.4.1.1"><p id="obs_04_0081__p557684510211">Header</p>
</th>
<th align="left" class="cellrowborder" valign="top" width="19.5%" id="mcps1.3.10.4.2.4.1.2"><p id="obs_04_0081__p311312107313"><strong id="obs_04_0081__b25293108180">Type</strong></p>
</th>
<th align="left" class="cellrowborder" valign="top" width="55.489999999999995%" id="mcps1.3.10.4.2.4.1.3"><p id="obs_04_0081__p1576144515219"><strong id="obs_04_0081__b87102546">Description</strong></p>
</th>
</tr>
</thead>
<tbody><tr id="obs_04_0081__row25761045929"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p8576114517213">x-obs-version-id</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p1257614451627">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p1995093512521"><strong id="obs_04_0081__b103920710983813">Explanation</strong>:</p>
<p id="obs_04_0081__p1327242816513">Object version ID.</p>
<p id="obs_04_0081__p13950835145212"><strong id="obs_04_0081__b1282231311561">Restrictions</strong>:</p>
<ul id="obs_04_0081__ul185513915917"><li id="obs_04_0081__li1185513920913">If versioning is enabled for the bucket, the object version ID will be returned.</li><li id="obs_04_0081__li28551339393">If versioning is suspended for the bucket, a string <strong id="obs_04_0081__b4940182751817">null</strong> is returned.</li></ul>
<p id="obs_04_0081__p11425361522"><strong id="obs_04_0081__b1102179258">Value range</strong>:</p>
<p id="obs_04_0081__p12425460524">The value is automatically generated by the server.</p>
<p id="obs_04_0081__p1442506155217"><strong id="obs_04_0081__b67446619">Default value</strong>:</p>
<p id="obs_04_0081__p1142586145216">None</p>
</td>
</tr>
<tr id="obs_04_0081__row105763457219"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p1657634511213">Access-Control-Allow-Origin</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p1336410311314">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p193281338145219"><strong id="obs_04_0081__b140594471783813">Explanation</strong>:</p>
<p id="obs_04_0081__p195765451626">Returned if the request origin meets the CORS configured on the server.</p>
<p id="obs_04_0081__p3293102112528"><strong id="obs_04_0081__b14293221115211">Restrictions</strong>:</p>
<p id="obs_04_0081__p19293142114524">None</p>
<p id="obs_04_0081__p1629319210521"><strong id="obs_04_0081__b1682742752">Value range</strong>:</p>
<p id="obs_04_0081__p1129315213522">The value that complies with the CORS</p>
<p id="obs_04_0081__p2293521195211"><strong id="obs_04_0081__b398587901">Default value</strong>:</p>
<p id="obs_04_0081__p1529342111520">None</p>
</td>
</tr>
<tr id="obs_04_0081__row20576345928"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p15768451623">Access-Control-Allow-Headers</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p049112419317">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p1995864085218"><strong id="obs_04_0081__b152781300583813">Explanation</strong>:</p>
<p id="obs_04_0081__p75764451428">Returned if the request headers meet the CORS configured on the server.</p>
<p id="obs_04_0081__p12180123517522"><strong id="obs_04_0081__b191801635205216">Restrictions</strong>:</p>
<p id="obs_04_0081__p4180163519523">None</p>
<p id="obs_04_0081__p4180193555213"><strong id="obs_04_0081__b1934002029">Value range</strong>:</p>
<p id="obs_04_0081__p181804358528">The value that complies with the CORS</p>
<p id="obs_04_0081__p81802035145213"><strong id="obs_04_0081__b866973713">Default value</strong>:</p>
<p id="obs_04_0081__p191801535165218">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1357694518215"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p1257610451929">Access-Control-Max-Age</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p95764455218">Integer</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p567124385211"><strong id="obs_04_0081__b191494014283813">Explanation</strong>:</p>
<p id="obs_04_0081__p134081055548">Value of <strong id="obs_04_0081__b132565065312">MaxAgeSeconds</strong> in the CORS configuration on the server when CORS is configured for buckets.</p>
<p id="obs_04_0081__p19731145235216"><strong id="obs_04_0081__b20731105211521">Restrictions</strong>:</p>
<p id="obs_04_0081__p13731552135212">None</p>
<p id="obs_04_0081__p173185220529"><strong id="obs_04_0081__b1474501845">Value range</strong>:</p>
<p id="obs_04_0081__p15731155285216">An integer greater than or equal to 0, in seconds</p>
<p id="obs_04_0081__p147311752185219"><strong id="obs_04_0081__b523268207">Default value</strong>:</p>
<p id="obs_04_0081__p173135213525">3000</p>
</td>
</tr>
<tr id="obs_04_0081__row857617451927"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p1457784517218">Access-Control-Allow-Methods</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p14173111220311">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p848094614524"><strong id="obs_04_0081__b89157337983813">Explanation</strong>:</p>
<p id="obs_04_0081__p195771745422">If a bucket has CORS configured, and Access-Control-Request-Method in the request meets the CORS configuration on the server, the specified methods in the rule are returned.</p>
<p id="obs_04_0081__p7480194618529"><strong id="obs_04_0081__b1220155475319">Restrictions</strong>:</p>
<p id="obs_04_0081__p11353937191011">None</p>
<p id="obs_04_0081__p14481184645213"><strong id="obs_04_0081__b158667624384047">Value range</strong>:</p>
<ul id="obs_04_0081__ul1927417525108"><li id="obs_04_0081__li1427415231018">GET</li><li id="obs_04_0081__li13274125212102">PUT</li><li id="obs_04_0081__li1527465211103">HEAD</li><li id="obs_04_0081__li3274852161016">POST</li><li id="obs_04_0081__li72751052191015">DELETE</li></ul>
<p id="obs_04_0081__p2048114616527"><strong id="obs_04_0081__b204261690684140">Default value</strong>:</p>
<p id="obs_04_0081__p725011391106">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1557710455217"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p25779453214">Access-Control-Expose-Headers</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p75246132312">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p9251319145316"><strong id="obs_04_0081__b1885433036">Explanation</strong>:</p>
<p id="obs_04_0081__p025171935313"><strong id="obs_04_0081__b386794554102841">ExposeHeader</strong> in the CORS rules of the bucket. It specifies additional headers allowed in the response by a CORS rule. These headers provide extra information to clients. By default, a browser can access only headers <strong id="obs_04_0081__b1886814408272">Content-Length</strong> and <strong id="obs_04_0081__b14868184016276">Content-Type</strong>. If the browser needs to access other headers, you need to configure them as additional headers.</p>
<p id="obs_04_0081__p172511519155310"><strong id="obs_04_0081__b9251131935313">Restrictions</strong>:</p>
<p id="obs_04_0081__p525101965318">Spaces, asterisks (*), ampersands (&amp;), colons (:), less-than signs (&lt;), and full-width characters are not allowed.</p>
<p id="obs_04_0081__p122516194538"><strong id="obs_04_0081__b2020432728">Value range</strong>:</p>
<p id="obs_04_0081__p1525151915312">None</p>
<p id="obs_04_0081__p6251131913537"><strong id="obs_04_0081__b309913152">Default value</strong>:</p>
<p id="obs_04_0081__p1251519105320">None</p>
</td>
</tr>
<tr id="obs_04_0081__row7577545729"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p16577174520218">x-obs-server-side-encryption</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p369951412312">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p4290145665216"><strong id="obs_04_0081__b38748532483813">Explanation</strong>:</p>
<p id="obs_04_0081__p11577114514216">The encryption method used by the server.</p>
<p id="obs_04_0081__p18577154517215">Example: <strong id="obs_04_0081__b439538583">x-obs-server-side-encryption:kms</strong></p>
<p id="obs_04_0081__p1829015564522"><strong id="obs_04_0081__b1290165615521">Restrictions</strong>:</p>
<p id="obs_04_0081__p209960120917">This header is included in a response if SSE-KMS is used.</p>
<p id="obs_04_0081__p16394163711532"><strong id="obs_04_0081__b1379589809">Value range</strong>:</p>
<ul id="obs_04_0081__ul195426438531"><li id="obs_04_0081__li9542114345311">kms</li><li id="obs_04_0081__li1254254305312">AES256</li></ul>
<p id="obs_04_0081__p3394837155316"><strong id="obs_04_0081__b30481534">Default value</strong>:</p>
<p id="obs_04_0081__p1639453711538">None</p>
</td>
</tr>
<tr id="obs_04_0081__row1157713451726"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p1657714451028">x-obs-server-side-encryption-kms-key-id</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p48531215237">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p4206111913617"><strong id="obs_04_0081__b6551184010915">Explanation</strong>:</p>
<p id="obs_04_0081__p620610199614">ID of a specified key used for SSE-KMS encryption.</p>
<p id="obs_04_0081__p52072197616"><strong id="obs_04_0081__b446280404">Restrictions</strong>:</p>
<p id="obs_04_0081__p42073191666">This header can only be used when you specify <strong id="obs_04_0081__b4794109368">kms</strong> for the <strong id="obs_04_0081__b2794129762">x-obs-server-side-encryption</strong> header.</p>
<p id="obs_04_0081__p82079199611"><strong id="obs_04_0081__b1945944841">Default value</strong>:</p>
<p id="obs_04_0081__p12072197617">If you specify <strong id="obs_04_0081__b15257411365">kms</strong> for encryption but do not specify a key ID, the default master key will be used. If there is not a default master key, OBS will create one and use it.</p>
</td>
</tr>
<tr id="obs_04_0081__row557716459217"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p7577124518214">x-obs-server-side-encryption-customer-algorithm</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p1026814171435">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p16438162115315"><strong id="obs_04_0081__b80765428183813">Explanation</strong>:</p>
<p id="obs_04_0081__p357844513214">The algorithm used for encryption.</p>
<p id="obs_04_0081__p145781545124">Example: <strong id="obs_04_0081__b808077383">x-obs-server-side-encryption-customer-algorithm:AES256</strong></p>
<p id="obs_04_0081__p54381325539"><strong id="obs_04_0081__b743819245320">Restrictions</strong>:</p>
<p id="obs_04_0081__p113711353131">Only for SSE-C server-side encryption.</p>
<p id="obs_04_0081__p1012002317548"><strong id="obs_04_0081__b1912488742">Value range</strong>:</p>
<p id="obs_04_0081__p312012239544">AES256</p>
<p id="obs_04_0081__p312082311544"><strong id="obs_04_0081__b426837751">Default value</strong>:</p>
<p id="obs_04_0081__p11201236545">None</p>
</td>
</tr>
<tr id="obs_04_0081__row105781645522"><td class="cellrowborder" valign="top" width="25.009999999999998%" headers="mcps1.3.10.4.2.4.1.1 "><p id="obs_04_0081__p7578945423">x-obs-server-side-encryption-customer-key-MD5</p>
</td>
<td class="cellrowborder" valign="top" width="19.5%" headers="mcps1.3.10.4.2.4.1.2 "><p id="obs_04_0081__p46801184317">String</p>
</td>
<td class="cellrowborder" valign="top" width="55.489999999999995%" headers="mcps1.3.10.4.2.4.1.3 "><p id="obs_04_0081__p19214954533"><strong id="obs_04_0081__b211865116083813">Explanation</strong>:</p>
<p id="obs_04_0081__p85786451229">The MD5 value of the key used for encryption.</p>
<p id="obs_04_0081__p1057811452210">Example: <strong id="obs_04_0081__b1905461784">x-obs-server-side-encryption-customer-key-MD5:4XvB3tbNTN+tIEVa0/fGaQ==</strong></p>
<p id="obs_04_0081__p22143565314"><strong id="obs_04_0081__b621414575314">Restrictions</strong>:</p>
<p id="obs_04_0081__p636414335140">Only for SSE-C server-side encryption.</p>
<p id="obs_04_0081__p3868193113547"><strong id="obs_04_0081__b796796083">Value range</strong>:</p>
<p id="obs_04_0081__p1686873135411">MD5 value of the key.</p>
<p id="obs_04_0081__p1886833115411"><strong id="obs_04_0081__b827438015">Default value</strong>:</p>
<p id="obs_04_0081__p1486810311541">None</p>
</td>
</tr>
</tbody>
</table>
</div>
</div>
<div class="section" id="obs_04_0081__section35566529"><h4 class="sectiontitle">Response Elements</h4><p class="msonormal" id="obs_04_0081__p13778070">This response contains no elements.</p>
</div>
<div class="section" id="obs_04_0081__section51663312"><h4 class="sectiontitle">Error Responses</h4><p class="msonormal" id="obs_04_0081__p42281924">No special error responses are returned. For details about error responses, see <a href="obs_04_0115.html#obs_04_0115__d0e843">Table 2</a>.</p>
</div>
<div class="section" id="obs_04_0081__section14482163815396"><h4 class="sectiontitle">Sample Request: Uploading an Object Using POST</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen8484163863919"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span>
<span class="normal">13</span>
<span class="normal">14</span>
<span class="normal">15</span>
<span class="normal">16</span>
<span class="normal">17</span>
<span class="normal">18</span>
<span class="normal">19</span>
<span class="normal">20</span>
<span class="normal">21</span>
<span class="normal">22</span>
<span class="normal">23</span>
<span class="normal">24</span>
<span class="normal">25</span>
<span class="normal">26</span>
<span class="normal">27</span>
<span class="normal">28</span>
<span class="normal">29</span>
<span class="normal">30</span>
<span class="normal">31</span>
<span class="normal">32</span>
<span class="normal">33</span>
<span class="normal">34</span>
<span class="normal">35</span>
<span class="normal">36</span>
<span class="normal">37</span>
<span class="normal">38</span>
<span class="normal">39</span>
<span class="normal">40</span>
<span class="normal">41</span>
<span class="normal">42</span>
<span class="normal">43</span>
<span class="normal">44</span>
<span class="normal">45</span>
<span class="normal">46</span>
<span class="normal">47</span>
<span class="normal">48</span>
<span class="normal">49</span>
<span class="normal">50</span>
<span class="normal">51</span>
<span class="normal">52</span>
<span class="normal">53</span>
<span class="normal">54</span>
<span class="normal">55</span>
<span class="normal">56</span>
<span class="normal">57</span>
<span class="normal">58</span>
<span class="normal">59</span>
<span class="normal">60</span>
<span class="normal">61</span>
<span class="normal">62</span></pre></div></td><td class="code"><div><pre><span></span>POST<span class="w"> </span>/<span class="w"> </span>HTTP/1.1
Date:<span class="w"> </span>WED,<span class="w"> </span>01<span class="w"> </span>Jul<span class="w"> </span>2015<span class="w"> </span>04:15:23<span class="w"> </span>GMT
Host:<span class="w"> </span>examplebucket.obs.region.example.com
Content-Type:<span class="w"> </span>multipart/form-data;<span class="w"> </span>boundary=7db143f50da2
Content-Length:<span class="w"> </span>2424
Origin:<span class="w"> </span>www.example.com
Access-Control-Request-Headers:acc_header_1
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;key&quot;
object01
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;acl&quot;
public-read
--7db143f50da2<span class="w"> </span>
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;content-type&quot;
text/plain
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;expires&quot;
WED,<span class="w"> </span>01<span class="w"> </span>Jul<span class="w"> </span>2015<span class="w"> </span>04:16:15<span class="w"> </span>GMT
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;AccessKeyId&quot;
14RZT432N80TGDF2Y2G2
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;policy&quot;
ew0KICAiZXhaaXJhdGlvbiI6ICIyMDE1LTA3LTAxVDEyOjAwOjAwLjAwMFoiLA0KICAiY29uZGl0aW9ucyI6IFsNCiAgICB7ImJ1Y2tldCI6ICJleG1hcGxlYnVja2V0IiB9LA0KICAgIHsiYWNsIjogInB1YmxpYy1yZWFkIiB9LA0KICAgIHsiRXhaaXJlcyI6ICIxMDAwIiB9LA0KICAgIFsiZXEiLCAiJGtleSIsICJvYmplY3QwMSJdLA0KICAgIFsic3RhcnRzLXdpdGgiLCAiJENvbnRlbnQtVHlwZSIsICJ0ZXh0LyJdLA0KICBdDQp9DQo=
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;signature&quot;
Vk6rwO0Nq09BLhvNSIYwSJTRQ+k=
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-persistent-headers&quot;
<span class="w"> </span>
test:dmFsdWUx
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-grant-read&quot;
<span class="w"> </span>
id=52f24s3593as5730ea4f722483579xxx
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-server-side-encryption&quot;
<span class="w"> </span>
kms
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-website-redirect-location&quot;
<span class="w"> </span>
http://www.example.com/
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;file&quot;;<span class="w"> </span>filename=&quot;C:\Testtools\UpLoadFiles\object\1024Bytes.txt&quot;
Content-Type:<span class="w"> </span>text/plain
01234567890
--7db143f50da2
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;submit&quot;
Upload
--7db143f50da2--
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section76081155815"><h4 class="sectiontitle">Sample Response: Uploading an Object Using POST</h4><p id="obs_04_0081__p1672012407193">After CORS is configured for a bucket, the response contains the <strong id="obs_04_0081__b875111155611">Access-Control-*</strong> information.</p>
<div class="codecoloring" codetype="Xml" id="obs_04_0081__screen8485113814"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span></pre></div></td><td class="code"><div><pre><span></span>HTTP/1.1<span class="w"> </span>204<span class="w"> </span>No<span class="w"> </span>Content
x-obs-request-id:<span class="w"> </span>90E2BA00C26C00000133B442A90063FD
x-obs-id-2:<span class="w"> </span>OTBFMkJBMDBDMjZDMDAwMDAxMzNCNDQyQTkwMDYzRkRBQUFBQUFBQWJiYmJiYmJi
Access-Control-Allow-Origin:<span class="w"> </span>www.example.com
Access-Control-Allow-Methods:<span class="w"> </span>POST,GET,HEAD,PUT
Access-Control-Allow-Headers:<span class="w"> </span>acc_header_01
Access-Control-Max-Age:<span class="w"> </span>100
Access-Control-Expose-Headers:<span class="w"> </span>exp_header_01
Content-Type:<span class="w"> </span>text/xml
Location:<span class="w"> </span>http://examplebucket.obs.region.example.com/object01
Date:<span class="w"> </span>WED,<span class="w"> </span>01<span class="w"> </span>Jul<span class="w"> </span>2015<span class="w"> </span>04:15:23<span class="w"> </span>GMT
ETag:<span class="w"> </span>&quot;ab7abb0da4bca5323ab6119bb5dcd296&quot;
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section392181218378"><h4 class="sectiontitle">Sample Request: Uploading an Object (with <strong id="obs_04_0081__b862018125216">x-obs-acl</strong> and a Storage Class Specified)</h4><p id="obs_04_0081__p10361460163"><strong id="obs_04_0081__b12283193111717">Upload an object with the </strong><strong id="obs_04_0081__b1268922113589">x-obs-acl</strong><strong id="obs_04_0081__b1328414314174">, storage class, and redirection header fields carried in the request message.</strong></p>
<p id="obs_04_0081__p17861838134017">Before encoding, the policy content is as follows:</p>
<div class="codecoloring" codetype="Xml" id="obs_04_0081__screen2041324410401"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span>
<span class="normal">13</span>
<span class="normal">14</span>
<span class="normal">15</span>
<span class="normal">16</span>
<span class="normal">17</span>
<span class="normal">18</span>
<span class="normal">19</span>
<span class="normal">20</span>
<span class="normal">21</span>
<span class="normal">22</span>
<span class="normal">23</span>
<span class="normal">24</span>
<span class="normal">25</span>
<span class="normal">26</span>
<span class="normal">27</span></pre></div></td><td class="code"><div><pre><span></span>{
<span class="w"> </span>&quot;expiration&quot;:&quot;2018-07-17T04:54:35Z&quot;,
<span class="w"> </span>&quot;conditions&quot;:[
<span class="w"> </span>{
<span class="w"> </span>&quot;content-type&quot;:&quot;text/plain&quot;
<span class="w"> </span>},
<span class="w"> </span>{
<span class="w"> </span>&quot;x-obs-storage-class&quot;:&quot;WARM&quot;
<span class="w"> </span>},
<span class="w"> </span>{
<span class="w"> </span>&quot;success_action_redirect&quot;:&quot;http://www.example.com&quot;
<span class="w"> </span>},
<span class="w"> </span>{
<span class="w"> </span>&quot;x-obs-acl&quot;:&quot;public-read&quot;
<span class="w"> </span>},
<span class="w"> </span>[
<span class="w"> </span>&quot;starts-with&quot;,
<span class="w"> </span>&quot;$bucket&quot;,
<span class="w"> </span>&quot;&quot;
<span class="w"> </span>],
<span class="w"> </span>[
<span class="w"> </span>&quot;starts-with&quot;,
<span class="w"> </span>&quot;$key&quot;,
<span class="w"> </span>&quot;&quot;
<span class="w"> </span>]
<span class="w"> </span>]
}
</pre></div></td></tr></table></div>
</div>
<p id="obs_04_0081__p227118101816">Sample request:</p>
<div class="codecoloring" codetype="Xml" id="obs_04_0081__screen1792131223715"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span>
<span class="normal">13</span>
<span class="normal">14</span>
<span class="normal">15</span>
<span class="normal">16</span>
<span class="normal">17</span>
<span class="normal">18</span>
<span class="normal">19</span>
<span class="normal">20</span>
<span class="normal">21</span>
<span class="normal">22</span>
<span class="normal">23</span>
<span class="normal">24</span>
<span class="normal">25</span>
<span class="normal">26</span>
<span class="normal">27</span>
<span class="normal">28</span>
<span class="normal">29</span>
<span class="normal">30</span>
<span class="normal">31</span>
<span class="normal">32</span>
<span class="normal">33</span>
<span class="normal">34</span>
<span class="normal">35</span>
<span class="normal">36</span>
<span class="normal">37</span>
<span class="normal">38</span>
<span class="normal">39</span></pre></div></td><td class="code"><div><pre><span></span>POST<span class="w"> </span>/<span class="w"> </span>HTTP/1.1
Host:<span class="w"> </span>examplebucket.obs.region.example.com
Accept-Encoding:<span class="w"> </span>identity
Content-Length:<span class="w"> </span>947
Content-Type:<span class="w"> </span>multipart/form-data;<span class="w"> </span>boundary=9431149156168
User-Agent:<span class="w"> </span>OBS/Test
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;x-obs-acl&quot;
public-read
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;AccessKeyId&quot;
H4IPJX0TQTHTHEBQQCEC
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;key&quot;
my-obs-object-key-demo
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;signature&quot;
WNwv8P1ZiWdqPQqjXeLmAfzPDAI=
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;policy&quot;
eyJleHBpcmF0aW9uIjoiMjAxOC0wNy0xN1QwODozNDoyM1oiLCAiY29uZGl0aW9ucyI6W3siY29udGVudC10eXBlIjoidGV4dC9wbGFpbiJ9LHsieC1vYnMtYWNsIjoicHVibGljLXJlYWQifSxbInN0YXJ0cy13aXRoIiwgIiRidWNrZXQiLCAiIl0sWyJzdGFydHMtd2l0aCIsICIka2V5IiwgIiJdXX0=
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;content-type&quot;
text/plain
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;file&quot;;<span class="w"> </span>filename=&quot;myfile&quot;
Content-Type:<span class="w"> </span>text/plain
c2c6cd0f-898e-11e8-aab6-e567c91fb541
52b8e8a0-8481-4696-96f3-910635215a78
--9431149156168--
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section1999141253715"><h4 class="sectiontitle">Sample Response: Uploading an Object (with <strong id="obs_04_0081__b1353410111491">x-obs-acl</strong> and a Storage Class Specified)</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen1013151314377"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
<span class="normal">2</span>
<span class="normal">3</span>
<span class="normal">4</span>
<span class="normal">5</span>
<span class="normal">6</span>
<span class="normal">7</span></pre></div></td><td class="code"><div><pre><span></span>HTTP/1.1<span class="w"> </span>204<span class="w"> </span>No<span class="w"> </span>Content
Server:<span class="w"> </span>OBS
Location:<span class="w"> </span>http://examplebucket.obs.region.example.com/my-obs-object-key-demo
ETag:<span class="w"> </span>&quot;17a83fc8d431273405bd266114b7e034&quot;
x-obs-request-id:<span class="w"> </span>5DEB00000164A728A7C7F4E032214CFA
x-obs-id-2:<span class="w"> </span>32AAAUJAIAABAAAQAAEAABAAAQAAEAABCSwj2PcBE0YcoLHUDO7GSj+rVByzjflA
Date:<span class="w"> </span>Tue,<span class="w"> </span>17<span class="w"> </span>Jul<span class="w"> </span>2018<span class="w"> </span>07:33:36<span class="w"> </span>GMT
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section430011014337"><h4 class="sectiontitle">Sample Request: Using a Token for Authentication</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen312815284210"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal"> 1</span>
<span class="normal"> 2</span>
<span class="normal"> 3</span>
<span class="normal"> 4</span>
<span class="normal"> 5</span>
<span class="normal"> 6</span>
<span class="normal"> 7</span>
<span class="normal"> 8</span>
<span class="normal"> 9</span>
<span class="normal">10</span>
<span class="normal">11</span>
<span class="normal">12</span>
<span class="normal">13</span>
<span class="normal">14</span>
<span class="normal">15</span>
<span class="normal">16</span>
<span class="normal">17</span>
<span class="normal">18</span>
<span class="normal">19</span>
<span class="normal">20</span>
<span class="normal">21</span></pre></div></td><td class="code"><div><pre><span></span>POST<span class="w"> </span>/<span class="w"> </span>HTTP/1.1
Content-Type:multipart/form-data;<span class="w"> </span>boundary=9431149156168
Content-Length:<span class="w"> </span>634
Host:<span class="w"> </span>examplebucket.obs.region.example.com
<span class="w"> </span>
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;key&quot;
obj01
<span class="w"> </span>
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;token&quot;
UDSIAMSTUBTEST002538:XsVcTzR2/A284oE4VH9qPndGcuE=:eyJjb25kaXRpb25zIjogW3siYnVja2V0IjogInRlc3QzMDAzMDU4NzE2NjI2ODkzNjcuMTIifSwgeyJDb250ZW50LVR5cGUiOiAiYXBwbGljYXRpb24veG1sIn0sIFsiZXEiLCAiJGtleSIsICJvYmoudHh0Il1dLCAiZXhwaXJhdGlvbiI6ICIyMDIyLTA5LTA5VDEyOjA5OjI3WiJ9
<span class="w"> </span>
--9431149156168
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;file&quot;;<span class="w"> </span>filename=&quot;myfile&quot;
Content-Type:<span class="w"> </span>text/plain
01234567890
<span class="w"> </span>
--9431149156168--
Content-Disposition:<span class="w"> </span>form-data;<span class="w"> </span>name=&quot;submit&quot;
Upload<span class="w"> </span>to<span class="w"> </span>OBS
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section47211218103213"><h4 class="sectiontitle">Sample Response: Using a Token for Authentication</h4><div class="codecoloring" codetype="Xml" id="obs_04_0081__screen13186124813488"><div class="highlight"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre><span class="normal">1</span>
<span class="normal">2</span>
<span class="normal">3</span>
<span class="normal">4</span>
<span class="normal">5</span>
<span class="normal">6</span>
<span class="normal">7</span></pre></div></td><td class="code"><div><pre><span></span>HTTP/1.1<span class="w"> </span>204<span class="w"> </span>No<span class="w"> </span>Content
Server:<span class="w"> </span>OBS
Location:<span class="w"> </span>http://examplebucket.obs.region.example.com/my-obs-object-key-demo
ETag:<span class="w"> </span>&quot;7eda50a430fed940023acb9c4c6a2fff&quot;
x-obs-request-id:<span class="w"> </span>000001832010443D80F30B649B969C47
x-obs-id-2:<span class="w"> </span>32AAAUgAIAABAAAQAAEAABAAAQAAEAABCTj0yO9KJd5In+i9pzTgCDVG9vMnk7O/
Date:<span class="w"> </span>Fri,09Sep<span class="w"> </span>2022<span class="w"> </span>02:<span class="w"> </span>24:40<span class="w"> </span>GMT
</pre></div></td></tr></table></div>
</div>
</div>
<div class="section" id="obs_04_0081__section29219401538"><h4 class="sectiontitle">Sample Request: Specifying an Object Expiration Time</h4><pre class="screen" id="obs_04_0081__screen4136194018535">POST / HTTP/1.1
Date: WED, 01 Jul 2015 04:15:23 GMT
Host: examplebucket.obs.<em id="obs_04_0081__i17150161818212">region</em>.example.com
Content-Type: multipart/form-data; boundary=148828969260233905620870
Content-Length: 1639
Origin: www.example.com
Access-Control-Request-Headers:acc_header_1
--148828969260233905620870
Content-Disposition: form-data; name="key"
object01
--148828969260233905620870
Content-Disposition: form-data; name="ObsAccessKeyId"
55445349414d5354554254455354303030303033
--148828969260233905620870
Content-Disposition: form-data; name="signature"
396246666f6f42793872792f7a3958524f6c44334e4e69763950553d--7db143f50da2
--148828969260233905620870
Content-Disposition: form-data; name="policy"
65794a6c65484270636d463061573975496a6f694d6a41794d7930774e6930784e565178...
--148828969260233905620870
Content-Disposition: form-data; name="x-obs-expires"
4
--148828969260233905620870
Content-Disposition: form-data; name="file"; filename="test.txt"
Content-Type: text/plain
01234567890
--148828969260233905620870
Content-Disposition: form-data; name="submit"
Upload
--148828969260233905620870--</pre>
</div>
<div class="section" id="obs_04_0081__section179615402535"><h4 class="sectiontitle">Sample Response: Specifying an Object Expiration Time</h4><pre class="screen" id="obs_04_0081__screen513634017536">
HTTP/1.1 204 No Content
Server: OBS
Date: Thu, 15 Jun 2023 12:39:03 GMT
Connection: keep-alive
Location: http://examplebucket.obs.<em id="obs_04_0081__i563154218215">region</em>.example.com/my-obs-object-key-demo
x-obs-expiration: expiry-date="Tue, 20 Jun 2023 00:00:00 GMT"
ETag: "d41d8cd98f00b204e9800998ecf8427e"
x-obs-request-id: 00000188BF11049553064911000FC30D
x-obs-id-2: 32AAAUJAIAABAAAQAAEAABAAAQAAEAABCSwj2PcBE0YcoLHUDO7GSj+rVByzjflA
x-forward-status: 0x40020000000001
x-dae-api-type: REST.POST.OBJECT</pre>
</div>
<div class="section" id="obs_04_0081__section199604065313"><h4 class="sectiontitle">Sample Request: Specifying a Status Code</h4><p id="obs_04_0081__p1613734065313"><strong id="obs_04_0081__b11893418183818">Set the status code of a successful action to 200.</strong></p>
<pre class="screen" id="obs_04_0081__screen1113774010531">POST /srcbucket HTTP/1.1
User-Agent: PostmanRuntime/7.26.8
Accept: */*
Postman-Token: 667dcc44-1c48-41ba-9e41-9f87d8975089
Host: obs.<em id="obs_04_0081__i168241151529">region</em>.example.com
Accept-Encoding: gzip, deflate, br
Connection: keep-alive
Content-Type: multipart/form-data; boundary=--------------------------285613759795901770404350
Content-Length: 1134
----------------------------285613759795901770404350
Content-Disposition: form-data; name="key"
obj
----------------------------285613759795901770404350
Content-Disposition: form-data; name="ObsAccessKeyId"
XXXXXXXXXXXXXXX000003
----------------------------285613759795901770404350
Content-Disposition: form-data; name="signature"
9rc4bVhDPQ7eHtw17hWtYxLnBWU=
----------------------------285613759795901770404350
Content-Disposition: form-data; name="policy"
eyJleHBpcmF0aW9uIjoiMjAyMy0wNi0xNVQxNDoxMTozNFoiLCAiY29uZGl0aW9ucyI6W3siYnVja2V0Ijoic3JjYnVja2V0MiJ9LHsic3VjY2Vzc19hY3Rpb25fc3RhdHVzIjoiMjAwIn0seyJjb250ZW50LXR5cGUiOiJ0ZXh0L3BsYWluIn0seyJrZXkiOiIzMzMifSxdfQ==
----------------------------285613759795901770404350
Content-Disposition: form-data; name="success_action_status"
200
----------------------------285613759795901770404350
Content-Disposition: form-data; name="file"; filename="test.txt"
Content-Type: text/plain
----------------------------285613759795901770404350
Content-Disposition: form-data; name="submit"
Upload to OBS
----------------------------285613759795901770404350--</pre>
</div>
<div class="section" id="obs_04_0081__section299114025312"><h4 class="sectiontitle">Sample Response: Specifying a Status Code</h4><p id="obs_04_0081__p73286258157"><strong id="obs_04_0081__b7594221193613">Response to the configuration of success status code 200</strong></p>
<pre class="screen" id="obs_04_0081__screen17137174011533">HTTP/1.1 200 OK
Server: OBS
Date: Thu, 15 Jun 2023 13:12:51 GMT
Content-Length: 0
Connection: keep-alive
Location: http://obs.<em id="obs_04_0081__i573845820211">region</em>.example.com/srcbucket/obj
ETag: "d41d8cd98f00b204e9800998ecf8427e"
x-obs-request-id: 00000188BF2FF55F5306426E000FE366
x-obs-id-2: 32AAAUJAIAABAAAQAAEAABAAAQAAEAABCScDjcXgZ7oMYSVnZnk4+HrClVwLVPTi
x-forward-status: 0x40020000000001
x-dae-api-type: REST.POST.OBJECT</pre>
</div>
<div class="section" id="obs_04_0081__section1299154075311"><h4 class="sectiontitle">Sample Request: Uploading an Object (with a WORM Retention Policy Configured)</h4><pre class="screen" id="obs_04_0081__screen16138124035319">POST /srcbucket HTTP/1.1
User-Agent: PostmanRuntime/7.26.8
Accept: */*
Postman-Token: 4c2f4c7e-2e0b-46c0-b1a7-4a5da560b6a1
Host: obs.<em id="obs_04_0081__i76414712313">region</em>.example.com
Accept-Encoding: gzip, deflate, br
Connection: keep-alive
Content-Type: multipart/form-data; boundary=--------------------------940435396775653808840608
Content-Length: 1409
----------------------------940435396775653808840608
Content-Disposition: form-data; name="key"
obj
----------------------------940435396775653808840608
Content-Disposition: form-data; name="ObsAccessKeyId"
XXXXXXXXXXXXXXX000003
----------------------------940435396775653808840608
Content-Disposition: form-data; name="signature"
X/7QiyMYUvxUWk0R5fToeTcgMMU=
----------------------------940435396775653808840608
Content-Disposition: form-data; name="policy"
eyJleHBpcmF0aW9uIjoiMjAyMy0wNi0xNVQxNDoyMjo1MVoiLCAiY29uZGl0aW9ucyI6W3sieC1vYnMtb2JqZWN0LWxvY2stcmV0YWluLXVudGlsLWRhdGUiOiJUaHUsIDIwIEp1biAyMDIzIDEzOjEyOjUxIEdNVCJ9LHsieC1vYnMtb2JqZWN0LWxvY2stbW9kZSI6IkNPTVBMSUFOQ0UifSx7ImJ1Y2tldCI6InNyY2J1Y2tldDIifSx7ImNvbnRlbnQtdHlwZSI6InRleHQvcGxhaW4ifSx7ImtleSI6IjMzMyJ9LF19
----------------------------940435396775653808840608
Content-Disposition: form-data; name="x-obs-object-lock-mode"
COMPLIANCE
----------------------------940435396775653808840608
Content-Disposition: form-data; name="x-obs-object-lock-retain-until-date"
Thu, 20 Jun 2023 13:12:51 GMT
----------------------------940435396775653808840608
Content-Disposition: form-data; name="file"; filename="test.txt"
Content-Type: text/plain
----------------------------940435396775653808840608
Content-Disposition: form-data; name="submit"
Upload to OBS
----------------------------940435396775653808840608--</pre>
</div>
<div class="section" id="obs_04_0081__section1102140135316"><h4 class="sectiontitle">Sample Response: Uploading an Object (with a WORM Retention Policy Configured)</h4><pre class="screen" id="obs_04_0081__screen61382040125315">HTTP/1.1 204 No Content
Server: OBS
Date: Thu, 15 Jun 2023 13:24:03 GMT
Connection: keep-alive
Location: http://obs.<em id="obs_04_0081__i9158196173911">region</em>.example.com/srcbucket/obj
ETag: "d41d8cd98f00b204e9800998ecf8427e"
x-obs-request-id: 00000188BF3A36EE5306427D000FEE0A
x-obs-id-2: 32AAAUJAIAABAAAQAAEAABAAAQAAEAABCS/5pj0p0hAQcDVI3B6E5y167zy4eAQv
x-forward-status: 0x40020000000001
x-dae-api-type: REST.POST.OBJECT</pre>
</div>
</div>
<div>
<div class="familylinks">
<div class="parentlink"><strong>Parent topic:</strong> <a href="obs_04_0079.html">Operations on Objects</a></div>
</div>
</div>