/rest-api-pipeline:create-rest-api-pipeline [dlthub-pipeline-init-command]from rest-api-pipeline
Creates a dlt REST API pipeline using dlthub pipeline init. Guides through scaffolding, reading generated files, and researching docs for data ingestion from REST/HTTP APIs.
Ships in rest-api-pipeline. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub dlt-hub/dlthub-ai-harness --plugin rest-api-pipelineCreate the simplest working dlt pipeline — single endpoint, no pagination or incremental loading — to get data flowing fast.
Requires a dlthub pipeline init command as the argument (e.g. dlthub pipeline init shopify_store duckdb).
If you don't have one yet, run find-source first to identify the right source.
The argument is the full dlthub pipeline init command to run (e.g. dlthub pipeline init shopify_store duckdb or dlthub pipeline init sql_database postgres).
Run ls -la to see the current state before scaffolding.
dlthub pipeline init can be run multiple times in the same project — each run adds new files without overwriting existing pipeline scripts. It will update shared files (.dlt/secrets.toml, .dlt/config.toml, requirements.txt, .gitignore).
Run the provided dlthub pipeline init command with the global --non-interactive flag in the active venv (e.g. uv run dlthub --non-interactive pipeline init rest_api duckdb).
If the command fails with invalid choice: 'pipeline', the dlthub workspace is not initialized. Run uv run dlthub init and follow its instructions — most importantly run uv sync to pull required dependencies — then retry.
Depending on the source type, this creates:
Core source (dlthub pipeline init rest_api duckdb):
rest_api_pipeline.py (or similar) — full working example with RESTAPIConfig, pagination, incremental loadingGeneric fallback (dlthub pipeline init <unknown_name> duckdb):
<name>_pipeline.py — basic intro template (less useful, prefer core sources)Shared files (created on first init, updated on subsequent runs):
.dlt/secrets.toml — credentials template.dlt/config.toml — pipeline configrequirements.txt — Python dependencies.gitignoreRun ls -la again to confirm what was created.
Read the following files to understand the scaffold:
<source>_pipeline.py — the pipeline code template<source>-docs.yaml — API endpoint scaffold with auth, endpoints, params, data selectors (if present).dlt/config.toml — source/destination config ie. api_urlDo NOT read the .md file or any secrets.toml file.
Do these in parallel:
Read essential dlt docs upfront:
https://dlthub.com/docs/dlt-ecosystem/verified-sources/rest_api/basic.mdhttps://dlthub.com/docs/general-usage/source.md and https://dlthub.com/docs/general-usage/resource.mdWeb search the data source:
Read additional docs as needed in later steps:
https://dlthub.com/docs/reference/explainers/how-dlt-works.mdhttps://dlthub.com/docs/hub/command-line-interface.mdhttps://dlthub.com/docs/dlt-ecosystem/file-formats/https://dlthub.com/docs/llms.txtPresent your findings so user can pick ONE of the endpoints that you will implement. Answer questions, do more research if needed.
Edit <source>_pipeline.py using information from the scaffold, API research, and dlt docs:
base_url and authendpoint.path, data_selector, params, primary_keydev_mode=True on the pipeline (fresh dataset on every run during debugging).add_limit(1) on the source when calling pipeline.run() (load one page only)replace write disposition to startrefresh="drop_sources" if present — dev_mode handles the clean slate@dlt.source and @dlt.resource are regular Python function decorators — expose useful parameters:
dlt.secrets.value): auto-loaded from secrets.toml, user can also pass explicitlydlt.config.value): auto-loaded from config.toml, user can also pass explicitlyUsers will call the source both ways:
pipeline.run(my_source()) # auto-inject from TOML
pipeline.run(my_source(starting_at="2025-01-01T00:00:00Z", bucket_width="1h")) # explicit
Add a docstring documenting parameters and example calls.
@dlt.source
def my_source(
access_token: str = dlt.secrets.value,
starting_at: str = None,
):
"""Load data from My API.
Args:
access_token: API token. Auto-loaded from secrets.toml.
starting_at: Start of range (ISO8601). Defaults to 7 days ago.
"""
if starting_at is None:
starting_at = pendulum.now("UTC").subtract(days=7).start_of("day").to_iso8601_string()
config: RESTAPIConfig = {
"client": {"base_url": "https://api.example.com/v1/", ...},
"resources": [...],
}
yield from rest_api_resources(config)
Essential Reading Credentials & config resolution: https://dlthub.com/docs/general-usage/credentials/setup.md https://dlthub.com/docs/general-usage/credentials/advanced
Config (non-secret values like base_url, api_version): edit .dlt/config.toml directly.
# .dlt/config.toml
[sources.<name>]
base_url = "https://api.example.com/v1/"
Secrets (API keys, tokens, passwords): never read or write secrets.toml directly. Never run commands that output secret values (e.g. gh auth token, env | grep KEY).
Use secrets_view_redacted, secrets_list, and secrets_update_fragment MCP tools (or equivalent dlthub ai secrets CLI commands) — see setup-secrets skill for details.
Use secrets_list to pick the target file, then secrets_update_fragment with the TOML fragment:
[sources.<name>]
access_token = "ak-*******-cae"
<name> = name= arg on @dlt.source if set; otherwise the function name<configure me>)For more complex credential setup (research where to get keys, multiple providers), use setup-secrets skill.
Rate limits: dlt handles HTTP 429 and Retry-After automatically — no custom retry code needed. For strict rate-limited APIs, tune retry settings in adjust-endpoint.
ALWAYS Get Feedback before you run the pipeline for a first time. Show summary of files that you changed or generated.
When user requests to run pipeline ALWAYS use debug-pipeline to diagnose and guide credential setup
NEVER add more endpoints before that - keep it simple
8 skills in this plugin
/adjust-endpointAdjust a working dlt pipeline for production — remove dev limits, verify pagination (including stuck or looping paginators), configure incremental loading, expand date ranges, and handle rate-limit/429 errors with retries, backoff, and request timeouts. Use when the user wants to remove .add_limit(), load more data, fix stuck or looping pagination, set up incremental loading, or make the pipeline retry/back off on 429s. For throughput/concurrency tuning (parallel resources, page size) when a working pipeline is slow, use optimize-rest-api-performance instead. For inspecting loaded data, fixing column types, or flattening nested structures after a load, use validate-data instead./debug-pipelineDebug and inspect a dlt pipeline after running it. Use after a pipeline run (success or failure) to inspect traces, load packages, schema, data, and diagnose errors like missing credentials or failed load jobs. Also covers pipelines built on a verified source./find-sourceFind a dlt source for a given API or data provider. Use when the user asks about a source, wants to find a connector, or asks to implement a pipeline for a specific data source./new-endpointAdd a new REST API endpoint/resource to an existing dlt pipeline. Use when the user wants to pull additional data from an API that already has a working pipeline./optimize-rest-api-performanceSpeed up a dlt REST API pipeline. Use when a REST/HTTP API pipeline is slow because of many sequential requests, nested child resources, or large responses, and the user wants higher throughput — parallelize resources, use async, tune page size and concurrency. For removing .add_limit(), fixing pagination, first-time incremental/merge setup, or retry/backoff on 429 / rate-limit errors use adjust-endpoint instead./validate-dataValidate schema and data after a successful dlt pipeline load. Use when the user wants to check if loaded data looks correct, inspect table schemas, fix data types, flatten nested structures, or refine the data shape.Other plugins' skills for the same job