Skip to main content
Glama

follow_tag

Follow specific tags on Qiita to receive updates and discover relevant content from the Japanese developer community platform.

Instructions

指定されたタグをフォローします

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
tagIdYesタグID

Implementation Reference

  • The handler for the 'follow_tag' tool. It validates the input using tagIdSchema and executes the followTag method on the Qiita API client.
    follow_tag: { schema: tagIdSchema, execute: async ({ tagId }, client) => client.followTag(tagId), },
  • Zod schema definition for tagId input parameter used in the follow_tag handler and other tag-related tools.
    const tagIdSchema = z.object({ tagId: z.string(), });
  • Tool metadata including name, description, and JSON input schema provided in the MCP listTools response.
    name: 'follow_tag', description: '指定されたタグをフォローします', inputSchema: { type: 'object', properties: { tagId: { type: 'string', description: 'タグID', }, }, required: ['tagId'], }, },
  • Implementation of the followTag method in the Qiita API client, which sends a PUT request to the Qiita API to follow the specified tag.
    async followTag(tagId: string) { this.assertAuthenticated(); await this.client.put(`/tags/${tagId}/following`); return { success: true }; }
  • src/index.ts:11-36 (registration)
    Registration of tools via the toolHandlers object imported and dynamically dispatched in the MCP server request handler for CallToolRequest.
    import { toolHandlers } from './tools/handlers.js'; import { tools } from './tools/definitions.js'; const server = new Server( { name: 'mcp-server-qiita', version: '1.0.0', }, { capabilities: { tools: {}, }, } ); server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools }; }); server.setRequestHandler(CallToolRequestSchema, async (request) => { const { name, arguments: args } = request.params; const accessToken = process.env.QIITA_ACCESS_TOKEN; const qiita = new QiitaApiClient(accessToken); const handler = toolHandlers[name];

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/Selenium39/mcp-server-qiita'

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