上传 Project 文件
上传用于直接调用或预设调用的 Project 草稿文件,无需 Agent。
POST
/projects/{projectId}/files上传用于直接调用或预设调用的 Project 草稿文件,无需 Agent。
Authorization
publicApiBearer AuthorizationBearer <token>
使用 Authorization: Bearer msp_...。Project API key 只能配置、执行和访问本 Project 的 Agent、Session 和文件。密钥和账号管理需要 console 或 CLI 登录。旧账号 token 已被拒绝。
In: header
Path Parameters
projectId*string
自己拥有的 Project。Project key 只能访问其绑定的 Project;CLI 登录须显式指定自己拥有的 Project。
Match
^[0-7][0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{25}$Format
ulidRequest Body
multipart/form-data
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X POST "https://example.com/projects/01ARZ3NDEKTSV4RRFFQ69G5FAV/files" \ -F file="string"{ "file": { "createdAt": "2019-08-24T14:15:22Z", "id": "01ARZ3NDEKTSV4RRFFQ69G5FAV", "mimeType": "string", "name": "string", "size": 0 }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}{ "error": { "code": "agent_not_published", "message": "string" }}