Delete LLM Provider Definition
Endpoint
DELETE /apiops/projects/{projectName}/llm-provider-definitions/{definitionName}/
Authentication
Requires a Personal API Access Token.
Header
Authorization: Bearer YOUR_TOKEN
Request
Headers
| Header | Value | Required |
|---|---|---|
| Authorization | Bearer {token} | Yes |
Path Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| projectName | string | Yes | Project name |
| definitionName | string | Yes | Provider catalog definition name to delete |
Query Parameters
None
Response
Success Response (200 OK)
{
"status": "SUCCESS",
"deploymentResult": {
"success": true
}
}
Response Fields
| Field | Type | Description |
|---|---|---|
| status | string | Response status: SUCCESS or FAILURE |
| deploymentResult | object | Standard write-envelope result; no worker undeploy is involved (see Notes) |
| deploymentResult.success | boolean | true when the definition was removed |
EnumStatus
SUCCESS- Operation successfulFAILURE- Operation failed
Error Response (400 Bad Request)
{
"status": "FAILURE",
"resultMessage": "Provider definition (name: internal-llm-gateway) was not found!"
}
or
{
"status": "FAILURE",
"resultMessage": "Built-in provider definitions are read-only."
}
or
{
"status": "FAILURE",
"resultMessage": "Provider definition name can not be empty!"
}
Error Response (401 Unauthorized)
{
"status": "FAILURE",
"resultMessage": "Token is not valid!"
}
cURL Example
curl -X DELETE \
"https://demo.apinizer.com/apiops/projects/MyProject/llm-provider-definitions/internal-llm-gateway/" \
-H "Authorization: Bearer YOUR_TOKEN"
Permissions
- User must have
AI_DEVELOPMENT+MANAGEpermission in the project
Notes and Warnings
- Name-based Deletion:
- The definition is located by
name(case-insensitive) within the caller's visible scope; a non-existent name returns a400 Bad Requestwith a "was not found" message
- The definition is located by
- Built-in Is Read-Only:
- Deleting a built-in (Mongock seed) definition is rejected with
400 Bad Request("Built-in provider definitions are read-only.")
- Deleting a built-in (Mongock seed) definition is rejected with
- Project Ownership Enforced:
- The service re-verifies the definition belongs to the calling project before deleting, even though the name lookup already scoped to built-in ∪ this project
- No Worker Undeploy:
- Unlike deleting an LLM Provider connection, deleting a catalog definition does not undeploy anything from AI Gateway workers — it only removes the template
- Existing Connections Unaffected:
- Deleting a definition does not delete or break any
ConnectionConfigLlm(LLM Provider) that references it viaproviderDefinitionId; it only removes it from the catalog offered for future connections
- Deleting a definition does not delete or break any
- Irreversible:
- There is no soft-delete; deletion is permanent
Related Documentation
- Get LLM Provider Definition - Retrieve a definition by name before deleting
- List LLM Provider Definitions - List all definitions visible to a project
- Create LLM Provider Definition - Create or upsert a custom definition
- LLM Provider Definitions API - Resource overview, permissions and the LlmProviderDefinition vs. LLM Provider distinction