Manage energy invoices — electricity, gas, water, and other utility records for facilities
Early Access - The Dcycle CLI is currently available for enterprise customers.
Contact us to learn more about access.
Overview
The invoice command manages energy and utility invoice records attached to facilities. Invoices are the primary data source for Scope 1 and Scope 2 emissions calculations.
dcy invoice <subcommand> [flags]
Available Commands
Command
Description
list
List invoices for a facility
show
Show invoice details
download
Download the invoice file
edit
Edit invoice metadata
delete
Delete an invoice
bulk-delete
Delete multiple invoices at once
migrate
Move invoices to another facility
recalculate
Recalculate invoice emissions (one-by-one via PATCH)
recalculate-v2
Batch recalculate via activity categories
recalculate-legacy
Batch recalculate via legacy endpoint
Invoice Types
Type
Typical Unit
GHG Scope
electricity
kWh
Scope 2
heat
kWh
Scope 1/2
water
m³
Scope 3
recharge
kWh
Scope 2
process
varies
Scope 1
waste_water_treatment
m³
Scope 3
List Invoices
List invoices for a specific facility. Requires --facility.
dcy invoice list --facility <facility-id># Aliasesdcy invoice ls --facility <facility-id>
Examples
# List all invoices for a facilitydcy invoice list --facility <facility-id># Filter by type and yeardcy invoice list --facility <facility-id> --type electricity --year 2024# Filter by statusdcy invoice list --facility <facility-id> --status active# Increase page sizedcy invoice list --facility <facility-id> --size 200# JSON output for scriptingdcy invoice list --facility <facility-id> --format json
Set facility fuel ID (uses PUT, triggers recalculation)
--unit-id
—
Set unit ID (uses PUT, triggers recalculation)
--base-quantity
—
Set base quantity / consumption (uses PUT, triggers recalculation)
--yes
-y
Skip confirmation prompt
--org
—
Organization ID override
--facility-fuel-id, --unit-id, and --base-quantity use PUT instead of PATCH, which triggers full invoice recalculation. The --enabled and --disabled flags are mutually exclusive.