Contents

Connecting through MCP

The demo company

The demo company comes with demonstration agents, which use this interface from inside the platform. Connecting your company’s own agents is part of a company deployment, arranged on request: request a quote.

An assistant that speaks MCP (the Model Context Protocol) can work with Synarun without code written for the HTTP interface. It sees the tools its agent is granted, and every action it takes goes through the same Guardrails decision as any other action. You choose how it connects when you add the agent in the console.

The two connections

ConnectionForWhat the assistant holds
Access code (the default)Any client that can send a header with each request, such as a code assistant that reads a project fileAn access code, kept in an environment variable.
The synarun-mcp program, with a proof bound to a keyClients that cannot send a header, and companies that want the key never to leave the agent’s computerA private key in a file that the program alone reads.

The two are equal in what the agent is allowed to do: the grants, the decisions and the limits are the same. They differ only in what has to be protected.

With an access code

  1. In the console, the Owner of the company adds the agent as an external agent, with the connection “Access code” and a validity, and confirms it (by a click or with the passkey, as the company’s setting says; “Add an external agent”, on the agents page of the console).
  2. The console shows the access code once, with the text to copy. It is not shown again: if it is lost, the Owner issues a new one, and the old one stops working.
  3. Put the code in an environment variable, preferably in your profile file, not in the terminal’s history:
export SYNARUN_ACCESS_CODE='<the access code>'
  1. In the project’s configuration file (.mcp.json, for a client that reads such a file), connect the server without writing the code in it:
{
  "mcpServers": {
    "synarun": {
      "type": "http",
      "url": "https://api.synarun.com/mcp",
      "headers": { "Authorization": "Bearer ${SYNARUN_ACCESS_CODE}" }
    }
  }
}

The assistant sends the access code in the Authorization header of every request to https://api.synarun.com/mcp. The access code begins with syn_bt_.

Forbid the assistant to read the file where you keep the access code, with the client’s deny rule. An assistant that can read the file can read the code, and a code read is a code lost.

With the synarun-mcp program

The program runs on the agent’s computer. It makes the agent’s key, keeps it in a file only the program reads, and proves with it, in each request, that the request comes from that computer.

Download: https://synarun.com/downloads/synarun-mcp-1.0.1.mjs

SHA-256 thumbprint of the file:

c4ff7088f196bb59862684e462f8eeb25b233147836bf10bd8e8eb458d21cf9a

The program needs Node.js, the version Synarun itself runs (26.7.0) or newer. Download the file, check its thumbprint before you run it, and compare the result with the one above:

shasum -a 256 synarun-mcp-1.0.1.mjs

If the two differ, delete the file and do not run it. Then:

  1. node synarun-mcp-1.0.1.mjs cheie <agent> makes the key and prints its public part. In the console, add the agent with the connection “The synarun-mcp program (DPoP)” and that public key.
  2. node synarun-mcp-1.0.1.mjs cheie <agent> <credential_id> <agent_id> binds the identifiers the console shows.
  3. node synarun-mcp-1.0.1.mjs configurare --legatura dpop <agent> prints the block to put in the client’s configuration, and the deny rule for the key’s folder (Read(~/.config/synarun-mcp/**)). Put both in.

The program’s other commands: pornire (the bridge itself, started by the client), token (stores an access code, read from the standard input only), tipuri (writes the declarations of the granted tools for an assistant that writes code against them) and apel (one action from the command line).

The desktop application of an assistant

To be confirmed. Whether the desktop application of an assistant accepts the address with an access code in a header, or only with a sign-in of its own (OAuth), is being verified, and this page will say the result. Until then: if the desktop application does not accept the header, use it with the synarun-mcp program, as above; the access code stays for the clients that accept a header.

What the assistant sees

The tools of the agent are the services and operations granted to it, the same ones that GET /v1/tools lists, described in Documents and access requests. An action that changes something is submitted as an action: Guardrails decides, and the answer is Allowed, Approval required or Blocked, as described in Outcomes. The agent never sees the connections’ secrets.

The limits of the interface apply to this connection too: see Limits.