Bulk Upload Waste Water Treatments
Bulk Upload Waste Water Treatments
Create waste water treatment records in bulk with automatic data imputation
POST
Bulk Upload Waste Water Treatments
Bulk Upload Waste Water Treatments
Upload daily waste water treatment measurements in bulk for a waste water facility. This endpoint automatically imputes missing values using interpolation and moving averages.Request
Headers
Your API key for authenticationExample:
sk_live_1234567890abcdefYour organization UUIDExample:
ff4adcc7-8172-45fe-9cf1-e90a6de53aa9Your user UUIDExample:
a1b2c3d4-e5f6-7890-abcd-ef1234567890Body Parameters
UUID of the waste water facilityExample:
"facility-uuid-here"Array of daily measurement records (max 31 days)Each daily record contains:
name(string, required): Description of the datameasurement_date(date, required): Date of measurement (YYYY-MM-DD)m3_water_in(float, optional): Input flow in m³m3_water_out(float, optional): Output flow in m³kg_bod_per_m3_wwt_line(float, optional): Input BOD in kg/m³kg_n_per_m3_wwt_line(float, optional): Nitrogen in kg/m³ (treatment line)kg_sludge(float, optional): Total evacuated sludge in kgst(float, optional): Proportion of solids (0-1)m3_biogas_engine(float, optional): Engine biogas in m³m3_biogas_flare(float, optional): Flare biogas in m³m3_biogas_boiler(float, optional): Boiler biogas in m³methane(float, optional): Methane proportion (0-1)kg_bod_per_kg_sludge_line(float, optional): BOD in sludge kg/kgkg_bod_per_m3_wwd_line(float, optional): BOD in discharge kg/m³kg_n_per_m3_wwd_line(float, optional): Nitrogen in discharge kg/m³
Last Entry Requirement: The last entry in your data array must have non-null values for:
m3_water_inm3_water_outkg_sludgem3_biogas_enginem3_biogas_flarem3_biogas_boiler
Response
Returns an array of created waste water treatment records with calculated emissions.Example
Data Imputation
The endpoint automatically fills missing values using these methods:Interpolation
Missing values are interpolated linearly between known values for:m3_water_inm3_water_outkg_sludgem3_biogas_enginem3_biogas_flarem3_biogas_boiler
Moving Average
Missing values are filled with 6-period moving average (forward/backward fill) for:kg_n_per_m3_wwt_linekg_bod_per_m3_wwt_linekg_bod_per_m3_wwd_linest(solid proportion)methanekg_bod_per_kg_sludge_linekg_n_per_m3_wwd_line
You can submit partial data for intermediate days. The endpoint will automatically fill gaps, but the last entry must have complete totalized values.
Common Errors
400 Bad Request - Facility Not Found
400 Bad Request - Maximum Rows Exceeded
400 Bad Request - Null Values in Last Row
m3_water_in, m3_water_out, kg_sludge, m3_biogas_engine, m3_biogas_flare, m3_biogas_boiler.
400 Bad Request - Negative Value
Best Practices
1. Submit Complete Final Entry
Always ensure the last entry has all required fields:2. Handle Date Ranges
Split large date ranges into multiple requests:3. Validate Before Upload
Check data quality before submitting:Related Endpoints
Delete Treatment
Remove a treatment record
Facilities
List waste water facilities

