Skip to main content

Welcome to Agent Office API

Agent Office API allows you to programmatically edit Microsoft Word and PDF documents using AI. Upload documents, apply edits via natural language instructions, and download the modified files.

Base URL

All API requests should be made to:

Authentication

All API endpoints require authentication using a Bearer token. You can generate API keys from your Agent Office Dashboard.
Keep your API keys secure and never share them publicly. API keys should be stored as environment variables.

Using Your API Key

Include your API key in the Authorization header of every request:

Example Authentication

Request Latency

Most document edits complete in under 5 seconds. Response times vary based on document complexity and edit instructions.
Pro and Enterprise users benefit from dedicated infrastructure with faster request processing and priority queue handling for optimal performance.
You can monitor your request performance under usage.

Error Handling

The API uses standard HTTP status codes:

API Workflow

  1. Upload Document - Upload a Word (.docx) or PDF file to create a document
  2. Apply Edits - Send natural language instructions to edit the document
  3. Download Result - Get a presigned URL to download the edited document
Documents are automatically stored for 1 hour (configurable) and the TTL is refreshed after each edit.

Supported File Types

  • Microsoft Word (.docx)
  • PDF (.pdf)
  • Maximum file size: 10MB

Getting Started

Ready to start? Check out our endpoint documentation:

Upload Document

Upload a Word or PDF document

Edit Document

Apply AI-powered edits to your document

Download Document

Get a presigned URL to download your document

Read as Markdown

Extract document content as markdown