UNPKG

spaps

Version:

Sweet Potato Authentication & Payment Service CLI - Zero-config local development with built-in admin middleware and permission utilities

115 lines (113 loc) 3.2 kB
{ "name": "spaps", "version": "0.1.0", "description": "Auth + payments via SPAPS (local by default). Start with: npx spaps local", "base_url": "http://localhost:3300", "auth": { "local_mode": true, "production": { "header": "X-API-Key", "env": "SPAPS_API_KEY" } }, "tools": [ { "name": "login", "description": "Login with email/password. Local mode accepts any values.", "method": "POST", "path": "/api/auth/login", "parameters": { "type": "object", "required": ["email", "password"], "properties": { "email": { "type": "string" }, "password": { "type": "string" } } } }, { "name": "register", "description": "Register a new user with email/password.", "method": "POST", "path": "/api/auth/register", "parameters": { "type": "object", "required": ["email", "password"], "properties": { "email": { "type": "string" }, "password": { "type": "string" } } } }, { "name": "get_current_user", "description": "Get the currently authenticated user.", "method": "GET", "path": "/api/auth/user", "parameters": { "type": "object", "properties": { "authorization": { "type": "string", "description": "Bearer <access_token>" } } } }, { "name": "create_checkout_session", "description": "Create a Stripe Checkout session.", "method": "POST", "path": "/api/stripe/checkout-sessions", "parameters": { "type": "object", "required": ["success_url", "cancel_url"], "properties": { "price_id": { "type": "string" }, "product_name": { "type": "string" }, "amount": { "type": "number" }, "currency": { "type": "string", "default": "usd" }, "success_url": { "type": "string" }, "cancel_url": { "type": "string" } } } }, { "name": "list_products", "description": "List products (Stripe-backed or local).", "method": "GET", "path": "/api/stripe/products", "parameters": { "type": "object", "properties": { "active": { "type": "boolean" }, "limit": { "type": "number" } } } }, { "name": "request_magic_link", "description": "Send a magic link for passwordless login (simulated locally).", "method": "POST", "path": "/api/auth/magic-link", "parameters": { "type": "object", "required": ["email"], "properties": { "email": { "type": "string" } } } }, { "name": "get_wallet_nonce", "description": "Get a nonce to sign for wallet authentication.", "method": "POST", "path": "/api/auth/nonce", "parameters": { "type": "object", "required": ["wallet_address"], "properties": { "wallet_address": { "type": "string" }, "chain_type": { "type": "string", "enum": ["solana", "ethereum", "bitcoin", "base"] } } } } ] }