@brander/mcp-demo 0.1.9 → 0.1.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +48 -63
- package/package.json +2 -2
package/README.md
CHANGED
|
@@ -1,33 +1,27 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @brander/mcp-demo
|
|
2
2
|
|
|
3
|
-
A
|
|
3
|
+
A demo MCP server showcasing [BranderUX](https://branderux.com) branded UI rendering inside AI chatbots. Uses [`@brander/mcp-tools`](https://www.npmjs.com/package/@brander/mcp-tools) to render interactive, branded UI components directly in conversations on Claude, ChatGPT, and other MCP-compatible hosts.
|
|
4
4
|
|
|
5
|
-
|
|
5
|
+
## Connect
|
|
6
6
|
|
|
7
|
-
|
|
7
|
+
### Claude.ai / ChatGPT (Remote)
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
# Clone the repo
|
|
11
|
-
git clone https://github.com/BranderUX/mcp-demo.git
|
|
12
|
-
cd mcp-demo
|
|
9
|
+
Use the hosted URL — no installation needed:
|
|
13
10
|
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
# Build
|
|
18
|
-
npm run build
|
|
11
|
+
```
|
|
12
|
+
https://mcp-demo.branderux.com/mcp
|
|
19
13
|
```
|
|
20
14
|
|
|
21
|
-
|
|
15
|
+
### Claude Desktop (Local)
|
|
22
16
|
|
|
23
|
-
Add
|
|
17
|
+
Add to your config (`~/Library/Application Support/Claude/claude_desktop_config.json`):
|
|
24
18
|
|
|
25
19
|
```json
|
|
26
20
|
{
|
|
27
21
|
"mcpServers": {
|
|
28
|
-
"
|
|
29
|
-
"command": "
|
|
30
|
-
"args": ["/
|
|
22
|
+
"branderux-demo": {
|
|
23
|
+
"command": "npx",
|
|
24
|
+
"args": ["-y", "@brander/mcp-demo"],
|
|
31
25
|
"env": {
|
|
32
26
|
"BRANDER_PROJECT_ID": "your_project_id",
|
|
33
27
|
"BRANDER_BETA_KEY": "bux_dp_your_key"
|
|
@@ -37,75 +31,66 @@ Add this to your Claude Desktop config (`~/Library/Application Support/Claude/cl
|
|
|
37
31
|
}
|
|
38
32
|
```
|
|
39
33
|
|
|
40
|
-
|
|
34
|
+
## Tools
|
|
41
35
|
|
|
42
|
-
|
|
36
|
+
| Tool | Description |
|
|
37
|
+
|---|---|
|
|
38
|
+
| `generate_screen` | Render branded UI screens (charts, tables, grids, forms, cards, etc.) |
|
|
39
|
+
| `browse_components` | Browse available BranderUX UI components |
|
|
40
|
+
| `get_component_details` | View details of a specific component |
|
|
41
|
+
| `browse_scenarios` | Explore demo business scenarios |
|
|
42
|
+
| `get_scenario_details` | View a specific scenario with sample data |
|
|
43
|
+
| `get_platform_analytics` | View platform analytics and metrics |
|
|
44
|
+
| `get_feature_overview` | Explore BranderUX platform features |
|
|
45
|
+
| `get_integration_guide` | Get integration guides for different frameworks |
|
|
46
|
+
| `explore_ai_capabilities` | Explore AI-powered UI generation capabilities |
|
|
43
47
|
|
|
44
|
-
|
|
45
|
-
|---|---|---|
|
|
46
|
-
| `BRANDER_PROJECT_ID` | Yes | Your BranderUX project ID |
|
|
47
|
-
| `BRANDER_BETA_KEY` | Yes | Design partner key (`bux_dp_...`) |
|
|
48
|
-
| `BRANDER_API_BASE_URL` | No | API URL (defaults to `https://branderux.com`) |
|
|
48
|
+
## Try It
|
|
49
49
|
|
|
50
|
-
|
|
50
|
+
Connect to the demo and try these prompts:
|
|
51
51
|
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
| `get_order_details` | View single order details | Header + Details Data |
|
|
58
|
-
| `get_customers` | Search customers by name, segment, tier | Data Table |
|
|
59
|
-
| `get_customer_profile` | View customer profile with order history | Header + Details Data + Line Chart |
|
|
60
|
-
| `get_analytics_summary` | Revenue, orders, and trend analytics | Header + Stats Grid + Line Chart + Pie Chart |
|
|
61
|
-
| `get_inventory_status` | Stock levels with low-stock alerts | Data Table + Alert |
|
|
52
|
+
- "Show me a sales dashboard with analytics"
|
|
53
|
+
- "Create a product catalog with items and pricing"
|
|
54
|
+
- "Display a customer data table"
|
|
55
|
+
- "Show a login form with email and password"
|
|
56
|
+
- "Create a stats overview with revenue metrics"
|
|
62
57
|
|
|
63
|
-
##
|
|
58
|
+
## How It Works
|
|
59
|
+
|
|
60
|
+
BranderUX uses the [MCP Apps](https://modelcontextprotocol.io/docs/extensions/apps) standard to render interactive UI inside AI conversations. When the AI calls `generate_screen`, it returns:
|
|
64
61
|
|
|
65
|
-
|
|
62
|
+
1. **Text summary** — for the AI to understand what was rendered
|
|
63
|
+
2. **Structured content** — element data (charts, tables, forms, etc.)
|
|
64
|
+
3. **HTML resource** — a bundled React app that renders the branded UI in a sandboxed iframe
|
|
66
65
|
|
|
67
|
-
|
|
68
|
-
- "What are the latest orders?"
|
|
69
|
-
- "Show me the analytics dashboard"
|
|
70
|
-
- "Which products are low on stock?"
|
|
71
|
-
- "Show me customer John's profile"
|
|
66
|
+
All UI is styled with your project's brand colors, fonts, and layout — configured in the BranderUX dashboard.
|
|
72
67
|
|
|
73
68
|
## Integration Pattern
|
|
74
69
|
|
|
75
|
-
|
|
70
|
+
Adding BranderUX to any MCP server is one line:
|
|
76
71
|
|
|
77
72
|
```typescript
|
|
78
73
|
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
|
|
79
74
|
import { registerBranderTools } from "@brander/mcp-tools";
|
|
80
75
|
|
|
81
|
-
const server = new McpServer({ name: "
|
|
76
|
+
const server = new McpServer({ name: "my-server", version: "1.0.0" });
|
|
82
77
|
|
|
83
|
-
//
|
|
84
|
-
registerProductTools(server);
|
|
85
|
-
registerOrderTools(server);
|
|
86
|
-
// ...
|
|
78
|
+
// Add your own tools...
|
|
87
79
|
|
|
88
|
-
// One line — branded UI for
|
|
80
|
+
// One line — branded UI rendering for 15 element types
|
|
89
81
|
await registerBranderTools(server, {
|
|
90
82
|
projectId: process.env.BRANDER_PROJECT_ID!,
|
|
91
83
|
betaKey: process.env.BRANDER_BETA_KEY!,
|
|
92
84
|
});
|
|
93
|
-
|
|
94
|
-
await server.connect(new StdioServerTransport());
|
|
95
85
|
```
|
|
96
86
|
|
|
97
|
-
##
|
|
98
|
-
|
|
99
|
-
```bash
|
|
100
|
-
# Watch mode (auto-restarts on changes)
|
|
101
|
-
npm run dev
|
|
102
|
-
|
|
103
|
-
# Build for production
|
|
104
|
-
npm run build
|
|
87
|
+
## Environment Variables
|
|
105
88
|
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
89
|
+
| Variable | Required | Description |
|
|
90
|
+
|---|---|---|
|
|
91
|
+
| `BRANDER_PROJECT_ID` | Yes | Your BranderUX project ID |
|
|
92
|
+
| `BRANDER_BETA_KEY` | Yes | Design partner key (`bux_dp_...`) |
|
|
93
|
+
| `BRANDER_API_BASE_URL` | No | API URL (defaults to `https://branderux.com`) |
|
|
109
94
|
|
|
110
95
|
## License
|
|
111
96
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@brander/mcp-demo",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.11",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "BranderUX Demo — Explore BranderUX capabilities through branded UI",
|
|
6
6
|
"bin": {
|
|
@@ -24,7 +24,7 @@
|
|
|
24
24
|
"start": "node dist/index.js"
|
|
25
25
|
},
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@brander/mcp-tools": "^0.2.
|
|
27
|
+
"@brander/mcp-tools": "^0.2.11",
|
|
28
28
|
"@modelcontextprotocol/sdk": "^1.0.0",
|
|
29
29
|
"zod": "^4.3.6"
|
|
30
30
|
},
|