Cursor integration

Build in Cursor. Share with the team instantly.

Add a few .cursor/rules/ files and Cursor knows how to structure, deploy, and register prototypes on VibeSharing — so the team always sees the latest work.

What Cursor rules are

Rules are .mdc files in your project that give Cursor persistent context about how you work. They survive between sessions and guide the AI to follow your team's patterns. Live in .cursor/rules/, committed to git so the whole team benefits.

What the rules give you

  1. 01

    One-step deploy

    Tell Cursor to deploy and the rules guide it through the VibeSharing API automatically.

  2. 02

    Consistent structure

    Rules enforce the team's prototype patterns: self-contained pages, inline mock data, the styling stack you actually use.

  3. 03

    Context that travels

    Rules prompt Cursor to keep CLAUDE.md updated and synced to VibeSharing after each session.

  4. 04

    Team feedback loop

    Once registered, the team sees the prototype instantly and leaves structured feedback right on the page.

Quick start

01

Get a deploy token

Sign up at VibeSharing and copy the token from Account Settings.

Get your token →
02

Add rule files to your project

Create a .cursor/rules/ directory and add the rules below. Commit them to git.

mkdir -p .cursor/rules
03

Optional — connect MCP for direct API access

Cursor supports MCP servers. Add this to .cursor/mcp.json for tools like deploy_prototype, get_feedback, and sync_context:

{
  "mcpServers": {
    "vibesharing": {
      "command": "npx",
      "args": ["-y", "@vibesharingapp/mcp-server"],
      "env": {
        "VIBESHARING_TOKEN": "vs_your_token"
      }
    }
  }
}
04

Build something

Cursor now knows the project conventions and how to deploy to VibeSharing. Just ask it to deploy when ready to share.

Starter rules

Copy these into your .cursor/rules/ directory. Customize them for the team's stack and conventions.

.cursor/rules/vibesharing-deploy.mdc

Cursor pulls this in when you ask to deploy, share, or register a prototype.

---
description: "How to deploy and register prototypes on VibeSharing"
alwaysApply: false
---

# VibeSharing Deployment

When asked to deploy, share, or register a prototype:

## Requirements
- VIBESHARING_DEPLOY_TOKEN env variable (or user provides token inline)
- A prototype ID from vibesharing.app (ask the user if not provided)

## Deploy Process

1. Collect all source files from the app/ directory
2. Build a JSON files array with each file's path and content
3. POST to the deploy-code API:

```bash
curl -X POST "https://vibesharing.app/api/prototypes/PROTOTYPE_ID/deploy-code" \
  -H "Authorization: Bearer $VIBESHARING_DEPLOY_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "files": [
      {"path": "app/page.tsx", "content": "...file contents..."},
      {"path": "app/layout.tsx", "content": "...file contents..."}
    ],
    "commitMessage": "Deploy from Cursor"
  }'
```

4. Report the returned deployUrl and repoUrl to the user

## Response fields
- deployUrl: Live URL (e.g. https://vs-myprototype-abc123.vercel.app)
- repoUrl: GitHub repo URL
- commitSha: Git commit reference

## Important
- Do NOT zip files or use the /api/deploy/zip endpoint
- Do NOT deploy to Vercel directly — use the deploy-code API
- Include all files needed to run the prototype (pages, components, styles)
- After deploying, update CLAUDE.md with what was built
.cursor/rules/context-handoff.mdc

Activates when editing CLAUDE.md. Guides context structure for team handoff.

---
description: "Rules for maintaining CLAUDE.md for session handoff"
globs: ["CLAUDE.md"]
alwaysApply: false
---

# CLAUDE.md Context Management

Update CLAUDE.md at the end of each session or before deploying.

## Required sections
1. **Current State** — What version, last updated
2. **What Was Built** — Changes this session
3. **Key Decisions** — Why things were done this way
4. **Known Issues** — Bugs or incomplete items
5. **Next Steps** — What to work on next

Keep it under 300 lines. This file is auto-imported by VibeSharing
when deployed, so your team sees the context alongside the prototype.
.cursor/rules/prototype-structure.mdc

Enforces consistent prototype patterns when editing page files.

---
description: "How to structure prototype code for easy sharing"
globs: ["app/**/page.tsx"]
alwaysApply: false
---

# Prototype Structure

- Keep each prototype in a single page.tsx when possible
- Use inline mock data (no external API dependencies)
- Tailwind CSS only — no CSS modules
- Dark theme: bg-gray-950, text-white, border-white/10
- Mock data as constants at top of file
- Sub-components inline in same file
- Export default function as the page component

Also optimized for Claude Code

VibeSharing has a dedicated MCP server for Claude Code with direct terminal integration. Register prototypes, check feedback, and sync context without leaving the conversation.

Claude Code setup →

Your rules. Your workflow. Your team's hub.

Add the rules, build the prototype, and share — all from Cursor.

Get started free