{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/bookmyhost/json-schema/bookmyhost-generate-key-response-schema.json",
  "title": "GenerateKeyResponse",
  "x-generated": "2026-11-12",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/bookmyhost-key-management-api-openapi.yml#/components/schemas/GenerateKeyResponse",
  "properties": {
    "key_alias": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Key Alias"
    },
    "duration": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Duration"
    },
    "models": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Models",
      "default": []
    },
    "spend": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ],
      "title": "Spend",
      "default": 0
    },
    "max_budget": {
      "anyOf": [
        {
          "type": "number"
        },
        {
          "type": "null"
        }
      ],
      "title": "Max Budget"
    },
    "user_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "User Id"
    },
    "team_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Team Id"
    },
    "agent_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Agent Id"
    },
    "max_parallel_requests": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Max Parallel Requests"
    },
    "metadata": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Metadata",
      "default": {}
    },
    "tpm_limit": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tpm Limit"
    },
    "rpm_limit": {
      "anyOf": [
        {
          "type": "integer"
        },
        {
          "type": "null"
        }
      ],
      "title": "Rpm Limit"
    },
    "budget_duration": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Budget Duration"
    },
    "budget_limits": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/BudgetLimitEntry"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Budget Limits"
    },
    "allowed_cache_controls": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Cache Controls",
      "default": []
    },
    "config": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Config",
      "default": {}
    },
    "permissions": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Permissions",
      "default": {}
    },
    "model_max_budget": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Model Max Budget",
      "default": {}
    },
    "budget_fallbacks": {
      "anyOf": [
        {
          "additionalProperties": {
            "items": {
              "type": "string"
            },
            "type": "array"
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Budget Fallbacks"
    },
    "model_rpm_limit": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Model Rpm Limit"
    },
    "model_tpm_limit": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Model Tpm Limit"
    },
    "mcp_rpm_limit": {
      "anyOf": [
        {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Mcp Rpm Limit"
    },
    "tag_rpm_limit": {
      "anyOf": [
        {
          "additionalProperties": {
            "type": "integer"
          },
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tag Rpm Limit"
    },
    "guardrails": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Guardrails"
    },
    "policies": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Policies"
    },
    "prompts": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Prompts"
    },
    "blocked": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Blocked"
    },
    "aliases": {
      "anyOf": [
        {
          "additionalProperties": true,
          "type": "object"
        },
        {
          "type": "null"
        }
      ],
      "title": "Aliases",
      "default": {}
    },
    "object_permission": {
      "anyOf": [
        {
          "$ref": "#/$defs/LiteLLM_ObjectPermissionBase"
        },
        {
          "type": "null"
        }
      ]
    },
    "key": {
      "type": "string",
      "title": "Key"
    },
    "budget_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Budget Id"
    },
    "tags": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Tags"
    },
    "disable_global_guardrails": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Disable Global Guardrails"
    },
    "throttle_on_budget_exceeded": {
      "anyOf": [
        {
          "type": "boolean"
        },
        {
          "type": "null"
        }
      ],
      "title": "Throttle On Budget Exceeded"
    },
    "enforced_params": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Enforced Params"
    },
    "allowed_routes": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Routes",
      "default": []
    },
    "allowed_passthrough_routes": {
      "anyOf": [
        {
          "items": {},
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Passthrough Routes"
    },
    "allowed_vector_store_indexes": {
      "anyOf": [
        {
          "items": {
            "$ref": "#/$defs/AllowedVectorStoreIndexItem"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Allowed Vector Store Indexes"
    },
    "rpm_limit_type": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "guaranteed_throughput",
            "best_effort_throughput",
            "dynamic"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Rpm Limit Type"
    },
    "tpm_limit_type": {
      "anyOf": [
        {
          "type": "string",
          "enum": [
            "guaranteed_throughput",
            "best_effort_throughput",
            "dynamic"
          ]
        },
        {
          "type": "null"
        }
      ],
      "title": "Tpm Limit Type"
    },
    "router_settings": {
      "anyOf": [
        {
          "$ref": "#/$defs/UpdateRouterConfig"
        },
        {
          "type": "null"
        }
      ]
    },
    "access_group_ids": {
      "anyOf": [
        {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        {
          "type": "null"
        }
      ],
      "title": "Access Group Ids"
    },
    "key_name": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Key Name"
    },
    "expires": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Expires"
    },
    "token_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Token Id"
    },
    "organization_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Organization Id"
    },
    "project_id": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Project Id"
    },
    "litellm_budget_table": {
      "anyOf": [
        {},
        {
          "type": "null"
        }
      ],
      "title": "Litellm Budget Table"
    },
    "token": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Token"
    },
    "created_by": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Created By"
    },
    "updated_by": {
      "anyOf": [
        {
          "type": "string"
        },
        {
          "type": "null"
        }
      ],
      "title": "Updated By"
    },
    "created_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Created At"
    },
    "updated_at": {
      "anyOf": [
        {
          "type": "string",
          "format": "date-time"
        },
        {
          "type": "null"
        }
      ],
      "title": "Updated At"
    }
  },
  "type": "object",
  "required": [
    "key"
  ],
  "$defs": {
    "AllowedVectorStoreIndexItem": {
      "properties": {
        "index_name": {
          "type": "string",
          "title": "Index Name"
        },
        "index_permissions": {
          "items": {
            "type": "string",
            "enum": [
              "read",
              "write"
            ]
          },
          "type": "array",
          "title": "Index Permissions"
        }
      },
      "type": "object",
      "required": [
        "index_name",
        "index_permissions"
      ],
      "title": "AllowedVectorStoreIndexItem"
    },
    "BudgetLimitEntry": {
      "properties": {
        "budget_duration": {
          "type": "string",
          "title": "Budget Duration"
        },
        "max_budget": {
          "type": "number",
          "title": "Max Budget"
        },
        "reset_at": {
          "anyOf": [
            {
              "type": "string",
              "format": "date-time"
            },
            {
              "type": "null"
            }
          ],
          "title": "Reset At"
        }
      },
      "type": "object",
      "required": [
        "budget_duration",
        "max_budget"
      ],
      "title": "BudgetLimitEntry",
      "description": "A single budget window with its own limit and independent reset schedule."
    },
    "LiteLLM_ObjectPermissionBase": {
      "properties": {
        "mcp_servers": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mcp Servers"
        },
        "mcp_access_groups": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mcp Access Groups"
        },
        "mcp_tool_permissions": {
          "anyOf": [
            {
              "additionalProperties": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mcp Tool Permissions"
        },
        "mcp_toolsets": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mcp Toolsets"
        },
        "blocked_tools": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Blocked Tools"
        },
        "vector_stores": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Vector Stores"
        },
        "agents": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Agents"
        },
        "agent_access_groups": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Agent Access Groups"
        },
        "models": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Models"
        },
        "search_tools": {
          "anyOf": [
            {
              "items": {
                "type": "string"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Search Tools"
        },
        "mcp_tool_search_enabled": {
          "anyOf": [
            {
              "type": "boolean"
            },
            {
              "type": "null"
            }
          ],
          "title": "Mcp Tool Search Enabled"
        }
      },
      "type": "object",
      "title": "LiteLLM_ObjectPermissionBase"
    },
    "RetryPolicy": {
      "properties": {
        "BadRequestErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Badrequesterrorretries"
        },
        "AuthenticationErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Authenticationerrorretries"
        },
        "TimeoutErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Timeouterrorretries"
        },
        "RateLimitErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Ratelimiterrorretries"
        },
        "ContentPolicyViolationErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Contentpolicyviolationerrorretries"
        },
        "InternalServerErrorRetries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Internalservererrorretries"
        }
      },
      "type": "object",
      "title": "RetryPolicy",
      "description": "Use this to set a custom number of retries per exception type\nIf RateLimitErrorRetries = 3, then 3 retries will be made for RateLimitError\nMapping of Exception type to number of retries\nhttps://docs.litellm.ai/docs/exception_mapping"
    },
    "RoutingGroup": {
      "properties": {
        "group_name": {
          "type": "string",
          "title": "Group Name"
        },
        "models": {
          "items": {
            "type": "string"
          },
          "type": "array",
          "title": "Models"
        },
        "routing_strategy": {
          "type": "string",
          "title": "Routing Strategy"
        },
        "routing_strategy_args": {
          "anyOf": [
            {
              "additionalProperties": true,
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Routing Strategy Args"
        }
      },
      "type": "object",
      "required": [
        "group_name",
        "models",
        "routing_strategy"
      ],
      "title": "RoutingGroup",
      "description": "A group of models that share a routing strategy."
    },
    "UpdateRouterConfig": {
      "properties": {
        "routing_strategy_args": {
          "anyOf": [
            {
              "additionalProperties": true,
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Routing Strategy Args"
        },
        "routing_strategy": {
          "anyOf": [
            {
              "type": "string"
            },
            {
              "type": "null"
            }
          ],
          "title": "Routing Strategy"
        },
        "routing_groups": {
          "anyOf": [
            {
              "items": {
                "$ref": "#/$defs/RoutingGroup"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Routing Groups"
        },
        "retry_policy": {
          "anyOf": [
            {
              "$ref": "#/$defs/RetryPolicy"
            },
            {
              "type": "null"
            }
          ]
        },
        "model_group_retry_policy": {
          "anyOf": [
            {
              "additionalProperties": {
                "$ref": "#/$defs/RetryPolicy"
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Model Group Retry Policy"
        },
        "model_group_affinity_config": {
          "anyOf": [
            {
              "additionalProperties": {
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Model Group Affinity Config"
        },
        "allowed_fails": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Allowed Fails"
        },
        "cooldown_time": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "title": "Cooldown Time"
        },
        "num_retries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Num Retries"
        },
        "timeout": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "title": "Timeout"
        },
        "max_retries": {
          "anyOf": [
            {
              "type": "integer"
            },
            {
              "type": "null"
            }
          ],
          "title": "Max Retries"
        },
        "retry_after": {
          "anyOf": [
            {
              "type": "number"
            },
            {
              "type": "null"
            }
          ],
          "title": "Retry After"
        },
        "fallbacks": {
          "anyOf": [
            {
              "items": {
                "additionalProperties": true,
                "type": "object"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Fallbacks"
        },
        "context_window_fallbacks": {
          "anyOf": [
            {
              "items": {
                "additionalProperties": true,
                "type": "object"
              },
              "type": "array"
            },
            {
              "type": "null"
            }
          ],
          "title": "Context Window Fallbacks"
        },
        "model_group_alias": {
          "anyOf": [
            {
              "additionalProperties": {
                "anyOf": [
                  {
                    "type": "string"
                  },
                  {
                    "additionalProperties": true,
                    "type": "object"
                  }
                ]
              },
              "type": "object"
            },
            {
              "type": "null"
            }
          ],
          "title": "Model Group Alias",
          "default": {}
        }
      },
      "type": "object",
      "title": "UpdateRouterConfig",
      "description": "Set of params that you can modify via `router.update_settings()`."
    }
  }
}