Core & Batch Emission Calculation API
The Core Calculation API combines exact factor selection (emissionFactorId, activityCode), custom organizational mapping rules, and VALENQ Engine in a single endpoint. Requests can run as stateless simulations (persist: false), saved carbon ledger records (persist: true), background jobs (async: true), or blockchain-sealed records (anchorToBlockchain: true).
1. Emission Factor Selection Order
When POST /api/v1/integrations/emissions/calculate is called, the engine selects an emission factor in this order:
1. Exact Factor ID (emissionFactorId): Pins the calculation to a specific public or private emission factor UUID.
2. Activity Code (activityCode / activityId): Selects the best matching factor for the requested region, dataVersion, year, and calculationMethod (ar4, ar5, ar6).
- Setting
regionFallback: falserequires an exact regional match and returns422 no_emission_factors_foundinstead of falling back to macro/global regions.
- Setting
yearFallback: falserestricts selection strictly to the requestedyear.
3. Custom Organization Rules: Applies vendor, GL account code, and keyword rules configured by your organization.
4. Manual Factor Override (manualFactorValue): Applies primary supplier EPD or metered coefficients directly.
5. VALENQ Engine Matching: Matches free-text activity descriptions (sourceType) automatically using AI.
2. Single Emission Calculation
POST /api/v1/integrations/emissions/calculate
- Required Scope:
emissions:calculate(persist: false) oremissions:write(persist: true/async: true)
#### Request Parameters
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| sourceType | string | Selector | "" | Activity description (e.g., "Natural Gas", "Steel Hot Rolled Coil"). At least one selector field is required. |
| activityCode / activityId | string | Selector | null | Standard activity code (e.g., "steel_section_structural"). |
| emissionFactorId | string | Selector | null | Exact public or private emission factor UUID. |
| quantity | number | Yes | — | Positive activity quantity. |
| unit | string | Yes | — | Input unit (kWh, MWh, GJ, kg, t, L, m3, tkm, pkm, EUR, USD, TRY, etc.). |
| region | string | No | "Global" | ISO-3166 country or macro-region code ("TR", "DE", "EU", "US"). |
| regionFallback | boolean | No | true | When false, rejects candidates outside the exact requested region. |
| year | integer | No | Current Year | Preferred factor validity year (1990–2100). |
| yearFallback | boolean | No | true | When false, rejects candidates outside the exact requested year. |
| dataVersion | string | No | "^2026.1" | Fixed ("2026.1") or dynamic ("^2026.1") dataset release selector. |
| calculationMethod | string | No | "ar6" | IPCC 100-year GWP metric family: "ar6", "ar5", or "ar4". |
| distance | number | No | null | Transport distance (km) when converting mass into freight tkm. |
| persist | boolean | No | true | false runs statelessly in-memory; true saves to the corporate carbon ledger. |
| async | boolean | No | false | true queues the calculation for background processing. |
| anchorToBlockchain | boolean | No | false | When persist: true, anchors a SHA-256 proof of the record on-chain. |
| externalReferenceId | string | No | null | ERP invoice or document ID (e.g., "SAP-INV-2026-009841"). |
| vendorName | string | No | null | Supplier or vendor name. |
#### Example Request (cURL)
curl -X POST "https://api.climeqai.com/api/v1/integrations/emissions/calculate" \
-H "X-Api-Key: sust_YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"activityCode": "steel_section_structural",
"quantity": 2500,
"unit": "kg",
"region": "DE",
"regionFallback": false,
"dataVersion": "^2026.1",
"calculationMethod": "ar6",
"persist": true,
"externalReferenceId": "SAP-MM-2026-4410",
"anchorToBlockchain": true
}'
#### Example Response (200 OK)
{
"success": true,
"message": "Emission calculated synchronously and persisted to ledger.",
"data": {
"id": "94a8f2c1-7b3d-4e9a-8c21-6f0e5d1a3b9c",
"scope": 3,
"sourceType": "steel_section_structural",
"quantity": 2500,
"unit": "kg",
"co2e": 4.625,
"appliedFactor": 1.85,
"factorSource": "Verified LCA Dataset 2025",
"dataVersion": "2026.1",
"confidenceScore": 1.0,
"matchStatus": "Verified",
"externalReferenceId": "SAP-MM-2026-4410"
}
}
3. Batch Emission Calculation
POST /api/v1/integrations/emissions/calculate/batch
Processes up to 100 calculation items in a single HTTP call. Responses preserve the input order: if individual items fail validation or factor matching, valid items still succeed and every item is returned at its original index.
- Required Scope:
emissions:calculate(all itemspersist: false) oremissions:write
{
"items": [
{ "sourceType": "Diesel", "quantity": 500, "unit": "L", "region": "TR", "persist": false },
{ "activityCode": "natural_gas_industrial", "quantity": 1200, "unit": "m3", "region": "TR", "persist": false }
]
}
#### Example Batch Response
{
"success": true,
"message": "Batch emission calculation completed (2/2 succeeded).",
"data": {
"totalItems": 2,
"succeededCount": 2,
"failedCount": 0,
"totalCO2eTons": 3.764,
"totalCO2eKg": 3764.0,
"results": [
{ "index": 0, "success": true, "message": "Stateless emission calculation completed synchronously (persist=false).", "data": { "scope": 1, "co2e": 1.34 } },
{ "index": 1, "success": true, "message": "Stateless emission calculation completed synchronously (persist=false).", "data": { "scope": 1, "co2e": 2.424 } }
]
}
}
4. Get Emission Record
GET /api/v1/integrations/emissions/{id}
- Required Scope:
emissions:read
- Returns full details for a saved emission record, including
matchStatus(Pending,Autonomous,Verified), gas breakdown (CO₂,CH₄,N₂O),sourceTrailJsoncalculation history,factorValueMaskedlicense status, andblockchainProof(txHash,blockNumber,payloadHash).
Platform Guide & Technical Documents
- Smart Invoice and Document Reader
- Carbon Forecasting and Scenario Analysis
- AI Workflow Management
- Supply Chain Risk Monitoring
- VALENQ Engine Mapping & Industry Codes
- Catalog Search, Units & Private Factors
- API Versioning & Changelog
- Energy, Freight, Procurement & Travel APIs
- Product, CBAM, Cloud, IoT & Passport APIs
- OpenAPI, Postman & MCP Server
- Audit Logs User Guide
- Corporate Emission Calculation Methods
- Blockchain Data Sealing and Verification
- Digital Product Passport Guide
- Supported Reporting Standards
- Dashboard User Guide
- Data Quality, Standardization & Version Management
- Decarbonization Pathways User Guide
- Digital Product Passport Workspace
- AI Emission Factor Mapping Methodology
- Emission Factor Library
- Emission Scopes (Scope 1, 2 & 3)
- Validating and Approving Emission Data
- Data Explorer & Carbon Ledger User Guide
- Frequently Asked Questions (FAQ)
- Carbon Accounting & Sustainability Glossary
- Support Center & Help Channels
- Financial Integration & ERP Sync User Guide
- Core & Batch Emission Calculation API
- API Authentication, Permissions & Error Codes
- ERP, Cloud & IoT Connectors
- Webhooks & Signature Verification
- Intelligence & Resilience Hub User Guide
- Organization Invitations
- Methodology Overview
- Mission Control Center User Guide
- Carbon Offset & Environmental Attribute Hub User Guide
- Account Creation and First Steps
- Role and Permission Management (RBAC)
- Team Setup and Organization Management
- Product Carbon Footprint & CBAM Methodology
- Product Impact & LCA Studio User Guide
- Quickstart (Step 1): Generating an API Key
- Quickstart (Step 2): Making Your First Calculation Request
- Quickstart (Step 3): Reviewing, Approving & Anchoring Records
- Reports Hub & AI Report Editor User Guide
- ESG Risk Guardian User Guide
- Security Center
- Data Lineage, Integrity & Independent Auditor Workspace
- Data Security and Encryption
- Identity and Access Management (IAM)
- System & Organization Settings User Guide
- Supply Chain & Value Chain Portal User Guide
- Sustainability & Targets Hub User Guide
- User Management (RBAC)
- Webhook Management