v3
latestOpenAPI 3.1.02026-07-311,4541,5202.3 MBDelete Custom Provider
Retrieve, update, and delete individual custom LLM providers
Supports both internal (JWT) and public (API key) authentication.
- Internal API: Returns all fields
- Public API: Hides internal fields (litellm_provider_id, is_managed, moderation)
Access control (layered): 1. SuperAdminMixin: Routes queryset (superadmins see all, users see own org) + auto-registers ObjectOwnershipPermission for object-level ownership checks 2. Server-side org assignment: Prevents cross-org writes via request body
Endpoints: Platform (JWT auth, uses numeric pk): GET /llm_models/custom_providers/{pk}/ - Retrieve a specific custom provider PATCH /llm_models/custom_providers/{pk}/ - Update a specific custom provider DELETE /llm_models/custom_providers/{pk}/ - Delete a specific custom provider Public API (API key auth, uses provider_id string): GET /api/providers/{provider_id}/ - Retrieve a specific custom provider PATCH /api/providers/{provider_id}/ - Update a specific custom provider DELETE /api/providers/{provider_id}/ - Delete a specific custom provider
Args (PATCH): - provider_name (Optional): Updated provider name - litellm_provider_id (Optional): Updated base provider ID - moderation (Optional): Updated moderation setting - extra_kwargs (Optional): Updated additional configuration (all credentials live here) * api_key: Updated provider API key * base_url: Updated custom base URL for the provider's API * temperature: Updated default temperature setting * max_tokens: Updated default max tokens setting * timeout: Updated request timeout in seconds
Returns (GET): { "id": 123, "provider_id": "my-custom-openai", "provider_name": "My Custom OpenAI Provider", "litellm_provider_id": "openai", "moderation": "filtered", "extra_kwargs": { "api_key": "sk-custom-key-123", "base_url": "https://api.my-custom-provider.com/v1", "temperature": 0.7, "max_tokens": 4096 }, "organization": 456, "created_at": "2024-01-15T10:30:00Z", "updated_at": "2024-01-15T11:00:00Z" }
Returns (PATCH): { "id": 123, "provider_id": "my-custom-openai", "provider_name": "My Updated Custom OpenAI Provider", "extra_kwargs": { "api_key": "sk-updated-key-456", "base_url": "https://api.my-updated-provider.com/v1", "temperature": 0.8, "max_tokens": 8192 }, ... }
Path parameters
Headers
Use your Respan API key for Respan API authentication. Enter only the Respan API key value; clients send Authorization: Bearer <RESPAN_API_KEY>. For /api/responses, provider credentials such as Perplexity, OpenAI, or Azure OpenAI go in Settings -> Providers or respan_params.credential_override in the request body, not in this authentication field.
Response
Successful response