Loading...
Loading...
Manage database, file system, and API connections for Sling. Use when setting up connections, testing connectivity, discovering tables/files, or configuring credentials.
npx skill4agent add slingdata-io/slingdata-ai sling-connections~/.sling/env.yaml| Type | Examples | Kind |
|---|---|---|
| Database | postgres, mysql, snowflake, bigquery | |
| File System | s3, gcs, azure, sftp, local | |
| API | Custom REST APIs via specs | |
{"action": "list", "input": {}}{
"action": "test",
"input": {
"connection": "MY_POSTGRES",
"debug": true
}
}{
"action": "discover",
"input": {
"connection": "MY_POSTGRES",
"pattern": "public.*",
"columns": true
}
}{
"action": "set",
"input": {
"name": "MY_POSTGRES",
"properties": {
"type": "postgres",
"host": "localhost",
"user": "myuser",
"database": "mydb"
}
}
}sling conns list # List all
sling conns test MY_POSTGRES --debug # Test
sling conns discover MY_POSTGRES --pattern "public.*" # Discover
sling conns exec MY_POSTGRES -q "SELECT 1" # Execute SQLexport MY_POSTGRES='host=localhost user=postgres dbname=mydb'export MY_POSTGRES='postgresql://user:pass@host:5432/dbname'# ~/.sling/env.yaml
connections:
MY_POSTGRES:
type: postgres
host: localhost
user: postgres
password: ${PG_PASSWORD}
database: mydb
MY_S3:
type: s3
bucket: my-bucket
access_key_id: ${AWS_ACCESS_KEY}
secret_access_key: ${AWS_SECRET_KEY}
MY_API:
type: api
spec: stripe
secrets:
api_key: ${STRIPE_API_KEY}| Property | Description |
|---|---|
| Database type (postgres, mysql, etc.) |
| Hostname or IP |
| Port number |
| Username |
| Password |
| Database name |
| Default schema |
| SSH tunnel URL |
| Property | Description |
|---|---|
| File system type (s3, gcs, etc.) |
| Bucket/container name |
| Access key |
| Secret key |
| Cloud region |
| Property | Description |
|---|---|
| Must be |
| API spec name or path |
| Authentication credentials |
| Optional configuration |
sling conns discover MY_PG --pattern "public.*" # All in schema
sling conns discover MY_PG --pattern "sales.customer_*" # With prefix
sling conns discover MY_S3 --pattern "data/*.csv" # Files
sling conns discover MY_S3 --pattern "**/*.parquet" --recursive
sling conns discover MY_PG --pattern "public.users" --columnstelnet host portsslmode=disable