Skip to main content
Glama
hichana

Goal Story MCP Server

by hichana

goalstory_read_steps

Retrieve and view the sequential action plan for a specific goal, displaying all steps in order from earliest to latest to track progress toward achievement.

Instructions

Access the action plan for a specific goal, showing all steps in the journey toward achievement. IMPORTANT: Steps are returned ordered by their 'order_ts' timestamp in ascending order - the step with the earliest timestamp is step 1, and steps with later timestamps follow in sequence. The ordering is maintained automatically by the system.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
goal_idYesUnique identifier of the goal whose steps to retrieve.
pageNoPage number for viewing subsets of steps (starts at 1).
limitNoMaximum number of steps to return per page.

Implementation Reference

  • Handler implementation for the 'goalstory_read_steps' tool. Constructs API URL with goal_id and optional page/limit params, performs GET request via doRequest helper, returns formatted response with step ordering note.
    server.tool( READ_STEPS_TOOL.name, READ_STEPS_TOOL.description, READ_STEPS_TOOL.inputSchema.shape, async (args) => { const params = new URLSearchParams(); params.set("goal_id", args.goal_id); if (args.page) params.set("page", `${args.page}`); if (args.limit) params.set("limit", `${args.limit}`); const url = `${GOALSTORY_API_BASE_URL}/steps?${params.toString()}`; const result = await doRequest(url, "GET"); return { content: [ { type: "text", text: `Steps for goal '${args.goal_id}':\n${JSON.stringify( result, null, 2, )}\n\nIMPORTANT: Steps are ordered by their 'order_ts' timestamp in ascending order - the step with the smallest timestamp value (updated first) is step 1, and steps with larger timestamp values come later in the sequence. Example: If step A has timestamp 12:00 and step B has timestamp 12:01, then step A is step 1 and step B is step 2.`, }, ], isError: false, }; }, );
  • Tool definition object for 'goalstory_read_steps' including name, description, and Zod input schema for goal_id (required), page and limit (optional).
    export const READ_STEPS_TOOL = { name: "goalstory_read_steps", description: "Access the action plan for a specific goal, showing all steps in the journey toward achievement. IMPORTANT: Steps are returned ordered by their 'order_ts' timestamp in ascending order - the step with the earliest timestamp is step 1, and steps with later timestamps follow in sequence. The ordering is maintained automatically by the system.", inputSchema: z.object({ goal_id: z .string() .describe("Unique identifier of the goal whose steps to retrieve."), page: z .number() .optional() .describe("Page number for viewing subsets of steps (starts at 1)."), limit: z .number() .optional() .describe("Maximum number of steps to return per page."), }), };
  • src/index.ts:484-509 (registration)
    Registration of the 'goalstory_read_steps' tool via McpServer.tool() method, linking name, description, input schema, and handler function.
    server.tool( READ_STEPS_TOOL.name, READ_STEPS_TOOL.description, READ_STEPS_TOOL.inputSchema.shape, async (args) => { const params = new URLSearchParams(); params.set("goal_id", args.goal_id); if (args.page) params.set("page", `${args.page}`); if (args.limit) params.set("limit", `${args.limit}`); const url = `${GOALSTORY_API_BASE_URL}/steps?${params.toString()}`; const result = await doRequest(url, "GET"); return { content: [ { type: "text", text: `Steps for goal '${args.goal_id}':\n${JSON.stringify( result, null, 2, )}\n\nIMPORTANT: Steps are ordered by their 'order_ts' timestamp in ascending order - the step with the smallest timestamp value (updated first) is step 1, and steps with larger timestamp values come later in the sequence. Example: If step A has timestamp 12:00 and step B has timestamp 12:01, then step A is step 1 and step B is step 2.`, }, ], isError: false, }; }, );
  • TypeScript interface defining input shape for GoalstoryReadStepsInput, matching the Zod schema (goal_id required, page/limit optional).
    export interface GoalstoryReadStepsInput { goal_id: string; page?: number; limit?: number; }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/hichana/goalstory-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server