> ## Documentation Index
> Fetch the complete documentation index at: https://praison.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# API Config • AI Agent SDK

> ApiConfig: Configuration for additive protocol surfaces on the gateway app.

# ApiConfig

> Defined in the [**config**](../modules/config) module.

<Badge color="blue">AI Agent</Badge>

Configuration for additive protocol surfaces on the gateway app.

All surfaces are opt-in. When both are False (default), no extra routes
are mounted and the gateway behaves exactly as before.

Attributes:
openai: Serve OpenAI-compatible endpoints
(`/v1/chat/completions`, `/v1/responses`, `/v1/models`)
backed by the gateway's live agents and sessions.
mcp: Serve an MCP JSON-RPC endpoint (`/mcp`) exposing the gateway's
registered agents as callable tools.

## Properties

<ResponseField name="openai" type="bool">
  No description available.
</ResponseField>

<ResponseField name="mcp" type="bool">
  No description available.
</ResponseField>

## Methods

<CardGroup cols={2}>
  <Card title="enabled()" icon="function" href="../functions/ApiConfig-enabled">
    Whether any additional protocol surface is enabled.
  </Card>
</CardGroup>

<Accordion title="Internal & Generic Methods">
  * **from\_dict**: Create from a parsed `gateway.api` mapping (tolerant of None).
  * **to\_dict**: Convert to dictionary.
</Accordion>

## Source

<Card title="View on GitHub" icon="github" href="https://github.com/MervinPraison/PraisonAI/blob/main/src/praisonai-agents/praisonaiagents/gateway/config.py#L672">
  `praisonaiagents/gateway/config.py` at line 672
</Card>

***

## Related Documentation

<CardGroup cols={2}>
  <Card title="Configuration Overview" icon="gear" href="/docs/docs/configuration/index" />

  <Card title="Agent Config" icon="robot" href="/docs/docs/configuration/agent-config" />
</CardGroup>
