Skip to main content

Datasources - Complete Guide

Placeholder for Demo

๐Ÿ”Œ Connect Your Data in Minutesโ€‹

25+ Built-in Connectors ยท Secure Connection Management ยท Real-time Testing


๐Ÿ“‹ Table of Contentsโ€‹


What are Datasources?โ€‹

Datasources are connection configurations that allow Jet Admin to communicate with external systems. They serve as the foundation for all data operations in the platform, enabling you to:

  • ๐Ÿ“Š Query databases for dashboard visualizations
  • ๐Ÿ”„ Fetch data for workflow automations
  • ๐Ÿ“ Write data back to external systems
  • ๐Ÿ”— Integrate with third-party services

Key Featuresโ€‹

  • Unified Interface - Consistent API across all connector types
  • Secure Storage - Encrypted credentials at rest
  • Connection Pooling - Optimized database connections
  • Real-time Testing - Validate connections before saving
  • SSH Tunneling - Connect to private networks (coming soon)
  • Cloning - Duplicate configurations for different environments

Supported Data Sourcesโ€‹

Jet Admin supports 25+ data sources across multiple categories:

๐Ÿ’พ Databasesโ€‹

DatabaseStatusFeatures
PostgreSQLโœ… StableQuery, Table Manager, Triggers
MySQLโœ… StableQuery, Table Manager
MongoDBโœ… StableQuery, Aggregation
MS SQL Serverโœ… StableQuery, Stored Procedures
SQLiteโœ… StableQuery, Local Files
CockroachDBโœ… StableQuery, Distributed SQL
Oracle๐Ÿงช BetaQuery, PL/SQL
Redis๐Ÿงช BetaKey-Value Operations
Neo4j๐Ÿงช BetaCypher Queries

โ˜๏ธ Cloud Servicesโ€‹

ServiceStatusFeatures
Google BigQueryโœ… StableSQL Queries, Data Export
Google Sheetsโœ… StableRead/Write, Real-time Sync
Google Analyticsโœ… StableReports, Real-time Data
Firestoreโœ… StableQuery, Document Operations
Supabaseโœ… StableQuery, Real-time Subscriptions
Airtableโœ… StableQuery, Record Operations
Amazon S3โœ… StableFile Upload/Download
Elasticsearchโœ… StableSearch, Aggregations

๐Ÿ”— APIs & Messagingโ€‹

ServiceStatusFeatures
REST APIโœ… StableCustom Endpoints, Auth
GraphQLโœ… StableQueries, Mutations
Slackโœ… StableSend Messages, Channels
Twilioโœ… StableSMS, Voice, WhatsApp
SendGridโœ… StableEmail Templates
Stripeโœ… StablePayments, Customers
Jiraโœ… StableIssues, Projects
Notionโœ… StablePages, Databases
RabbitMQ๐Ÿงช BetaPublish/Consume

Creating a Datasourceโ€‹

Step-by-Step Guideโ€‹

1. Navigate to Datasourcesโ€‹

From the Jet Admin sidebar, click on Datasources to open the datasource management page.

2. Click "Create Datasource"โ€‹

Click the Create Datasource button in the top-right corner to open the datasource catalog.

3. Choose a Connectorโ€‹

Browse or search through the available connectors. They're organized by category:

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ ๐Ÿ“Š Databases โ˜๏ธ Cloud Services โ”‚
โ”‚ ๐Ÿ”— APIs ๐Ÿ“ง Messaging โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

4. Configure Connectionโ€‹

Fill in the connection details specific to your datasource type.

Example: PostgreSQL Configuration

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ PostgreSQL Connection โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Datasource Title: [Production DB ] โ”‚
โ”‚ Host: [db.example.com ] โ”‚
โ”‚ Port: [5432 ] โ”‚
โ”‚ Database: [myapp_production ] โ”‚
โ”‚ Username: [admin ] โ”‚
โ”‚ Password: [โ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ขโ€ข ] โ”‚
โ”‚ โ”‚
โ”‚ [โœ“] Use SSL โ”‚
โ”‚ [ ] Require SSL Certificate โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

5. Test Connectionโ€‹

Before saving, click Test Connection to verify the credentials work correctly.

6. Save Datasourceโ€‹

Once the test succeeds, click Save Datasource to persist the configuration.


Datasource Configurationโ€‹

Common Configuration Fieldsโ€‹

Most datasources share these common fields:

FieldTypeRequiredDescription
Datasource TitleStringโœ…Human-readable name for identification
Datasource TypeStringโœ…Connector type (postgresql, restapi, etc.)
TagsArrayโŒOrganizational tags for filtering
DescriptionStringโŒNotes about the datasource's purpose

Database-Specific Configurationโ€‹

PostgreSQL / MySQLโ€‹

{
datasourceType: 'postgresql',
datasourceTitle: 'Production Database',
datasourceOptions: {
host: 'localhost',
port: 5432,
database: 'myapp',
username: 'admin',
password: 'secret',
ssl: {
enabled: true,
rejectUnauthorized: false
},
pool: {
min: 2,
max: 10
}
}
}

MongoDBโ€‹

{
datasourceType: 'mongodb',
datasourceTitle: 'Analytics DB',
datasourceOptions: {
connectionString: 'mongodb://user:pass@host:27017/dbname',
database: 'analytics',
options: {
useNewUrlParser: true,
useUnifiedTopology: true
}
}
}

API Configurationโ€‹

REST APIโ€‹

{
datasourceType: 'restapi',
datasourceTitle: 'Payment Gateway',
datasourceOptions: {
baseUrl: 'https://api.stripe.com/v1',
authentication: {
type: 'bearer',
token: 'sk_test_...'
},
headers: {
'Content-Type': 'application/json',
'Accept': 'application/json'
},
timeout: 30000
}
}

GraphQLโ€‹

{
datasourceType: 'graphql',
datasourceTitle: 'GraphQL API',
datasourceOptions: {
endpoint: 'https://api.example.com/graphql',
authentication: {
type: 'header',
headerName: 'Authorization',
headerValue: 'Bearer token123'
},
defaultQuery: `
query GetData($id: ID!) {
item(id: $id) {
id
name
description
}
}
`
}
}

Cloud Service Configurationโ€‹

Google Sheetsโ€‹

{
datasourceType: 'google_sheets',
datasourceTitle: 'Marketing Data',
datasourceOptions: {
spreadsheetId: '1BxiMvs0XRA5nFMdKvBdBZjgmUUqptlbs74OgvE2upms',
authentication: {
type: 'service_account',
credentials: {
// Service account JSON key
}
}
}
}

Airtableโ€‹

{
datasourceType: 'airtable',
datasourceTitle: 'Project Tracker',
datasourceOptions: {
apiKey: 'keyXXXXXXXXXXXXXX',
baseId: 'appXXXXXXXXXXXXXX',
tables: ['Projects', 'Tasks']
}
}

Testing Connectionsโ€‹

How Testing Worksโ€‹

When you click Test Connection, Jet Admin:

  1. Validates Configuration - Checks required fields
  2. Establishes Connection - Attempts to connect to the external system
  3. Executes Test Query - Runs a simple query/ping
  4. Returns Result - Shows success or detailed error

Test Resultsโ€‹

โœ… Successโ€‹

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ โœ“ Connection Successful! โ”‚
โ”‚ โ”‚
โ”‚ Connected to: postgresql://db:5432 โ”‚
โ”‚ Database: myapp_production โ”‚
โ”‚ Response Time: 45ms โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

โŒ Failureโ€‹

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ โœ— Connection Failed โ”‚
โ”‚ โ”‚
โ”‚ Error: ECONNREFUSED โ”‚
โ”‚ Message: Connection refused โ”‚
โ”‚ Host: db.example.com:5432 โ”‚
โ”‚ โ”‚
โ”‚ Troubleshooting: โ”‚
โ”‚ โ€ข Check if the database is running โ”‚
โ”‚ โ€ข Verify firewall settings โ”‚
โ”‚ โ€ข Confirm credentials are correct โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Common Test Errorsโ€‹

ErrorCauseSolution
ECONNREFUSEDDatabase not reachableCheck host/port, firewall rules
ETIMEDOUTConnection timeoutIncrease timeout, check network
ER_ACCESS_DENIEDWrong credentialsVerify username/password
SSL_REQUIREDSSL not enabledEnable SSL in connection
DATABASE_NOT_FOUNDInvalid database nameCheck database exists

Managing Datasourcesโ€‹

Datasource Listโ€‹

View all datasources in a searchable, filterable table:

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚ Search datasources... [Filter by Type โ–ผ] โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚ Name Type Tags Last Tested โ”‚
โ”‚ โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€ โ”‚
โ”‚ Production DB PostgreSQL prod, main 2 min ago โœ“ โ”‚
โ”‚ Analytics MongoDB analytics 1 hour ago โœ“ โ”‚
โ”‚ Stripe API REST API payments 1 day ago โœ“ โ”‚
โ”‚ Marketing Sheets Google marketing 1 week ago โš  โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

Actionsโ€‹

From the datasource list, you can:

  • Edit - Update connection details
  • Test - Re-test the connection
  • Clone - Duplicate for another environment
  • Delete - Remove the datasource (with confirmation)

Cloning Datasourcesโ€‹

Cloning is useful for creating environment-specific variants:

Production DB (postgresql://prod-db:5432/app_prod)
โ†“ Clone
Staging DB (postgresql://staging-db:5432/app_staging)

Use Cases:

  • Development vs Production databases
  • Multiple regional instances
  • Backup/failover configurations

Security & Encryptionโ€‹

Credential Encryptionโ€‹

All sensitive datasource credentials are encrypted at rest:

// Encryption process
const encrypted = encryptCredentials({
password: 'secret123',
apiKey: 'key_XXXXX'
});

// Stored in database as:
{
encrypted: 'a1b2c3d4...',
iv: 'initialization_vector'
}

Access Controlโ€‹

Datasources are protected by RBAC:

PermissionDescription
datasource:listView datasource list
datasource:readView datasource details
datasource:createCreate new datasources
datasource:updateEdit existing datasources
datasource:deleteRemove datasources
datasource:testTest connections

Network Securityโ€‹

Best Practices:

  1. Use SSL/TLS - Always enable encrypted connections
  2. Restrict IPs - Whitelist Jet Admin server IPs
  3. Use Service Accounts - Don't use personal credentials
  4. Rotate Keys - Regularly update API keys and passwords
  5. Audit Access - Monitor datasource usage logs

Troubleshootingโ€‹

Connection Issuesโ€‹

"Connection Refused"โ€‹

Symptoms: Test connection fails with ECONNREFUSED

Solutions:

  1. Verify the host and port are correct
  2. Check if the database/service is running
  3. Ensure firewall allows connections from Jet Admin
  4. Test connectivity using telnet or nc:
    telnet db.example.com 5432

"Connection Timeout"โ€‹

Symptoms: Test hangs and eventually times out

Solutions:

  1. Check network connectivity
  2. Increase timeout in datasource options
  3. Verify DNS resolution
  4. Check for network proxies

"Authentication Failed"โ€‹

Symptoms: Connection established but auth fails

Solutions:

  1. Double-check username/password
  2. Verify the user has correct permissions
  3. Check if password expired
  4. For APIs, verify the token hasn't expired

SSL/TLS Issuesโ€‹

"SSL Required"โ€‹

Solutions:

  1. Enable SSL in datasource configuration
  2. For self-signed certs, disable certificate validation (dev only)
  3. Install CA certificate on Jet Admin server

"Certificate Verification Failed"โ€‹

Solutions:

  1. Check certificate hasn't expired
  2. Verify certificate chain is complete
  3. Ensure hostname matches certificate

Performance Issuesโ€‹

Slow Queriesโ€‹

Solutions:

  1. Add database indexes
  2. Optimize query logic
  3. Increase connection pool size
  4. Use read replicas for heavy queries

Connection Pool Exhaustionโ€‹

Solutions:

  1. Increase max pool size
  2. Reduce idle timeout
  3. Check for connection leaks
  4. Monitor active connections

Best Practicesโ€‹

Organizationโ€‹

โœ… Use Descriptive Names

Good: "Production PostgreSQL - Orders DB"
Bad: "Postgres 1"

โœ… Add Tags for Filtering

Tags: ['production', 'orders', 'postgresql']
Tags: ['staging', 'analytics', 'mongodb']

โœ… Document Purpose

{
datasourceTitle: 'Analytics DB',
description: 'Main analytics database for dashboard metrics. Updated hourly via ETL pipeline.'
}

Securityโ€‹

โœ… Use Environment-Specific Credentials

Development: dev_user / dev_pass
Staging: staging_user / staging_pass
Production: prod_user / prod_pass

โœ… Enable SSL Everywhere

ssl: {
enabled: true,
rejectUnauthorized: true // except for self-signed in dev
}

โœ… Rotate Credentials Regularly

  • API keys: Every 90 days
  • Database passwords: Every 60 days
  • Service accounts: Every 180 days

Performanceโ€‹

โœ… Configure Connection Pools

pool: {
min: 2, // Minimum idle connections
max: 20, // Maximum total connections
idleTimeout: 30000
}

โœ… Use Read Replicas

// For read-heavy workloads
readReplicas: [
'postgresql://replica1:5432/db',
'postgresql://replica2:5432/db'
]

โœ… Set Appropriate Timeouts

timeout: 30000,        // 30s for most queries
queryTimeout: 60000, // 60s for complex queries
connectionTimeout: 5000 // 5s to establish connection

Monitoringโ€‹

โœ… Test Connections Regularly

  • Automated health checks every 5 minutes
  • Alerts on consecutive failures

โœ… Monitor Usage

  • Track query execution times
  • Monitor connection pool usage
  • Alert on high error rates

โœ… Audit Access

  • Log all datasource modifications
  • Review access patterns monthly
  • Remove unused datasources

Next Stepsโ€‹