framework-adapters

A guide for adding Dodo Payments checkout, customer-portal, and verified webhook routes to supported web frameworks. Webhooks are messages sent by a payment service when an event happens, such as a successful payment.

In plain words
What is it for?
Use it with Next.js, Express, Fastify, Hono, Astro, Remix, SvelteKit, Nuxt, TanStack, Bun, or Convex to mount checkout, customer-portal, and signed webhook routes.
Why use it?
It provides the framework-specific route setup and configuration needed to connect payment flows without writing those HTTP handlers from scratch.

Skill for Claude CodeCodex

Part of the dodopayments plugin — 17 skills, 2 MCP servers shipped together

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/dodopayments/dodo-agent-plugin/framework-adapters
Any agent
npx skills add dodopayments/dodo-agent-plugin --skill framework-adapters
Clone the repo
git clone --depth 1 https://github.com/dodopayments/dodo-agent-plugin

Made for: Claude Code, Codex.

Or install dodopayments, the plugin that ships this one along with the rest of its 17 skills, 2 MCP servers.

Per session 38 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 5,107 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 1 finding. Scan, not verified.
Origin 100% copy Near-identical to another mod in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00038 $0.05107
Opus 5 $0.00019 $0.02554
Sonnet 5 $0.00008 $0.01021
Haiku 4.5 $0.00004 $0.00511

Measured 3d ago against content hash 3bea9521afde, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

framework-adapters scanned grade A with 1 finding against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 3d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

fetch(request) {
Origin

This is a copy

100% identical to framework-adapters — 0 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

plugins/dodopayments/skills/framework-adapters/SKILL.md · 645 lines

How it starts

The opening of the file, as written. The whole thing — 645 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Framework Adapters

Use this skill when you need to integrate Dodo Payments into a web framework using the official adapter packages. Framework adapters handle route plumbing, environment configuration, and handler setup so you don't build checkout, portal, and webhook routes from scratch.

When to use this skill

  • You're building a checkout flow in Next.js, Express, Fastify, Hono, Astro, Remix, SvelteKit, Nuxt, TanStack, Bun, or Convex.
  • You need to set up a customer portal session endpoint.
  • You're adding webhook handlers that verify signatures and dispatch events.
  • You want framework-idiomatic route placement and environment variable handling.
  • You need to choose between static, dynamic, or session checkout modes.

What framework adapters do

Dodo publishes @dodopayments/* packages that wrap the core SDK with framework-specific route handlers. Instead of writing your own HTTP handlers, you import the adapter's handlers and mount them directly in your routes.

Each adapter exposes three handler families:

  • Checkout: static (GET only), dynamic (POST with cart), or session (POST with pre-built session).
  • CustomerPortal: generates a time-bound portal session link.
  • Webhooks: verifies webhook signatures and dispatches typed events.

Export names are not uniform across adapters. Most export Checkout / CustomerPortal / Webhooks, but two differ, and the return shapes differ as well. Check this table before writing imports:

Adapter Checkout export Portal export Handler shape
nextjs, hono, astro, bun, remix, tanstack Checkout CustomerPortal returns a request handler
express checkoutHandler (lowercase) CustomerPortal returns (req, res)
fastify Checkout CustomerPortal returns { getHandler, postHandler }
sveltekit Checkout CustomerPortal returns { GET, POST } / { GET }
nuxt checkoutHandler (auto-imported) customerPortalHandler no import statement
convex DodoPayments component createDodoWebhookHandler

Read the full file on GitHub · 645 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 3d ago First seen · 645 lines · 38 tokens per session scan A 3bea9521afde

Subscribe to this mod's changes

framework-adapters is a skill published in the GitHub repository dodopayments/dodo-agent-plugin (6 stars, last pushed 9d ago), licensed MIT. It adds 38 tokens to every session and 5,107 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it A with 1 finding (makes network calls). It is 100% identical to framework-adapters, differing in 0 lines, and is treated as a copy.

Related

Other skills, from other repositories

cmux-billing

Stripe checkout, pricing, subscription, Pro plan, webhook, and entitlement runbook for cmux billing work. Use when editing or debugging billing, pricing, Stripe Checkout, subscription recording, Pro plan status, webhooks, entitlement metadata, or pricing dev/prod tooling.

manaflow-ai/cmux · 59 tokens

opencode-ensemble

Use when coordinating multiple coding agents, delegating independent software work, managing OpenCode Ensemble teams, choosing teammate roles or models, reviewing teammate output, or deciding whether parallel execution is appropriate.

hueyexe/opencode-ensemble · 42 tokens

ce:plan

Create structured plans for any multi-step task -- software features, research workflows, events, study plans, or any goal that benefits from structured breakdown. Also deepen existing plans with interactive review of sub-agent findings. Use for plan creation when the user says 'plan this', 'create a plan', 'write a…

marcusrbrown/systematic · 152 tokens

ce:review

Structured code review using tiered persona agents, confidence-gated findings, and a merge/dedup pipeline. Use when reviewing code changes before creating a PR.

marcusrbrown/systematic · 36 tokens

ce:compound-refresh

Refresh stale or drifting learnings and pattern docs in docs/solutions/ by reviewing, updating, consolidating, replacing, or deleting them against the current codebase. Use after refactors, migrations, dependency upgrades, or when a retrieved learning feels outdated or wrong. Also use when reviewing docs/solutions/…

marcusrbrown/systematic · 105 tokens

ce:compound

Document a recently solved problem to compound your team's knowledge.

marcusrbrown/systematic · 14 tokens