Docent class is the main entry point for the SDK. All API operations are methods on this client.
Initialization
Constructor Parameters
str | None
API key for authentication. Falls back to the discovered config file
(
~/.docent/docent.env when no project-level file is found), then the
DOCENT_API_KEY environment variable. See the
configuration priority table for
the full resolution order. Required — if no key is found, raises ValueError.str | None
Stored as
default_collection_id for your convenience, but SDK methods
do not fall back to it automatically — you must pass collection_id
explicitly to each method call. Falls back to DOCENT_COLLECTION_ID from
the config file.str | None
Direct URL of the Docent API server. Overrides URL derived from
domain.
Falls back to DOCENT_API_URL environment variable.str | None
Direct URL of the Docent frontend UI. Overrides URL derived from
domain.
Falls back to DOCENT_FRONTEND_URL environment variable.str | None
default:"docent.transluce.org"
Domain of the Docent instance. API and frontend URLs are derived as
https://api.{domain} and https://{domain} unless overridden.bool
default:"True"
Whether to use HTTPS when constructing URLs from the domain.
str | Path | None
Explicit path to a dotenv config file. If not provided, the SDK searches for
project-level
docent.env overrides from the current directory upward, then
checks the default global config file at ~/.docent/docent.env.IO[str] | None
Output stream for SDK log messages. Defaults to
sys.stdout.Properties
str
The resolved Docent frontend base URL.
str
The resolved Docent API base URL.
str | None
The default collection ID, if configured.

