GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — GitHub - datafold/datafold-api-examples: Demonstrates examples of the GraphQL API

This repository was archived by the owner on Oct 22, 2026. It is now read-only.
BranchesTags
Open more actions menu

Latest commit

 

History

32 Commits
32 Commits

Folders and files

NameName
Last commit message
Last commit date
queries
queries
 
 
.gitignore
.gitignore
 
 
README.md
README.md
 
 
analyze_impact.py
analyze_impact.py
 
 
common.py
common.py
 
 
get_last_modified.py
get_last_modified.py
 
 
get_lineage.py
get_lineage.py
 
 
jeeves.py
jeeves.py
 
 
propagate_tag.py
propagate_tag.py
 
 
requirements.txt
requirements.txt
 
 
usage_counters.py
usage_counters.py
 
 

Repository files navigation

Useful examples for Datafold GraphQL API

Preparation steps

Make sure you have Python ⩾ 3.10 installed.

# Create and activate python virtual environment
virtualenv .venv
. .venv/bin/activate

# Install dependencies
pip install -r requirements.txt

# If you are using a single-tenant install, set its base URL
export DATAFOLD_HOST=https://app.datafold.com

# Set env variable with Datafold key
# You can get it here: https://app.datafold.com/users/me
export DATAFOLD_API_KEY=<token-that-you-can-get-in-datafold-ui>

Try this out

Issue the following command to print available commands:

j

…and follow the white rabbit.

For instance, j analyze-impact will help you analyze downstream impact of a table or its columns.

Commands not wrapped under j

Might be slightly out of date.

Usage counters

Shows how to use column-level access counters. It prints out all columns of a table and number of times they were accessed by different users.

./usage_counters.py 1234 DATABASE SCHEMA TABLE

1234 here is the datasource_id, this is found in the URL on the catalog. Ex: /catalog/profile/table/1234/

Propogate tag

Propagates a tag through connected columns. One of the main usecases is to propagate PII tags to all downstream tables.

To add tags: ./propagate_tag.py 1234 DATABASE SCHEMA TABLE tagName --set-tag

To remove tags: ./propagate_tag.py 1234 DATABASE SCHEMA TABLE tagName --no-set-tag

Get lineage

Gets and prints lineage for a table. Default depth is 1 upstream, 1 downstream and can be changed with -u and -d optional arguments.

./get_lineage.py 1234 DATABASE.SCHEMA.TABLENAME

About

Demonstrates examples of the GraphQL API

Resources

Readme
Activity
Custom properties

Stars

5 stars

Watchers

0 watching

Forks

1 fork
Report repository

Releases

Packages

Used by

Contributors

Languages

You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.