waroom_delete_service_label
Remove a specific label from a service in Waroom MCP by providing the service name and label UUID to manage service categorization.
Instructions
特定のサービスのラベルを削除します。
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| service_name | Yes | サービス名 | |
| label_uuid | Yes | 削除するラベルのUUID |
Implementation Reference
- src/tools/labels.ts:104-132 (registration)Registers the MCP tool 'waroom_delete_service_label' including input schema validation and the handler function that delegates to WaroomClient.server.tool( 'waroom_delete_service_label', '特定のサービスのラベルを削除します。', { service_name: z.string().min(1).max(100).describe('サービス名'), label_uuid: z.string().uuid().describe('削除するラベルのUUID'), }, async (params) => { try { const response = await waroomClient.deleteServiceLabel( params.service_name, params.label_uuid ); return { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] }; } catch (error) { return { content: [{ type: 'text', text: `サービスラベルの削除に失敗しました: ${error}` }] }; } } );
- src/tools/labels.ts:111-131 (handler)The handler function for the tool, which calls the WaroomClient to delete the label and returns the JSON response or error message.async (params) => { try { const response = await waroomClient.deleteServiceLabel( params.service_name, params.label_uuid ); return { content: [{ type: 'text', text: JSON.stringify(response, null, 2) }] }; } catch (error) { return { content: [{ type: 'text', text: `サービスラベルの削除に失敗しました: ${error}` }] }; } }
- src/tools/labels.ts:107-110 (schema)Zod schema defining the input parameters for the tool: service_name and label_uuid.{ service_name: z.string().min(1).max(100).describe('サービス名'), label_uuid: z.string().uuid().describe('削除するラベルのUUID'), },
- src/WaroomClient.ts:200-207 (helper)Helper method in WaroomClient that performs the HTTP DELETE request to the Waroom API to delete a service label.async deleteServiceLabel(serviceName: string, labelUuid: string) { try { const response = await this.axiosInstance.delete(`${this.baseUrl}/services/${serviceName}/labels/${labelUuid}`); return response.data; } catch (error) { throw new Error(`Failed to delete service label: ${error}`); } }