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.
21 lines • 557 B
JavaScript
/**
* Use case for listing random tables.
*/
export class ListTablesUseCase {
/**
* Creates a new ListTablesUseCase instance.
* @param repository The table repository to use.
*/
constructor(repository) {
this.repository = repository;
}
/**
* Executes the use case.
* @param filter Optional filter criteria.
* @returns An array of tables matching the filter.
*/
async execute(filter) {
return await this.repository.list(filter);
}
}
//# sourceMappingURL=list-tables-use-case.js.map