Create local upload
create_local_uploadAuthorize a short-lived upload of the user's selected local MP3 only when the current environment can both read that file and send an outbound HTTPS PUT, such as Codex Desktop or CLI. Reading a ChatGPT attachment in a code sandbox does not establish outbound network access; prefer prepare_karaoke with native file parameters in ChatGPT. Supply the filename, exact byte size and SHA256, then stream that file with the returned PUT URL and purpose-bound headers. Ticket issuance does not mean audio was received. No OAuth credentials are needed or exposed. The completed PUT creates a free Quick draft; read it with get_karaoke, then confirm its price before starting. After a timeout or lost upload response, always call get_karaoke with the ticket's project_id before declaring failure, renewing a ticket or creating another project. If an awaiting_start draft exists, resume its current quote. An immediate not_found may precede an in-flight upload commit; briefly wait and recheck that same ID once. If still unconfirmed, report unconfirmed receipt, not server unavailability inferred from a timeout. Keep the same file and key; do not repeatedly renew tickets after an environment network denial. Does not start processing or charge funds.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"filename": "<filename>",
"byte_size": "<byte_size>",
"sha256": "<sha256>",
"idempotency_key": "<idempotency_key>"
},
"name": "create_local_upload"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| title | No | ||
| artist | No | ||
| sha256 | Yes | ||
| filename | Yes | ||
| language | No | auto | |
| byte_size | Yes | ||
| idempotency_key | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file | No | ||
| error | No | ||
| method | No | ||
| headers | No | ||
| max_bytes | No | ||
| expires_at | No | ||
| project_id | No | ||
| upload_url | No |