# Doctorine App permissions

One Doctorine App supports docs synchronization and SDK publishing. Install it on
the repositories you intend to connect; an installation is not permission for a
different Doctorine workspace to claim your repository.

The shared permission set covers repository metadata, content and pull requests;
workflow files, Actions and repository variables; checks, statuses, deployments
and environments; issues; organization membership lookup; and read-only
administration and merge-queue inspection. These permissions support the shared
App's capabilities. They do not mean every connected repository enables every
automation tier.

## Why administration read access?

Doctorine inspects repository protections when deciding whether automation may
merge. Administration access is read-only: it does not authorize Doctorine to
turn off your branch protections. If the protection or bypass result is unknown,
use manual review.

## Approve an installation update

An existing installation can retain its old grants until an administrator
approves an App update. Studio shows **approval pending** when the SDK-required
grants are absent. Open the installation's configuration link, review the change
on GitHub, and return to Studio. Existing docs synchronization can continue while
SDK linking waits for the new grants.

If a repository is missing, use **I don't see my repo** to refresh authorization.
Use the separate account/organization option when you need another installation.

## What publishing consent controls

Consent enables Doctorine's publishing automation for a target. The repository
variable `DOCTORINE_PUBLISHING` records that preference. Repository administrators
can change variables and workflows themselves, so this is not an enforcement
boundary against the repository owner. Studio reports detected drift as
repository-managed publishing.

Disabling or unlinking in Doctorine does not revoke a registry trusted publisher
or a credential you created yourself. Follow the full
[offboarding inventory](/guides/plans-and-offboarding/).

## Related pages

- [Doctorine SDK documentation](../index.md)
- [Publish SDKs to registries](./publish-sdks.md)
- [Set up a registry publisher](./registry-setup.md)
- [Keep custom code during regeneration](./custom-code.md)
- [Plans, disable and offboarding](./plans-and-offboarding.md)
- [Troubleshoot an SDK release](./troubleshooting.md)

# Agent Instructions

This portal answers questions programmatically. To receive a synthesized,
source-cited answer instead of crawling page by page, append the `?ask=`
query parameter to any page URL on this site:

    /guides/quickstart?ask=how+do+I+authenticate

Optional parameters:

- `&goal=<what-you-are-trying-to-do>` steers the answer toward your
  objective (e.g. `&goal=write+a+python+client`).
- `&version=<label>` scopes the answer to a mounted version when the
  portal publishes more than one.

The response is `text/markdown`: the answer followed by a `# Sources` list
of the portal pages it was grounded in. Status codes are the contract:

- `200` — the answer; `402` — the portal owner’s plan or answer credits are
  exhausted (surface this to your operator; do NOT retry); `429` — you are
  rate-limited; back off for the `Retry-After` seconds; `503` — the answer
  lane is temporarily unavailable; fall back to crawling the `.md` pages.

For the full corpus map read `llms.txt` at the site root; for the tool
surface (search + page fetch as MCP tools) see `/mcp`.
