{"openapi":"3.1.0","info":{"title":"Environmental, Carbon & Water Intelligence API","version":"1.0.0","description":"Normalize emission factors with source/version/timestamp provenance, calculate Scope 1–2 emissions, validate Scope 3 supplier data, check carbon-report consistency, detect water anomalies, calculate water intensity, check permit expiry, reconcile waste manifests, and build environmental evidence reports—using caller-supplied operational records plus optional key-free Carbon Intensity API and disclosed public-style factors. Paid with x402 exact USDC on Base. No account is required.","contact":{"email":"support@brainiac.software"},"x-guidance":"BRAINIAC.software is a pay-per-call API for software agents. No account or API key is required.\nPayment uses the x402 protocol with exact USDC on Base (chain id 8453). Each POST operation has a fixed USD price.\nHow to call an operation:\n1. POST a JSON body matching the operation's requestBody schema to the operation path. Include an Idempotency-Key header (64 hex characters, 32 random bytes).\n2. If you have not paid, the server responds 402 with payment requirements in the body. Pay the exact amount to the payTo address on Base.\n3. Retry the identical request with the same Idempotency-Key and add a payment-signature header containing the x402 payment payload. On success (200) the operation result is returned.\n4. Reuse the same Idempotency-Key only for retries of the same operation and request body; it will not be charged twice.\nAll outputs are compliance prechecks, drafts, or data lookups for human review. They are not official determinations, legal advice, identity confirmation, or certified filings. Verify time-sensitive or official data with the cited source before acting."},"servers":[{"url":"https://www.brainiac.software"}],"paths":{"/api/v1/environmental-intelligence/carbon-emission-factor-normalize":{"post":{"operationId":"normalize_carbon_emission_factors","summary":"Normalize carbon emission factors","description":"Normalize caller-supplied emission factors with source, version, and asOf provenance. Disclosed public-style DEFRA/eGRID references may be listed when no factors are supplied. No paid ESG database.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","factors":[{"id":"F1","activityKey":"natural_gas_kwh","unit":"kWh","kgCo2ePerUnit":0.18316,"scopeHint":"1","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"},{"id":"F2","activityKey":"electricity_uk_kwh","unit":"kWh","kgCo2ePerUnit":0.20705,"scopeHint":"2","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"factorCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"activityKey":{"type":"string"},"name":{"type":"string"},"unit":{"type":"string"},"kgCo2ePerUnit":{"type":"number"},"kgCo2ePerUnitSupplied":{"type":"boolean"},"scopeHint":{"type":"string"},"region":{"type":"string"},"source":{"type":"string"},"version":{"type":"string"},"asOf":{"type":"string"},"publicReferenceFactorUsed":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"normalized","factorCount":2,"items":[{"id":"F1","activityKey":"natural_gas_kwh","name":"natural_gas_kwh","unit":"kWh","kgCo2ePerUnit":0.18316,"kgCo2ePerUnitSupplied":true,"scopeHint":"1","region":"","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z","publicReferenceFactorUsed":false,"paidEsgDatabaseUsed":false},{"id":"F2","activityKey":"electricity_uk_kwh","name":"electricity_uk_kwh","unit":"kWh","kgCo2ePerUnit":0.20705,"kgCo2ePerUnitSupplied":true,"scopeHint":"2","region":"","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z","publicReferenceFactorUsed":false,"paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.03"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/scope-1-emissions-calculate":{"post":{"operationId":"calculate_scope_1_emissions","summary":"Calculate Scope 1 emissions","description":"Calculate Scope 1 emissions from caller-supplied activity quantities and emission factors (or disclosed public-style factors when unmatched). Factor source, version, and asOf are echoed.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","factors":[{"id":"F1","activityKey":"natural_gas_kwh","unit":"kWh","kgCo2ePerUnit":0.18316,"scopeHint":"1","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"}],"activities":[{"id":"A1","activityKey":"natural_gas_kwh","quantity":10000,"unit":"kWh","scope":"1","facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","source":"Caller-supplied meter"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"scope":{"type":"string"},"activityCount":{"type":"number"},"totalKgCo2e":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"activityKey":{"type":"string"},"name":{"type":"string"},"quantity":{"type":"number"},"unit":{"type":"string"},"scope":{"type":"string"},"kgCo2e":{"type":"number"},"kgCo2eSupplied":{"type":"boolean"},"facilityId":{"type":"string"},"periodStart":{"type":"string"},"periodEnd":{"type":"string"},"factorId":{"type":"string"},"factorActivityKey":{"type":"string"},"factorUnit":{"type":"string"},"factorKgCo2ePerUnit":{"type":"number"},"factorSource":{"type":"string"},"factorVersion":{"type":"string"},"factorAsOf":{"type":"string"},"publicReferenceFactorUsed":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"calculated","scope":"1","activityCount":1,"totalKgCo2e":1831.6,"items":[{"id":"A1","activityKey":"natural_gas_kwh","name":"","quantity":10000,"unit":"kWh","scope":"1","kgCo2e":1831.6,"kgCo2eSupplied":true,"facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","factorId":"F1","factorActivityKey":"natural_gas_kwh","factorUnit":"kWh","factorKgCo2ePerUnit":0.18316,"factorSource":"UK DESNZ/DEFRA GHG Conversion Factors","factorVersion":"2024","factorAsOf":"2024-06-01T00:00:00.000Z","publicReferenceFactorUsed":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/scope-2-emissions-calculate":{"post":{"operationId":"calculate_scope_2_emissions","summary":"Calculate Scope 2 emissions","description":"Calculate Scope 2 emissions from electricity activities and caller factors, disclosed public-style grid factors, or optional key-free Carbon Intensity API intensity.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","factors":[{"id":"F2","activityKey":"electricity_uk_kwh","unit":"kWh","kgCo2ePerUnit":0.20705,"scopeHint":"2","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"}],"activities":[{"id":"A2","activityKey":"electricity_uk_kwh","quantity":50000,"unit":"kWh","scope":"2","facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","source":"Caller-supplied bill"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"scope":{"type":"string"},"activityCount":{"type":"number"},"totalKgCo2e":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"activityKey":{"type":"string"},"name":{"type":"string"},"quantity":{"type":"number"},"unit":{"type":"string"},"scope":{"type":"string"},"kgCo2e":{"type":"number"},"kgCo2eSupplied":{"type":"boolean"},"facilityId":{"type":"string"},"periodStart":{"type":"string"},"periodEnd":{"type":"string"},"factorId":{"type":"string"},"factorActivityKey":{"type":"string"},"factorUnit":{"type":"string"},"factorKgCo2ePerUnit":{"type":"number"},"factorSource":{"type":"string"},"factorVersion":{"type":"string"},"factorAsOf":{"type":"string"},"publicReferenceFactorUsed":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"calculated","scope":"2","activityCount":1,"totalKgCo2e":10352.5,"items":[{"id":"A2","activityKey":"electricity_uk_kwh","name":"","quantity":50000,"unit":"kWh","scope":"2","kgCo2e":10352.5,"kgCo2eSupplied":true,"facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","factorId":"F2","factorActivityKey":"electricity_uk_kwh","factorUnit":"kWh","factorKgCo2ePerUnit":0.20705,"factorSource":"UK DESNZ/DEFRA GHG Conversion Factors","factorVersion":"2024","factorAsOf":"2024-06-01T00:00:00.000Z","publicReferenceFactorUsed":false,"source":"Caller-supplied bill","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/scope-3-supplier-data-validate":{"post":{"operationId":"validate_scope_3_supplier_data","summary":"Validate Scope 3 supplier data","description":"Validate caller-supplied Scope 3 supplier emission rows for identity, period, quantity, and factor provenance. Recalculates when activity quantity and a factor are available.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","factors":[{"id":"F3","activityKey":"diesel_litre","unit":"litre","kgCo2ePerUnit":2.51233,"scopeHint":"3","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"}],"suppliers":[{"id":"S1","supplierId":"SUP-9","supplierName":"Haul Co","category":"diesel_litre","periodStart":"2026-01-01","periodEnd":"2026-01-31","activityQuantity":1000,"unit":"litre","reportedKgCo2e":2512.33,"factorSource":"UK DESNZ/DEFRA GHG Conversion Factors","factorVersion":"2024","factorAsOf":"2024-06-01T00:00:00.000Z","source":"Caller-supplied supplier file"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"supplierCount":{"type":"number"},"validCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"supplierId":{"type":"string"},"supplierName":{"type":"string"},"category":{"type":"string"},"periodStart":{"type":"string"},"periodEnd":{"type":"string"},"reportedKgCo2e":{"type":"number"},"reportedKgCo2eSupplied":{"type":"boolean"},"recalculatedKgCo2e":{"type":"number"},"recalculatedKgCo2eSupplied":{"type":"boolean"},"consistent":{"type":"boolean"},"issues":{"type":"array","items":{}},"valid":{"type":"boolean"},"factorId":{"type":"string"},"factorSource":{"type":"string"},"factorVersion":{"type":"string"},"factorAsOf":{"type":"string"},"publicReferenceFactorUsed":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"validated","supplierCount":1,"validCount":1,"items":[{"id":"S1","supplierId":"SUP-9","supplierName":"Haul Co","category":"diesel_litre","periodStart":"2026-01-01","periodEnd":"2026-01-31","reportedKgCo2e":2512.33,"reportedKgCo2eSupplied":true,"recalculatedKgCo2e":2512.33,"recalculatedKgCo2eSupplied":true,"consistent":true,"issues":[],"valid":true,"factorId":"F3","factorSource":"UK DESNZ/DEFRA GHG Conversion Factors","factorVersion":"2024","factorAsOf":"2024-06-01T00:00:00.000Z","publicReferenceFactorUsed":false,"source":"Caller-supplied supplier file","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/carbon-report-consistency-check":{"post":{"operationId":"check_carbon_report_consistency","summary":"Check carbon report consistency","description":"Compare reported Scope 1–3 totals to summed scope values from caller-supplied reports and/or calculated activities. Flags inconsistent totals within tolerance.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","reports":[{"id":"R1","periodStart":"2026-01-01","periodEnd":"2026-01-31","scope1KgCo2e":1831.6,"scope2KgCo2e":10352.5,"scope3KgCo2e":2512.33,"totalKgCo2e":14696.43,"source":"Caller-supplied carbon report"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"reportCount":{"type":"number"},"inconsistentCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"periodStart":{"type":"string"},"periodEnd":{"type":"string"},"scope1KgCo2e":{"type":"number"},"scope2KgCo2e":{"type":"number"},"scope3KgCo2e":{"type":"number"},"summedKgCo2e":{"type":"number"},"reportedTotalKgCo2e":{"type":"number"},"reportedTotalKgCo2eSupplied":{"type":"boolean"},"deltaKgCo2e":{"type":"number"},"deltaKgCo2eSupplied":{"type":"boolean"},"consistent":{"type":"boolean"},"toleranceKg":{"type":"number"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"checked","reportCount":1,"inconsistentCount":0,"items":[{"id":"R1","periodStart":"2026-01-01","periodEnd":"2026-01-31","scope1KgCo2e":1831.6,"scope2KgCo2e":10352.5,"scope3KgCo2e":2512.33,"summedKgCo2e":14696.43,"reportedTotalKgCo2e":14696.43,"reportedTotalKgCo2eSupplied":true,"deltaKgCo2e":0,"deltaKgCo2eSupplied":true,"consistent":true,"toleranceKg":1,"source":"Caller-supplied carbon report","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/water-consumption-anomaly-detect":{"post":{"operationId":"detect_water_consumption_anomalies","summary":"Detect water consumption anomalies","description":"Detect anomalous water consumption using z-scores on caller-supplied facility water quantity series.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","waterAnomalyZ":2,"waterRecords":[{"id":"W1","facilityId":"PLANT-1","at":"2026-01-01","quantityM3":100,"source":"Caller-supplied meter"},{"id":"W2","facilityId":"PLANT-1","at":"2026-01-08","quantityM3":105,"source":"Caller-supplied meter"},{"id":"W3","facilityId":"PLANT-1","at":"2026-01-15","quantityM3":98,"source":"Caller-supplied meter"},{"id":"W4","facilityId":"PLANT-1","at":"2026-01-22","quantityM3":102,"source":"Caller-supplied meter"},{"id":"W5","facilityId":"PLANT-1","at":"2026-01-29","quantityM3":250,"source":"Caller-supplied meter"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"seriesCount":{"type":"number"},"anomalyCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"facilityId":{"type":"string"},"at":{"type":"string"},"quantityM3":{"type":"number"},"meanM3":{"type":"number"},"stdevM3":{"type":"number"},"zScore":{"type":"number"},"anomalous":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"detected","seriesCount":1,"anomalyCount":0,"items":[{"id":"W1","facilityId":"PLANT-1","at":"2026-01-01","quantityM3":100,"meanM3":131,"stdevM3":66.5733,"zScore":-0.4657,"anomalous":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false},{"id":"W2","facilityId":"PLANT-1","at":"2026-01-08","quantityM3":105,"meanM3":131,"stdevM3":66.5733,"zScore":-0.3905,"anomalous":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false},{"id":"W3","facilityId":"PLANT-1","at":"2026-01-15","quantityM3":98,"meanM3":131,"stdevM3":66.5733,"zScore":-0.4957,"anomalous":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false},{"id":"W4","facilityId":"PLANT-1","at":"2026-01-22","quantityM3":102,"meanM3":131,"stdevM3":66.5733,"zScore":-0.4356,"anomalous":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false},{"id":"W5","facilityId":"PLANT-1","at":"2026-01-29","quantityM3":250,"meanM3":131,"stdevM3":66.5733,"zScore":1.7875,"anomalous":false,"source":"Caller-supplied meter","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.03"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/water-intensity-calculate":{"post":{"operationId":"calculate_water_intensity","summary":"Calculate water intensity","description":"Calculate water intensity (m³ per denominator unit) from caller-supplied water quantities and production/occupancy denominators.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","waterRecords":[{"id":"W1","facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","quantityM3":1200,"denominator":400,"denominatorUnit":"tonne","source":"Caller-supplied"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"recordCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"facilityId":{"type":"string"},"periodStart":{"type":"string"},"periodEnd":{"type":"string"},"quantityM3":{"type":"number"},"quantityM3Supplied":{"type":"boolean"},"denominator":{"type":"number"},"denominatorSupplied":{"type":"boolean"},"denominatorUnit":{"type":"string"},"intensityM3PerDenominator":{"type":"number"},"intensityM3PerDenominatorSupplied":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"calculated","recordCount":1,"items":[{"id":"W1","facilityId":"PLANT-1","periodStart":"2026-01-01","periodEnd":"2026-01-31","quantityM3":1200,"quantityM3Supplied":true,"denominator":400,"denominatorSupplied":true,"denominatorUnit":"tonne","intensityM3PerDenominator":3,"intensityM3PerDenominatorSupplied":true,"source":"Caller-supplied","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.03"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/permit-expiry-check":{"post":{"operationId":"check_environmental_permit_expiry","summary":"Check environmental permit expiry","description":"Check caller-supplied environmental permit expiry dates against asOf and a warning window. Compliance determinations are not made.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","expiryWarningDays":60,"permits":[{"id":"P1","permitNumber":"EP-100","facilityId":"PLANT-1","permitType":"Air","issuedAt":"2024-01-01","expiresAt":"2026-12-01","authority":"Environment Agency","source":"Caller-supplied register"},{"id":"P2","permitNumber":"WP-200","facilityId":"PLANT-1","permitType":"Water discharge","issuedAt":"2020-01-01","expiresAt":"2026-10-01","authority":"Environment Agency","source":"Caller-supplied register"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"permitCount":{"type":"number"},"expiredCount":{"type":"number"},"expiringSoonCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"id":{"type":"string"},"permitNumber":{"type":"string"},"facilityId":{"type":"string"},"permitType":{"type":"string"},"authority":{"type":"string"},"issuedAt":{"type":"string"},"expiresAt":{"type":"string"},"daysRemaining":{"type":"number"},"daysRemainingSupplied":{"type":"boolean"},"status":{"type":"string"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string"},"code":{"type":"string"},"subject":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"checked","permitCount":2,"expiredCount":1,"expiringSoonCount":1,"items":[{"id":"P1","permitNumber":"EP-100","facilityId":"PLANT-1","permitType":"Air","authority":"Environment Agency","issuedAt":"2024-01-01","expiresAt":"2026-12-01","daysRemaining":26.125,"daysRemainingSupplied":true,"status":"expiring_soon","source":"Caller-supplied register","paidEsgDatabaseUsed":false},{"id":"P2","permitNumber":"WP-200","facilityId":"PLANT-1","permitType":"Water discharge","authority":"Environment Agency","issuedAt":"2020-01-01","expiresAt":"2026-10-01","daysRemaining":-34.875,"daysRemainingSupplied":true,"status":"expired","source":"Caller-supplied register","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[{"kind":"conflict","code":"permit_status","subject":"P1","detail":"Permit is expiring_soon (26.125 days from asOf)."},{"kind":"conflict","code":"permit_status","subject":"P2","detail":"Permit is expired (-34.875 days from asOf)."}],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.03"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/waste-manifest-reconcile":{"post":{"operationId":"reconcile_waste_manifests","summary":"Reconcile waste manifests","description":"Reconcile shipper and receiver waste manifest rows by manifest number, waste code, unit, and quantity.","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","wasteManifests":[{"id":"M1","manifestNumber":"WM-1","wasteCode":"13 02 05*","quantity":2.5,"unit":"tonne","side":"shipper","source":"Caller-supplied shipper"},{"id":"M2","manifestNumber":"WM-1","wasteCode":"13 02 05*","quantity":2.5,"unit":"tonne","side":"receiver","source":"Caller-supplied receiver"},{"id":"M3","manifestNumber":"WM-2","wasteCode":"15 01 10*","quantity":1,"unit":"tonne","side":"shipper","source":"Caller-supplied shipper"},{"id":"M4","manifestNumber":"WM-2","wasteCode":"15 01 10*","quantity":0.8,"unit":"tonne","side":"receiver","source":"Caller-supplied receiver"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"manifestCount":{"type":"number"},"reconciledCount":{"type":"number"},"items":{"type":"array","items":{"type":"object","properties":{"key":{"type":"string"},"shipperId":{"type":"string"},"receiverId":{"type":"string"},"manifestNumber":{"type":"string"},"wasteCode":{"type":"string"},"shipperQuantity":{"type":"number"},"receiverQuantity":{"type":"number"},"quantityMatch":{"type":"boolean"},"reconciled":{"type":"boolean"},"source":{"type":"string"},"paidEsgDatabaseUsed":{"type":"boolean"}},"additionalProperties":true}},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string"},"code":{"type":"string"},"subject":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"reconciled","manifestCount":2,"reconciledCount":1,"items":[{"key":"wm_1_13_02_05_tonne","shipperId":"M1","receiverId":"M2","manifestNumber":"WM-1","wasteCode":"13 02 05*","shipperQuantity":2.5,"receiverQuantity":2.5,"quantityMatch":true,"reconciled":true,"source":"Caller-supplied shipper; Caller-supplied receiver","paidEsgDatabaseUsed":false},{"key":"wm_2_15_01_10_tonne","shipperId":"M3","receiverId":"M4","manifestNumber":"WM-2","wasteCode":"15 01 10*","shipperQuantity":1,"receiverQuantity":0.8,"quantityMatch":false,"reconciled":false,"source":"Caller-supplied shipper; Caller-supplied receiver","paidEsgDatabaseUsed":false}],"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[{"kind":"conflict","code":"waste_quantity_mismatch","subject":"M3","detail":"Matched waste manifests disagree on quantity."}],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.04"},"protocols":[{"x402":{}}]}}},"/api/v1/environmental-intelligence/evidence-report":{"post":{"operationId":"build_environmental_evidence_report","summary":"Build environmental evidence report","description":"Aggregate emission-factor, Scope 1–3, carbon-report, water, permit, and waste sections from caller-supplied operational records (and optional Carbon Intensity fetch).","tags":["environmental-intelligence"],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$schema":"https://json-schema.org/draft/2020-12/schema","type":"object","properties":{"text":{"type":"string","maxLength":200000},"json":{"type":"string","maxLength":200000},"csv":{"type":"string","maxLength":200000},"file":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false},"files":{"maxItems":20,"type":"array","items":{"type":"object","properties":{"filename":{"type":"string","minLength":1,"maxLength":180},"mediaType":{"type":"string","enum":["text/plain","text/csv","application/json","application/octet-stream"]},"fileBase64":{"type":"string","minLength":1,"maxLength":12000000},"role":{"type":"string","maxLength":80}},"required":["fileBase64"],"additionalProperties":false}},"factors":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"unit":{"type":"string","maxLength":40},"kgCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000},"gCo2ePerUnit":{"type":"number","minimum":0,"maximum":1000000000},"scopeHint":{"type":"string","enum":["1","2","3","any"]},"source":{"type":"string","maxLength":200},"version":{"type":"string","maxLength":80},"asOf":{"type":"string","maxLength":40},"region":{"type":"string","maxLength":80}},"additionalProperties":false}},"activities":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"activityKey":{"type":"string","maxLength":120},"name":{"type":"string","maxLength":160},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"scope":{"type":"string","enum":["1","2","3"]},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"region":{"type":"string","maxLength":80},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"suppliers":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"supplierId":{"type":"string","maxLength":80},"supplierName":{"type":"string","maxLength":160},"category":{"type":"string","maxLength":120},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"spendAmount":{"type":"number","minimum":0,"maximum":1000000000000},"activityQuantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"reportedKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"factorId":{"type":"string","maxLength":80},"factorSource":{"type":"string","maxLength":200},"factorVersion":{"type":"string","maxLength":80},"factorAsOf":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"reports":{"maxItems":200,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"scope1KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope2KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"scope3KgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"totalKgCo2e":{"type":"number","minimum":0,"maximum":1000000000000},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"waterRecords":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"at":{"type":"string","maxLength":40},"periodStart":{"type":"string","maxLength":40},"periodEnd":{"type":"string","maxLength":40},"quantityM3":{"type":"number","minimum":0,"maximum":1000000000000},"denominator":{"type":"number","minimum":0,"maximum":1000000000000},"denominatorUnit":{"type":"string","maxLength":40},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"permits":{"maxItems":2000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"permitNumber":{"type":"string","maxLength":80},"facilityId":{"type":"string","maxLength":80},"permitType":{"type":"string","maxLength":120},"issuedAt":{"type":"string","maxLength":40},"expiresAt":{"type":"string","maxLength":40},"authority":{"type":"string","maxLength":160},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"wasteManifests":{"maxItems":5000,"type":"array","items":{"type":"object","properties":{"id":{"type":"string","maxLength":80},"manifestNumber":{"type":"string","maxLength":80},"wasteCode":{"type":"string","maxLength":80},"description":{"type":"string","maxLength":200},"quantity":{"type":"number","minimum":0,"maximum":1000000000000},"unit":{"type":"string","maxLength":40},"shippedAt":{"type":"string","maxLength":40},"receivedAt":{"type":"string","maxLength":40},"facilityId":{"type":"string","maxLength":80},"side":{"type":"string","enum":["shipper","receiver","left","right","a","b"]},"source":{"type":"string","maxLength":200}},"additionalProperties":false}},"carbonIntensity":{"type":"object","properties":{"fetch":{"type":"boolean"},"regionId":{"type":"integer","minimum":1,"maximum":30}},"additionalProperties":false},"asOf":{"type":"string","maxLength":40},"expiryWarningDays":{"type":"number","minimum":0,"maximum":3650},"waterAnomalyZ":{"type":"number","minimum":1,"maximum":10},"consistencyToleranceKg":{"type":"number","minimum":0,"maximum":1000000000}},"additionalProperties":false},"example":{"asOf":"2026-11-04T21:00:00.000Z","expiryWarningDays":60,"waterAnomalyZ":2,"factors":[{"id":"F1","activityKey":"natural_gas_kwh","unit":"kWh","kgCo2ePerUnit":0.18316,"scopeHint":"1","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"},{"id":"F2","activityKey":"electricity_uk_kwh","unit":"kWh","kgCo2ePerUnit":0.20705,"scopeHint":"2","source":"UK DESNZ/DEFRA GHG Conversion Factors","version":"2024","asOf":"2024-06-01T00:00:00.000Z"}],"activities":[{"id":"A1","activityKey":"natural_gas_kwh","quantity":10000,"unit":"kWh","scope":"1","facilityId":"PLANT-1","source":"Caller-supplied meter"},{"id":"A2","activityKey":"electricity_uk_kwh","quantity":50000,"unit":"kWh","scope":"2","facilityId":"PLANT-1","source":"Caller-supplied bill"}],"suppliers":[{"id":"S1","supplierId":"SUP-9","supplierName":"Haul Co","category":"diesel_litre","periodStart":"2026-01-01","periodEnd":"2026-01-31","activityQuantity":1000,"unit":"litre","reportedKgCo2e":2512.33,"factorSource":"UK DESNZ/DEFRA","factorVersion":"2024","factorAsOf":"2024-06-01T00:00:00.000Z","source":"Caller-supplied"}],"reports":[{"id":"R1","scope1KgCo2e":1831.6,"scope2KgCo2e":10352.5,"scope3KgCo2e":2512.33,"totalKgCo2e":14696.43,"source":"Caller-supplied"}],"waterRecords":[{"id":"W1","facilityId":"PLANT-1","at":"2026-01-01","quantityM3":100,"denominator":40,"denominatorUnit":"tonne","source":"Caller-supplied"},{"id":"W2","facilityId":"PLANT-1","at":"2026-01-08","quantityM3":105,"denominator":40,"denominatorUnit":"tonne","source":"Caller-supplied"},{"id":"W3","facilityId":"PLANT-1","at":"2026-01-15","quantityM3":98,"denominator":40,"denominatorUnit":"tonne","source":"Caller-supplied"},{"id":"W4","facilityId":"PLANT-1","at":"2026-01-22","quantityM3":102,"denominator":40,"denominatorUnit":"tonne","source":"Caller-supplied"},{"id":"W5","facilityId":"PLANT-1","at":"2026-01-29","quantityM3":250,"denominator":40,"denominatorUnit":"tonne","source":"Caller-supplied"}],"permits":[{"id":"P1","permitNumber":"EP-100","facilityId":"PLANT-1","permitType":"Air","expiresAt":"2026-12-01","authority":"Environment Agency","source":"Caller-supplied"}],"wasteManifests":[{"id":"M1","manifestNumber":"WM-1","wasteCode":"13 02 05*","quantity":2.5,"unit":"tonne","side":"shipper","source":"Caller-supplied"},{"id":"M2","manifestNumber":"WM-1","wasteCode":"13 02 05*","quantity":2.5,"unit":"tonne","side":"receiver","source":"Caller-supplied"}]}}}},"parameters":[{"name":"Idempotency-Key","in":"header","required":true,"description":"Fresh random 32-byte value encoded as 64 hexadecimal characters. Reuse unchanged only for retries of the same operation and request.","schema":{"type":"string","pattern":"^[0-9a-fA-F]{64}$"}}],"responses":{"200":{"description":"Illustrative endpoint-specific JSON response shape. Conditional fields depend on the result and data-source availability.","content":{"application/json":{"schema":{"type":"object","properties":{"checkedAt":{"type":"string"},"status":{"type":"string"},"asOf":{"type":"string"},"sections":{"type":"object","properties":{"factors":{"type":"object","properties":{"factorCount":{"type":"number"}},"additionalProperties":true},"scope1":{"type":"object","properties":{"activityCount":{"type":"number"},"totalKgCo2e":{"type":"number"}},"additionalProperties":true},"scope2":{"type":"object","properties":{"activityCount":{"type":"number"},"totalKgCo2e":{"type":"number"}},"additionalProperties":true},"scope3":{"type":"object","properties":{"supplierCount":{"type":"number"},"validCount":{"type":"number"}},"additionalProperties":true},"carbonReports":{"type":"object","properties":{"reportCount":{"type":"number"},"inconsistentCount":{"type":"number"}},"additionalProperties":true},"waterAnomalies":{"type":"object","properties":{"seriesCount":{"type":"number"},"anomalyCount":{"type":"number"}},"additionalProperties":true},"waterIntensity":{"type":"object","properties":{"recordCount":{"type":"number"}},"additionalProperties":true},"permits":{"type":"object","properties":{"permitCount":{"type":"number"},"expiredCount":{"type":"number"},"expiringSoonCount":{"type":"number"}},"additionalProperties":true},"waste":{"type":"object","properties":{"manifestCount":{"type":"number"},"reconciledCount":{"type":"number"}},"additionalProperties":true}},"additionalProperties":true},"paidProviderUsed":{"type":"boolean"},"apiKeyRequired":{"type":"boolean"},"paidEsgDatabaseUsed":{"type":"boolean"},"carbonIntensityFetched":{"type":"boolean"},"findings":{"type":"array","items":{"type":"object","properties":{"kind":{"type":"string"},"code":{"type":"string"},"subject":{"type":"string"},"detail":{"type":"string"}},"additionalProperties":true}},"limitations":{"type":"array","items":{"type":"string"}}},"additionalProperties":true},"example":{"checkedAt":"2026-11-04T21:00:00.000Z","status":"reported","asOf":"2026-11-04T21:00:00.000Z","sections":{"factors":{"factorCount":2},"scope1":{"activityCount":1,"totalKgCo2e":1831.6},"scope2":{"activityCount":1,"totalKgCo2e":10352.5},"scope3":{"supplierCount":1,"validCount":0},"carbonReports":{"reportCount":1,"inconsistentCount":0},"waterAnomalies":{"seriesCount":1,"anomalyCount":0},"waterIntensity":{"recordCount":5},"permits":{"permitCount":1,"expiredCount":0,"expiringSoonCount":1},"waste":{"manifestCount":1,"reconciledCount":1}},"paidProviderUsed":false,"apiKeyRequired":false,"paidEsgDatabaseUsed":false,"carbonIntensityFetched":false,"findings":[{"kind":"observation","code":"scope3_validation","subject":"S1","detail":"Supplier data issues: factor_unresolved_for_recalculation."},{"kind":"conflict","code":"permit_status","subject":"P1","detail":"Permit is expiring_soon (26.125 days from asOf)."}],"limitations":["Emission factors, activities, supplier rows, carbon reports, water records, permits, and waste manifests are copied only from labeled fields supplied by the caller, or from key-free Carbon Intensity API / disclosed public-style factor references when explicitly used.","No paid ESG database is used and no API key is required.","Emission outputs always echo factor source, version, and timestamp/asOf when a factor is applied. Missing values are not invented.","Disclosed public-style DEFRA/eGRID reference factors are used only when the caller does not supply a matching factor.","Evidence reports aggregate only sections for which records were supplied or optionally fetched."]}}}},"400":{"description":"Invalid JSON or request schema."},"402":{"description":"Payment Required"},"409":{"description":"Idempotency conflict, in-progress payment, or expired result cache. Reusing the key cannot trigger a second charge."},"413":{"description":"Request body exceeds the 24 MB limit."},"500":{"description":"Operation failed. With upfront settlement this may occur after payment; reuse the same idempotency key to retrieve the stored result."},"503":{"description":"Payment or retry-safe result storage is unavailable; the operation is not run."}},"x-payment-info":{"price":{"mode":"fixed","currency":"USD","amount":"0.08"},"protocols":[{"x402":{}}]}}}},"components":{"schemas":{"ApiError":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{}}}}}}}}