Modify File Storage Type
Last updated on: 2024-08-12 15:47:43
describe
This interface is used to modify the storage type information of files, and can realize the conversion between standard storage, low-frequency access storage, archive direct read storage, archive storage and deep archive storage.
Low frequency access storage, archive direct read storage, archive storage, and deep archive storage have the minimum storage time requirements. When changing to other storage types, metering and billing may be deleted in advance. See for details Measurement and billing items explain
request
Request Syntax
instructions:
- Archive/deep archive stores files. The storage type can only be modified when the file is unfrozen.
Request Parameters
Parameter name |
Required |
explain |
EncodedEntryURI |
yes |
Specify file information, please refer to EncodedEntryURI |
type |
yes |
The value is a number, 0 represents standard storage, 1 represents low-frequency access storage, 2 represents archive storage, 3 represents deep archive storage, 4 represents archive direct read storage, and 5 represents intelligent tiered storage |
Request Header
Header name |
Required |
explain |
Authorization |
yes |
This parameter should be strictly in accordance with Management Certificates The format is filled in, otherwise the 401 error code will be returned A valid Authorization value should be similar to: Qiniu QNJi_bYJlmO5LeY08FfoNj9w_r7... |
other |
|
Please refer to Public request header |
Request Content
The request body of the request operation is empty.
response
Response syntax
Response Header
Header name |
Required |
explain |
Content-Type |
yes |
Normally this value will be set to application/json , indicating that text information in JSON format is returned. |
other |
|
For other possible returned header information, please refer to Public response header 。 |
Response content
If the request is successful, nothing is returned.
If the request fails, a JSON string containing the following contents is returned (formatted for easy reading):
Field Name |
Required |
explain |
error |
yes |
Message text corresponding to HTTP status code |
Response status code
HTTP status code |
meaning |
two hundred |
Change succeeded |
four hundred |
Request message format error When <EncodedEntryURI> Parsing failed, return 400 Bad Request {"error":"invalid argument"} When <EncodedEntryURI> Not conforming to UTF-8 code, returned 400 Bad Request {"error":"key must be utf8 encoding"} When the file type has been converted to normal storage, it will return 400 Bad Request {"error":"already in normal stat"} When the file type is already low-frequency storage and is still converted to low-frequency storage, it will return 400 Bad Request {"error":"already in line stat"} When the file type is archived direct read storage and still converted to archive system storage, it will return 400 Bad Request {"error":"already in archive_ir stat"} When the file type is already archive storage and is still converted to archive storage, it will return 400 Bad Request {"error":"already in archive stat"} When the file type is deep archive storage, it will return 400 Bad Request {"error":"already in deep archive stat"} |
four hundred and one |
Invalid management voucher |
four hundred and three |
Operation prohibited When the archive storage file is not unfrozen completely, the calling interface will return 403 ArchiveUnrestored {"error":"archive unrestored"} When the deep archive storage file is not unfrozen completely, the calling interface will return 403 DeepArchiveUnrestored {"error":"deep archive unrestored"} |
six hundred and twelve |
The target file does not exist |
Other error codes |
Please refer to Error response |
In case of 599 error, please send the complete error information (including all HTTP response headers) Submit work order Give us.
Example
Request Example
Note: Authorization
Cephalic <AccessToken>
Add before Qiniu
And half space.
Response example