Lore Data
Base URL: https://loremind.peekgames.dev/api/loremind/v1
Last verified against LoreMind v1.0.67 (August 2026).
Read-only endpoints for fetching your project’s lore data. These power the Unity SDK’s editor tooling and Lore Sync, and can be called directly from your own tools.
Authentication: Editor Key (sk_editor_*) for all endpoints on this page.
Tooling API - subject to change. This section exists to serve the engine SDKs (Lore Sync, Entity Mind dropdowns) and is useful for backups, CI, and custom editor integrations. It may change between SDK releases without notice. If you build tooling against it directly, pin your versions and expect occasional churn; for your game’s runtime, use POST /npc/interact.
Authentication and other common failures are covered in Errors & Rate Limits.
GET /lore/minds
List all Entity Minds for the key’s project. Returns only minds with at least one knowledge tag configured.
Response
{
minds: Array<{
id: string;
entityName: string;
personality: string;
backstory: string | null;
backstorySummary: string | null;
role: string | null;
speakingStyle: string | null;
hints: string[];
restrictions: string[];
locationId: string | null;
location: { id: string; name: string } | null;
knowledgeTags: string[];
knowledgeDescription: string;
computedFilter: object;
responseConfig: object;
buildCreditsUsed: number;
interactionCount: number;
relationshipCount: number;
createdAt: string;
updatedAt: string;
}>;
}Example
curl https://loremind.peekgames.dev/api/loremind/v1/lore/minds \
-H "Authorization: Bearer sk_editor_your_key"GET /lore/tags
List all tags for the key’s project.
Response
{
success: true;
tags: Array<{
id: string;
name: string;
color: string | null;
isDefault: boolean;
documentCount: number;
}>;
defaultTags: Array<{ id: string; name: string; color: string | null; documentCount: number }>;
customTags: Array<{ id: string; name: string; color: string | null; documentCount: number }>;
totalCount: number;
}GET /lore/locations
List all locations for the key’s project, ordered by name.
Response
{
success: true;
locations: Array<{
id: string;
name: string;
description: string | null;
documentId: string | null;
document: { id: string; name: string } | null;
entityMindCount: number;
createdAt: string;
updatedAt: string;
}>;
totalCount: number;
}GET /lore/relationships
List NPC-to-NPC relationships for the key’s project.
Query Parameters:
entityMindId(optional) — relationships involving this Entity Mind (either direction)fromEntityId+toEntityId(optional, both required together) — relationships between a specific pair, both directionslimit(optional) — default 100, max 500offset(optional) — default 0
Response
{
success: true;
relationships: Array<{
id: string;
type: string | null; // Built-in type (FRIEND, RIVAL, MENTOR, ...) or null for custom
customTypeId: string | null;
customType: { id: string; name: string; color: string } | null;
description: string | null;
fromEntity: { id: string; entityName: string; location: { id: string; name: string } | null };
toEntity: { id: string; entityName: string; location: { id: string; name: string } | null };
createdAt: string;
updatedAt: string;
}>;
totalCount: number;
}GET /lore/relationship-types
List the project’s custom relationship types.
Response
{
success: true;
customTypes: Array<{
id: string;
name: string;
description: string | null;
color: string;
isSymmetric: boolean;
inverseTypeId: string | null;
conflictsWithBuiltIn: string[];
conflictsWithCustom: string[];
usageCount: number;
createdAt: string;
updatedAt: string;
}>;
}GET /lore/documents
List Lore Documents for the key’s project (metadata only — use the export endpoint for content).
Query Parameters:
status(optional) —PENDING|PROCESSING|COMPLETED|FAILEDtag(optional) — filter by tag namesearch(optional) — full-text search over name and contentlimit(optional) — default 50, max 100offset(optional) — default 0
Response
{
success: true;
documents: Array<{
id: string;
name: string;
status: string;
chunkCount: number;
createdAt: string;
updatedAt: string;
processedAt: string | null;
tags: Array<{ id: string; name: string; color: string | null; isDefault: boolean }>;
}>;
pagination: { total: number; limit: number; offset: number; hasMore: boolean };
}GET /lore/documents/{documentId}
Get a single document including its full content and chunks.
Response
{
success: true;
document: {
id: string;
name: string;
content: string;
status: string;
chunkCount: number;
chunks: Array<{ id: string; content: string; chunkIndex: number; tags: string[] }>;
tags: Array<{ id: string; name: string }>;
location: { id: string; name: string } | null;
createdAt: string;
updatedAt: string;
processedAt: string | null;
};
}GET /lore/documents/export
Bulk-export documents with full content and chunks. This is the endpoint the Unity SDK’s Lore Sync uses; page through it for backups or custom tooling.
Query Parameters:
limit(optional) — default 20, max 50offset(optional) — default 0
Returns the same document shape as the single-document endpoint, plus a pagination object (total, limit, offset, hasMore), ordered newest first.
GET /lore/project-settings
Fetch project-level configuration relevant to NPC interactions.
Response
{
success: true;
settings: {
projectName: string | null;
longTermMemoryEnabled: boolean; // default true
maxSessionLength: number; // default 20 turns
maxSessionTokens: number; // default 50000
enhancedMemoryRetrieval: boolean; // default false
};
}Next Steps
- Lore Sync - The Unity Editor tool these endpoints power
- Lore Scanner - Scanner endpoint reference
- API Reference overview - All endpoints at a glance