Skip to main content
Glama
README.md
# ๐Ÿš€ LaunchOps - Autonomous Developer Teammate & B2B Micro-SaaS Procurement Engine

> **Everything between "I built it" and "it is live."**  
> Powered by Model Context Protocol (MCP) tool orchestration & Prava Virtual Visa Payment Rails ($100 Mandate).  
> ๐ŸŒ **Live Web App**: [https://launchops-hackathon.vercel.app/](https://launchops-hackathon.vercel.app/)  

---

## โšก The Problem & Solution

### Problem
AI coding assistants (Claude Code, OpenCode, Cursor) generate software in seconds. But the moment an agent needs a cloud database, hosting, custom domain, or API usage credits, automation stops dead at the checkout counter:
- **No Payment Authority**: Giving an AI agent an uncapped corporate credit card risks a $10,000 runaway bill from infinite loops or trial traps.
- **Fragmented Context**: Withholding payment authority forces developers back into 8 different vendor dashboards to enter credit cards, run SQL migrations, and copy secrets by hand.

### Solution
LaunchOps serves as a **controlled purchasing layer** between coding agents and SaaS vendors. Powered by Model Context Protocol (MCP) tool orchestration and governed by **Prava Virtual Visa Cards**, LaunchOps turns a half-day manual procurement chore into a single-approval automated launch:
1. **One-Command Connect**: Zero API keys or signup required for judges (`opencode mcp add launchops --url https://launchops-hackathon.vercel.app/api/mcp`).
2. **Natural Language Requests**: Ask your agent `@launchops setup database for myapp with $15 budget`.
3. **Owner Approval Gate**: Converts requests into purchase plans requiring biometric Touch ID / Passkey approval before any money moves.
4. **Single-Use Visa Cards**: Prava issues merchant-scoped cards that **auto-freeze to $0 balance post-settlement**, making runaway charges impossible.
5. **Real Infrastructure Provisioning**: Provisions real Supabase Postgres 16 databases, runs SQL migrations, configures RLS security policies, and automatically writes `DATABASE_URL` credentials to `.env.local`.

---

## ๐Ÿ”Œ 1-Command MCP Connection (Claude Code / OpenCode / Cursor)

LaunchOps runs a remote WebStandard Streamable HTTP MCP server at `https://launchops-hackathon.vercel.app/api/mcp` as well as a native local Stdio MCP server (`bin/mcp-server.ts`).

### Quick Add (Remote MCP โ€” Recommended)

#### Claude Code
```bash
claude mcp add launchops --transport http https://launchops-hackathon.vercel.app/api/mcp
```

#### OpenCode
```bash
opencode mcp add launchops --url https://launchops-hackathon.vercel.app/api/mcp
```

#### Cursor
- Settings โž” MCP โž” Add Server โž” URL: `https://launchops-hackathon.vercel.app/api/mcp`

---

## ๐Ÿ’ฌ 4-Step Quick Start Flow (In Your IDE)

Once connected, execute this workflow in your AI assistant chat:

1. **Authenticate via GitHub SSO**:
   ```text
   LaunchOps login
   ```
   *Follow the returned GitHub OAuth URL to sign in and get your token.*

2. **Request Infrastructure**:
   ```text
   Use LaunchOps to set up a production database for myapp with a $15 budget
   ```
   *LaunchOps generates a Prava payment session and returns a checkout URL.*

3. **Approve Payment**:
   Open the checkout URL in your browser and use the Prava sandbox test credentials:
   - **Card Number**: `4622943123232291`
   - **Expiry**: `12/30` | **CVV**: `867` | **OTP**: `456789`

4. **Confirm & Claim Infrastructure**:
   ```text
   Confirm the database for session <session_id>
   ```
   *LaunchOps verifies payment, provisions PostgreSQL 16 on Supabase, applies schema/RLS, and syncs connection strings.*

---

## ๐Ÿ› ๏ธ Exposed MCP Tools

The LaunchOps MCP server exposes 13 tools across remote and local transports:

| Tool Name | Purpose | Inputs |
| :--- | :--- | :--- |
| `launchops_login` | Day 0 GitHub SSO OAuth authentication & session token check | `secretKey?`, `sessionToken?` |
| `launchops_auth_status` | Returns active vendor connection status & budget summary | *(none)* |
| `launchops_setup_database` | Creates Prava payment session & prepares Supabase Postgres 16 DB | `domain`, `appName?`, `amount?` |
| `launchops_confirm_database` | Polls payment approval & provisions real database, schema & RLS | `sessionId`, `domain`, `appName?` |
| `launchops_claim_database` | Transfers root ownership & returns connection credentials | `sessionId` |
| `launchops_topup_api_credits` | Programmatically tops up API credits (Resend, OpenAI, Anthropic) | `vendor`, `amount?` |
| `launchops_deploy_vercel` | Deploys preview environments to Vercel & syncs secrets | `appName`, `domain?` |
| `launchops_generate_brand` | Synthesizes Recraft V4 Pro SVG logo, favicon & OG cards into `./public/` | `domain`, `appName?` |
| `launchops_package_devfolio` | Auto-packages Devfolio submission markdown & architecture SVG | `domain`, `appName?` |
| `launchops_buy_domain` | Registers custom TLD via Namecheap/Porkbun API & sets Cloudflare DNS | `domain` |
| `launchops_get_budget` | Returns Prava $100 budget governance audit log | *(none)* |
| `launchops_get_payment_result` | Queries Prava sandbox transaction settlement status | `sessionId` |
| `launchops_report_payment_status` | Reports payment outcome back to Prava network ledger | `sessionId`, `txnRefId`, `status` |

---

## ๐Ÿ’ณ Prava SDK & $100 Budget Governance

All financial operations are governed by Prava Payments (`@prava-sdk/core`):
- **Workspace Cap**: Hard limit of **$100.00 USD** per workspace execution.
- **Single-Use Virtual Cards**: Generates merchant-scoped Visa virtual cards (`4622943123232291`).
- **Auto-Freeze Protection**: Post-settlement, virtual card balances freeze to $0, preventing surprise auto-renewals.
- **Enforceable Boundaries**: Upgrades exceeding approved session limits fail with:  
  `Prava Authorization Limit Violation: Requested $25.00 exceeds pre-approved single-use card limit ($15.00)`.

---

## ๐Ÿงช Local Setup, Testing & Demo App

### Clone & Install
```bash
git clone https://github.com/piyushagarwal-55/launchops-hackathon.git
cd launchops-hackathon
npm install
```

### Run Vitest Test Suite (40/40 Passing)
```bash
npm run test
```

### Quota-Safe Prava Sandbox E2E Harness
```bash
# Verify stdio MCP tools
npm run prava:e2e -- list

# Create a single live test session
PRAVA_E2E_CONFIRM=CREATE_ONE_PRAVA_SESSION npm run prava:e2e -- create
```

### Run FeedbackKit Demo App
```bash
cd feedbackkit-app
npm install
npm run dev
```
Open [http://localhost:3001](http://localhost:3001) to view the live demo app.

---

## ๐Ÿ“œ License
Licensed under the MIT License. Prava Payments integration compliant with PCI DSS tokenization standards.