Connection Management APIs
APIs for creating and managing connections to your data sources. Connect to Elasticsearch, OpenSearch, Snowflake, and 50+ other data sources to query them in place.
Create Connection
Create a new connection to an external data source.
Endpoint
POST /source/{source_type}
Example:
POST /source/elasticsearch
Request Body
{
"connector_id": "elasticsearch",
"name": "Production ES Cluster",
"config": {
"host": "https://es-cluster.example.com:9200",
"username": "admin",
"password": "secret",
"ssl_verify": true
}
}
Response
{
"connection_id": "conn_abc123",
"connector_id": "elasticsearch",
"name": "Production ES Cluster",
"status": "active",
"created_at": "2024-10-15T10:30:00Z"
}
List Connections
Get all configured connections.
Endpoint
GET /sources/connections
Response
[
{
"connection_id": "conn_abc123",
"connector_id": "elasticsearch",
"name": "Production ES Cluster",
"status": "active",
"created_at": "2024-10-15T10:30:00Z",
"last_used_at": "2024-10-15T12:00:00Z"
}
]
Get Connection Details
Retrieve details for a specific connection.
Endpoint
GET /source/{connection_id}
Response
{
"connection_id": "conn_abc123",
"connector_id": "elasticsearch",
"name": "Production ES Cluster",
"status": "active",
"config": {
"host": "https://es-cluster.example.com:9200"
},
"created_at": "2024-10-15T10:30:00Z",
"last_used_at": "2024-10-15T12:00:00Z"
}
Test Connection
Verify connectivity and credentials.
Endpoint
POST /source/{connection_id}/test
Response
{
"status": "success",
"message": "Connection successful",
"datasets_available": 42
}
Update Connection
Update connection configuration.
Endpoint
PATCH /source/{connection_id}
Request Body
{
"name": "Updated Connection Name",
"config": {
"host": "https://new-cluster.example.com:9200"
}
}
Delete Connection
Remove a connection.
Endpoint
DELETE /source/{connection_id}
Response
{
"acknowledged": true,
"connection_id": "conn_abc123"
}
List Available Connectors
Get all available connector types.
Endpoint
GET /_connector/connectors
Response
[
{
"id": "elasticsearch",
"name": "Elasticsearch",
"category": "Search & Analytics",
"description": "Connect to Elasticsearch clusters"
},
{
"id": "opensearch",
"name": "OpenSearch",
"category": "Search & Analytics",
"description": "Connect to OpenSearch clusters"
},
{
"id": "snowflake",
"name": "Snowflake",
"category": "Data Warehouse",
"description": "Connect to Snowflake data warehouses"
}
]
Query Connected Sources
Once connected, query external data using standard Infino APIs with the connectionId parameter:
SQL Query
POST /_sql?connection_id=conn_abc123
{
"query": "SELECT * FROM external_table LIMIT 10"
}
Query DSL
POST /dataset/_search?connection_id=conn_abc123
{
"query": { "match_all": {} }
}
Natural Language (Fino API)
Fino automatically detects and queries connected sources when you ask questions.
Connection Status
Status Values
active- Connection is healthy and queryableinactive- Connection configured but not in useerror- Connection failed (check credentials or network)
Error Handling
Common Errors
401- Authentication failed (invalid credentials)403- Permission denied (insufficient permissions on external source)404- Connection not found500- Connection error (network issues, invalid host)
Best Practices
- Test connections before using them in production queries
- Monitor status regularly via Connect → Connections in the UI
- Use descriptive names to identify connections easily
- Rotate credentials when needed without recreating connections
- Query in place - avoid importing data unless needed for agent memories