rpgjs-studio

Manage RPGJS Studio game content through authenticated HTTP API calls.

1.7k|246|Updated Apr 10, 2011
One-click install
npx skills add https://github.com/RSamaium/RPG-JS --skill rpgjs-studio-rsamaium
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: rpgjs-studio
Source: https://github.com/RSamaium/RPG-JS/tree/main/skills/rpgjs-studio
Command: npx skills add https://github.com/RSamaium/RPG-JS --skill rpgjs-studio-rsamaium

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Creating and updating 2D RPG content in RPGJS Studio requires many structured REST calls with correct IDs, media references, and credit-confirmed generation steps. This Skill gives an AI agent the exact endpoints, payload schemas, and safety rules to perform those operations reliably with curl and an API key. ## Core Features & Use Cases - Full content CRUD: Create, read, update, and delete maps, map events, block-based event workflows, database records (actors, classes, skills, items, enemies, variables), media assets, and project settings through the RPGJS Studio API. - AI generation with cost control: Generate maps, character spritesheets, illustrations, and cinematics through prepare/estimate-then-execute flows that always confirm credit costs with the user before spending. - Dependency resolution: Automatically search and reuse existing media and database IDs before creating new records, keeping game content coherent. - Use Case: Ask the agent to add a village shopkeeper NPC to a map; it resolves the map, searches for a suitable spritesheet and faceset, creates the priced item, and wires a call_shop block to the event. ## Quick Start Set the RPGSTUDIO_API_KEY environment variable, then ask the agent to create a treasure chest event on your forest map in RPGJS Studio.

Frequently Asked Questions about rpgjs-studio

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create an NPC event in RPGJS Studio with the API?

Resolve the target map first, search media for a matching spritesheet and faceset, then POST to /api/events with the mapId and position. For scripted behavior, create a block collection and link it through the event's onAction trigger.

How do I generate an RPG map with AI in RPGJS Studio?

Call POST /api/map-generations with action prepare, an objective describing the visual style, dimensions, and optional terrain references. After the user confirms the credit estimate, call the same endpoint with action execute and poll the returned instance until finalized with a mapId.

What authentication does the RPGJS Studio API use?

Requests use an x-api-key header read from the RPGSTUDIO_API_KEY environment variable, scoped to one project. The key value must never be printed or stored, and 401 or 403 responses stop the task immediately.

Does AI media generation in RPGJS Studio cost credits?

Yes, generation debits metered API-key credits on execute. The workflow always calls the unified media endpoint with action estimate first, reports the cost, and only proceeds after explicit user confirmation; failed executions are refunded.

Why does creating an Actor fail with a classId error?

New Actors require a valid classId referencing a Class record in the same project. Create or search the Class first via /api/database/classes, then pass its _id when creating the Actor.

When should I use a block collection instead of trigger dialogue?

A character whose only behavior is one dialogue can store it directly in triggers[].typeData.dialogue on an onAction trigger. Use a block collection only when the interaction includes choices, rewards, state changes, shops, or movement.