Skip to content

Commit adf0bbd

Browse files
authored
examples: add arcade example to servers (modelcontextprotocol#399)
1 parent 2187bd4 commit adf0bbd

File tree

7 files changed

+25
-2
lines changed

7 files changed

+25
-2
lines changed

.github/workflows/npm-publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -98,6 +98,7 @@ jobs:
9898
fail-fast: false
9999
matrix:
100100
example:
101+
- arcade-server
101102
- basic-server-preact
102103
- basic-server-react
103104
- basic-server-solid

.github/workflows/publish.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,7 @@ jobs:
2626
. \
2727
./examples/basic-server-react \
2828
./examples/basic-server-vanillajs \
29+
./examples/arcade-server \
2930
./examples/budget-allocator-server \
3031
./examples/cohort-heatmap-server \
3132
./examples/customer-segmentation-server \

README.md

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,16 @@ To use these examples with MCP clients that support the stdio transport (such as
176176
"--stdio"
177177
]
178178
},
179+
"arcade": {
180+
"command": "npx",
181+
"args": [
182+
"-y",
183+
"--silent",
184+
"--registry=https://registry.npmjs.org/",
185+
"@modelcontextprotocol/server-arcade",
186+
"--stdio"
187+
]
188+
},
179189
"budget-allocator": {
180190
"command": "npx",
181191
"args": [
@@ -393,6 +403,13 @@ Then configure your MCP client to build and run the local server. Replace `~/cod
393403
"cd ~/code/ext-apps/examples/basic-server-solid && npm run build >&2 && node dist/index.js --stdio"
394404
]
395405
},
406+
"arcade": {
407+
"command": "bash",
408+
"args": [
409+
"-c",
410+
"cd ~/code/ext-apps/examples/arcade-server && npm run build >&2 && node dist/index.js --stdio"
411+
]
412+
},
396413
"budget-allocator": {
397414
"command": "bash",
398415
"args": [
446 KB
Loading

examples/arcade-server/server.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ export function validateGameId(gameId: string): boolean {
3535
*/
3636
export function createServer(port: number): McpServer {
3737
const server = new McpServer({
38-
name: "arcade-mcp-server",
38+
name: "Arcade Server",
3939
version: "1.0.0",
4040
});
4141

tests/e2e/generate-grid-screenshots.spec.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ const EXTRA_WAIT_MS: Record<string, number> = {
2727

2828
// Servers to skip (screenshots maintained manually)
2929
const SKIP_SERVERS = new Set([
30+
"arcade-server", // Loads games from archive.org - screenshots maintained manually
3031
"video-resource", // Uses custom screenshot from PR comment
3132
"qr-server", // Uses custom screenshot from PR comment
3233
"say-server", // TTS model download from HuggingFace can be slow
@@ -37,6 +38,7 @@ const EXAMPLE_FILTER = process.env.EXAMPLE;
3738

3839
// Server configurations (excludes integration-server which is for E2E testing)
3940
const ALL_SERVERS = [
41+
{ key: "arcade-server", name: "Arcade Server", dir: "arcade-server" },
4042
{
4143
key: "basic-react",
4244
name: "Basic MCP App Server (React)",

tests/e2e/servers.spec.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@ const DYNAMIC_MASKS: Record<string, string[]> = {
3535
// Servers that need extra stabilization time (e.g., for tile loading, WebGL init)
3636
const SLOW_SERVERS: Record<string, number> = {
3737
"map-server": 15000, // CesiumJS needs time for tiles to load
38+
"arcade-server": 15000, // Game loading from archive.org can be slow
3839
threejs: 2000, // Three.js WebGL initialization
3940
"say-server": 10000, // TTS model download from HuggingFace can be slow
4041
};
@@ -57,7 +58,7 @@ const HOST_MASKS: Record<string, string[]> = {
5758

5859
// Servers to skip in CI (require special resources like GPU, large ML models)
5960
const SKIP_SERVERS = new Set<string>([
60-
// None currently - say-server view works without TTS model for screenshots
61+
"arcade-server", // Loads games from archive.org which may be slow/unreliable in CI
6162
"qr-server", // TODO
6263
"say-server", // TTS model download from HuggingFace can be slow
6364
]);
@@ -67,6 +68,7 @@ const EXAMPLE_FILTER = process.env.EXAMPLE;
6768

6869
// Server configurations (key is used for screenshot filenames, name is the MCP server name, dir is the folder name)
6970
const ALL_SERVERS = [
71+
{ key: "arcade-server", name: "Arcade Server", dir: "arcade-server" },
7072
{
7173
key: "integration",
7274
name: "Integration Test Server",

0 commit comments

Comments
 (0)