作者 API

プログラムからシナリオの管理、素材の取り込み、下書きのテストプレイができます。

Getting started

Manage interactive scripts, import SillyTavern PNG/JSON character cards and lorebooks, and playtest drafts over SSE with Bearer token authentication. Base URL: https://api.isekai.date with header Authorization: Bearer $ISEKAI_TOKEN.

Scopes

  • scripts:read: Read account info, quota, script drafts, and play statistics
  • scripts:write: Create, update, delete, import, and publish scripts, covers, and character cards
  • playtest: Playtest authored drafts or published scripts and inspect story state

Endpoint reference

  • GET /api/author/scripts — List your scripts and status
  • POST /api/author/scripts — Create a new script
  • PUT /api/author/scripts/{id} — Save full script JSON with optimistic lock
  • POST /api/author/scripts/{id}/import/tavern — Parse a SillyTavern PNG/JSON card and lorebook
  • POST /api/author/scripts/{id}/publish — Validate and publish a script
  • POST /api/author/scripts/{id}/play — Start a playtest session from current draft
  • POST /api/stories/{storyId}/turns — Send a turn and stream SSE events (token / scene_changed / world)