{"_id":"@elizaos/app-scape","_rev":"2-50af315cac92ffb39052091f1deac722","name":"@elizaos/app-scape","dist-tags":{"beta":"2.0.0-beta.1","latest":"2.0.0-beta.1"},"versions":{"2.0.0-beta.1":{"name":"@elizaos/app-scape","version":"2.0.0-beta.1","keywords":["game","runescape","xrsps","agents","autonomous"],"_id":"@elizaos/app-scape@2.0.0-beta.1","maintainers":[{"name":"haruhunab1320","email":"jakob@magickml.com"},{"name":"shawticus","email":"shawmakesmagic@gmail.com"},{"name":"odilitime","email":"janesmith@airmail.cc"}],"dist":{"shasum":"3303f78ce8c8c2526805ea36d33aa3fbaf71096e","tarball":"https://registry.npmjs.org/@elizaos/app-scape/-/app-scape-2.0.0-beta.1.tgz","fileCount":98,"integrity":"sha512-uUxuPwRjpHUtr9hEoSpddMelXIxdgHA5aQMnKZu675xT+/usDUD4KyEWS/rMSck9RQlvrwbae+b2CSR272fdJw==","signatures":[{"sig":"MEQCIBJgQp+V/ZD3hLk2H3Il5n2XWGVZKu/puxLruAw4Lz/2AiAXcI1fzMn3cj01vYndeNRY+eSUR/g/V5sjY6EBEmlbMA==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":481414},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","elizaos":{"app":{"viewer":{"url":"/api/apps/scape/viewer","sandbox":"allow-scripts allow-same-origin allow-popups allow-forms","embedParams":{"embedded":"true"}},"session":{"mode":"spectate-and-steer","features":["commands","telemetry","suggestions"]},"category":"game","heroImage":"assets/hero.png","launchUrl":"https://scape-client-2sqyc.kinsta.page","launchType":"connect","displayName":"'scape","capabilities":["autonomous","game","journal","operator-steering"],"runtimePlugin":"@elizaos/app-scape"},"kind":"app"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"},"./package.json":"./package.json"},"gitHead":"fb5c65dd89117b393a3c8d0962fe19302efc7cc7","scripts":{"build":"bun run build:js && bun run build:types","clean":"rm -rf dist","build:js":"tsup --config ../tsup.plugin-packages.shared.ts","build:types":"tsc --noCheck -p tsconfig.build.json"},"_npmUser":{"name":"shawticus","email":"shawmakesmagic@gmail.com"},"_npmVersion":"11.5.1","agentConfig":{"pluginParameters":{"SCAPE_AGENT_ID":{"type":"string","required":false,"sensitive":false,"description":"Stable identifier across reconnects. Used as the journal filename. Defaults to 'scape-{SCAPE_AGENT_NAME}'."},"SCAPE_AGENT_NAME":{"type":"string","default":"scape-agent","required":false,"sensitive":false,"description":"In-game display name for the agent. Becomes the account username (normalized, max 12 chars). Must not conflict with any human player's name."},"SCAPE_CLIENT_URL":{"type":"string","default":"https://scape-client-2sqyc.kinsta.page","required":false,"sensitive":false,"description":"URL the /viewer iframe loads — the xRSPS React client. Defaults to the production 'scape deployment at https://scape-client-2sqyc.kinsta.page (React client with WS URL, OSRS cache URL, and map tiles all baked in at build time, pointing at the deployed game server). Override to http://localhost:3000 for local dev against the craco server."},"SCAPE_MODEL_SIZE":{"type":"string","default":"TEXT_SMALL","options":["TEXT_NANO","TEXT_SMALL","TEXT_MEDIUM","TEXT_LARGE"],"required":false,"sensitive":false,"description":"Which model tier the autonomous loop uses. Smaller = cheaper, larger = smarter."},"SCAPE_BOT_SDK_URL":{"type":"string","default":"wss://scape-96cxt.sevalla.app/botsdk","required":false,"sensitive":false,"description":"WebSocket URL of the xRSPS bot-SDK endpoint. Defaults to the production 'scape deployment at wss://scape-96cxt.sevalla.app/botsdk (same host as the main game, path-routed, TLS-terminated by Sevalla's ingress). Override to ws://127.0.0.1:8080/botsdk for local dev against the shared-HTTP topology, or ws://127.0.0.1:43595 for legacy standalone BOT_SDK_PORT."},"SCAPE_AGENT_PERSONA":{"type":"string","required":false,"sensitive":false,"description":"Optional persona string fed into the LLM's system prompt so the agent keeps a consistent voice across sessions."},"SCAPE_BOT_SDK_TOKEN":{"type":"string","required":true,"sensitive":true,"description":"Shared secret for the xRSPS bot-SDK endpoint. Must match the server's BOT_SDK_TOKEN env var. Without this set, the plugin will not connect and the agent will not enter the world."},"SCAPE_AGENT_PASSWORD":{"type":"string","required":false,"sensitive":true,"description":"Password for the agent's xRSPS account. Leave blank to auto-generate a 24-char random password on first launch (persisted to ~/.eliza/scape-agent-identity.json and reused on every subsequent run). Only set this if you want to pin a specific existing account — and note that whatever value you set will be written to the identity file in plaintext, so do not reuse a production password."},"SCAPE_LOOP_INTERVAL_MS":{"type":"string","default":"15000","required":false,"sensitive":false,"description":"Autonomous LLM step interval in milliseconds. Lower = more expensive, more responsive. Minimum 1000."}}},"description":"'scape — first-class agent integration for xRSPS. Autonomous RuneScape-alike agent with JSON-encoded state, Scape Journal, and directed-prompt operator control.","directories":{},"_nodeVersion":"24.5.0","dependencies":{"@elizaos/ui":"2.0.0-beta.1","@elizaos/core":"2.0.0-beta.1","@elizaos/agent":"2.0.0-beta.1","@elizaos/shared":"2.0.0-beta.1","@elizaos/app-core":"2.0.0-beta.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.5.1"},"_npmOperationalInternal":{"tmp":"tmp/app-scape_2.0.0-beta.1_1778451381320_0.7606780415435694","host":"s3://npm-registry-packages-npm-production"}}},"time":{"created":"2026-05-10T22:16:21.222Z","modified":"2026-06-16T05:13:25.522Z","2.0.0-beta.1":"2026-05-10T22:16:21.466Z"},"keywords":["game","runescape","xrsps","agents","autonomous"],"description":"'scape — first-class agent integration for xRSPS. Autonomous RuneScape-alike agent with JSON-encoded state, Scape Journal, and directed-prompt operator control.","maintainers":[{"email":"shawmakesmagic@gmail.com","name":"shawticus"},{"email":"janesmith@airmail.cc","name":"odilitime"}],"readme":"# @elizaos/app-scape\n\nFirst-class agent integration for **xRSPS** — the TypeScript OSRS private\nserver at [xrsps-typescript](https://github.com/xrsps/xrsps-typescript).\n\n## What this plugin does\n\n`'scape` turns a running xRSPS instance into an autonomous-agent playground\nfor the eliza runtime. When you click **'scape** in the apps launcher:\n\n1. The viewer iframe loads the xRSPS React client — by default the\n   production 'scape deployment at\n   [`https://scape-client-2sqyc.kinsta.page`](https://scape-client-2sqyc.kinsta.page),\n   a React/WebGL build hosted as a Sevalla static site. It's wired at\n   build time to a live game server at `wss://scape-96cxt.sevalla.app`\n   and an OSRS cache + map-tile bucket at\n   `https://scape-cache-skrm0.sevalla.storage`. Override\n   `SCAPE_CLIENT_URL` to point at a local `http://localhost:3000` dev\n   server or your own fork's deployment.\n2. The plugin's `ScapeGameService` connects to xRSPS's **bot-SDK**\n   endpoint — a JSON-encoded WebSocket at\n   `wss://scape-96cxt.sevalla.app/botsdk` by default. That's the\n   production deployment: the bot-SDK shares the main game server's\n   HTTP port (8080) and is routed by URL path, so TLS is terminated by\n   Sevalla's ingress and everything flows over a single public\n   WebSocket endpoint. Spawning creates a first-class agent-player\n   account using the same scrypt auth + Postgres-backed persistence\n   human logins use. Override `SCAPE_BOT_SDK_URL` to\n   `ws://127.0.0.1:8080/botsdk` for a local dev stack.\n3. The eliza LLM runtime drives the agent via the action list (walk,\n   fight, chat, skill, bank, ...) every N seconds, with optional\n   directed prompts from the operator UI.\n\n## Why \"first-class citizen\"?\n\nThe agent isn't a scripted bot glued on top of the client protocol. It's\na `PlayerState` in the xRSPS world with an optional `AgentComponent`\nattached — same tick loop, same combat rules, same autosave, same\nvisibility to human players. Human and agent logins share the *exact*\nsame account store, save file, and code path. The only differences are:\n\n- Agents talk over JSON frames at path `/botsdk` on the shared HTTP\n  server (default port 8080) instead of the binary game protocol\n  on `/`. Both endpoints share a single port so TLS is terminated\n  once at the ingress.\n- Agents carry an `AgentComponent` on their `PlayerState` that holds\n  perception snapshots, action queues, journal refs, and goals.\n\nThis is the first step toward turning xRSPS into an ECS-for-agents.\n\n## Protocol\n\nAgents speak JSON — the same structured format used by the native tool-calling\nruntime and trajectory viewer,\ntypically 40–60% cheaper than JSON for the kinds of state snapshots an\nagent loop emits every few seconds. The full frame reference lives in\nthe xRSPS server at\n[`server/src/network/botsdk/BotSdkProtocol.ts`](https://github.com/xrsps/xrsps-typescript/blob/main/server/src/network/botsdk/BotSdkProtocol.ts).\n\n## Env vars\n\n| Variable              | Default                                         | Purpose                                          |\n|-----------------------|-------------------------------------------------|--------------------------------------------------|\n| `SCAPE_CLIENT_URL`    | `https://scape-client-2sqyc.kinsta.page`        | xRSPS client URL the viewer iframe points at. Set to `http://localhost:3000` for local dev. |\n| `SCAPE_BOT_SDK_URL`   | `wss://scape-96cxt.sevalla.app/botsdk`          | bot-SDK WebSocket endpoint on the xRSPS server. Defaults to the live Sevalla deployment (shared HTTP server, path-routed, TLS by ingress). Override to `ws://127.0.0.1:8080/botsdk` for local dev. |\n| `SCAPE_BOT_SDK_TOKEN` | *(unset → autonomous loop disabled)*            | Shared secret matching xRSPS `BOT_SDK_TOKEN`.   |\n| `SCAPE_AGENT_NAME`    | `scape-agent`                                   | In-game display name for the agent.              |\n| `SCAPE_AGENT_PASSWORD`| *(unset → auto-generated + persisted to disk)*  | Plaintext password for the agent's account.    |\n| `SCAPE_LOOP_INTERVAL_MS` | `15000`                                      | Autonomous LLM step interval.                    |\n| `SCAPE_MODEL_SIZE`    | `TEXT_SMALL`                                    | eliza model tier for the loop.                  |\n\n## Scope by PR\n\n- **PR 2 (this):** Plugin skeleton, curated-registry entry, viewer route\n  embedding the xRSPS client. No agent loop yet.\n- **PR 3:** Bot-SDK client (`sdk/`) + connection manager + empty game\n  service. Plugin connects to xRSPS and logs `agent spawned`, but\n  doesn't do anything afterward.\n- **PR 4:** First LLM loop + 5 actions + 3 providers. Watch the agent\n  walk itself one tile at a time based on model output.\n- **PR 5:** Full action toolbelt (~25 actions), world-knowledge\n  provider, skill data.\n- **PR 6:** Scape Journal — persistent memory/goals/progress.\n- **PR 7:** Operator-directed prompts via `POST /api/apps/scape/prompt`.\n- **PR 8:** Docs, deployment guide, end-to-end verification.\n","readmeFilename":"README.md"}