mcpField
D
delete-model

delete-model

github.com/berriaiCloud & DevOps103132 installsUpdated 25w ago
Repository

About delete-model

delete-model is a skill for removing a model from a live LiteLLM proxy. It looks up a model ID when needed, asks for confirmation before deletion, and reports that keys scoped to the model name may then return errors.

Key features

  1. 01Look up model IDs by name
  2. 02Request confirmation before deletion
  3. 03Delete a model through the proxy API
  4. 04Warn about affected scoped keys

Use cases

  1. 01Remove a retired model from a LiteLLM proxy
  2. 02Find a model ID before requesting its removal

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/berriai/litellm-skills --skill delete-model

After installing, type/delete-modelin Claude Code to confirm it loaded.

Details

From the project README

Delete Model

Remove a model from a live LiteLLM proxy.

Setup

LITELLM_BASE_URL  — e.g. https://my-proxy.example.com
LITELLM_API_KEY   — proxy admin key

Ask the user

  1. Model name or model_id — if they give a name, look up the ID first:
    curl -s "$BASE/model/info" -H "Authorization: Bearer $KEY" | python3 -c "
    import sys,json
    for m in json.load(sys.stdin).get('data',[]):
      print(m['model_info']['id'], m['model_name'])
    "
    
  2. Confirm — show the model name and ask for confirmation before deleting.

Run

curl -s -X POST "$BASE/model/delete" \
  -H "Authorization: Bearer $KEY" \
  -H "Content-Type: application/json" \
  -d '{"id": "<model_id>"}'

Output

Show the success message. Warn the user that any keys scoped to this model name will start getting errors.

Comments

Markdown supported