Skip to main content

Overview

The Data Connectors component provides custom Airbyte connectors that extract data from 9 different e-commerce platforms, enabling Trendteller to aggregate data from 11 brands into a unified analytics platform.

Technology Stack

Airbyte CDK

Connector Development Kit for building integrations

TypeScript

Type-safe connector development

Lerna

Monorepo management for multiple connectors

Jest

Comprehensive testing framework

Connector Architecture

Monorepo Structure

The connectors are organized in a Lerna monorepo:

Source Connectors

Available Sources

Bling (source-bling, source-bling-v3)
  • Orders, products, customers, inventory
  • Invoices, payments, shipping
  • Incremental sync support
Tiny (source-tiny, source-tiny-v3)
  • Complete ERP data extraction
  • Multi-entity support
  • Real-time inventory updates
Totvs Moda (source-totvs-moda)
  • Fashion industry specific
  • Size/color variant handling
  • Collection management

Sync Modes

When to use: Small datasets, no incremental support
  • Replaces all existing data
  • Ensures consistency
  • Higher resource usage
Example: Product catalogs, brand configurations
When to use: Large datasets with timestamp fields
  • Only syncs new/modified records
  • Uses cursor field (e.g., updated_at)
  • Efficient and fast
Example: Orders, customer updates, inventory changes
When to use: Real-time requirements
  • Tracks all changes at source
  • Minimal latency
  • Requires source support
Example: Real-time order processing

Destination Connectors

Available Destinations

CRM360

destination-crm360Syncs customer and order data to CRM360 for marketing campaigns and customer engagement.

Shops

destination-shopsPushes consolidated product and inventory data to Shops platform for multi-channel selling.

Connector Development

Creating a New Connector

1

Generate Connector Scaffold

2

Implement Source Interface

3

Add Stream Definitions

4

Write Tests

Stream Configuration

Each stream defines:
  • Schema: JSON schema for data validation
  • Sync modes: Supported synchronization methods
  • Cursor field: Field for incremental sync
  • Primary key: Unique identifier(s)
  • Partitioning: How data is divided for sync

Testing Strategy

Test Levels

Test individual functions and utilities:
  • API request formatting
  • Response parsing
  • Data transformation
  • Error handling

Test Configuration

Error Handling

Retry Strategies

Strategy: Exponential backoff with jitter
  • Network timeouts
  • Rate limit errors (429)
  • Server errors (5xx)
Strategy: Fail fast and log
  • Authentication failures (401)
  • Invalid configuration (400)
  • Resource not found (404)
Require user intervention to resolve.

Logging

Comprehensive logging for debugging:
  • Request/response logging (sanitized)
  • Sync progress and statistics
  • Error details with context
  • Performance metrics

Performance Optimization

Batching

Fetch multiple records per API call to reduce overhead

Pagination

Efficiently handle large datasets with cursor-based pagination

Parallel Streams

Sync independent streams concurrently

Caching

Cache API responses for repeated requests

Deployment

Building Connectors

Docker Images

Connectors are packaged as Docker images:

Airbyte Cloud

Connectors can be deployed to:
  • Airbyte Cloud: Hosted Airbyte service
  • Self-hosted: On-premise Airbyte instance
  • Kubernetes: Scalable container orchestration

Monitoring

Sync Metrics

Track connector performance:
  • Sync duration: Time to complete sync
  • Records synced: Number of records extracted
  • Data volume: Bytes transferred
  • Error rate: Failed syncs percentage

Health Checks

Automated monitoring:
  • Connection health (daily checks)
  • API quota usage
  • Sync schedule adherence
  • Data freshness alerts

Next Steps

Architecture

Understand connector architecture

Development Guide

Build custom connectors

Testing Guide

Test and validate connectors

Source Connectors

Explore all available sources