Skip to content

dimagi/commcare-export

Repository files navigation

CommCare Data Export Tool

https://github.com/dimagi/commcare-export

Build Status Test coverage PyPI version

A command-line tool (and Python library) to generate customized exports from the CommCare HQ REST API.

Quick Start

Installation

uv pip install commcare-export

Basic Usage

# Export forms to Markdown (useful for testing)
commcare-export \
    --query examples/demo-registration.xlsx \
    --project YOUR_PROJECT \
    --output-format markdown

# Export to a SQL database with incremental updates
commcare-export \
    --query examples/demo-registration.xlsx \
    --project YOUR_PROJECT \
    --output-format sql \
    --output postgresql://user:pass@localhost/dbname

Example query files are provided in the examples/ directory for both Excel and JSON formats.

Documentation

For Users

See the User Documentation for installation, creating queries, command-line usage, scheduling, and common use cases.

For Developers

See the Technical Documentation for:

Contributing

We welcome contributions! See CONTRIBUTING.md for how to set up your development environment, coding style guidelines, testing, and the release process.

Python Versions

Tested with Python 3.10, 3.11, 3.12, and 3.13.

License

MIT License - see LICENSE for details.

About

A command-line tool and Python library to generate customized exports from CommCareHQ.

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors