endfield-mcp
Version:
MCP Server for Arknights: Endfield (TypeScript / stdio + Streamable HTTP)
73 lines (72 loc) • 2.58 kB
TypeScript
/**
* Worldview category listing — the browse entry points.
*
* Exposes the two top-level trees of the worldview domain:
* - PRTS archive categories (collection/document/media/...) and their
* first-level groups (the unit a player opens to read documents)
* - In-game wiki categories and the groups under each
*
* Both trees are eager-loaded and cached in `worldviewCore`; this module
* just shapes them for tool consumption (resolving display names through
* i18n). Depends on `./worldviewCore.js` for the catalog loaders and
* `./texts.js` for name resolution.
*/
/** A PRTS category with its display name resolved, plus its group count. */
export interface LoreCategoryView {
categoryId: string;
displayName: string;
order: number;
/** Number of first-level groups in this category. */
groupCount: number;
}
/** A wiki category with its display name resolved, plus its group count. */
export interface WikiCategoryView {
categoryId: string;
displayName: string;
priority: number;
/** Number of groups under this category. */
groupCount: number;
}
/** A first-level group with its display name resolved. */
export interface LoreGroupView {
firstLvId: string;
categoryId: string;
displayName: string;
/** Resolved subtitle, or "" if absent. */
subtitle: string;
order: number;
/** Number of narrative items in this group. */
itemCount: number;
}
/** A wiki group with its display name resolved. */
export interface WikiGroupView {
groupId: string;
categoryId: string;
displayName: string;
}
/**
* List the PRTS archive's top-level categories.
*
* Each category is annotated with how many first-level groups it contains,
* so a caller can see the browse depth without a second round-trip.
*/
export declare function listLoreCategories(): LoreCategoryView[];
/**
* List first-level groups within a PRTS category.
*
* Returns an empty array if the category id is unknown.
*/
export declare function listLoreGroups(categoryId: string): LoreGroupView[];
/**
* List the in-game wiki's top-level categories.
*/
export declare function listWikiCategories(): WikiCategoryView[];
/**
* List wiki groups within a category.
*
* Returns an empty array if the category id is unknown. Matching is
* case-insensitive, but the returned `categoryId` is always the canonical
* casing from the data (the actual map key), so callers see a stable value
* regardless of how they cased their input.
*/
export declare function listWikiGroups(categoryId: string): WikiGroupView[];