Manage script and dictionary file uploads. Requires uploads:write scope.
Uploads use a three-step presigned URL flow: the CLI creates an upload record, PUTs the file bytes directly to S3 via the presigned URL, then you confirm the upload to finalize it.
Audio file uploads use a separate endpoint that is not accessible via API key. This command handles script (.txt, .docx) and dictionary (.csv) files only.
Three steps executed by this command:
POST /api/v1/uploads with {filename, category} → server returns {upload: {id, ...}, upload_url}.PUT <upload_url> with the file bytes directly to S3 — the presigned URL is used, not the OnePin API.upload_id. The upload is not yet confirmed — run onepin uploads confirm to finalize.Extension is validated server-side. Mismatches return a 422 error.
Finalizes an upload by binding it to a workflow. Calls POST /api/v1/uploads/{upload_id} with {context_type: "workflow", context_id: <workflow_id>}.
The server verifies the staged file in S3, consumes storage quota, and transitions the upload to confirmed status. Run this after create.
Deletes an upload record and removes the associated file from S3. Releases storage quota.