Write a generic MCP server
- graal Agentic Platform
- Version 0.30 (current)
- Open source · Apache 2.0
- Source : graalsystems/tranibor@v0.30.2
Your DNS agent works against OVHcloud. The next team hosts its zones at GoDaddy, and a customer at a
third provider. You do not want three agents with three sets of instructions and three sets of tool
names. You want one agent that calls list_records, plan_changes and create_record, whoever
hosts the zone, and one small server per provider behind it.
Tranibor does this with profiles
(ADR 0224):
a plugin declares a contract of tools, provider plugins bring MCP servers that implement it, and the
platform proves at validation and at install that each server keeps the contract. This page walks
through it with the real dns profile and a hypothetical provider, Example DNS.
What you will be able to do: decide when a profile is worth it, write one with provider-neutral tools, write a provider’s server that implements it, govern its writes, give it a fake and tests, package and validate it, and run it as several named instances in one organisation.
Before you start:
- the CLI;
tranibor plugin validateworks offline; - Package agents as a plugin and Give agents tools: this page builds on both;
- a core that supports profiles: 0.30.0 or later for profiles (declared, checked, called by an agent), 0.30.1 or later for named instances and their console pages.
The examples come from the public repository
graalsystems/tranibor-agents: the
profile plugin plugins/dns and its two providers, plugins/dns-ovh and plugins/dns-godaddy. The
same layout serves the profiles backup, certificates, gitops, identity, lan and
observability there.
When to write a profile
Section titled “When to write a profile”Write a plain MCP server (one plugin, one server, an agent that names its connector) when the system is one of a kind: there is one ServiceNow, and an agent that triages its incidents speaks its words.
Write a profile when:
- several products do the same job (DNS hosting, an identity provider, a LAN controller, a backup tool), and the work the agent does does not depend on which one;
- you want the agent, its skill, its template and its evals written once and reused from one organisation to the next;
- an organisation may run two providers side by side, or two accounts at the same provider.
A profile costs you a neutral vocabulary and a conformance suite. If you cannot name the tools without the product’s words, the systems are not alike enough: keep a plain server.
Profile, provider, instance
Section titled “Profile, provider, instance”| Part | What it is | In the DNS example | Ships in |
|---|---|---|---|
| Profile | A named contract of tools, plugin/name@version, with their input and output schemas and a governance floor |
dns/dns@1, eleven tools |
the profile plugin, contents.profiles |
| Profile plugin | The profile and everything that does not depend on a provider: agents, skills, templates, evals, a conformance suite | dns: the dns-steward agent, its skill, the dns-change template |
its own plugin, with no server |
| Provider plugin | One provider’s MCP server, which implements the profile, with its setup procedure |
dns-ovh, dns-godaddy |
one plugin per provider, which requires the profile plugin |
| Instance | One running copy of a provider’s server, with its own configuration and secrets: one organisation connector | dns-ovh, dns-ovh-customer-b, dns-godaddy |
created in the organisation, not in a plugin |
The core treats a profile as opaque: it checks the profile’s shape and compares servers with it, but it never reads what DNS means. A profile is therefore yours to design; the platform only enforces that every implementation keeps it.
An agent names the profile instead of a connector. When a run starts, the platform opens the profile’s
tools on every instance the project may use, under each instance’s name: dns-ovh__list_records,
dns-godaddy__list_records.
1. Write the profile
Section titled “1. Write the profile”A profile is one YAML file in the profile plugin. Here is four of the eleven tools of dns/dns@1, as the
real file writes them (two field descriptions left out); the full file is
plugins/dns/profiles/dns.yaml:
# Four of the eleven tools of dns/dns@1, as plugins/dns/profiles/dns.yaml writes them.name: dnsversion: 1description: Authoritative DNS zones and their records, whatever the provider.tools: - name: get_provider access: read description: >- Which provider and which zones this instance serves. An agent reads it on every instance of the profile first, to pick the instance that serves the zone it is asked about. input: {type: object, additionalProperties: false, properties: {}} output: {$ref: "#/$defs/provider"}
- name: list_records access: read description: A zone's records, optionally of one type and/or at one name. input: type: object additionalProperties: false required: [zone] properties: zone: {type: string} type: {type: string} name: {type: string, description: Relative to the zone; "" is the apex.} output: type: object required: [zone, count, records] properties: zone: {type: string} count: {type: integer} records: {type: array, items: {$ref: "#/$defs/record"}}
- name: create_record access: write human_approval: false # a floor: an implementation may raise it, never lower it platform_arguments: [action_key] description: >- Creates a record. An identical record (same type, name and value) is returned instead of duplicated, so a replay of the same governed action (same `action_key`) writes nothing twice. input: type: object additionalProperties: false required: [zone, name, type, value] properties: zone: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer, minimum: 0} output: type: object required: [zone, created, id, name, type, value, ttl, needs_publish] properties: zone: {type: string} created: {type: boolean, description: False when an identical record already existed and nothing was written.} id: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer} needs_publish: {type: boolean}
- name: delete_record access: write human_approval: true description: Deletes a record. The answer holds the record, from which it is recreated. input: type: object additionalProperties: false required: [zone, id] properties: zone: {type: string} id: {type: string} output: type: object required: [zone, deleted, id, name, type, value, ttl, needs_publish] properties: zone: {type: string} deleted: {type: boolean} id: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer} needs_publish: {type: boolean}
$defs: provider: type: object required: [instance, provider, zones] properties: instance: {type: string, description: The name of this instance of the server (its connector name).} provider: {type: string, description: "The provider, e.g. ovhcloud or godaddy."} zones: {type: array, items: {type: string}, description: The zones this instance may touch (its allow-list).} record: type: object required: [id, zone, name, type, ttl, value] properties: id: {type: string} zone: {type: string} name: {type: string} type: {type: string} ttl: {type: integer} value: {type: string}The profile plugin declares it in contents.profiles. The real dns plugin also ships the agent, its
skill, the template and the evals:
apiVersion: tranibor/v1kind: Pluginmetadata: name: dns version: 0.1.1 publisher: GRAAL.SYSTEMS SAS license: Apache-2.0 description: >- Run DNS changes for zones at any provider under human approval. The agent names no provider: it works with whichever DNS server plugins the organisation installed. core: ">=0.30.0,<1.0.0"requires: plugins: [] connectors: {}contents: profiles: [profiles/dns.yaml]Name the tools and the data, not the product
Section titled “Name the tools and the data, not the product”- Neutral words.
zone,record,ttl,value: what every DNS provider has. Not OVHcloud’ssubDomainandfieldType, not GoDaddy’s@for the apex. Each server translates (from_ovh,from_godaddy), and the profile says once what the words mean: indns.yaml, a record is one value at one name,nameis relative to the zone and""is the apex,ttl0 is the provider’s default. - Opaque identifiers.
idis a string only the server that issued it reads. OVHcloud’s ids are numbers, GoDaddy’s are not; the profile promises neither. - A first read that tells instances apart.
get_provideranswersinstance, provider, zones. The agent calls it on every instance before anything else, and picks the one whose answer lists the zone. The core does not require such a tool, but without it an agent with two instances cannot choose. - Writes that return their undo.
update_recordanswersprevious,delete_recordthe record it deleted, so that each provider can declare a compensation from the result (step 3). - Only what every provider can do.
dns/dns@1leaves out zone history, DNSSEC and NS or SOA changes: provider-specific, or too dangerous for every implementation to carry. A server may serve more tools than the profile, but agents that name the profile never see them. - Few tools, the most needed first. A profile entry offers at most 16 tools by default
(
TRANIBOR_BROKER_PROFILE_TOOL_CAP, an operator setting), counted across instances, in the profile’s tool order then the instance’s name. Two instances of an eleven-tool profile are 22 tools: the last six (here the last three tools of the profile on both instances) are left out and named in the run’s journal (profile.capped). Keep profiles small, put the reads an agent needs first, and list in an agent’s entry only the tools it uses.
Stay inside the schema subset
Section titled “Stay inside the schema subset”A profile’s input and output use only type, properties, required, additionalProperties,
items, enum and const, the numeric and length bounds, pattern, format (date-time, date,
time, uri, email, uuid), $ref to the profile’s own $defs, description and title. No
oneOf, anyOf, allOf, not or if: the comparison with a server’s schemas must never guess, so
the validator refuses them. The full list is in Profiles a plugin declares.
Version it
Section titled “Version it”The profile’s name is dns/dns@1: the plugin, the profile’s name, its integer version. A change that
an installed server could fail (a new tool, a new required field, a tighter bound) is a new version
(dns@2), served beside the old one; a server may implements: [dns/dns@1, dns/dns@2] while agents move.
The platform holds you to it. At install, a server is checked against the profile stored with the
installed version of the profile plugin. An upgrade of the profile plugin re-checks every installed
server that implements one of its profiles, and refuses with a 409 that names each server that no
longer conforms. Nothing is written; upgrade the providers first.
2. Write a provider
Section titled “2. Write a provider”A provider is a plugin with one server. It requires the profile plugin, and its server says
implements:
apiVersion: tranibor/v1kind: Pluginmetadata: name: dns-example version: 0.1.0 publisher: ACME platform team license: Apache-2.0 description: Serve DNS zones hosted at Example DNS to the `dns` plugin's agent. core: ">=0.30.0,<1.0.0"requires: plugins: [{name: dns, version: ">=0.1.0,<1.0.0"}] connectors: {}contents: servers: [servers/dns-example.yaml]The server file declares every tool of the profile under operations, with the same access, a
governance at least as strict, and input and output schemas that keep the profile’s. The simplest way to
keep them is to copy the profile’s schemas, each with the $defs it points to:
name: dns-exampleimplements: [dns/dns@1]image: registry.example.com/acme/dns-example-mcp@sha256:5f1c3e9a0d7b2468ace13579bdf02468ace13579bdf02468ace13579bdf02468port: 8080protocol: mcp-httppaths: {mcp: /mcp, health: /healthz}
config_schema: type: object additionalProperties: false required: [base_url, api_token, zones] properties: base_url: type: string format: uri description: The address of the Example DNS API. x-env: DNS_EXAMPLE_BASE_URL x-help: The API address of your account's region, without a path. api_token: type: string minLength: 1 description: An API token limited to the zones below. x-env: DNS_EXAMPLE_API_TOKEN x-help: Create it with the DNS scope only, restricted to the listed zones. zones: type: array minItems: 1 items: {type: string} description: The zones this server may touch (joined with commas). Any other zone is refused, even to read. x-env: DNS_EXAMPLE_ZONESsecret_fields: [api_token]
egress: from_fields: [base_url]
operations:- name: get_provider access: read input_schema: {type: object, additionalProperties: false, properties: {}} output_schema: $ref: '#/$defs/provider' $defs: provider: type: object required: [instance, provider, zones] properties: instance: {type: string} provider: {type: string} zones: {type: array, items: {type: string}}- name: list_records access: read input_schema: type: object additionalProperties: false required: [zone] properties: zone: {type: string} type: {type: string} name: {type: string} output_schema: type: object required: [zone, count, records] properties: zone: {type: string} count: {type: integer} records: {type: array, items: {$ref: '#/$defs/record'}} $defs: record: type: object required: [id, zone, name, type, ttl, value] properties: id: {type: string} zone: {type: string} name: {type: string} type: {type: string} ttl: {type: integer} value: {type: string}- name: create_record access: write platform_arguments: [action_key] input_schema: type: object additionalProperties: false required: [zone, name, type, value] properties: zone: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer, minimum: 0} output_schema: type: object required: [zone, created, id, name, type, value, ttl, needs_publish] properties: zone: {type: string} created: {type: boolean} id: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer} needs_publish: {type: boolean}- name: delete_record access: write human_approval: true compensation: operation: create_record arguments: zone: '{{ result.zone }}' name: '{{ result.name }}' type: '{{ result.type }}' value: '{{ result.value }}' ttl: '{{ result.ttl }}' input_schema: type: object additionalProperties: false required: [zone, id] properties: zone: {type: string} id: {type: string} output_schema: type: object required: [zone, deleted, id, name, type, value, ttl, needs_publish] properties: zone: {type: string} deleted: {type: boolean} id: {type: string} name: {type: string} type: {type: string} value: {type: string} ttl: {type: integer} needs_publish: {type: boolean}
fake: env: {DNS_EXAMPLE_FAKE: "1"} scenes: [default]This file keeps the four tools shown above. Against the full dns/dns@1 it must declare all eleven;
servers/dns-ovh.yaml
is a complete one.
Map the provider’s API in the server
Section titled “Map the provider’s API in the server”The server is ordinary code that answers MCP over HTTP. Everything provider-specific stays inside it:
the API’s authentication, its routes, its record shapes, its pagination, its rate limits. The two DNS
servers are written in Python with the MCP SDK, and split the same way: config.py (the environment),
client.py (the provider’s API), tools.py (the profile’s tools over the client), fake.py (the
provider, in memory) and app.py (MCP, the token, the health probe).
Check the scope before you call the provider. Every DNS tool that names a zone passes the
allow-list first, on a read as on a write (from dns-ovh’s tools.py):
def _zone(self, zone: str) -> str: name = normalise_zone(zone) if not ZONE_NAME.fullmatch(name) or name not in self.allowed: # Not a word about whether the zone exists: the allow-list is the only thing said. raise Refused(f"zone {zone!r} is not in this server's allow-list ({', '.join(self.allowed)})") return nameAnswer every tool with structured content that matches the declared output schema. The platform
checks it: a successful answer outside the server’s outputSchema reaches the agent as a refusal, not as
data.
Normalise errors
Section titled “Normalise errors”A tool that fails answers an MCP error (isError), never a success with an error inside. The platform
hands the error’s text to the agent, so make it useful and safe. The DNS servers make two kinds (from
dns-ovh’s app.py):
async def _run[T](name: str, call: Awaitable[T]) -> T: structlog.contextvars.bind_contextvars(tool=name) try: return await call except Refused as error: log.info("tool_refused", reason=str(error)) raise ToolError(f"refused: {error}") from error except OvhError as error: log.warning("ovh_error", status=error.status, reason=str(error)) raise ToolError(str(error)) from error finally: structlog.contextvars.unbind_contextvars("tool")- The server refused (outside the scope, an invalid record): the text starts with
refused:, the convention of the core’s own tracker profile, and nothing was sent to the provider. - The provider refused or failed: the status and what it means, in the same words for every
provider (
OVHcloud answered 403: the consumer key's access rules do not allow this call), with the provider’s own message shortened. Never a credential, a signed URL or a full response body.
The core does not read the text of a plugin profile’s errors. Write the profile’s error conventions in
the profile, and test them in its conformance suite: the DNS suite requires that a refused zone’s message
says allow-list and that the provider was not called.
Page and bound inside the server
Section titled “Page and bound inside the server”An agent reads at most 64 KiB of one tool answer by default; the platform cuts a longer one and says so. Do not hand the provider’s pagination to the agent:
- Read every page in the server and answer one list: the GoDaddy server reads
pageandpageSize(at most 100) until a short page. - Give the profile filters (
list_recordstakestypeandname) so that an agent asks for less. - Cap and say it. Past 1 000 records,
list_recordsrefuses and asks for a narrower filter;export_zoneanswerstruncated: true. A cut the agent does not know about is a wrong answer. - Handle the provider’s rate limits in the client: GoDaddy’s client waits for
Retry-Afteron a429, within a cap.
Make writes idempotent
Section titled “Make writes idempotent”A governed write can be replayed (a worker retry, a resumed action). Make the replay harmless:
- Declare
platform_arguments: [action_key]where the profile does. The platform fillsaction_key, stable for one action and call, and drops whatever the agent wrote under that name. A server keys on it when the provider supports idempotency keys, as the tracker profile’s servers do. - Or make the write idempotent by content:
create_recordreturns an identical existing record withcreated: falseand writes nothing (fromdns-ovh’stools.py):
here = await self._records(zone, name=sub) for existing in here: if existing["type"] == kind and same_value(kind, existing["value"], value): return self._created(existing, created=False, needs_publish=False)3. Reads, writes and approvals
Section titled “3. Reads, writes and approvals”The governance of a provider’s server is declared in its operations; the organisation can tighten it, never loosen it below the floor:
| Declared | What the platform does by default |
|---|---|
access: read |
allowed: the agent calls it, the call is journaled |
access: write |
a governed action: recorded under its own key, done once, and held for approval unless an administrator allows it |
human_approval: true |
always a person’s approval: no policy goes below it, and the platform re-applies the floor whatever a row says |
compensation |
the operation that undoes the write, its arguments rendered from the write’s result, played if a later step of the action fails |
A profile carries the floor (access, human_approval, platform_arguments); a server may raise it,
never lower it. A tool the server serves but does not declare in operations is refused: discovery
does not add it and no agent can call it.
Plan, then apply. Writing DNS records by hand is how outages start, so the profile has a read that
computes the change: plan_changes takes the records the zone must hold and answers the diff, the
warnings, valid and the exact proposed_calls, without writing anything. It is the profile’s dry run.
The agent proposes those calls; each one becomes a governed action a person approves (delete_record
and publish always), and the platform applies it. Nothing is applied by the agent’s call itself.
Staged changes. Some providers hold writes until a publish (OVHcloud’s zone refresh), others apply
them at once (GoDaddy). The profile hides the difference without lying: every write answers
needs_publish, and publish (human_approval: true) is a real publish on OVHcloud and a no-op that says
so on GoDaddy. Model your own provider’s two-phase behaviour the same way, rather than pretending it has
none.
Compensation arguments are strings. The platform renders each argument of a compensation to text:
ttl: '{{ result.ttl }}' arrives as "3600". The server must accept a number written as text.
4. Configuration and secrets
Section titled “4. Configuration and secrets”An administrator configures each instance in the console, in a form drawn from the server’s
config_schema (Configuring a server):
- One flat form per provider. Top-level properties only, no field that depends on another:
secret_fieldsnames top-level fields, and the form draws aoneOfonly as a choice between constants. This is why the recommended packaging is one plugin per provider, never one server for all providers. - Secrets are write-only. Each name in
secret_fieldsis sealed when it is typed and never shown again; it reaches the pod from a Kubernetes Secret, never a run. - Each field becomes an environment variable: the property’s
x-env, else its name in upper case. A list is joined with commas.TRANIBOR_*names are the platform’s and are refused. - Help the person filling the form:
x-helpis one line under the field,x-linkanhttps:documentation link. - Until the configuration satisfies the schema, the instance has no replica and says
unconfigured.
The platform also gives the pod TRANIBOR_SERVER_TOKEN, a token per instance that it presents as
Authorization: Bearer on every call: refuse every call without it, the health path aside. The
reference says which variable names each core version sets:
What the server must do. From 0.30.1 the pod also gets TRANIBOR_INSTANCE_NAME, its
connector’s name, which get_provider answers; fall back to the server’s own name on an older core.
Ship a setup procedure with the provider (applies_to: {connector: mcp/<server>}, by convention
procedures/connector.mcp.<server>.md) that says how to create a narrowly scoped credential: the console shows it on the instance’s page, and the documentation
site publishes it under Connector setup. The DNS procedures tell the
administrator to restrict the provider token to the listed zones, so that the server’s allow-list is the
second lock, not the only one.
5. Network egress
Section titled “5. Network egress”A provider’s server reaches only the hosts it declares, and only the platform reaches it:
egress.hostsnames fixed hosts:dns-ovhlists the three OVHcloud API hosts, because itsendpointfield is a region, not a URL.egress.from_fieldsreads the hosts from configuration fields:dns-exampletakesbase_url. Each host is checked against the organisation’s network bounds when it is typed; a denied host is refused.- The server’s network policy lets through DNS and those hosts’ public addresses. Private, link-local and
metadata addresses stay closed, unless the operator lists a private range for the organisation
(
plugins.servers.privateCidrs, Network): the case of a LAN controller or an on-premises directory. - Only the platform’s API and workers may call the server; a run never does.
6. The fake and the tests
Section titled “6. The fake and the tests”Every provider server ships a fake: the provider, in memory, switched on by an environment variable
the configuration cannot set. The DNS fakes plug in under the real client as an httpx transport, so the
signing, the paging and the error mapping run in tests too. The OVHcloud fake recomputes each request’s
signature and refuses a wrong one. Its seed holds a TXT record that carries a prompt injection, a dangling
CNAME and a zone outside the allow-list, to prove the server and the agent handle each.
Declare it in the server file (fake: {env, scenes}). The platform then uses it for the live eval matrix,
where the deployment serves eval fakes, and for a demonstration with the server in the API’s own process
(On a laptop), which refuses a server
without a fake.
Test at three levels:
-
The profile’s conformance suite. The profile plugin ships it as a package (
plugins/dns/conformance,tranibor-dns-conformance), and each provider runs it against its own fake. It checks what the platform cannot: every profile tool is served and declared, the governance floor, the answers against the profile’s output schemas, the allow-list refused before any call to the provider,plan_changeswriting nothing, a create idempotent for oneaction_key, and each compensation, rendered as the platform renders it and played. A provider in another repository runs it in its own CI. The provider’s side is one fixture and one class (fromdns-ovh’s tests):@pytest.fixturedef dns_target(server: MCPServer, fake: FakeOvh) -> McpTarget:"""What the profile's conformance suite drives: this server over the OVHcloud fake."""return McpTarget(server,descriptor_path=DESCRIPTOR,zone="example.com",foreign_zone="private.example",# The fake's auth/time reads count too: a refused call must send nothing at all.upstream_calls=lambda: len(fake.calls),stages_changes=True,)class TestDnsProfile(Conformance):"""Every `test_*` it inherits runs here.""" -
The provider’s own tests, on the fake: the client (signature, clock, retries), the mapping of records, the descriptor against the tools the server really serves, the HTTP door (
401without the token, the health probe open). -
A live suite, opt-in. The same conformance class over the real API, skipped unless its variables are set, on a throwaway zone and a credential restricted to it. In tranibor-agents,
TRANIBOR_LIVE_REQUIRED=dns-ovhturns a missing variable into a failure. Its README must say whether it has ever run: the DNS live suites have not yet.
cd plugins/dns-ovh/server && uv run pytest -q7. Package and validate
Section titled “7. Package and validate”The image is the server’s only code the platform runs:
- Pinned by digest in the server file (a tag alone is refused), from a registry prefix the operator allows, signed when the operator enforces signatures (Images).
- A numeric non-root user and a read-only root filesystem;
/tmpis a small writable volume. The DNS Dockerfiles build withuvin one stage and run as65532:65532in a slim one, with an exec-form entry point. - The plugin directory holds the server’s source beside it (
server/), but only whatplugin.yamldeclares is packed: the source, its tests and its virtual environment never ship in the plugin.
Validate the profile plugin, then the provider against it, before you publish either:
tranibor plugin validate dns/tranibor plugin validate dns-example/ --profiles-from dns/tranibor plugin pack dns-example/ -o dns-example-0.1.0.tar.gzWhat you should see: ✓ dns-example 0.1.0 sha256:…. Without --profiles-from, validate says the
profile was not checked. A server that does not keep the profile is refused with the tool, the
direction and the path, for example:
server `dns-example`: `delete_record` of `dns/dns@1` requires `human_approval: true` (a floor: it may be raised, never lowered)server `dns-example`: `create_record` of `dns/dns@1`, input does not accept what the profile accepts: /ttl: `minimum` is 1 for the server but 0 for the profileThe comparison is sound, not complete: a pattern or a format must be written exactly as the
profile’s, even when another spelling means the same. Copy the profile’s schema rather than rewrite it.
The installer runs the same check against the profile version the organisation installed.
8. Named instances and several providers
Section titled “8. Named instances and several providers”Installing a provider plugin creates its server’s default instance, named after the server. An administrator adds others in Library › Plugins (Add instance, a name, then the instance’s connector page), or by API:
curl -s -X POST "$TRANIBOR_API_URL/api/v1/orgs/acme/plugins/dns-ovh/servers/dns-ovh/instances" \ -H "Authorization: Bearer $TRANIBOR_TOKEN" -H 'Content-Type: application/json' \ -d '{"name": "dns-ovh-customer-b"}'- Each instance is its own organisation connector: its configuration and sealed secrets, its token, its
operation policies, its egress hosts and its own pod. Two OVHcloud accounts are two instances of
dns-ovh; OVHcloud and GoDaddy are instances of two plugins. Never copy a plugin under another name to get a second account. - A name is two to 48 lower-case letters, digits or hyphens, starting with a letter, and unique among the organisation’s connectors. The default instance cannot be deleted alone; uninstalling the plugin removes every instance, and an upgrade re-applies each one with its configuration.
- An agent that names the profile sees every instance the project may use, each tool as
<instance>__<tool>, and every call is governed as a call to that connector. When none serves the project, the run still starts and its journal saysprofile.unbound.
An agent names the profile in its mcp_servers, never a provider. The dns-steward agent lists the
profile’s tools:
{ "mcp_servers": [ { "profile": "dns/dns@1", "tools": ["get_provider", "list_zones", "get_zone", "list_records", "get_record", "export_zone", "plan_changes", "create_record", "update_record", "delete_record", "publish"] } ]}Its instructions tell it what to do with several instances: call get_provider on every one, act on the
single instance whose zones list the zone, and ask a question (never guess) when none or several do.
Write the same rule into the agent of any profile.
Generic MCP guidelines
Section titled “Generic MCP guidelines”Do:
- name tools and fields after the job, and define each word once in the profile;
- start the profile with a read that says which provider, which instance and which scope (
get_provider); - keep identifiers opaque strings, and say which fields a write returns to undo it;
- declare every write as
write, mark the destructive and public oneshuman_approval: true, and give every undoable write acompensation; - offer a read-only plan (
plan_changes) that returns the exact calls to propose; - check the scope (zones, realms, sites) in the server before any call to the provider, on reads too;
- answer structured content that matches the output schema, and errors that start with
refused:when the server itself refused; - page, filter and bound inside the server, and say when an answer is cut;
- ship a fake under the real client, the profile’s conformance suite in CI, and an opt-in live suite;
- copy the profile’s schemas into the server file, and run
validate --profiles-frombefore every release; - read the instance name from the platform, and fall back to the server’s name.
Don’t:
- put a provider’s vocabulary, ids or quirks in the profile (
subDomain,@, a numeric id); - use
oneOf,anyOfor conditional schemas: the validator refuses them; - change a published profile version in a way an installed server could fail: publish a new version;
- hold several providers or accounts in one server’s configuration: one plugin per provider, one instance per account;
- serve a tool you do not declare, or declare a write as a read;
- hand the provider’s pagination, rate limits or raw errors to the agent;
- echo a credential, a signed URL or a full upstream response in an error or a log;
- assume a write is applied when the provider stages it: say
needs_publish; - make the agent guess which instance serves a request.
What is not delivered yet
Section titled “What is not delivered yet”- The core floor in the agents’ plugins. Profiles are in core 0.30.0 and named instances in 0.30.1.
The
dns,dns-ovhanddns-godaddymanifests saycore: ">=0.30.0,<1.0.0", and their comments still call that floor a placeholder. - Live runs. The DNS servers are proven on their fakes; their live suites have never run against a
real account, and the
dnsplugin’s live eval cases have not run either. - Proof on a real cluster. Named instances and the profile’s console pages are tested against fakes and in a simulated browser; reaching a private range is tested with rendered policies, not a real Cilium.
- The agent form. An agent names a profile in its spec (YAML or API), and its page shows the entry; the console’s agent form has no profile picker.
- A provider’s server at an outpost (ADR 0224 §6b) is left to a later decision.
Go further
Section titled “Go further”- Profiles and providers: what an organisation installs and sees.
- Writing a plugin, the reference: the subset, the checks, calling a profile, named instances.
- ADR 0224, the decision and the alternatives it rejected.
- graalsystems/tranibor-agents, the
dnsprofile and its two providers in full.