Skip to content
Pilotoo
v0.1

Connectors

A connector brings sources into one or more memories without anyone uploading them. Each connector is a workflow, edited with the same workflow editor as the rest of Pilotoo, that Brain runs on a schedule. It reads through your connections in Pilotoo Connect, and every item it adds goes through compile and labels exactly like an upload.

Connectors live in Connectors in Brain’s main menu, next to Memories, because one connector can write into several memories.

Connection steps read with the connections of the connector’s owner, so each person links their Connect account once:

  1. Open Connectors and choose Link Connect.
  2. Connect asks you to sign in if needed, then shows what Brain will be allowed to do. Choose Allow.
  3. You are back in Brain, linked as your Connect account.

Connect creates a personal token named “Brain” for you. Brain stores it encrypted and uses it only to run your connectors, also while you are signed out.

Unlink revokes the “Brain” token in Connect, then forgets it. If Connect cannot be reached, the link is kept and Brain asks you to try again. Revoking the token in Connect yourself pauses your connectors until you link again.

Pick a template under Start from a template, or Blank. A template only fills in a new workflow: from then on it is an ordinary workflow, and the connector keeps no link to the template.

The Mail inbox template, for example, starts with these steps:

  1. Schedule: every 5 minutes.
  2. Mail: search messages: unread messages in the inbox.
  3. For each message, Mail: get message reads it in full.
  4. If it looks like a newsletter, it is skipped.
  5. Memory: add source: the memory you pick, the subject as title, the body as text and the message id as its identity.

Add, change or remove any step, then Save. New connectors start turned off: turn one on once its test run looks right.

Step What it does
Memory: add source Adds a source to a memory you administer: title, text, labels and the item’s external id. The same id with the same text changes nothing; changed text becomes a new version. Without labels, the memory’s label rules decide, like an upload.
Memory: remove source Retires the source with that external id from a memory, as a delete does: its facts are rebuilt from the sources that remain.

A connector needs at least one Memory: add source or Memory: remove source, so a cleanup connector that only removes is allowed. It may have several, each writing to its own memory, for example a Switch that sends invoices to the company graph and manuals to a collection.

Code steps run JavaScript to reshape what comes in, such as building a title or choosing labels. Each snippet runs isolated from the server, with only the workflow’s data in and out, and fails at its time limit (at most 30 seconds) or memory limit. A few snippets run at once across Brain; the others wait.

Test run runs the whole workflow but writes nothing. It shows each item it would add, to which memory and with which labels, whether it would be new, a new version or unchanged, and any step that failed. Connection steps that could change something in the connected app are not called during a test.

  • Daily cap: the most sources a connector adds in a day, across every memory it writes to (default 200). Once reached, it pauses until the next day (UTC).
  • Schedule: never more often than every 5 minutes.
  • A connector also pauses by itself when its owner is no longer admin of a memory it writes to, when the Connect link is missing or revoked, or when its workflow no longer validates. The list shows the reason, and the connector resumes once the cause is gone.

An agent can create, change, turn on and run connectors over Brain’s MCP endpoint, with the same workflow tools as the desktop app, from any MCP client such as Claude Desktop, Claude Code or Cursor. Give its token the connectors access on the memories it may feed when you create it in Agents & tokens. It then works on your connectors, as you, but only on those that write into those memories.

Each memory’s menu has Fed by: the connectors writing into that memory, who owns them, how many sources they added today, and their status. A memory admin who does not own a connector can choose Pause here to stop it for this memory only, without touching the other memories it feeds.

The same screen keeps the uploads and the label rules, which can match on the connector a source came from.

Brain enables connectors when these three settings are present together:

Variable Service Meaning
CONNECT_URL Brain Connect’s public address, https outside localhost.
CONNECT_LINK_SECRET Brain The secret Brain and Connect share for the link, at least 32 characters.
BRAIN_CONNECT_KEYS Brain The keys that encrypt the stored tokens, in the same version:base64 format as CONNECTIONS_ENCRYPTION_KEYS.
CONNECT_LINK_CLIENTS Connect A JSON array of the products allowed to link, such as [{"id":"brain","name":"Brain","redirectUri":"https://brain.example.com/api/connect/link/callback","secret":"<the same secret>"}].

Without them, Brain works as before and the Link Connect button is not offered.