Your own credential
Every source is read with a credential you create and control: a Notion integration of your own, a Google service account in your own Google Cloud project, or your own Atlassian API token. There is no Hookie app to install in Notion, Google or Atlassian. A website needs no credential. Hookie checks the credential with the source when you connect, stores it encrypted and never shows it again. To stop Hookie reading, disconnect the source in Hookie, or revoke the credential at the source.Connect a source
- Open the project and choose Sources, then Knowledge.
- Choose Connect beside the source.
- Fill in the fields for that source, as described below.
- Choose Connect and sync.
Notion
Hookie mirrors every page your integration can see.- Go to notion.so/profile/integrations and create a new internal integration in your workspace. It only needs to read content.
- Open the integration and copy its secret from the Configuration tab.
- In Notion, open each page or database you want mirrored, choose •••, then Connections, and add your integration. Pages under a shared page are included.
- In Hookie, paste the secret into Notion integration token.
Google Drive
Hookie mirrors the files in one folder and its subfolders.- In your own Google Cloud project, enable the Google Drive API.
- Under IAM & Admin, then Service accounts, create a service account. It needs no roles in the project.
- Open the service account, choose Keys, then Add key and Create new key, and download the key as JSON.
- In Google Drive, share the folder with the service account’s email address (it ends in
iam.gserviceaccount.com) as a Viewer. - In Hookie, paste the folder’s link (or its id) into Folder, then paste the key file’s contents into Service-account key (JSON), or choose Choose key file.
Confluence
Hookie mirrors the current pages of the spaces you name, on an Atlassian Cloud site (your-site.atlassian.net).
- Go to id.atlassian.com/manage-profile/security/api-tokens and create an API token. Classic and scoped tokens both work.
- In Hookie, enter:
- Site:
acmeoracme.atlassian.net. - Atlassian account email: the account the token belongs to.
- Space keys: up to 20, separated by commas, such as
ENG, OPS. A personal space’s key starts with~. - Atlassian API token: the token.
- Site:
Atlassian API tokens expire. You choose an expiry when you create one, at most a year ahead. When the token runs out, the connector shows Needs attention: create a new token, choose Edit and paste it.
Website
Hookie crawls one public site from a start page you name, as HookieBot. It needs no credential.- Choose the Start page, such as
https://docs.example.com/. It must be a publichttpsaddress on the default port. - Choose Connect and sync. Hookie reads the start page first and refuses to connect if it cannot.
https://example.com/docs/intro reads pages under https://example.com/docs/ and nothing else. Query strings and # fragments are ignored, so each page is read once.
Hookie finds pages through the site’s sitemaps (those named in robots.txt, or /sitemap.xml) and through the links on each page it reads. It is a polite crawler:
- It follows
robots.txt: the rules forHookieBotif there are any, otherwise the rules for*. - A page marked
noindex(in arobotsmeta tag or anX-Robots-Tagheader) is not indexed, and one already mirrored leaves the brain. Links on anofollowpage are not followed. - Redirects are followed only within the crawl’s scope, at most five times.
- If
robots.txtcannot be read because the site is failing, Hookie reads nothing and tries again later.
HookieBot/1.0 (+https://docs.hookie.ai/knowledge-connectors). To keep HookieBot out of part of your site, add a User-agent: HookieBot group to your robots.txt.
What is mirrored
Hookie turns PDF, Word and HTML into Markdown and keeps that text, not the original file. Mirrored pages are documents with source
connector, shown in the Documents table on the project’s Brain page.
A page is Skipped, with the reason, when:
- it holds anything that looks like a key, token or password. Its content is never stored.
- it is too large: text and Markdown over 1 MB, PDF, Word and HTML over 5 MB, or a Google file over Google’s 10 MB export limit.
- it has no text to index.
- its Google Drive owner does not allow it to be downloaded.
- a website page answers with an error such as
401or403, redirects too often, or is a type Hookie does not index.
Limits
Mirrored pages count towards the project’s document allowance. When the allowance is full, the sync stops and the connector says why.
Syncing
- When you connect, and when you save a change with Edit. A change of settings reads every page again.
- Sync now, in the console or with the
sync_project_connectortool. Anyone who can write to the project’s context may sync, agents included. - Once a day, for every connector.
lastmod in its sitemap is read again once a day.
For agents
Agents search mirrored pages with
search_project_knowledge, like any other document. The project’s context bundle lists its connectors too. No tool takes or shows a credential: a person connects a source in the console. The CLI has the same tools as hookie connectors list|get|sync.
Everything mirrored was written by people, so agents receive it as data, not instructions.
Over the API
All routes are under/admin/api/projects/{project_id}/connectors:
GET connectors: the project’s connectors, the providers on offer, and the limits.GET,PUT,PATCHandDELETE connectors/{provider}: read, connect, change or disconnect one.PUTandPATCHtake{"config": {…}, "credential": "…"}. APATCHwithoutcredentialkeeps the stored one.POST connectors/{provider}/sync: sync now.GET connectors/{provider}/pages?offset=&limit=: the pages it found, and why any were skipped.
config for each provider:
Connecting, changing and disconnecting need a workspace owner or admin, or a project admin. A connected agent is refused with
agent_not_permitted, whatever its access. See the API reference for every field.
Troubleshooting
A source in Needs attention is retried every hour. Its last error is shown under the table.