curl --request GET \
--url https://api.moonshot.cn/v1/files/{file_id}/content \
--header 'Authorization: Bearer <token>'"<string>"获取以 file-extract 用途上传的文件的提取文本内容。
curl --request GET \
--url https://api.moonshot.cn/v1/files/{file_id}/content \
--header 'Authorization: Bearer <token>'"<string>"Documentation Index
Fetch the complete documentation index at: https://platform.kimi.com/docs/llms.txt
Use this file to discover all available pages before exploring further.
调用示例
# 注意,之前 retrieve_content api 在最新版本标记了 warning, 可以用下面这行代替
# 如果是旧版本,可以用 retrieve_content
file_content = client.files.content(file_id=file_object.id).text
curl https://api.moonshot.cn/v1/files/{file_id}/content \
-H "Authorization: Bearer $MOONSHOT_API_KEY"
此页面对您有帮助吗?