random-tables-mcp
Version:
An MCP (Model Context Protocol) server for managing and rolling on random-table assets used in tabletop RPGs. Create, update, and roll on random tables with support for nested tables, weighted entries, and range-based results.
40 lines (39 loc) • 1.35 kB
TypeScript
import { RollTemplate } from '../value-objects/roll-template.js';
/**
* Represents a roll template entity that can be persisted.
* Unlike the RollTemplate value object, this entity has identity and metadata.
*/
export declare class RollTemplateEntity {
readonly id: string;
readonly name: string;
readonly description: string;
readonly template: RollTemplate;
/**
* Creates a new RollTemplateEntity instance.
* @param id Unique identifier for the template.
* @param name Template name.
* @param description Optional description.
* @param template The RollTemplate value object.
*/
constructor(id: string, name: string, description: string, template: RollTemplate);
/**
* Converts this template entity to a plain object.
* @returns A plain object representation of this template entity.
*/
toObject(): RollTemplateEntityDTO;
/**
* Creates a RollTemplateEntity from a plain object.
* @param obj The object to create the template entity from.
* @returns A new RollTemplateEntity instance.
*/
static fromObject(obj: RollTemplateEntityDTO): RollTemplateEntity;
}
/**
* Data Transfer Object for RollTemplateEntity.
*/
export interface RollTemplateEntityDTO {
id: string;
name: string;
description: string;
template: string;
}