Skip to documentation
Omni Developers

Give your agent knowledge

Encrypt a local file, upload it, and wait for it to be ready for citation.

View the TypeScript upload example.

Encrypt locally and reserve

Generate a fresh 32-byte FEK and encrypt the source bytes with omni-file-v1. Reserve with POST /v1/files/uploads, including the logical filename, MIME type, plaintext and expected ciphertext sizes, encryption metadata, and vault_workspace_id.

Use a unique Idempotency-Key. Save data.file.file_id and the returned data.upload capability.

Upload exactly as directed

PUT the ciphertext to data.upload.url using its returned method and required_headers. The URL is a short-lived secret: use it directly and do not log it.

Complete

Call POST /v1/files/{file_id}/complete with another stable idempotency key. Completion verifies the upload exists and matches the expected size.

Wait for Vault

Poll GET /v1/workspaces/{workspace_id}/vault/files/{file_id} until data.file.status is ready. Stop and surface an error if it becomes failed or the polling deadline expires.

A confirmed upload is stored; a ready file can be attached to a task.

Continue to Ask with a file.