waroom_create_incident
Create incidents in Waroom by specifying service name, title, severity, and description to track and manage operational issues.
Instructions
インシデントを作成します。
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| service_name | Yes | サービス名またはサービスID | |
| title | Yes | インシデントのタイトル(1-255文字) | |
| severity | Yes | 重要度(critical, high, low, info, unknown) | |
| description | Yes | インシデントの説明 | |
| experimental | No | 実験的なインシデントかどうか(デフォルト: false) | |
| is_private | No | プライベートインシデントかどうか(デフォルト: false) |
Implementation Reference
- src/tools/incidents.ts:17-41 (handler)The async handler that executes the waroom_create_incident tool logic by calling waroomClient.createIncident and returning the JSON response or error.async (params) => { try { const response = await waroomClient.createIncident( params.service_name, params.title, params.severity, params.description, params.experimental, params.is_private ); return { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] }; } catch (error) { return { content: [{ type: 'text', text: `インシデントの作成に失敗しました: ${error}` }] }; } }
- src/tools/incidents.ts:10-16 (schema)Zod input schema defining parameters for the waroom_create_incident tool.service_name: z.string().min(1).describe('サービス名またはサービスID'), title: z.string().min(1).max(255).describe('インシデントのタイトル(1-255文字)'), severity: z.enum(['critical', 'high', 'low', 'info', 'unknown']).describe('重要度(critical, high, low, info, unknown)'), description: z.string().min(1).describe('インシデントの説明'), experimental: z.boolean().default(false).describe('実験的なインシデントかどうか(デフォルト: false)'), is_private: z.boolean().default(false).describe('プライベートインシデントかどうか(デフォルト: false)'), },
- src/tools/incidents.ts:6-42 (registration)Registration of the waroom_create_incident tool using server.tool, including description, schema, and handler.server.tool( 'waroom_create_incident', 'インシデントを作成します。', { service_name: z.string().min(1).describe('サービス名またはサービスID'), title: z.string().min(1).max(255).describe('インシデントのタイトル(1-255文字)'), severity: z.enum(['critical', 'high', 'low', 'info', 'unknown']).describe('重要度(critical, high, low, info, unknown)'), description: z.string().min(1).describe('インシデントの説明'), experimental: z.boolean().default(false).describe('実験的なインシデントかどうか(デフォルト: false)'), is_private: z.boolean().default(false).describe('プライベートインシデントかどうか(デフォルト: false)'), }, async (params) => { try { const response = await waroomClient.createIncident( params.service_name, params.title, params.severity, params.description, params.experimental, params.is_private ); return { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] }; } catch (error) { return { content: [{ type: 'text', text: `インシデントの作成に失敗しました: ${error}` }] }; } } );
- src/main.ts:26-26 (registration)Top-level call to createIncidentsTools which registers the waroom_create_incident tool (and other incident tools).createIncidentsTools(server, waroomClient);