code: def create_route(
      name: str,
      route_type: Optional[str] = None,
      model: Optional[Dict[str, Any]] = None,
  ) -> Route:
      """
      Create a new route in the Gateway.
  
      .. warning::
  
          This API is ``only available`` when running within Databricks. When running elsewhere,
          route configuration is handled via updates to the route configuration YAML file that
          is specified during Gateway server start.
  
      Args:
          name: The name of the route. This parameter is required for all routes.
          route_type: The type of the route (e.g., 'llm/v1/chat', 'llm/v1/completions',
              'llm/v1/embeddings'). This parameter is required for routes that are
              not managed by Databricks (the provider isn't 'databricks').
          model: A dictionary representing the model details to be associated with the route.
              This parameter is required for all routes. This dictionary should define:
              - The model name (e.g., "gpt-3.5-turbo")
              - The provider (e.g., "openai", "anthropic")
              - The configuration for the model used in the route
  
      Returns:
          A serialized representation of the `Route` data structure,
          providing information about the name, type, and model details for the
          newly created route endpoint.
  
      .. note::
  
          See the official Databricks documentation for MLflow Gateway for examples of supported
          model configurations and how to dynamically create new routes within Databricks.
  
      Example usage from within Databricks:
  
      .. code-block:: python
  
          from mlflow.gateway import set_gateway_uri, create_route
  
          set_gateway_uri(gateway_uri="databricks")
  
          openai_api_key = ...
  
          create_route(
              name="my-route",
              route_type="llm/v1/completions",
              model={
                  "name": "question-answering-bot",
                  "provider": "openai",
                  "openai_config": {
                      "openai_api_key": openai_api_key,
                  },
              },
          )
      """
      return MlflowGatewayClient().create_route(name, route_type, model)
  
file_path: mlflow/mlflow/gateway/fluent.py
imports: from typing import Any, Dict, List, Optional
  from mlflow.gateway.client import MlflowGatewayClient
  from mlflow.gateway.config import LimitsConfig, Route
  from mlflow.gateway.constants import MLFLOW_GATEWAY_SEARCH_ROUTES_PAGE_SIZE
  from mlflow.gateway.utils import gateway_deprecated
  from mlflow.utils import get_results_from_paginated_fn
label_desc: Use image node_id 3 for calling a global function with example usage: create_route(name, route_type, model) and returns: MlflowGatewayClient