UNPKG

mcp-server-ddd-sample

Version:

A sample of MCP implementation using DDD structure with some APIs call.

12 lines (11 loc) 358 B
import { formatResponse } from "../helpers/format.js"; export class BlockService { requestService; constructor(requestService) { this.requestService = requestService; } async getBlock({ hash }) { const data = await this.requestService.getBlock({ hash }); return formatResponse("Details about a block.", data); } }