Skip to main content
Glama

esa_create_post

Create a new post in esa with a title, markdown body, category, tags, and optional template. Mark as WIP or specify a poster for team owners.

Instructions

Create a new post

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
body_mdNoPost body (Markdown format)
categoryNoPost category
messageNoChange message
nameYesPost title
tagsNoList of tags for the post
template_post_idNoID of the post to use as a template
userNoPoster's screen_name (only team owners can specify)
wipNoWhether to mark as WIP (Work In Progress)

Implementation Reference

  • Handler for 'esa_create_post' tool: validates 'name' argument, calls esaClient.createPost(args), returns JSON response.
    case "esa_create_post": { const args = request.params.arguments as unknown as CreatePostArgs; if (!args.name) { throw new Error("name is required"); } const response = await esaClient.createPost(args); return { content: [{ type: "text", text: JSON.stringify(response) }], }; }
  • Schema definition for 'esa_create_post' tool including input schema with properties like name (required), body_md, tags, etc.
    const createPostTool: Tool = { name: "esa_create_post", description: "Create a new post", inputSchema: { type: "object", properties: { name: { type: "string", description: "Post title", }, body_md: { type: "string", description: "Post body (Markdown format)", }, tags: { type: "array", items: { type: "string" }, description: "List of tags for the post", }, category: { type: "string", description: "Post category", }, wip: { type: "boolean", description: "Whether to mark as WIP (Work In Progress)", default: true, }, message: { type: "string", description: "Change message", }, user: { type: "string", description: "Poster's screen_name (only team owners can specify)", }, template_post_id: { type: "number", description: "ID of the post to use as a template", }, }, required: ["name"], }, };
  • index.ts:607-619 (registration)
    Registration of createPostTool (esa_create_post) in the tools list returned by ListToolsRequest handler.
    tools: [ listPostsTool, getPostTool, createPostTool, updatePostTool, listCommentsTool, getCommentTool, createCommentTool, getMembersTool, getMemberTool, ], }; });
  • EsaClient.createPost helper method: sends POST request to Esa API /posts endpoint with post data.
    async createPost(postData: Omit<CreatePostArgs, 'template_post_id'> & { template_post_id?: number }): Promise<any> { const url = `${this.baseUrl}/posts`; const response = await fetch(url, { method: "POST", headers: this.headers, body: JSON.stringify({ post: postData }), }); return response.json(); }

Other Tools

Related Tools

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/kajirita2002/esa-mcp-server'

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