Connect AI agents to your doc sites
Let Claude Code, Codex, ChatGPT or your own scripts draft, organize and publish doc site pages. Plans (Pro and up), the doc site permissions, site scoping and publishing rules, with links to the full AI agents & API guides.
AI agents such as Claude Code, Codex, Cursor, Claude or ChatGPT can read and write your doc sites for you: draft articles, fix pages readers rate low, answer content gaps, translate or publish. This article covers what is specific to doc sites. Tokens, connectors, spending and errors are explained in AI agents & API.
Before you start
- AI agents & API is on the Pro, Business and Custom plans, including connectors for Claude and ChatGPT. Free and Starter don't include it; tokens and apps stop working if a workspace moves to one of them.
- An agent acts as the person who created its token or connected it, within that person's role. It can never do more on a site than they could.
- API calls cost no credits. Translating pages and generating site pages with AI cost credits, and only with a token that may spend them.
Connect an agent
Open the workspace menu and choose AI agents & API, or choose AI agents & API in a doc site's Settings menu (it opens the activity for that site).
- API token for Claude Code, Codex, Cursor or a script: Tokens → New token, then a four-step wizard (Purpose, Permissions, Limits, Review). Pick a doc site preset such as Writer or Publisher, choose the sites under Limits → Doc sites, and copy the token, which is shown once. See Create an API token.
- Connector for Claude.ai or ChatGPT: paste the Connector URL from Connected apps into the app, sign in and choose the Sites and Access. See Connect AI apps and agents.
Doc site presets
| Preset | Description on screen | For |
|---|---|---|
| Writer | "Agents draft; a person reviews and publishes." | Drafting articles and changelog entries, uploading images |
| Publisher | "Trusted automation that may change what readers see." | Everything for doc sites, including publishing, settings and creating sites |
| Support assistant | "Answers from published docs. Nothing else." | A help bot that searches published, public pages only |
| Read-only | "Research, audits and translation checks." | Reading content |
| Analyst | "Reads content and reader signals to suggest fixes." | Reading content and insights |
Producer and Workspace agent add videos and spending credits. Every permission and who can grant it: Agent permissions.
Doc site permissions
| Permission | Allows |
|---|---|
content:read |
Read sites, pages, articles (drafts too), revisions, the changelog and site pages |
articles:write |
Create draft articles and edit articles that are not live |
structure:write |
Create and edit sections; move, hide and rename pages |
site-pages:write |
Edit site pages such as home, contact and legal |
changelog:write |
Create and edit changelog entries as drafts |
media:write |
Upload images |
site:publish |
Publish: change what readers see, edit live content, mark pages ready |
insights:read |
Read search gaps, unanswered questions and page feedback |
site:configure |
Change site settings, appearance and navigation |
sites:create |
Create new doc sites |
help:read |
Search published, public pages only (for a support assistant) |
Reading is open to any member. Writing and organizing: owner, admins, editors and Content Creators. Publishing and site settings: owner, admins and editors ("Only owners, admins and editors can grant publishing."). Creating sites: owner and admins.
Which sites a token covers
Under Limits → Doc sites, choose All sites ("Every doc site in this workspace, including new ones.") or Chosen sites. A token or connected app only sees and changes the sites it covers. If an article also appears on a site outside its scope, the change is refused: "This article is also shown on a site this token cannot change."
Live content needs publishing rights
Without site:publish, an agent can't change what readers see. Editing an article that's live is refused ("This content is live on a published site, so changing it needs the site:publish ability."), and the agent can submit its draft for review instead. You get a notification, "agent asked for review of page on site": "Nothing was published. Read the article and publish it when it's ready."
Every change an agent makes shows in the page's history as "Agent name (token)". Publishes are limited to 10 an hour per token. A paused site is read-only for agents: "This site is paused or offline and read-only."
What agents can do on a site
List sites and read the page tree, search and read pages, preview Markdown, create and update articles, submit them for review, organize sections and pages, edit site pages and the changelog, upload images, read insights and mark gaps as covered, change settings, appearance, navigation and redirects, create sites, translate pages, generate site pages, publish and roll back. Each needs the matching permission.