Examples

Mcp Dispatch

Demonstrates discovery and execution timeout configuration for openai_mcp_connector inside an inference step

Praxis AI v0.13.0 (alpha) 2 min read

Category: Setup-dependent integration
Task: Demonstrates discovery and execution timeout configuration for openai_mcp_connector inside an inference step

Prerequisites: The external service, credentials, or certificates referenced by this configuration.

This configuration comes from the selected release. The example has not been run here; external services are not bundled.

Download the source file.

Companion resources from the same snapshot:

# MCP Connector Filter
# Requires `--features openai-mcp-tools,store-sqlite` because these filters are opt-in.
#
# Demonstrates discovery and execution timeout configuration for
# `openai_mcp_connector` inside an inference step. For a loop that executes the
# model's selected tools, see agentic-loop.yaml.
#
# The connector uses the filtered subrequest executor for both operations.
# Private MCP servers require the global allow_private_upstreams option.

listeners:
  - name: ai-gateway
    address: "127.0.0.1:8080"
    filter_chains: [mcp-connector-pipeline]

filter_chains:
  - name: mcp-connector-pipeline
    filters:
      - filter: ai_operation
      - filter: openai_responses_request
        on_invalid: continue
      - filter: openai_tool_parse
      - filter: iterative_request_router
        initial_step: inference
        max_iterations: 1
        steps:
          - name: inference
            filters:
              - filter: openai_mcp_connector
                discovery_timeout_ms: 5000
                call_timeout_ms: 30000
              - filter: router
                routes:
                  - path_prefix: "/"
                    cluster: "inference"
              - filter: load_balancer
                clusters:
                  - name: "inference"
                    endpoints:
                      - "127.0.0.1:3001"
            on_result:
              - default: true
                done: true

insecure_options:
  allow_private_endpoints: true # example proxies to local backends