sunpeak 0.6.7 → 0.7.9
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 +3 -3
- package/bin/commands/build.mjs +22 -5
- package/bin/commands/deploy.mjs +108 -0
- package/bin/commands/login.mjs +217 -0
- package/bin/commands/logout.mjs +87 -0
- package/bin/commands/pull.mjs +254 -0
- package/bin/commands/push.mjs +347 -0
- package/bin/sunpeak.js +85 -2
- package/dist/mcp/entry.cjs +2 -2
- package/dist/mcp/entry.cjs.map +1 -1
- package/dist/mcp/entry.js +2 -2
- package/dist/mcp/entry.js.map +1 -1
- package/dist/mcp/index.cjs +1 -1
- package/dist/mcp/index.js +1 -1
- package/dist/{server-CQGbJWbk.cjs → server-BOYwNazb.cjs} +25 -26
- package/dist/{server-CQGbJWbk.cjs.map → server-BOYwNazb.cjs.map} +1 -1
- package/dist/{server-DGCvp1RA.js → server-C6vMGV6H.js} +25 -26
- package/dist/{server-DGCvp1RA.js.map → server-C6vMGV6H.js.map} +1 -1
- package/package.json +1 -1
- package/template/.sunpeak/dev.tsx +8 -10
- package/template/README.md +4 -4
- package/template/dist/albums.json +15 -0
- package/template/dist/carousel.json +15 -0
- package/template/dist/counter.json +10 -0
- package/template/dist/map.json +19 -0
- package/template/index.html +1 -1
- package/template/node_modules/.vite/deps/@openai_apps-sdk-ui_components_Button.js +3 -3
- package/template/node_modules/.vite/deps/@openai_apps-sdk-ui_components_SegmentedControl.js +1 -1
- package/template/node_modules/.vite/deps/@openai_apps-sdk-ui_components_Select.js +16 -16
- package/template/node_modules/.vite/deps/@openai_apps-sdk-ui_components_Textarea.js +3 -3
- package/template/node_modules/.vite/deps/_metadata.json +32 -32
- package/template/node_modules/.vite/deps/{chunk-DQAZDQU3.js → chunk-LR7NKCX5.js} +8 -8
- package/template/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json +1 -1
- package/template/src/resources/albums-resource.json +12 -0
- package/template/src/resources/carousel-resource.json +12 -0
- package/template/src/resources/counter-resource.json +9 -0
- package/template/src/resources/map-resource.json +13 -0
- package/template/src/simulations/albums-simulation.ts +3 -15
- package/template/src/simulations/carousel-simulation.ts +3 -15
- package/template/src/simulations/counter-simulation.ts +3 -15
- package/template/src/simulations/map-simulation.ts +5 -28
- package/template/src/simulations/widget-config.ts +0 -42
- /package/template/dist/{chatgpt/albums.js → albums.js} +0 -0
- /package/template/dist/{chatgpt/carousel.js → carousel.js} +0 -0
- /package/template/dist/{chatgpt/counter.js → counter.js} +0 -0
- /package/template/dist/{chatgpt/map.js → map.js} +0 -0
- /package/template/node_modules/.vite/deps/{chunk-DQAZDQU3.js.map → chunk-LR7NKCX5.js.map} +0 -0
|
@@ -7,149 +7,149 @@
|
|
|
7
7
|
"react": {
|
|
8
8
|
"src": "../../../../node_modules/.pnpm/react@19.2.0/node_modules/react/index.js",
|
|
9
9
|
"file": "react.js",
|
|
10
|
-
"fileHash": "
|
|
10
|
+
"fileHash": "34de8f5c",
|
|
11
11
|
"needsInterop": true
|
|
12
12
|
},
|
|
13
13
|
"react-dom": {
|
|
14
14
|
"src": "../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/index.js",
|
|
15
15
|
"file": "react-dom.js",
|
|
16
|
-
"fileHash": "
|
|
16
|
+
"fileHash": "25345a12",
|
|
17
17
|
"needsInterop": true
|
|
18
18
|
},
|
|
19
19
|
"react/jsx-dev-runtime": {
|
|
20
20
|
"src": "../../../../node_modules/.pnpm/react@19.2.0/node_modules/react/jsx-dev-runtime.js",
|
|
21
21
|
"file": "react_jsx-dev-runtime.js",
|
|
22
|
-
"fileHash": "
|
|
22
|
+
"fileHash": "d70cf82d",
|
|
23
23
|
"needsInterop": true
|
|
24
24
|
},
|
|
25
25
|
"react/jsx-runtime": {
|
|
26
26
|
"src": "../../../../node_modules/.pnpm/react@19.2.0/node_modules/react/jsx-runtime.js",
|
|
27
27
|
"file": "react_jsx-runtime.js",
|
|
28
|
-
"fileHash": "
|
|
28
|
+
"fileHash": "e558722d",
|
|
29
29
|
"needsInterop": true
|
|
30
30
|
},
|
|
31
31
|
"@openai/apps-sdk-ui/components/Avatar": {
|
|
32
32
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Avatar/index.js",
|
|
33
33
|
"file": "@openai_apps-sdk-ui_components_Avatar.js",
|
|
34
|
-
"fileHash": "
|
|
34
|
+
"fileHash": "42d8a2ca",
|
|
35
35
|
"needsInterop": false
|
|
36
36
|
},
|
|
37
37
|
"@openai/apps-sdk-ui/components/Button": {
|
|
38
38
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Button/index.js",
|
|
39
39
|
"file": "@openai_apps-sdk-ui_components_Button.js",
|
|
40
|
-
"fileHash": "
|
|
40
|
+
"fileHash": "3a859716",
|
|
41
41
|
"needsInterop": false
|
|
42
42
|
},
|
|
43
43
|
"@openai/apps-sdk-ui/components/Checkbox": {
|
|
44
44
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Checkbox/index.js",
|
|
45
45
|
"file": "@openai_apps-sdk-ui_components_Checkbox.js",
|
|
46
|
-
"fileHash": "
|
|
46
|
+
"fileHash": "023fd696",
|
|
47
47
|
"needsInterop": false
|
|
48
48
|
},
|
|
49
49
|
"@openai/apps-sdk-ui/components/Icon": {
|
|
50
50
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Icon/index.js",
|
|
51
51
|
"file": "@openai_apps-sdk-ui_components_Icon.js",
|
|
52
|
-
"fileHash": "
|
|
52
|
+
"fileHash": "b28344ea",
|
|
53
53
|
"needsInterop": false
|
|
54
54
|
},
|
|
55
55
|
"@openai/apps-sdk-ui/components/Input": {
|
|
56
56
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Input/index.js",
|
|
57
57
|
"file": "@openai_apps-sdk-ui_components_Input.js",
|
|
58
|
-
"fileHash": "
|
|
58
|
+
"fileHash": "1f7a8a17",
|
|
59
59
|
"needsInterop": false
|
|
60
60
|
},
|
|
61
61
|
"@openai/apps-sdk-ui/components/SegmentedControl": {
|
|
62
62
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/SegmentedControl/index.js",
|
|
63
63
|
"file": "@openai_apps-sdk-ui_components_SegmentedControl.js",
|
|
64
|
-
"fileHash": "
|
|
64
|
+
"fileHash": "6dbcfe0b",
|
|
65
65
|
"needsInterop": false
|
|
66
66
|
},
|
|
67
67
|
"@openai/apps-sdk-ui/components/Select": {
|
|
68
68
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Select/index.js",
|
|
69
69
|
"file": "@openai_apps-sdk-ui_components_Select.js",
|
|
70
|
-
"fileHash": "
|
|
70
|
+
"fileHash": "df124076",
|
|
71
71
|
"needsInterop": false
|
|
72
72
|
},
|
|
73
73
|
"@openai/apps-sdk-ui/components/Textarea": {
|
|
74
74
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/components/Textarea/index.js",
|
|
75
75
|
"file": "@openai_apps-sdk-ui_components_Textarea.js",
|
|
76
|
-
"fileHash": "
|
|
76
|
+
"fileHash": "c3d4fd40",
|
|
77
77
|
"needsInterop": false
|
|
78
78
|
},
|
|
79
79
|
"@openai/apps-sdk-ui/theme": {
|
|
80
80
|
"src": "../../../../node_modules/.pnpm/@openai+apps-sdk-ui@0.2.0_@types+react-dom@19.2.3_@types+react@19.2.7__@types+react@19._60630c8dcc43ec213b3e346c9e26579b/node_modules/@openai/apps-sdk-ui/dist/es/lib/theme.js",
|
|
81
81
|
"file": "@openai_apps-sdk-ui_theme.js",
|
|
82
|
-
"fileHash": "
|
|
82
|
+
"fileHash": "bf2b8101",
|
|
83
83
|
"needsInterop": false
|
|
84
84
|
},
|
|
85
85
|
"clsx": {
|
|
86
86
|
"src": "../../../../node_modules/.pnpm/clsx@2.1.1/node_modules/clsx/dist/clsx.mjs",
|
|
87
87
|
"file": "clsx.js",
|
|
88
|
-
"fileHash": "
|
|
88
|
+
"fileHash": "8e45b38a",
|
|
89
89
|
"needsInterop": false
|
|
90
90
|
},
|
|
91
91
|
"embla-carousel-react": {
|
|
92
92
|
"src": "../../../../node_modules/.pnpm/embla-carousel-react@8.6.0_react@19.2.0/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js",
|
|
93
93
|
"file": "embla-carousel-react.js",
|
|
94
|
-
"fileHash": "
|
|
94
|
+
"fileHash": "e02c407d",
|
|
95
95
|
"needsInterop": false
|
|
96
96
|
},
|
|
97
97
|
"embla-carousel-wheel-gestures": {
|
|
98
98
|
"src": "../../../../node_modules/.pnpm/embla-carousel-wheel-gestures@8.1.0_embla-carousel@8.6.0/node_modules/embla-carousel-wheel-gestures/dist/embla-carousel-wheel-gestures.esm.js",
|
|
99
99
|
"file": "embla-carousel-wheel-gestures.js",
|
|
100
|
-
"fileHash": "
|
|
100
|
+
"fileHash": "995231f5",
|
|
101
101
|
"needsInterop": false
|
|
102
102
|
},
|
|
103
103
|
"mapbox-gl": {
|
|
104
104
|
"src": "../../../../node_modules/.pnpm/mapbox-gl@3.17.0/node_modules/mapbox-gl/dist/mapbox-gl.js",
|
|
105
105
|
"file": "mapbox-gl.js",
|
|
106
|
-
"fileHash": "
|
|
106
|
+
"fileHash": "ea0e6ce4",
|
|
107
107
|
"needsInterop": true
|
|
108
108
|
},
|
|
109
109
|
"react-dom/client": {
|
|
110
110
|
"src": "../../../../node_modules/.pnpm/react-dom@19.2.0_react@19.2.0/node_modules/react-dom/client.js",
|
|
111
111
|
"file": "react-dom_client.js",
|
|
112
|
-
"fileHash": "
|
|
112
|
+
"fileHash": "bb56d10f",
|
|
113
113
|
"needsInterop": true
|
|
114
114
|
},
|
|
115
115
|
"tailwind-merge": {
|
|
116
116
|
"src": "../../../../node_modules/.pnpm/tailwind-merge@3.4.0/node_modules/tailwind-merge/dist/bundle-mjs.mjs",
|
|
117
117
|
"file": "tailwind-merge.js",
|
|
118
|
-
"fileHash": "
|
|
118
|
+
"fileHash": "866233cc",
|
|
119
119
|
"needsInterop": false
|
|
120
120
|
}
|
|
121
121
|
},
|
|
122
122
|
"chunks": {
|
|
123
|
-
"chunk-
|
|
124
|
-
"file": "chunk-
|
|
123
|
+
"chunk-CQ3GYAYB": {
|
|
124
|
+
"file": "chunk-CQ3GYAYB.js"
|
|
125
125
|
},
|
|
126
|
-
"chunk-
|
|
127
|
-
"file": "chunk-
|
|
126
|
+
"chunk-LR7NKCX5": {
|
|
127
|
+
"file": "chunk-LR7NKCX5.js"
|
|
128
128
|
},
|
|
129
129
|
"chunk-YOJ6QPGS": {
|
|
130
130
|
"file": "chunk-YOJ6QPGS.js"
|
|
131
131
|
},
|
|
132
|
+
"chunk-QPJAV452": {
|
|
133
|
+
"file": "chunk-QPJAV452.js"
|
|
134
|
+
},
|
|
132
135
|
"chunk-BAG6OO6S": {
|
|
133
136
|
"file": "chunk-BAG6OO6S.js"
|
|
134
137
|
},
|
|
138
|
+
"chunk-EGRHWZRV": {
|
|
139
|
+
"file": "chunk-EGRHWZRV.js"
|
|
140
|
+
},
|
|
135
141
|
"chunk-SGWD4VEU": {
|
|
136
142
|
"file": "chunk-SGWD4VEU.js"
|
|
137
143
|
},
|
|
138
144
|
"chunk-KFGKZMLK": {
|
|
139
145
|
"file": "chunk-KFGKZMLK.js"
|
|
140
146
|
},
|
|
141
|
-
"chunk-CQ3GYAYB": {
|
|
142
|
-
"file": "chunk-CQ3GYAYB.js"
|
|
143
|
-
},
|
|
144
|
-
"chunk-QPJAV452": {
|
|
145
|
-
"file": "chunk-QPJAV452.js"
|
|
146
|
-
},
|
|
147
|
-
"chunk-EGRHWZRV": {
|
|
148
|
-
"file": "chunk-EGRHWZRV.js"
|
|
149
|
-
},
|
|
150
147
|
"chunk-CNYJBM5F": {
|
|
151
148
|
"file": "chunk-CNYJBM5F.js"
|
|
152
149
|
},
|
|
150
|
+
"chunk-XB525PXG": {
|
|
151
|
+
"file": "chunk-XB525PXG.js"
|
|
152
|
+
},
|
|
153
153
|
"chunk-PTVT3RFX": {
|
|
154
154
|
"file": "chunk-PTVT3RFX.js"
|
|
155
155
|
},
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import {
|
|
2
|
-
Check_default,
|
|
3
|
-
Copy_default
|
|
4
|
-
} from "./chunk-XB525PXG.js";
|
|
5
1
|
import {
|
|
6
2
|
useTimeout
|
|
7
3
|
} from "./chunk-YOJ6QPGS.js";
|
|
4
|
+
import {
|
|
5
|
+
o
|
|
6
|
+
} from "./chunk-QPJAV452.js";
|
|
8
7
|
import {
|
|
9
8
|
handlePressableMouseEnter,
|
|
10
9
|
isDev,
|
|
@@ -16,12 +15,13 @@ import {
|
|
|
16
15
|
toTransformProperty,
|
|
17
16
|
waitForAnimationFrame
|
|
18
17
|
} from "./chunk-BAG6OO6S.js";
|
|
19
|
-
import {
|
|
20
|
-
o
|
|
21
|
-
} from "./chunk-QPJAV452.js";
|
|
22
18
|
import {
|
|
23
19
|
clsx_default
|
|
24
20
|
} from "./chunk-CNYJBM5F.js";
|
|
21
|
+
import {
|
|
22
|
+
Check_default,
|
|
23
|
+
Copy_default
|
|
24
|
+
} from "./chunk-XB525PXG.js";
|
|
25
25
|
import {
|
|
26
26
|
require_jsx_runtime
|
|
27
27
|
} from "./chunk-PTVT3RFX.js";
|
|
@@ -625,4 +625,4 @@ export {
|
|
|
625
625
|
ButtonLink,
|
|
626
626
|
CopyButton
|
|
627
627
|
};
|
|
628
|
-
//# sourceMappingURL=chunk-
|
|
628
|
+
//# sourceMappingURL=chunk-LR7NKCX5.js.map
|
package/template/node_modules/.vite/vitest/da39a3ee5e6b4b0d3255bfef95601890afd80709/results.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"4.0.13","results":[[":src/resources/carousel-resource.test.tsx",{"duration":
|
|
1
|
+
{"version":"4.0.13","results":[[":src/resources/carousel-resource.test.tsx",{"duration":223.75794699999983,"failed":false}],[":src/components/album/albums.test.tsx",{"duration":323.4242160000001,"failed":false}],[":src/components/map/map-view.test.tsx",{"duration":81.51079499999992,"failed":false}],[":src/components/map/place-inspector.test.tsx",{"duration":422.8601289999997,"failed":false}],[":src/resources/counter-resource.test.tsx",{"duration":322.9052020000004,"failed":false}],[":src/components/album/fullscreen-viewer.test.tsx",{"duration":228.40596499999992,"failed":false}],[":src/components/map/place-list.test.tsx",{"duration":142.98616300000003,"failed":false}],[":src/components/map/place-card.test.tsx",{"duration":348.2026999999998,"failed":false}],[":src/components/map/place-carousel.test.tsx",{"duration":438.33390999999983,"failed":false}],[":src/components/album/album-carousel.test.tsx",{"duration":89.84293600000001,"failed":false}],[":src/components/carousel/carousel.test.tsx",{"duration":87.84814800000004,"failed":false}],[":src/resources/albums-resource.test.tsx",{"duration":246.36836600000015,"failed":false}],[":src/components/album/film-strip.test.tsx",{"duration":483.7447050000003,"failed":false}],[":src/components/album/album-card.test.tsx",{"duration":279.70283800000016,"failed":false}],[":src/components/carousel/card.test.tsx",{"duration":59.06079599999998,"failed":false}]]}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "albums",
|
|
3
|
+
"title": "Albums",
|
|
4
|
+
"description": "Show photo albums widget",
|
|
5
|
+
"mimeType": "text/html+skybridge",
|
|
6
|
+
"_meta": {
|
|
7
|
+
"openai/widgetDomain": "https://sunpeak.ai",
|
|
8
|
+
"openai/widgetCSP": {
|
|
9
|
+
"resource_domains": ["https://*.oaistatic.com"]
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "carousel",
|
|
3
|
+
"title": "Carousel",
|
|
4
|
+
"description": "Show popular places to visit widget",
|
|
5
|
+
"mimeType": "text/html+skybridge",
|
|
6
|
+
"_meta": {
|
|
7
|
+
"openai/widgetDomain": "https://sunpeak.ai",
|
|
8
|
+
"openai/widgetCSP": {
|
|
9
|
+
"resource_domains": ["https://images.unsplash.com"]
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "map",
|
|
3
|
+
"title": "Map",
|
|
4
|
+
"description": "Pizza restaurant finder widget",
|
|
5
|
+
"mimeType": "text/html+skybridge",
|
|
6
|
+
"_meta": {
|
|
7
|
+
"openai/widgetDomain": "https://sunpeak.ai",
|
|
8
|
+
"openai/widgetCSP": {
|
|
9
|
+
"connect_domains": ["https://api.mapbox.com"],
|
|
10
|
+
"resource_domains": ["https://*.oaistatic.com", "https://api.mapbox.com"]
|
|
11
|
+
}
|
|
12
|
+
}
|
|
13
|
+
}
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* This file contains only metadata and doesn't import React components or CSS.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import albumsResourceMeta from '../resources/albums-resource.json';
|
|
7
7
|
|
|
8
8
|
const albumsData = {
|
|
9
9
|
albums: [
|
|
@@ -129,7 +129,6 @@ export const albumsSimulation = {
|
|
|
129
129
|
title: 'Show Albums',
|
|
130
130
|
annotations: { readOnlyHint: true },
|
|
131
131
|
_meta: {
|
|
132
|
-
'openai/outputTemplate': 'ui://AlbumsResource',
|
|
133
132
|
'openai/toolInvocation/invoking': 'Loading albums',
|
|
134
133
|
'openai/toolInvocation/invoked': 'Album loaded',
|
|
135
134
|
'openai/widgetAccessible': true,
|
|
@@ -137,19 +136,8 @@ export const albumsSimulation = {
|
|
|
137
136
|
},
|
|
138
137
|
},
|
|
139
138
|
|
|
140
|
-
// MCP Resource protocol -
|
|
141
|
-
|
|
142
|
-
// resource.title is used as the simulation display label
|
|
143
|
-
resource: {
|
|
144
|
-
uri: 'ui://AlbumsResource',
|
|
145
|
-
name: 'albums',
|
|
146
|
-
title: 'Albums',
|
|
147
|
-
description: 'Show photo albums widget markup',
|
|
148
|
-
mimeType: 'text/html+skybridge',
|
|
149
|
-
_meta: {
|
|
150
|
-
...defaultWidgetMeta,
|
|
151
|
-
},
|
|
152
|
-
},
|
|
139
|
+
// MCP Resource protocol - imported from resource meta file
|
|
140
|
+
resource: albumsResourceMeta,
|
|
153
141
|
|
|
154
142
|
// MCP CallTool protocol - data for CallTool response
|
|
155
143
|
toolCall: {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* This file contains only metadata and doesn't import React components or CSS.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import carouselResourceMeta from '../resources/carousel-resource.json';
|
|
7
7
|
|
|
8
8
|
const placesData = {
|
|
9
9
|
places: [
|
|
@@ -66,7 +66,6 @@ export const carouselSimulation = {
|
|
|
66
66
|
title: 'Show Carousel',
|
|
67
67
|
annotations: { readOnlyHint: true },
|
|
68
68
|
_meta: {
|
|
69
|
-
'openai/outputTemplate': 'ui://CarouselResource',
|
|
70
69
|
'openai/toolInvocation/invoking': 'Loading carousel',
|
|
71
70
|
'openai/toolInvocation/invoked': 'Carousel loaded',
|
|
72
71
|
'openai/widgetAccessible': true,
|
|
@@ -74,19 +73,8 @@ export const carouselSimulation = {
|
|
|
74
73
|
},
|
|
75
74
|
},
|
|
76
75
|
|
|
77
|
-
// MCP Resource protocol -
|
|
78
|
-
|
|
79
|
-
// resource.title is used as the simulation display label
|
|
80
|
-
resource: {
|
|
81
|
-
uri: 'ui://CarouselResource',
|
|
82
|
-
name: 'carousel',
|
|
83
|
-
title: 'Carousel',
|
|
84
|
-
description: 'Show popular places to visit widget markup',
|
|
85
|
-
mimeType: 'text/html+skybridge',
|
|
86
|
-
_meta: {
|
|
87
|
-
...defaultWidgetMeta,
|
|
88
|
-
},
|
|
89
|
-
},
|
|
76
|
+
// MCP Resource protocol - imported from resource meta file
|
|
77
|
+
resource: carouselResourceMeta,
|
|
90
78
|
|
|
91
79
|
// MCP CallTool protocol - data for CallTool response
|
|
92
80
|
toolCall: {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* This file contains only metadata and doesn't import React components or CSS.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import counterResourceMeta from '../resources/counter-resource.json';
|
|
7
7
|
|
|
8
8
|
export const counterSimulation = {
|
|
9
9
|
userMessage: 'Help me count something',
|
|
@@ -16,7 +16,6 @@ export const counterSimulation = {
|
|
|
16
16
|
title: 'Show Counter',
|
|
17
17
|
annotations: { readOnlyHint: true },
|
|
18
18
|
_meta: {
|
|
19
|
-
'openai/outputTemplate': 'ui://CounterResource',
|
|
20
19
|
'openai/toolInvocation/invoking': 'Counting beans',
|
|
21
20
|
'openai/toolInvocation/invoked': 'Beans counted',
|
|
22
21
|
'openai/widgetAccessible': true,
|
|
@@ -24,19 +23,8 @@ export const counterSimulation = {
|
|
|
24
23
|
},
|
|
25
24
|
},
|
|
26
25
|
|
|
27
|
-
// MCP Resource protocol -
|
|
28
|
-
|
|
29
|
-
// resource.title is used as the simulation display label
|
|
30
|
-
resource: {
|
|
31
|
-
uri: 'ui://CounterResource',
|
|
32
|
-
name: 'counter',
|
|
33
|
-
title: 'Counter',
|
|
34
|
-
description: 'Show a simple counter tool widget markup',
|
|
35
|
-
mimeType: 'text/html+skybridge',
|
|
36
|
-
_meta: {
|
|
37
|
-
...defaultWidgetMeta,
|
|
38
|
-
},
|
|
39
|
-
},
|
|
26
|
+
// MCP Resource protocol - imported from resource meta file
|
|
27
|
+
resource: counterResourceMeta,
|
|
40
28
|
|
|
41
29
|
// MCP CallTool protocol - data for CallTool response
|
|
42
30
|
toolCall: {
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
* This file contains only metadata and doesn't import React components or CSS.
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
|
-
import
|
|
6
|
+
import mapResourceMeta from '../resources/map-resource.json';
|
|
7
7
|
|
|
8
8
|
export interface Place {
|
|
9
9
|
id: string;
|
|
@@ -130,13 +130,12 @@ export const mapSimulation = {
|
|
|
130
130
|
|
|
131
131
|
// MCP Tool protocol - official Tool type from MCP SDK used in ListTools response
|
|
132
132
|
tool: {
|
|
133
|
-
name: '
|
|
134
|
-
description: '
|
|
133
|
+
name: 'show-map',
|
|
134
|
+
description: 'Show the map',
|
|
135
135
|
inputSchema: { type: 'object', properties: {}, additionalProperties: false } as const,
|
|
136
136
|
title: 'Find Pizza',
|
|
137
137
|
annotations: { readOnlyHint: true },
|
|
138
138
|
_meta: {
|
|
139
|
-
'openai/outputTemplate': 'ui://MapResource',
|
|
140
139
|
'openai/toolInvocation/invoking': 'Finding pizza places',
|
|
141
140
|
'openai/toolInvocation/invoked': 'Found pizza places',
|
|
142
141
|
'openai/widgetAccessible': true,
|
|
@@ -144,30 +143,8 @@ export const mapSimulation = {
|
|
|
144
143
|
},
|
|
145
144
|
},
|
|
146
145
|
|
|
147
|
-
// MCP Resource protocol -
|
|
148
|
-
|
|
149
|
-
// resource.title is used as the simulation display label
|
|
150
|
-
resource: {
|
|
151
|
-
uri: 'ui://MapResource',
|
|
152
|
-
name: 'map',
|
|
153
|
-
title: 'Map',
|
|
154
|
-
description: 'Pizza restaurant finder widget',
|
|
155
|
-
mimeType: 'text/html+skybridge',
|
|
156
|
-
_meta: {
|
|
157
|
-
...defaultWidgetMeta,
|
|
158
|
-
'openai/widgetCSP': {
|
|
159
|
-
...defaultWidgetMeta['openai/widgetCSP'],
|
|
160
|
-
connect_domains: [
|
|
161
|
-
...defaultWidgetMeta['openai/widgetCSP'].connect_domains,
|
|
162
|
-
'https://api.mapbox.com',
|
|
163
|
-
],
|
|
164
|
-
resource_domains: [
|
|
165
|
-
...defaultWidgetMeta['openai/widgetCSP'].resource_domains,
|
|
166
|
-
'https://api.mapbox.com',
|
|
167
|
-
],
|
|
168
|
-
},
|
|
169
|
-
},
|
|
170
|
-
},
|
|
146
|
+
// MCP Resource protocol - imported from resource meta file
|
|
147
|
+
resource: mapResourceMeta,
|
|
171
148
|
|
|
172
149
|
// MCP CallTool protocol - data for CallTool response
|
|
173
150
|
toolCall: {
|
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Default widget configuration for all simulations.
|
|
3
|
-
* Individual simulations can override these values as needed.
|
|
4
|
-
*/
|
|
5
|
-
|
|
6
|
-
export interface WidgetCSP {
|
|
7
|
-
connect_domains: string[];
|
|
8
|
-
resource_domains: string[];
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
export interface WidgetMeta {
|
|
12
|
-
'openai/widgetDomain': string;
|
|
13
|
-
'openai/widgetCSP': WidgetCSP;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
/**
|
|
17
|
-
* Default widget metadata that can be spread into resource._meta
|
|
18
|
-
*
|
|
19
|
-
* @example
|
|
20
|
-
* // Use default configuration
|
|
21
|
-
* resource: {
|
|
22
|
-
* _meta: {
|
|
23
|
-
* ...defaultWidgetMeta,
|
|
24
|
-
* }
|
|
25
|
-
* }
|
|
26
|
-
*
|
|
27
|
-
* @example
|
|
28
|
-
* // Override specific values
|
|
29
|
-
* resource: {
|
|
30
|
-
* _meta: {
|
|
31
|
-
* ...defaultWidgetMeta,
|
|
32
|
-
* 'openai/widgetDomain': 'https://custom.domain.com',
|
|
33
|
-
* }
|
|
34
|
-
* }
|
|
35
|
-
*/
|
|
36
|
-
export const defaultWidgetMeta: WidgetMeta = {
|
|
37
|
-
'openai/widgetDomain': 'https://sunpeak.ai', // YOUR DOMAIN HERE.
|
|
38
|
-
'openai/widgetCSP': {
|
|
39
|
-
connect_domains: ['https://sunpeak.ai'], // YOUR API HERE.
|
|
40
|
-
resource_domains: ['https://*.oaistatic.com', 'https://images.unsplash.com'], // YOUR CDN HERE (if any).
|
|
41
|
-
},
|
|
42
|
-
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|