Skip to main content
Glama

update_item

Modify existing articles on Qiita by updating titles, content in Markdown format, tags, and privacy settings using the article ID.

Instructions

既存の記事を更新します

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
bodyYes記事の本文(Markdown形式)
itemIdYes記事ID
privateNo非公開記事かどうか
tagsYesタグの配列
titleYes記事のタイトル

Implementation Reference

  • MCP tool handler definition for 'update_item', which destructures the input and delegates to the QiitaApiClient's updateItem method.
    update_item: { schema: updateItemSchema, execute: async ({ itemId, ...rest }, client) => client.updateItem(itemId, rest),
  • Zod input schema for validating 'update_item' tool parameters.
    const updateItemSchema = z.object({ itemId: z.string(), title: z.string(), body: z.string(), tags: z.array(tagSpecificationSchema), private: z.boolean().optional(), });
  • Tool metadata registration for 'update_item' used in MCP list tools response, including JSON input schema.
    { name: 'update_item', description: '既存の記事を更新します', inputSchema: { type: 'object', properties: { itemId: { type: 'string', description: '記事ID', }, title: { type: 'string', description: '記事のタイトル', }, body: { type: 'string', description: '記事の本文(Markdown形式)', }, tags: { type: 'array', description: 'タグの配列', items: { type: 'object', properties: { name: { type: 'string', description: 'タグ名', }, versions: { type: 'array', description: 'タグのバージョン', items: { type: 'string', }, }, }, required: ['name', 'versions'], }, }, private: { type: 'boolean', description: '非公開記事かどうか', default: false, }, }, required: ['itemId', 'title', 'body', 'tags'], }, },
  • QiitaApiClient helper method that executes the HTTP PATCH request to update the specified item on Qiita.
    async updateItem(itemId: string, item: { title: string; body: string; tags: Array<{ name: string; versions: string[] }>; private?: boolean; }) { this.assertAuthenticated(); const response = await this.client.patch(`/items/${itemId}`, item); return response.data; }

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