Eposyne Director

Eposyne Director API documentation

Eposyne Director is a decision service for games. You send it a question and a snapshot of your game state. It sends back suggested changes to the variables you said it may change. Your game decides what to do with them.

Status

The hosted Director is a beta for building and testing. A shipped game cannot use it yet, and an API key never goes into a build that players download. See API keys and security.

How it works

Every call is one HTTP request to POST /v2/decide. The body is a small JSON document with four parts:

The reply lists zero or more changes, each with a short rationale when you ask for one. Director checks every change against the rules you declared before it answers, so a reply never names a variable you did not declare or a value you did not allow. Your engine stays the final authority: it applies a suggestion, adjusts it, or ignores it.

Where to start

The basics

ItemValue
Base URLhttps://director.eposyne.com
Version prefix/v2. Within a version we add things and do not remove them. The earlier /v1 routes answer 404 contract_retired.
CredentialA Director API key (starts with epd_) in Authorization: Bearer
FormatsJSON only: application/json in, application/json; charset=utf-8 out, on success and on error.
CostPaid from your account's usage credits
Browser callsNot supported. Call Director from your backend.

Endpoints on these pages

EndpointPurposeCredential
GET /healthIs the service up.None
POST /v2/decideAsk for a decision.Key
GET /v2/modelsList the models you may select, with prices.Key
GET /v2/usage/meYour spend for the current month.Key
POST /v2/eventsSend observed events in batches.Key, Plots or Memory on
DELETE /v2/worlds/{world_instance_id}Delete one world and everything stored for it.Key
PUT /v2/policy, GET /v2/policyStore and read the policy for Plots and Memory.Key
PUT /v2/plots/library, GET /v2/plots/library, DELETE /v2/plots/library/{arc_id}Upload, list, and delete your story arcs.Key, Plots on
GET /v2/plots/runtime/arcsThe arcs running on a timeline.Key, Plots on
GET /v2/memory/runtime/npcs/{npc_id}What one character believes.Key, Memory on

Plots and Memory are off by default for every account. Switch them on under Modules at https://architect.eposyne.com/profile?section=director-keys. Their model calls are paid from your usage credits, like decisions. See Events to start.

Names in the documents

Every request and reply is one JSON object whose schema member names its format: eposyne.director.decision-request/v2 for the request and eposyne.director.decision-response/v2 for the reply. Write them exactly like that. The format is director/v2.