Feature · Model Context Protocol
A Model Context Protocol client for PHP, TypeScript and Python. Discover and call server tools with explicit trust policies, definition pinning and bounded results.
For TypeScript, a server package registers and dispatches your own tools over a transport you supply.
Capabilities
01
Every server needs a trust policy. Without one, asking for its tools throws server_not_trusted and no tool is offered.
const github = new Client({
server: 'github',
transport: httpTransport(process.env.MCP_GITHUB_URL!),
trust: TrustPolicy.allowing(['search_repositories']),
});02
A pin records the digest of a tool definition you have reviewed. If the server later changes it, the tool is refused instead of being offered to the model.
03
Every result passes a guard before it reaches the model: one larger than the cap is refused, not truncated, and the text is framed as data.
04
Trust decides which tools the model is told about; a gate decides whether a given caller may run one, checked before each call is sent.
05
PHP names tools mcp__<server>__<tool>, so two servers can both publish search.
06
The server package registers tools and dispatches calls over a consumer-supplied transport, with a per-request visibility predicate that hides a tool from callers who should not see it.
How it fits
MCP tools are ordinary Prism tools in PHP, so they go straight into a text request. TypeScript and Python carry the protocol rules (trust, pins, gates, result guarding) and take a transport you supply.
The PHP package replaces prism-php/relay and cannot be installed alongside it.
Install
particle-academy/prism-mcp PHP
@particle-academy/prism-mcp TypeScript
@particle-academy/prism-mcp-server TypeScript · server
prism-ai-mcp Python
Related features
Agents in shared surfaces
Human+
An agent joins a live Fancy surface as a named participant, and confirmation stays with the human.
Durable agent sessions
Agent harness
Durable sessions, threads, modes, approvals and subagents with their own budgets, for agents that outlive a request.
Open-web automation
Guarded browser
Let an agent use a real browser within limits you set: hosts, actions, and how much of a page it may read.