Before you start: an API key and your project
- Sign in to your KiteFrost dashboard and open your project (or create one: Projects -> New Project).
- Copy the project ID from the address bar - the part after
/projects/(for examplehttps://.../projects/my-campaign->my-campaign). - Open the project’s API Keys page -> New API Key. Choose Secret (sk_) and
Full Access, give it a name such as
foundry, then Create Key. - Copy the key right away - it is shown only once. Treat it like a password.
1. The module, point and click
Foundry v13 or v14, logged in as the Gamemaster.1
Install
Foundry setup screen -> Add-on Modules -> Install Module. Paste into
Manifest URL:Click Install. It appears as KiteFrost (Testing). Foundry offers each new
testing build as a normal module update.
2
Enable it in your world
Launch your world -> Game Settings (gear icon, right sidebar) ->
Manage Modules -> tick KiteFrost (Testing) -> Save Module Settings.
3
Configure
Game Settings -> Configure Settings -> KiteFrost:
- API URL:
https://api-staging.kitefrost.ai - API Key: the
sk_...key - Project ID: from the address bar (step 2 above)
4
Talk to an NPC
Actors tab -> right-click an Actor -> AI: Generate Dialogue. Type what the
player says, optionally the situation and tone, and submit. The reply is posted to
chat as that NPC, with its mood and suggested follow-ups. Use Report Issue on
the message if a reply is off.
kitefrost.personality
flag is sent with every request (run once, as a macro):
2. The module’s scripting API (macros and modules)
With the module installed and configured as above, everything the menu does is available from code atgame.modules.get("kitefrost").api.
Every call rejects on a problem - wrap it in
try / catch.
React to every reply - from the menu or the API:
3. Direct REST or the KiteFrost SDKs
Skip the module and call the API yourself. From a Foundry macro (browser) - the NPC dialogue endpoint accepts calls from any site, so plainfetch works:
In a browser only the NPC dialogue and issue-report endpoints can be called from
another site. Everything else (projects, NPCs, quests, sessions, …) is available from
Node.js or a server - a companion script, a bot, or a build step - not from a
Foundry page. A macro’s text is visible to anyone who can open it: never paste a key
into a macro you share.
npm install @kitefrost/ttrpg-gm@alpha):
pip install --pre kitefrost-ttrpg-gm):