Skip to main content
POST
/
api
/
v1
/
common
/
download-url
Get Download URL for Generated Files
curl --request POST \
  --url https://api.kie.ai/api/v1/common/download-url \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "url": "https://tempfile.1f6cxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxbd98"
}'
{
  "code": 200,
  "msg": "success",
  "data": "https://tempfile.1f6cxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxbd98"
}
Convert generated file URLs to downloadable temporary URLs. Only supports files generated by kie.ai services.

Features

  • Convert kie.ai generated file URLs to downloadable links
  • Supports all file types generated by kie.ai platform (images, videos, audio, etc.)
  • Temporary download URLs valid for 20 minutes
  • Secure access to generated content
  • API Key authentication protection

Important Notes

Only generated file URLs from kie.ai services are supported. External file URLs will result in a 422 validation error.
The downloadable URLs expire after 20 minutes. Make sure to download or cache the content within this timeframe.

Authorizations

Authorization
string
header
required

All APIs require authentication via Bearer Token.

Get API Key:

  1. Visit API Key Management Page to get your API Key

Usage: Add to request header: Authorization: Bearer YOUR_API_KEY

Body

application/json
url
string<uri>
required

Generated file URL from kie.ai services. External file URLs are not supported.

Example:

"https://tempfile.1f6cxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxbd98"

Response

Request successful

code
enum<integer>

Response Status Code

CodeDescription
200Success - Request has been processed successfully
401Unauthorized - Authentication credentials are missing or invalid
402Insufficient Credits - Account does not have enough credits to perform the operation
404Not Found - The requested resource or endpoint does not exist
422Validation Error - Invalid URL (External file URLs are not supported)
429Rate Limited - Request limit has been exceeded for this resource
455Service Unavailable - System is currently undergoing maintenance
500Server Error - An unexpected error occurred while processing the request
505Feature Disabled - The requested feature is currently disabled
Available options:
200,
401,
402,
404,
422,
429,
455,
500,
505
msg
string

Error message when code != 200

Example:

"success"

data
string<uri>

Downloadable URL for the file. Valid for 20 minutes.

Example:

"https://tempfile.1f6cxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxbd98"