Configuration File
Editdocker/assistant-api/.assistant.env before starting the service.
For local development (without Docker), export the variables and override the Docker hostnames shown in the table below.
Required Variables
| Variable | Default | Description |
|---|---|---|
SECRET | rpd_pks | JWT signing secret — must be identical across all services |
POSTGRES__HOST | postgres | PostgreSQL host |
POSTGRES__DB_NAME | assistant_db | Database name |
POSTGRES__AUTH__USER | rapida_user | Database user |
POSTGRES__AUTH__PASSWORD | rapida_db_password | Database password |
REDIS__HOST | redis | Redis host |
OPENSEARCH__HOST | (empty) | OpenSearch host — optional, leave empty to disable knowledge base |
INTEGRATION_HOST | integration-api:9004 | integration-api gRPC address |
ENDPOINT_HOST | endpoint-api:9005 | endpoint-api gRPC address |
WEB_HOST | web-api:9001 | web-api gRPC address |
DOCUMENT_HOST | (empty) | document-api HTTP address — optional, only needed for knowledge base |
PUBLIC_ASSISTANT_HOST | — | Publicly reachable hostname for telephony callbacks and WebSocket media |
Service Identity
| Variable | Default | Description |
|---|---|---|
SERVICE_NAME | workflow-api | Internal service name label |
HOST | 0.0.0.0 | Bind address |
PORT | 9007 | HTTP / gRPC / WebSocket port (cmux) |
LOG_LEVEL | debug | debug · info · warn · error |
ENV | development | development · staging · production |
PostgreSQL
| Variable | Default | Description |
|---|---|---|
POSTGRES__HOST | postgres | Host (localhost for local dev) |
POSTGRES__PORT | 5432 | Port |
POSTGRES__DB_NAME | assistant_db | Database name |
POSTGRES__AUTH__USER | rapida_user | User |
POSTGRES__AUTH__PASSWORD | rapida_db_password | Password |
POSTGRES__MAX_OPEN_CONNECTION | 50 | Connection pool size |
POSTGRES__MAX_IDEAL_CONNECTION | 25 | Idle connections |
POSTGRES__SSL_MODE | disable | disable · require · verify-full |
POSTGRES__SLC_CACHE__HOST | redis | Redis host for second-level GORM cache |
POSTGRES__SLC_CACHE__PORT | 6379 | Redis port for GORM cache |
POSTGRES__SLC_CACHE__DB | 1 | Redis DB index for GORM cache |
POSTGRES__SLC_CACHE__MAX_CONNECTION | 10 | Redis pool size |
Redis
| Variable | Default | Description |
|---|---|---|
REDIS__HOST | redis | Redis host (localhost for local dev) |
REDIS__PORT | 6379 | Redis port |
REDIS__MAX_CONNECTION | 10 | Connection pool size |
REDIS__MAX_DB | 0 | Redis DB index |
OpenSearch (Optional — Knowledge Base Only)
OpenSearch is only needed for knowledge base / RAG features. IfOPENSEARCH__HOST is left empty (the default), the assistant-api starts without knowledge base support and skips the OpenSearch connection entirely.
| Variable | Default | Description |
|---|---|---|
OPENSEARCH__SCHEMA | http | http · https |
OPENSEARCH__HOST | (empty) | OpenSearch host — leave empty to disable knowledge base |
OPENSEARCH__PORT | 9200 | OpenSearch port |
OPENSEARCH__MAX_RETRIES | 3 | Request retry count |
OPENSEARCH__MAX_CONNECTION | 10 | Connection pool size |
Asset Storage
| Variable | Default | Description |
|---|---|---|
ASSET_STORE__STORAGE_TYPE | local | local · s3 · azure |
ASSET_STORE__STORAGE_PATH_PREFIX | /app/rapida-data/assets/workflow | Path for local storage |
ASSET_STORE__PUBLIC_URL_PREFIX | http://localhost:8080/rapida-data/assets/workflow | Public URL for serving stored assets |
Telemetry (Optional)
assistant-api supports an optional environment-configured default telemetry exporter.
Set exporter type:
| Variable | Default | Description |
|---|---|---|
TELEMETRY__TYPE | (empty) | otlp_http · otlp_grpc · xray · google_trace · azure_monitor · datadog · opensearch · logging |
OTLP HTTP
| Variable | Description |
|---|---|
TELEMETRY__OTLP_HTTP__ENDPOINT | OTLP endpoint |
TELEMETRY__OTLP_HTTP__PROTOCOL | http/protobuf or grpc |
TELEMETRY__OTLP_HTTP__HEADERS | Comma-separated headers (A=B, C=D) |
TELEMETRY__OTLP_HTTP__INSECURE | true/false |
OTLP gRPC
| Variable | Description |
|---|---|
TELEMETRY__OTLP_GRPC__ENDPOINT | OTLP endpoint |
TELEMETRY__OTLP_GRPC__PROTOCOL | Usually grpc |
TELEMETRY__OTLP_GRPC__HEADERS | Comma-separated headers |
TELEMETRY__OTLP_GRPC__INSECURE | true/false |
Datadog
| Variable | Description |
|---|---|
TELEMETRY__DATADOG__ENDPOINT | Datadog OTLP/agent endpoint |
TELEMETRY__DATADOG__PROTOCOL | Protocol override |
TELEMETRY__DATADOG__HEADERS | Additional headers |
TELEMETRY__DATADOG__API_KEY | Datadog API key |
TELEMETRY__DATADOG__INSECURE | true/false |
AWS X-Ray
| Variable | Description |
|---|---|
TELEMETRY__XRAY__ENDPOINT | ADOT/OTLP endpoint |
TELEMETRY__XRAY__PROTOCOL | Protocol override |
TELEMETRY__XRAY__REGION | AWS region |
TELEMETRY__XRAY__INSECURE | true/false |
Google Trace
| Variable | Description |
|---|---|
TELEMETRY__GOOGLE_TRACE__ENDPOINT | Trace endpoint |
TELEMETRY__GOOGLE_TRACE__HEADERS | Additional headers |
TELEMETRY__GOOGLE_TRACE__API_KEY | API key |
TELEMETRY__GOOGLE_TRACE__ACCESS_TOKEN | OAuth bearer token |
TELEMETRY__GOOGLE_TRACE__INSECURE | true/false |
Azure Monitor
| Variable | Description |
|---|---|
TELEMETRY__AZURE_MONITOR__ENDPOINT | Azure Monitor endpoint |
TELEMETRY__AZURE_MONITOR__HEADERS | Additional headers |
TELEMETRY__AZURE_MONITOR__API_KEY | API key/instrumentation key |
TELEMETRY__AZURE_MONITOR__INSECURE | true/false |
OpenSearch / Logging
| Variable | Description |
|---|---|
TELEMETRY__OPENSEARCH__INDEX_PREFIX | Optional index prefix |
TELEMETRY__LOGGING__* | No options required |
Asterisk AudioSocket
The AudioSocket server binds on a separate TCP port. Asterisk dials into this port directly.| Variable | Default | Description |
|---|---|---|
AUDIOSOCKET__HOST | 0.0.0.0 | Bind address for the AudioSocket TCP server |
AUDIOSOCKET__PORT | 4573 | TCP port for AudioSocket connections |
SIP Server
The built-in SIP server handles direct SIP INVITE connections and Asterisk SIP trunk connections.| Variable | Default | Description |
|---|---|---|
SIP__SERVER | 0.0.0.0 | Bind address for SIP |
SIP__EXTERNAL_IP | 0.0.0.0 | Public IP advertised in SDP and SIP Contact headers — must be your server’s public IP |
SIP__PORT | 5090 | SIP signalling port (UDP) |
SIP__TRANSPORT | udp | udp · tcp |
SIP__RTP_PORT_RANGE_START | 10000 | RTP media port range start |
SIP__RTP_PORT_RANGE_END | 20000 | RTP media port range end |
Full Environment File
Local Development Overrides
When running from source, override Docker hostnames:Next Steps
STT / TTS Providers
Configure and add speech recognition and synthesis providers.
Telephony
Twilio, Asterisk, SIP, and other telephony provider setup.