Skip to main content

GatewayConfig

Defined in the config module.
AI Agent Configuration for the gateway server. Attributes: host: Host to bind to port: Port to listen on cors_origins: Allowed CORS origins allowed_origins: Allowed origins for WebSocket connections (CSWSH defense) auth_token: Optional authentication token max_connections: Maximum concurrent connections max_sessions_per_agent: Maximum sessions per agent (0 = unlimited) session_config: Default session configuration heartbeat_interval: Heartbeat interval in seconds reconnect_timeout: Time to wait for reconnection before closing session ssl_cert: Path to SSL certificate (for HTTPS/WSS) ssl_key: Path to SSL key max_buffered_bytes: Maximum buffered bytes before slow consumer disconnect (default 1MB) max_queued_frames: Maximum queued outbound frames per client before slow consumer disconnect (0 = unlimited frame count; byte ceiling still applies). Default 1000. push: Push notification service configuration auth_scopes: Optional operator scope policy mapping token -> list of scope names (see OperatorScope). When None/empty (default), any successfully authenticated client is granted all scopes — identical to the previous binary behaviour. Single-operator setups are unaffected.

Properties

str
No description available.
int
No description available.
Optional[str]
No description available.
List[str]
No description available.
List[str]
No description available.
Optional[str]
No description available.
int
No description available.
int
No description available.
SessionConfig
No description available.
int
No description available.
int
No description available.
float
No description available.
Optional[str]
No description available.
Optional[str]
No description available.
int
No description available.
int
No description available.
int
No description available.
int
No description available.
str
No description available.
int
No description available.
int
No description available.
PushConfig
No description available.
Optional
No description available.
ApiConfig
No description available.
LivenessConfig
No description available.
TurnLockConfig
No description available.

Methods

has_scope_policy()

Whether an operator scope policy is configured.

resolve_scopes()

Resolve the operator scopes granted to token.

is_secure()

Whether SSL/TLS is enabled.

ws_url()

WebSocket URL for this gateway.

http_url()

HTTP URL for this gateway.
  • to_dict: Convert to dictionary (hides sensitive data).

Source

View on GitHub

praisonaiagents/gateway/config.py at line 710

Configuration Overview

Agent Config

Gateway Feature