get_tag_items
Retrieve articles associated with a specific tag from Qiita, the Japanese developer community platform, using tag ID and pagination parameters.
Instructions
指定されたタグの記事一覧を取得します
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| tagId | Yes | タグID | |
| page | No | ページ番号(1-100) | |
| perPage | No | 1ページあたりの件数(1-100) |
Implementation Reference
- src/tools/handlers.ts:136-140 (handler)Handler definition for the 'get_tag_items' tool. It defines the input schema by merging tagIdSchema and paginationSchema, and the execute function which calls client.getTagItems with the parsed arguments.get_tag_items: { schema: tagIdSchema.merge(paginationSchema), execute: async ({ tagId, page, perPage }, client) => client.getTagItems(tagId, page, perPage), },
- src/tools/definitions.ts:398-421 (schema)MCP tool schema definition for 'get_tag_items', including name, description, and inputSchema for tool listing.{ name: 'get_tag_items', description: '指定されたタグの記事一覧を取得します', inputSchema: { type: 'object', properties: { tagId: { type: 'string', description: 'タグID', }, page: { type: 'number', description: 'ページ番号(1-100)', default: 1, }, perPage: { type: 'number', description: '1ページあたりの件数(1-100)', default: 20, }, }, required: ['tagId'], }, },
- src/qiitaApiClient.ts:149-154 (helper)Supporting method in QiitaApiClient that performs the actual API call to retrieve items associated with a specific tag from the Qiita API.async getTagItems(tagId: string, page = 1, perPage = 20) { const response = await this.client.get(`/tags/${tagId}/items`, { params: { page, per_page: perPage }, }); return response.data; }