Overview
At this time, Deck must manually configure jobs to fetch documents and extract data.
Once your fetching job is completed, the webhook will return with information to help you take action on said documents. Example of a successful webhook
Fetch a list of documents
You can get the list of all documents fetched during a session by calling the List documents endpoint.Download documents
You can download the raw files fetched by a job by calling the Download a document endpoint. Note that you can only download one document at a time.Data extraction from files
Extraction is currently limited to utility bills.
DocumentExtractionSuccess webhook will be sent with a document_id and a document_extraction_id.
Successful Document Extraction webhook:
(Note how
document_extraction_id is missing)
document_id represents the original statement whereas the document_extraction_id denotes the extraction result of that document.
Here are examples of extraction payloads:
- Utility Bill
- Detailed Interval Data
Extraction Data Dictionary
Top-level fields
| Field name | Type | Description | Example |
|---|---|---|---|
company_name | string | Name of the utility provider. | ”energylink” |
account_number | string | Unique identifier for the account. | ”58291-44720” |
billing_date | string | Date the bill was sent. | ”2025-01-22” |
next_billing_date | string | Date the next bill is stated to be sent. | ”2025-02-22” |
billing_period | object | Object containing details about the billing period. | |
balance_forward | number | Balance carried over from the previous billing period minus any payments or credits. This may have to be calculated based on previous balance plus payments made.When there is a previous balance and a payment but no balance forward provided, then it should be inferred on the basis of what was previously owed and what was paid. For example, if the previous balance was 52.96 and there is a payment of 52.96 (sometimes listed as a credit - CR), then the balance forward is 0, not 52.96. | 32.74 |
previous_payments | number | Amount paid for last billing. | 6892.44 |
previous_amount_due | number | Amount due at the time of last billing. | 6925.18 |
new_charges | number | New charges for the current billing period. | 8214.67 |
amount_due | number | Amount due for the current billing period. | 8247.41 |
payment_due_date | string | Due date for the payment of this statement. | ”2025-02-14” |
auto_pay_date | string | Date on which automatic payment is set to trigger. | ”2025-02-07” |
currency | string | Currency used in the statement. (Enum: “USD”, “CAD”, “EUR”, “GBP”, “MXN”, “JPY”, “AUD”, “CNY”, “KRW”, “THB”, “INR”, “BRL”, “CHF”, “RUB”, “SGD”, “HKD”, “SEK”, “NZD”, “ZAR”, “AED”) | “USD” |
billing_address | object | Object containing details about the billing address. | |
service_locations | array | Array containing details about the service locations. | |
payments | array | Array containing details about the payments. |
billing_period object
| Field name | Type | Description | Example |
|---|---|---|---|
start_date | string | Start date of the billing period. | ”2024-12-18” |
end_date | string | End date of the billing period. | ”2025-01-20” |
total_days | number | Total number of days elapsed during the billing period. | 33 |
billing_address object
| Field name | Type | Description | Example |
|---|---|---|---|
name | string | Name of the paying entity. | ”HARBORVIEW PROPERTIES LLP” |
street | string | Street number of the paying entity. | ”217 MAPLE RIDGE AVE” |
city | string | City of the paying entity. | ”BOSTON” |
state | string | Abbreviation of the state or province of the paying entity. | ”MA” |
postal_code | string | Postal code of the paying entity. | ”02123-5521” |
service_locations array
| Field name | Type | Description | Example |
|---|---|---|---|
service_type | string | Type of service. | ”Fuel” |
service_address | object | Object containing details about the service location. | |
total_usage | number | Total usage of all meters for this service location. | 5348 |
total_usage_unit | string | Total usage units of all meters for this service location. | ”Therms” |
service_plan | string | Name of the service plan. | ”SC5 - Commercial Heating” |
total_charges | number | Total dollar amount of all charges for this service location. | 8214.67 |
meters | array | Array containing details about the meters of the service location. | |
charges | array | Array containing details about the charges for the service location. |
service_address object
| Field name | Type | Description | Example |
|---|---|---|---|
street | string | Street number of the location using the service. | ”4421 OAK VIEW LN UNIT 3A” |
city | string | City of the location using the service. | ”CAMBRIDGE” |
state | string | Abbreviation of the state or province of the location using the service. | ”MA” |
postal_code | string | Postal code of the location using the service. | ”02140” |
meters array
| Field name | Type | Description | Example |
|---|---|---|---|
meter_number | string | Number for the meter, as registered on the statement. | ”89314472” |
usage_unit | string | Unit of measure for the utility used. | ”Therms” |
reading_cycle | string | Recurring timeframe during which the utility company reads the meter to measure consumption. | ”14” |
meter_reading | object | Object containing details about the meter readings. | |
demand_meter_reading | object | Object containing details about the peak rate of the meter. |
meter_reading object
| Field name | Type | Description | Example |
|---|---|---|---|
start_date | string | The start date of the date range for the meter reading. | ”2024-12-18” |
end_date | string | The end date of the date range for the meter reading. | ”2025-01-20” |
total_days | number | Total number of days elapsed during the billing period. | 33 |
start_value | number | The value of the meter at the start of the date range. | 38412 |
end_value | number | The value of the meter at the end of the date range. | 43716 |
delta | number | The difference between the end_value and the start_value. | 5304 |
multiplier_conversion | number | This adjusts the raw reading from the meter to account for larger consumption units. | 1.00829 |
reading_type | string | The type of reading for the meter (actual, estimate or null). | “actual” |
usage | number | Total utility used for this meter reading. This is an amount based on the units of utility, not a dollar amount. | 5348 |
additional_data | array | Array of additional data related to the location. |
additional_data array
| Field name | Type | Description | Example |
|---|---|---|---|
key | string | Key of the additional data. | ”Measured CCF” |
value | string | Value of the additional data. | ”5304” |
charges array
| Field name | Type | Description | Example |
|---|---|---|---|
group | string | Category of the charge. | ”Delivery Services” |
details | string | Details about the charge. | ”delivery_rate_adj” |
amount | number | Specific dollar amount for the indicated line item. | 82.46 |
usage_unit | string | Unit of measure for the utility used. | ”therms” |
usage | number | This is an amount based on the units of utility, not a dollar amount. | 5348 |
usage_unit_rate | number | An amount in dollars indicating the price of how much each usage unit costs. Normally, the total utility used for this meter reading is multiplied by this rate for calculating the total consumption billed for the meter reading. | 0.01542 |
payments array
| Field name | Type | Description | Example |
|---|---|---|---|
amount | number | Amount paid. | 6892.44 |
date | string | Date of payment. | ”2025-01-08” |
details | string | Description of payment. | ”Payment Received on JAN 8 (Direct Deposit)” |
