Queries the download URL of a file. For more information about best practices, visit https://help.aliyun.com/document_detail/175889.html.
Debugging
Authorization information
Request syntax
POST /v2/file/get_download_url HTTP/1.1
Request parameters
Parameter | Type | Required | Description | Example |
---|---|---|---|---|
body | object | No | The request parameters. | |
share_id | string | No | The share ID. If you want to manage a file by using a sharing link, carry the | |
drive_id | string | No | The drive ID. | 1 |
file_id | string | Yes | The file ID. | 9520943DC264 |
file_name | string | No | The name of the file. The name can be up to 1,024 characters in length. | 1.txt |
expire_sec | integer | No | The validity period of the download URL. Maximum value: 115200. Default value: 900. Unit: seconds. | 100 |
Response parameters
Examples
Sample success responses
JSON
format
{
"url": "https://data.aliyunpds.com/hz22%2F5d79219b0aa9a7c995a94a96993ba3205cd91c5a%2F5d79219bf3261a5d38744da0834ed489b677a27a?Expires=xxxOSSAccessKeyId=xxx&Signature=xxx&response-content-disposition=attachment%3Bfilename%3DtBiZAoJPC2c8b13450eda4292b7f5f8010618e078.txt",
"internal_url": "https://data-vpc.aliyunpds.com/hz22%2F5d79219b0aa9a7c995a94a96993ba3205cd91c5a%2F5d79219bf3261a5d38744da0834ed489b677a27a?Expires=xxxOSSAccessKeyId=xxx&Signature=xxx&response-content-disposition=attachment%3Bfilename%3DtBiZAoJPC2c8b13450eda4292b7f5f8010618e078.txt",
"cdn_url": "https://data-cdn.aliyunpds.com/hz22%2F5d79219b0aa9a7c995a94a96993ba3205cd91c5a%2F5d79219bf3261a5d38744da0834ed489b677a27a?Expires=xxxOSSAccessKeyId=xxx&Signature=xxx&response-content-disposition=attachment%3Bfilename%3DtBiZAoJPC2c8b13450eda4292b7f5f8010618e078.txt",
"expiration": "2022-01-02T15:04:05.999Z07:00",
"size": 10,
"crc64_hash": "5498595269368962671",
"content_hash": "EA4942AA8761213890A5C386F88E6464D2C31CA1",
"content_hash_name": "sha1"
}
Error codes
For a list of error codes, visit the Service error codes.