Fivetran CLI

The Paradime SDK provides CLI commands to interact with Fivetran, allowing you to trigger connector syncs and list available connectors with real-time monitoring capabilities.

Sync Fivetran Connectors

Trigger syncs for one or more Fivetran connectors with real-time progress monitoring and comprehensive status reporting.

CLI Command

paradime run fivetran-sync

Options

Flag
Type
Description

--connector-id

Required, TEXT (multiple)

The ID of the Fivetran connector(s) you want to sync. Can specify multiple connectors by repeating the flag.

--api-key

Required, TEXT

Your Fivetran API key. Can be set via FIVETRAN_API_KEY environment variable.

--api-secret

Required, TEXT

Your Fivetran API secret. Can be set via FIVETRAN_API_SECRET environment variable.

--force

Optional, Flag

Force restart ongoing syncs and attempt to sync paused connectors. Default: False.

--wait-for-completion / --no-wait-for-completion

Optional, Flag

Wait for sync jobs to complete before returning. Shows real-time progress and final status. Default: --wait-for-completion.

--timeout-minutes

Optional, INTEGER

Maximum time to wait for sync completion (in minutes). Only used with --wait-for-completion. Default: 1440 (24 hours).

Recommended Setup

For security and convenience, set your Fivetran credentials as environment variables:

FIVETRAN_API_KEY="your_api_key"
FIVETRAN_API_SECRET="your_api_secret"

Connector Sync Examples

Sync a single connector

# Using environment variables (recommended)
paradime run fivetran-sync --connector-id "connector_abc123"

# Or with explicit flags
paradime run fivetran-sync \
  --api-key "your_api_key" \
  --api-secret "your_api_secret" \
  --connector-id "connector_abc123"

Sync multiple connectors in parallel

# Using environment variables (recommended)
paradime run fivetran-sync \
  --connector-id "sales_data_connector" \
  --connector-id "marketing_connector" \
  --connector-id "support_tickets"

# Or with explicit flags
paradime run fivetran-sync \
  --api-key "your_api_key" \
  --api-secret "your_api_secret" \
  --connector-id "sales_data_connector" \
  --connector-id "marketing_connector" \
  --connector-id "support_tickets"

Force sync paused connectors

# Force sync paused or ongoing connectors
paradime run fivetran-sync \
  --connector-id "paused_connector" \
  --force

Trigger sync without waiting for completion

# Start sync and return immediately without monitoring
paradime run fivetran-sync \
  --connector-id "large_dataset_connector" \
  --no-wait-for-completion

Sample Output

List Fivetran Connectors

List all available Fivetran connectors with their IDs, status, and configuration details.

CLI Command

paradime run fivetran-list-connectors

Options

Flag
Type
Description

--api-key

Required, TEXT

Your Fivetran API key. Can be set via FIVETRAN_API_KEY environment variable.

--api-secret

Required, TEXT

Your Fivetran API secret. Can be set via FIVETRAN_API_SECRET environment variable.

--group-id

Optional, TEXT

Filter connectors by group ID. If not specified, lists all connectors across all groups.

Usage Examples

# List all connectors (using environment variables)
paradime run fivetran-list-connectors

# List connectors for a specific group
paradime run fivetran-list-connectors --group-id "group_abc123"

# With explicit credentials
paradime run fivetran-list-connectors \
  --api-key "your_api_key" \
  --api-secret "your_api_secret"

Connector Status Reference

Understanding the status indicators in the output:

Sync States

  • ✅ scheduled/rescheduled: Connector is ready for sync or next sync is scheduled

  • 🔄 syncing: Connector is currently performing a sync

  • ⏸️ paused: Connector is paused and won't sync automatically

  • ❓ unknown: Status could not be determined

Setup States

  • ✅ connected: Connector is properly configured and ready

  • ❌ broken: Connector configuration has issues that need attention

  • ⚠️ incomplete: Connector setup is not finished

Important Notes

  • Parallel Execution: Multiple connectors sync simultaneously for efficiency

  • Real-time Monitoring: Live progress updates show sync status with timestamps

  • Dashboard Integration: Direct links to Fivetran dashboard for each connector

  • Paused Connector Handling: Use --force flag to attempt syncing paused connectors

  • Long-running Operations: Default 24-hour timeout accommodates large data syncs

  • Connector Identification: Use the exact connector ID from your Fivetran dashboard

Environment Variable Reference

Environment Variable
Description

FIVETRAN_API_KEY

Your Fivetran API key

FIVETRAN_API_SECRET

Your Fivetran API secret

Troubleshooting

Paused Connectors

If connectors are paused, the sync will be skipped unless you use the --force flag:

paradime run fivetran-sync --connector-id "paused_connector" --force
Broken Setup State

Connectors with broken setup need manual intervention in the Fivetran dashboard before they can sync successfully.

Network Timeouts

For very large sources, consider increasing the timeout:

paradime run fivetran-sync --connector-id "big_data_connector" --timeout-minutes 2880  # 48 hours
Finding Connector IDs

Use the list command to discover available connector IDs:

paradime run fivetran-list-connectors

Workflow Integration

These Fivetran CLI commands are designed to integrate seamlessly into your data pipeline workflows. Common use cases include:

  1. Pre-dbt Sync: Trigger Fivetran syncs before running dbt™ transformations

  2. Scheduled Data Ingestion: Automate regular sync cycles for critical data sources

  3. Event-driven Syncs: Trigger syncs based on external events or schedules

  4. Multi-source Orchestration: Coordinate syncs across multiple data connectors

For more information about integrating Fivetran syncs into your Paradime workflows, see the Bolt Schedules documentation.

Last updated

Was this helpful?