canonical: https://jentic.com/apis/chatpdf.com/chatpdf

# ChatPDF API

Jentic publishes the only available OpenAPI specification for ChatPDF API, keeping it validated and agent-ready. ChatPDF lets applications upload a PDF and ask natural-language questions about its content. The API exposes four endpoints to register a PDF source from a URL or a direct file upload, delete sources when no longer needed, and send chat messages that are answered against the document. It is designed for teams building research, support, or compliance tools that need answers grounded in a specific document rather than the open web.

## For AI agents

Upload a PDF and ask questions about its content with citations across 4 endpoints.

## Scope

Does not handle PDF generation, OCR of scanned-only PDFs, or general LLM chat - use for grounded question-answering against uploaded PDF sources only.

## Capabilities

- Register a PDF as a chat source by submitting its public URL
- Upload a PDF file directly to ChatPDF and receive a source identifier for chat
- Send a natural-language question about a PDF and receive a grounded answer
- Request page references with answers for citation-aware document Q&A
- Delete one or more PDF sources to manage storage and retention

## Use cases

### Document Q&A for Customer Support

Let a support agent or end user ask plain-English questions against a product manual, terms-of-service PDF, or knowledge-base export. The integration uploads the PDF once via POST `/v1/sources/add-url` or `/v1/sources/add-file` and then routes user questions to POST `/v1/chats/message`, returning answers grounded in the document with optional page references. This avoids fine-tuning a model on the corpus and keeps answers traceable.

Example prompt: Add the PDF at https://example.com/manual.pdf as a source, then ask 'How do I reset the device?' and return the answer with the cited page numbers.

### Contract and Compliance Review

Upload a contract or policy document and run targeted questions to surface obligations, dates, and clause locations. ChatPDF's chat endpoint accepts free-form questions and returns the answer plus references to the pages it relied on, so a reviewer can verify the source. Useful in legal, procurement, and compliance workflows where citations are mandatory.

Example prompt: Upload a vendor contract PDF, then ask 'What is the notice period for termination?' and 'What are the data residency commitments?' and return both answers with page citations.

### Research Paper Summarisation

Ingest a research paper or whitepaper and ask the API to summarise sections, list cited works, or compare claims across documents. Each PDF is added as a source with a stable identifier, so a research session can ask multiple questions without re-uploading. When the session ends, `/v1/sources/delete` cleans up sources to keep storage tidy.

Example prompt: Add a research paper PDF, ask 'Summarise the methodology section in 5 bullets', then delete the source.

### AI Agent Document Workflows

Embed PDF Q&A inside a larger agent workflow through Jentic, where the agent searches for 'chat with a pdf', loads the chat schema, and executes calls without ever seeing the raw API key. Combine with Jentic-discovered storage or email APIs to fetch attachments, ask questions, and post answers back to a ticket - all in a single agent run.

Example prompt: Search Jentic for 'chat with a pdf', load the ChatPDF send-message schema, and answer 'What is the refund policy?' against a previously uploaded source.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| POST | `/v1/sources/add-url` | Add a PDF source by URL |
| POST | `/v1/sources/add-file` | Upload a PDF file as a source |
| POST | `/v1/chats/message` | Ask a question against a PDF source |
| POST | `/v1/sources/delete` | Delete one or more PDF sources |

## Key resources

- **Sources** — Add PDFs by URL or direct file upload, and delete sources when no longer needed
- **Chat** — Send a question against a registered PDF source and receive a grounded answer

## Why Jentic

- **Setup:** Wiring ChatPDF by hand means handling its x-api-key header auth and sequencing source uploads before you can ask a grounded question. Through Jentic you install once, import the ChatPDF API from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** ChatPDF identifies sources by an id in the request body rather than the URL path, so scope the agent to the operations it needs, such as adding a source and sending a chat message. You choose that set, so deleting a source is not included unless you add it.
- **Credential handling:** Your ChatPDF API key is stored once, encrypted, by your own Jentic One instance and injected at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'chat with a pdf' or 'add a pdf source', and Jentic returns the matching ChatPDF operation with its input schema so the agent calls the right endpoint without browsing the reference docs.

## Related APIs

- **OpenAI API** — OpenAI's Assistants and Files APIs offer general-purpose document Q&A with broader model choice.
- **PDF.co API** — PDF.co handles PDF parsing, OCR, splitting, and conversion that often run before chat-style Q&A.
- **Anthropic Messages API** — Anthropic's Messages API supports long-context document conversation with Claude models.

## FAQ

### Why is there no official OpenAPI spec for ChatPDF API?

ChatPDF does not publish an OpenAPI specification. Jentic generates and maintains this spec so that AI agents and developers can call ChatPDF API via structured tooling. It is validated against the live API and kept up to date. Get started with Jentic One, the self-hosted execution layer.

### What authentication does the ChatPDF API use?

The API uses an API key passed in the x-api-key header on every request. Keys are issued from chatpdf.com. Through Jentic, the key is stored encrypted in the credential vault and injected at execute time, so the agent never holds the raw key.

### Can I ask questions about a PDF I uploaded earlier?

Yes. POST `/v1/sources/add-url` or POST `/v1/sources/add-file` returns a sourceId. Pass that id to POST `/v1/chats/message` along with your question, and the API replies with an answer grounded in the document plus optional page references.

### What are the rate limits for the ChatPDF API?

The OpenAPI spec does not declare numeric rate limits. ChatPDF applies per-account quotas that vary by plan, so agents should handle 429 responses with exponential backoff and surface plan limits to the caller.

### How do I add a PDF and ask the first question through Jentic?

Search Jentic for 'add a PDF source', load the schema for POST `/v1/sources/add-url`, and execute with the document URL. Then search 'chat with a pdf', load POST `/v1/chats/message`, and execute with the returned sourceId and your question - two steps from intent to answer.

### Can I delete a PDF after I am done with it?

Yes. POST `/v1/sources/delete` accepts a list of source identifiers and removes them. This is useful when documents contain sensitive data and need to be purged once the analysis run completes.

### Can I limit what my agent is allowed to do with the ChatPDF API?

Yes. Because Jentic One is self-hosted, you set the rules that decide which ChatPDF operations and credentials your agent may use. You can grant only the calls a task needs, such as adding a source with POST `/v1/sources/add-url` or `/v1/sources/add-file` and asking questions with POST `/v1/chats/message`, while withholding destructive calls like POST `/v1/sources/delete` unless you choose to include it. Since ChatPDF identifies each PDF by an id in the request body, scoping is defined at the operation level and your own instance enforces it at execution time.
