{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/componecat-ai/json-schema/componecat-ai-update-aimodel-request-schema.json",
  "title": "UpdateAIModelRequest",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/componecat-ai-ai-models-api-openapi.yml#/components/schemas/UpdateAIModelRequest",
  "required": [
    "name",
    "provider",
    "modelId",
    "properties",
    "secrets",
    "isDefault",
    "enabled",
    "clearedSecretKeys"
  ],
  "type": "object",
  "properties": {
    "name": {
      "type": [
        "null",
        "string"
      ]
    },
    "provider": {
      "type": [
        "null",
        "string"
      ]
    },
    "modelId": {
      "type": [
        "null",
        "string"
      ]
    },
    "properties": {
      "type": [
        "null",
        "array"
      ],
      "items": {
        "$ref": "#/$defs/AIModelPropertyRequest"
      }
    },
    "secrets": {
      "type": [
        "null",
        "array"
      ],
      "items": {
        "$ref": "#/$defs/AIModelPropertyRequest"
      }
    },
    "isDefault": {
      "type": [
        "null",
        "boolean"
      ]
    },
    "enabled": {
      "type": [
        "null",
        "boolean"
      ]
    },
    "clearedSecretKeys": {
      "type": [
        "null",
        "array"
      ],
      "items": {
        "type": "string"
      }
    }
  },
  "$defs": {
    "AIModelPropertyRequest": {
      "required": [
        "key",
        "value"
      ],
      "type": "object",
      "properties": {
        "key": {
          "type": "string"
        },
        "value": {
          "type": "string"
        }
      }
    }
  }
}