From 88f3be1d35f60c10f43aeea71c7af9af637c96e7 Mon Sep 17 00:00:00 2001
From: Brendan Ryan <1572504+brendanjryan@users.noreply.github.com>
Date: Wed, 8 Jul 2026 21:36:31 -0700
Subject: [PATCH] docs: improve agentic discovery score
---
public/.well-known/agent-skills/index.json | 2 +-
public/.well-known/agent-skills/mppx/SKILL.md | 36 ++++-
public/.well-known/api-catalog | 10 ++
public/AGENTS.md | 34 +++++
public/agent-permissions.json | 36 +++++
public/agent.html | 96 ++++++++++++
skills/mppx/SKILL.md | 36 ++++-
src/env.d.ts | 10 ++
.../.well-known/agent-skills/mppx/SKILL.md.ts | 16 ++
src/pages/_api/.well-known/api-catalog.ts | 1 +
src/pages/_api/AGENTS.md.ts | 16 ++
src/pages/_api/agent-permissions.json.ts | 16 ++
src/pages/_api/api/api-catalog.ts | 10 ++
src/pages/_api/api/openapi.json.ts | 2 +
src/pages/_root.css | 5 +-
src/pages/blog/evm-x402-support.mdx | 1 +
src/pages/blog/go-and-ruby-sdks.mdx | 1 +
src/pages/blog/index.mdx | 1 +
src/pages/blog/multi-method-discovery.mdx | 1 +
src/pages/blog/payment-hooks.mdx | 1 +
src/pages/blog/sessions-improved.mdx | 1 +
src/pages/blog/subscriptions.mdx | 1 +
src/pages/services.mdx | 1 +
vercel.ts | 12 ++
vite.config.ts | 142 ++++++++++++++++++
25 files changed, 476 insertions(+), 12 deletions(-)
create mode 100644 public/AGENTS.md
create mode 100644 public/agent-permissions.json
create mode 100644 public/agent.html
create mode 100644 src/pages/_api/.well-known/agent-skills/mppx/SKILL.md.ts
create mode 100644 src/pages/_api/.well-known/api-catalog.ts
create mode 100644 src/pages/_api/AGENTS.md.ts
create mode 100644 src/pages/_api/agent-permissions.json.ts
diff --git a/public/.well-known/agent-skills/index.json b/public/.well-known/agent-skills/index.json
index 599b7111..3a6c3fb0 100644
--- a/public/.well-known/agent-skills/index.json
+++ b/public/.well-known/agent-skills/index.json
@@ -6,7 +6,7 @@
"type": "skill-md",
"description": "TypeScript SDK for the Payment HTTP Authentication Scheme. Handles 402 Payment Required flows with Tempo, Stripe, and other payment methods. Use when integrating payments or mppx into a client or server application.",
"url": "/.well-known/agent-skills/mppx/SKILL.md",
- "digest": "sha256:9520d231fd7ae64ce54c8176e870a36d758c272748ceeadc7a3a8d23c2b8a5ce"
+ "digest": "sha256:45039f241e97036627d9cf2b2864408fa6b6afb70faf7f0001ffc8eb5ceaece6"
}
]
}
diff --git a/public/.well-known/agent-skills/mppx/SKILL.md b/public/.well-known/agent-skills/mppx/SKILL.md
index a282fc68..22955079 100644
--- a/public/.well-known/agent-skills/mppx/SKILL.md
+++ b/public/.well-known/agent-skills/mppx/SKILL.md
@@ -7,6 +7,32 @@ description: TypeScript SDK for the Payment HTTP Authentication Scheme. Handles
TypeScript SDK for the "Payment" HTTP Authentication Scheme. Full 402 flow: challenge → credential → receipt.
+## What I can accomplish
+
+- Add `402` payment handling to a client with `Fetch.polyfill` or `Fetch.from`.
+- Protect HTTP routes with server-side MPP Challenges and Receipt responses.
+- Accept one-time Tempo stablecoin payments with `tempo.charge`.
+- Accept metered Tempo stablecoin payments with `tempo.session`.
+- Accept one-time card payments with `stripe.charge`.
+- Verify Credentials directly for custom transports or background workflows.
+- Wrap MCP clients and servers so tool calls can require payment.
+
+## Required inputs
+
+- Client integrations need a signing account and one or more client payment methods.
+- Server integrations need a recipient, currency, amount, and `MPP_SECRET_KEY`.
+- Tempo examples use chain ID `4217` unless a page explicitly covers Moderato testnet.
+- Stripe examples need a configured Stripe account and Shared Payment Token flow.
+- MCP integrations need the MCP client or server object to wrap.
+
+## Constraints
+
+- Keep `MPP_SECRET_KEY` server-side and out of logs.
+- Never commit private keys or wallet seeds.
+- Treat runtime `402` Challenges as authoritative for current payment terms.
+- Return `id` and `opaque` unchanged when responding to a Challenge.
+- Use `USDC.e` for Tempo bridged USDC examples, not generic USDC.
+
## Client
```ts
@@ -82,7 +108,9 @@ npx mppx example.com -v # verbose output
## References
-- Docs: https://mpp.dev/sdk/typescript
-- Repo: https://github.com/wevm/mppx
-- Spec: https://github.com/tempoxyz/payment-auth-spec
-- Tempo: https://docs.tempo.xyz
+- [TypeScript SDK docs](https://mpp.dev/sdk/typescript)
+- [Client quickstart](https://mpp.dev/quickstart/client)
+- [Server quickstart](https://mpp.dev/quickstart/server)
+- [mppx repository](https://github.com/wevm/mppx)
+- [IETF Specification](https://paymentauth.org)
+- [Tempo docs](https://docs.tempo.xyz)
diff --git a/public/.well-known/api-catalog b/public/.well-known/api-catalog
index a022c315..2917b179 100644
--- a/public/.well-known/api-catalog
+++ b/public/.well-known/api-catalog
@@ -24,6 +24,11 @@
"href": "https://mpp.dev/guides/building-with-an-llm",
"title": "Build with an LLM",
"type": "text/html"
+ },
+ {
+ "href": "https://mpp.dev/AGENTS.md",
+ "title": "Agent instructions",
+ "type": "text/markdown"
}
],
"status": [
@@ -38,6 +43,11 @@
"href": "https://mpp.dev/.well-known/agent-skills/index.json",
"title": "Agent Skills discovery index",
"type": "application/json"
+ },
+ {
+ "href": "https://mpp.dev/agent-permissions.json",
+ "title": "Agent permissions",
+ "type": "application/json"
}
]
}
diff --git a/public/AGENTS.md b/public/AGENTS.md
new file mode 100644
index 00000000..4a175957
--- /dev/null
+++ b/public/AGENTS.md
@@ -0,0 +1,34 @@
+# MPP documentation
+
+Use this site to integrate MPP, the Machine Payments Protocol for HTTP `402` payment flows.
+
+## Start here
+
+- Read [`llms.txt`](https://mpp.dev/llms.txt) for a concise page index.
+- Read [`llms-full.txt`](https://mpp.dev/llms-full.txt) when you need the full documentation in one request.
+- Use [`/.well-known/mcp.json`](https://mpp.dev/.well-known/mcp.json) to connect to the MPP documentation MCP server.
+- Use [`/.well-known/agent-skills/index.json`](https://mpp.dev/.well-known/agent-skills/index.json) to discover agent skills.
+
+## Main tasks
+
+- Add payments to an API with [`mppx`](https://mpp.dev/quickstart/server).
+- Connect a coding agent to paid APIs with [`mppx`](https://mpp.dev/quickstart/agent).
+- Use the TypeScript SDK reference at [`/sdk/typescript`](https://mpp.dev/sdk/typescript).
+- Browse paid services at [`/services`](https://mpp.dev/services).
+
+## Project structure
+
+- Documentation pages live under `/assets/md/` as Markdown mirrors.
+- Agent skills live under `/.well-known/agent-skills/`.
+- API discovery files live under `/.well-known/` and `/api/`.
+- Service catalog files live under `/services/`.
+
+## Protocol terms
+
+MPP uses a Challenge, Credential, and Receipt flow:
+
+- Servers return Challenges in `WWW-Authenticate`.
+- Clients return Credentials in `Authorization`.
+- Servers return Receipts in `Payment-Receipt`.
+
+Prefer Tempo stablecoin examples unless a page is specifically about another payment method.
diff --git a/public/agent-permissions.json b/public/agent-permissions.json
new file mode 100644
index 00000000..c9da129a
--- /dev/null
+++ b/public/agent-permissions.json
@@ -0,0 +1,36 @@
+{
+ "$schema": "https://mpp.dev/schemas/agent-permissions.schema.json",
+ "agentUserAgents": ["ChatGPT-User", "ClaudeBot", "GPTBot", "PerplexityBot"],
+ "allowedActions": [
+ "read-documentation",
+ "read-discovery",
+ "read-openapi",
+ "read-skill"
+ ],
+ "allowedPaths": [
+ "/",
+ "/.well-known/*",
+ "/AGENTS.md",
+ "/agent-permissions.json",
+ "/api/api-catalog",
+ "/api/openapi.json",
+ "/assets/md/*",
+ "/llms-full.txt",
+ "/llms.txt",
+ "/services/llms.txt"
+ ],
+ "disallowedActions": ["execute-payment", "submit-credential", "write-data"],
+ "humanRequiredActions": [
+ "execute-payment",
+ "send-transaction",
+ "store-private-key"
+ ],
+ "permissions": {
+ "read": true,
+ "write": false
+ },
+ "rateLimits": {
+ "burst": 60,
+ "period": "1m"
+ }
+}
diff --git a/public/agent.html b/public/agent.html
new file mode 100644
index 00000000..5f8ec41a
--- /dev/null
+++ b/public/agent.html
@@ -0,0 +1,96 @@
+
+
+
+
+
+ MPP agent index
+
+
+
+
+
+
+
+
+
MPP agent index
+
+ Use this page as the compact HTML entry point for agents integrating
+ MPP, mppx, or HTTP 402 payment flows. It links to the canonical
+ Markdown, skill, permissions, and API discovery documents.
+
Linkset discovery for docs, OpenAPI, skills, and metadata.
+
+
+
+
+
+
+
Recommended flow
+
+ Start with llms.txt, fetch the smallest
+ Markdown page that answers the task, then use the skill and API
+ catalog only when you need integration details or machine-readable
+ endpoints.
+
+ Documentation pages expose clean Markdown mirrors under
+ /assets/md/. Use the Copy for AI control in the page UI
+ or fetch the Markdown directly.
+