Purpose of Pipelines
- Operation Chaining: Connect multiple data operations in a sequential workflow
- AI-Powered Transformations: Use natural language prompts to transform and clean data
- Automated Data Sync: Build end-to-end data synchronization between systems
- Intelligent Remapping: Automatically map columns between different data schemas
- Error Resolution: Leverage AI to detect and fix data formatting issues
Creating a Pipeline
Pipelines are created using the Vern SDK by callingvern.workbooks.pipeline(sheetId)
and chaining operations:
.execute()
to run the workflow.
Pipeline Operations
Import
Import data into a workbook with intelligent column remapping:remappings
: Array of column mapping rulesfrom
: Source column name(s)to
: Target column name(s)delimiter
: Split source values across multiple columnsjoin
: Join multiple source columns into one
autoremap
: Enable AI-powered column mapping for unmapped fields
Transform
Apply data transformations using natural language instructions:Autoclean
Automatically detect and resolve data formatting issues:- Inconsistent formatting
- Invalid characters
- Type mismatches
- Missing required values
- Duplicate entries
Export
Send processed data to external systems via webhook:type
: Export destination type (currently supports'webhook'
)url
: Target API endpointheaders
: HTTP headers for authentication and content negotiation
Complete Example
Here’s a complete example of a pipeline that syncs sales data from one system to another:Pipeline Execution
When you call.execute()
, Vern:
- Validates the pipeline configuration
- Executes each operation in sequence
- Passes the output of each step to the next
- Returns the final result or throws an error if any step fails
.execute()
waits for all operations to complete before returning.
Error Handling
Always wrap pipeline execution in a try-catch block to handle potential errors:Best Practices
- Use Autoremap: Enable
autoremap: true
to reduce manual column mapping - Clear Transformations: Write specific, actionable transformation prompts
- Error Handling: Always implement proper error handling for pipeline execution
- Validation: Validate source data before importing to catch issues early
- Secure Credentials: Store API keys and tokens securely in environment variables
- Logging: Log pipeline results for debugging and monitoring
- Idempotency: Design pipelines to be safely re-runnable
Next Steps
- Learn about Workbooks to understand data storage in Vern
- Explore the SDK documentation for detailed API references
- Set up Webhooks to receive notifications about pipeline completions