Core tool

Search the shared corpus of compiled flows

Semantic search over the cross-tenant library of sanitized skill scaffolds, by intent and host — metadata only, no credentials, no private data.

search_library

What it is

The job: Find out whether somebody has already solved this shape of task on this host.

Every compiled skill is also, in sanitized form, a scaffold: the shape of a flow on a host, stripped of the values, credentials and tenant identity that made it somebody’s. search_library queries that corpus by free-form intent, optionally scoped to a host.

What you get back is metadata you can reason about — not a runnable path from another tenant’s account. The corpus is used for real by dispatch, which can seed a compile from a matching scaffold (the `cache-adapt` mode) and hand you your own verified path at the end of it. search_library is the read-only window onto the same data.

It talks to the web API rather than the execution engine, because the corpus lives in the platform database.

The call

Call it exactly like this.

Copied from the tool's registration and the route handler — not paraphrased.

MCPsearch_library.mcp.jsonjson
// MCP tool call — server "twin-browser"
{
  "tool": "search_library",
  "arguments": {
    "query": "log in and export invoices as CSV",
    "host": "app.example.com",
    "k": 5
  }
}
POST /api/v1/libraryrequest.shbash
curl -X POST https://twin-browser.com/api/v1/library \
  -H "Authorization: Bearer $TWIN_API_KEY" \
  -H "content-type: application/json" \
  -d '{"query":"log in and export invoices as CSV","host":"app.example.com","k":5}'
Parameters accepted by search_library
ParameterTypeWhat it does
query*stringFree-form intent to search for, e.g. "log in and export invoices as CSV".
hoststringOptional host or URL to scope the search. Omit to search every host.
knumberMax results. Default 10, max 25.
minScorenumberSimilarity floor, 0..1. Default 0.7 — raise it when you only want near-exact matches.

Returns

response.jsonjson
{ "results": [ { "name": "…", "host": "…", "goal": "…", "score": 0.83, … } ] }

What it costs

Free

A read against the shared corpus. No credits are reserved or charged; the call is recorded in your audit log for traceability.

See the full rate card

Which one

When a different tool is the right call.

The honest answer is often the neighbouring tool. These are the trades.

dispatch

dispatch is what actually uses the corpus — it will seed a compile from a matching scaffold without you searching first. Use search_library when you want to look before you spend, or to understand what coverage exists on a host.

dispatch
list_catalog

Catalog is your own skills with full contracts; the library is everyone’s, sanitized to scaffolds. You can run the first directly and only adapt the second.

list_catalog

Questions

search_library, answered.

Can another tenant see my compiled skills?
They can see a sanitized scaffold — the shape of the flow on a public host — and never the values, credentials, parameters or identity attached to your version of it. The invariant is simple: you replay your own skills, and you can only adapt everyone else’s.