delete_budget
Remove a budget rule from Kubecost cost management platform to eliminate unwanted spending constraints and maintain accurate cost control policies.
Instructions
Delete a budget rule from Kubecost
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"budgetId": "<budgetId>"
},
"name": "delete_budget"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| budgetId | Yes |
Implementation Reference
- src/index.ts:153-171 (registration)MCP tool registration for 'delete_budget', including input schema { budgetId: z.string() } and inline handler that calls kubecostClient.deleteBudget(budgetId) and returns formatted response
this.tool( 'delete_budget', 'Delete a budget rule from Kubecost', { budgetId: z.string() }, async ({ budgetId }) => { try { await this.kubecostClient.deleteBudget(budgetId); return { isError: false, content: [{ type: 'text', text: `Budget with ID ${budgetId} deleted successfully` }] }; } catch (error) { return { isError: true, content: [{ type: 'text', text: error instanceof Error ? error.message : String(error) }] }; } } ); - src/index.ts:156-156 (schema)Input schema for delete_budget tool using Zod validation
{ budgetId: z.string() }, - src/client/kubecost-client.ts:58-60 (helper)KubecostClient helper method that performs the HTTP DELETE request to delete the budget via Kubecost API
async deleteBudget(budgetId: string): Promise<void> { await this.client.delete(`/model/budget/${budgetId}`); }