mpp-setup

Scaffold an MPP project — install mppx SDK, configure payment methods, set up server middleware, and create a basic paid API endpoint. Use when starting a new MPP machine payments project from scratch.

17 stars

Best use case

mpp-setup is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Scaffold an MPP project — install mppx SDK, configure payment methods, set up server middleware, and create a basic paid API endpoint. Use when starting a new MPP machine payments project from scratch.

Teams using mpp-setup should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/mpp-setup/SKILL.md --create-dirs "https://raw.githubusercontent.com/OrcaQubits/agentic-commerce-skills-plugins/main/dist/antigravity/stripe-mpp/.agent/skills/mpp-setup/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/mpp-setup/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How mpp-setup Compares

Feature / Agentmpp-setupStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Scaffold an MPP project — install mppx SDK, configure payment methods, set up server middleware, and create a basic paid API endpoint. Use when starting a new MPP machine payments project from scratch.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

# MPP Project Setup

## Before writing code

**Fetch live docs**:
1. Fetch `https://www.npmjs.com/package/mppx` for the latest mppx SDK version, installation, and API surface
2. Web-search `site:github.com stripe-samples machine-payments` for the official sample project structure
3. Fetch `https://docs.stripe.com/payments/machine` for Stripe machine payments setup requirements
4. Web-search `site:mpp.dev overview` for the current protocol overview and getting started guide

## What This Skill Does

Scaffolds a new MPP project for monetizing HTTP services with machine payments:

1. **Detect language/framework** — TypeScript (Hono/Express/Next.js/Elysia), Python (FastAPI/Flask), or Rust
2. **Install SDK** — `npm install mppx` (TypeScript), `pip install pympp` (Python), or check mpp.dev for the Rust crate
3. **Create configuration** — Environment variables for secret key, payment method settings, Stripe keys
4. **Set up server middleware** — `Mppx.create()` with payment method configuration
5. **Create a paid endpoint** — Basic route protected by `mppx.charge()` middleware
6. **Add service discovery** — `GET /openapi.json` with `x-payment-info` extensions
7. **Set up client (optional)** — `mppx.fetch()` for consuming paid APIs

## Environment Configuration

These must be externalized (env vars or config file):
- `MPP_SECRET_KEY` — 32-byte hex key for HMAC challenge binding (generate with `openssl rand -hex 32`)
- `STRIPE_SECRET_KEY` — If using Stripe payment method
- `TEMPO_RECIPIENT_ADDRESS` — Wallet address for receiving Tempo payments
- `TEMPO_CHAIN_ID` — `4217` for Tempo mainnet
- `TEMPO_USDC_CONTRACT` — `0x20c000000000000000000000b9537d11c60e8b50` for USDC on Tempo

## Project Structure Pattern

```
my-mpp-service/
├── src/
│   ├── index.ts              # Server entry point with Mppx middleware
│   ├── routes/
│   │   ├── paid.ts           # Payment-protected endpoints
│   │   └── free.ts           # Free/health endpoints
│   ├── config.ts             # MPP and payment method configuration
│   └── openapi.ts            # Service discovery endpoint
├── .env                      # Secrets (MPP_SECRET_KEY, STRIPE_SECRET_KEY)
├── package.json
├── tsconfig.json
└── tests/
    └── payment.test.ts
```

## Key Setup Decisions

- **Payment method** — Tempo (crypto, sub-second), Stripe (cards via SPT), Lightning, or multiple
- **Payment intent** — Charge (one-time per request) or Session (streaming micropayments)
- **Framework** — Hono (recommended, lightweight), Express, Next.js, or Elysia
- **Pricing model** — Fixed per-request, dynamic based on payload, or session-based streaming

## Quick Start Pattern (Hono + Tempo)

```typescript
import { Hono } from 'hono';
import { Mppx, tempo } from 'mppx/server';

const mppx = Mppx.create({
  secretKey: process.env.MPP_SECRET_KEY,
  methods: [
    tempo.charge({
      chainId: 4217,
      currency: '0x20C000000000000000000000b9537d11c60E8b50',
      recipient: process.env.TEMPO_RECIPIENT_ADDRESS,
    }),
  ],
});

const app = new Hono();
app.get('/api/data', mppx.charge({ amount: '100' }), (c) => {
  return c.json({ data: 'premium content' });
});
```

Fetch the latest mppx README and Stripe machine payments docs for exact SDK API, current payment method configuration options, and framework-specific setup before scaffolding.

Related Skills

woo-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Install WooCommerce, configure the development stack, and set up a local dev environment with WP-CLI, Docker, or wp-env. Use when setting up a new WooCommerce project or development environment.

webmcp-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a WebMCP project — enable Chrome flags, install MCP-B polyfill, scaffold tool registration, and configure development environment. Use when starting a new WebMCP-enabled website from scratch.

ucp-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a UCP project — scaffold a merchant server or platform client with discovery profile, SDK installation, and project structure. Use when starting a new UCP implementation.

spree-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Bootstrap a new Spree project — `create-spree-app` CLI (v5.2+), `spree-starter` Rails backend, the Next.js storefront repo, `bin/rails g spree:install`, sample data, Docker Compose, and the PostgreSQL + Redis + Sidekiq prerequisites. Use when starting a new Spree project from scratch or onboarding an existing repo.

shopify-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a Shopify development environment — Shopify CLI installation, Partner account, development stores, environment variables, project structures for themes, apps, and Hydrogen. Use when starting a new Shopify project.

sf-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a Salesforce Commerce development environment — sfcc-ci CLI for B2C, sf CLI for B2B, Business Manager access, sandbox management, dw.json configuration, .sfdx project setup, and project structures for SFRA, PWA Kit, and Lightning. Use when starting a new Salesforce Commerce project.

saleor-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a Saleor development environment — saleor-platform Docker Compose, CLI, PostgreSQL/Redis prerequisites, manage.py commands, environment variables, project structure. Use when starting a new Saleor project.

nlweb-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Bootstrap a local NLWeb development environment from scratch — clone the repo, configure .env, install Python deps via `nlweb init-python`, run `nlweb init` for interactive LLM/retrieval selection, load sample Schema.org data, and verify with `nlweb check`. Use when starting a new NLWeb deployment from zero.

medusa-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a Medusa v2 development environment — CLI, PostgreSQL/Redis prerequisites, project creation, medusa-config.ts, directory structure, environment variables. Use when starting a new Medusa project.

magento-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a Magento 2 Open Source project — installation, Composer setup, system requirements verification, and initial configuration. Use when starting a new Magento project or setting up a development environment.

bc-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Set up a BigCommerce development environment — Stencil CLI, API credentials, sandbox stores, Catalyst, and developer tools. Use when starting a new BigCommerce project or configuring development tools.

ap2-setup

17
from OrcaQubits/agentic-commerce-skills-plugins

Scaffold a new AP2 project — install the SDK, set up agent roles, configure credentials, and create a basic multi-agent payment system. Use when starting a new AP2 agentic payments project from scratch.