-
Notifications
You must be signed in to change notification settings - Fork 1
/
dlt-zendesk-to-duckdb.yaml
49 lines (43 loc) · 1.69 KB
/
dlt-zendesk-to-duckdb.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
id: dlt-zendesk-to-duckdb
namespace: company.team
tasks:
- id: dlt_pipeline
type: io.kestra.plugin.scripts.python.Script
taskRunner:
type: io.kestra.plugin.scripts.runner.docker.Docker
containerImage: python:3.11
beforeCommands:
- pip install dlt[duckdb]
- dlt --non-interactive init zendesk duckdb
warningOnStdErr: false
env:
SOURCES__ZENDESK__ZENDESK_SUPPORT__CREDENTIALS__PASSWORD: "{{ secret('ZENDESK_PASSWORD') }}"
SOURCES__ZENDESK__ZENDESK_SUPPORT__CREDENTIALS__SUBDOMAIN: "{{ secret('ZENDESK_SUBDOMAIN') }}"
SOURCES__ZENDESK__ZENDESK_SUPPORT__CREDENTIALS__EMAIL: "{{ secret('ZENDESK_EMAIL') }}"
script: |
import dlt
from zendesk import zendesk_support
pipeline = dlt.pipeline(
pipeline_name="zendesk_pipeline",
destination="duckdb",
dataset_name="zendesk",
)
zendesk_source = zendesk_support(load_all=False)
tickets = zendesk_source.tickets
load_info = pipeline.run(tickets)
extend:
title: Ingest Zendesk data into DuckDB using dlt
description: >
This flow demonstrates how to extract data from Zendesk into a DuckDB
database using dlt. The entire workflow logic is contained in a single
Python script that uses the dlt Python library to ingest the data into a
DuckDB database.
The credentials to access the Zendesk API are stored using Secret.
tags:
- Ingest
ee: false
demo: false
meta_description: This flow demonstrates how to extract data from Zendesk into a
DuckDB database using dlt. The entire workflow logic is contained in a
single Python script that uses the dlt Python library to ingest the data
into a DuckDB database.