Prepared for GHG Protocol. Api Integration Spec. Draft in review.
This document outlines the technical specifications for API-based data exchange between DaedArch Corporation and the GHG Protocol’s systems. The GHG Protocol, as the de facto global standard for greenhouse gas (GHG) accounting, provides a framework for various standards including the Corporate Standard, Scope 3 Standard, and Product Standard. This API integration will facilitate the seamless exchange of data regarding emissions accounting, verification, and reporting, thereby enhancing compliance with GHG Protocol standards.
All API requests to the GHG Protocol systems shall require authentication to ensure data integrity and security. The following authentication mechanisms are mandated:
client_id: The unique identifier for the client application.response_type: Set to code.redirect_uri: The URI to which the authorization server will redirect the user after authorization.scope: The permissions the application is requesting.grant_type: Set to authorization_code.code: The received authorization code.redirect_uri: The same redirect URI used in the authorization request.client_id: The unique identifier for the client application.client_secret: The secret associated with the client ID.Access tokens shall have a validity period of 3600 seconds (1 hour). Clients must implement a token refresh mechanism using the refresh token provided during the initial token acquisition.
The following API endpoints shall be provided for data exchange. Each endpoint is designed to meet specific data exchange requirements as aligned with GHG Protocol standards.
` https://api.ghgprotocol.org/v1 `
` POST /data/submission `
This endpoint allows DaedArch to submit emissions data for verification and reporting.
`json { "entity_id": "string", "reporting_period": { "start_date": "YYYY-MM-DD", "end_date": "YYYY-MM-DD" }, "emissions_data": { "scope_1": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] }, "scope_2": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] }, "scope_3": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] } } } `
`json { "status": "string", "message": "string", "submission_id": "string", "timestamp": "YYYY-MM-DDTHH:MM:SSZ" } `
200 OK: Successful submission.400 Bad Request: Invalid request format or missing parameters.401 Unauthorized: Authentication failure.500 Internal Server Error: An unexpected error occurred on the server.` GET /data/retrieval/{submission_id} `
This endpoint retrieves the status and details of a previously submitted data set.
submission_id: The unique identifier for the submitted data.`json { "submission_id": "string", "status": "string", "timestamp": "YYYY-MM-DDTHH:MM:SSZ", "emissions_data": { "scope_1": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] }, "scope_2": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] }, "scope_3": { "total_emissions": "number", "source_breakdown": [ { "source": "string", "emissions": "number" } ] } } } `
200 OK: Successful retrieval.404 Not Found: Submission ID does not exist.401 Unauthorized: Authentication failure.500 Internal Server Error: An unexpected error occurred on the server.` GET /audit/trail/{submission_id} `
This endpoint retrieves the full audit trail for a given submission, including all verification steps.
submission_id: The unique identifier for the submitted data.`json { "submission_id": "string", "audit_trail": [ { "step": "string", "timestamp": "YYYY-MM-DDTHH:MM:SSZ", "details": "string" } ] } `
200 OK: Successful retrieval.404 Not Found: Submission ID does not exist.401 Unauthorized: Authentication failure.500 Internal Server Error: An unexpected error occurred on the server.The data models used in the API shall conform to the GHG Protocol’s standards for emissions reporting. The following data structures are defined:
scope_1: Direct emissions from owned or controlled sources.scope_2: Indirect emissions from the generation of purchased electricity, steam, heating, and cooling consumed.scope_3: All other indirect emissions that occur in a company’s value chain.`json { "entity_id": "12345", "reporting_period": { "start_date": "2023-01-01", "end_date": "2023-12-31" }, "emissions_data": { "scope_1": { "total_emissions": 1000.5, "source_breakdown": [ { "source": "Natural Gas", "emissions": 500.0 }, { "source": "Diesel", "emissions": 500.5 } ] }, "scope_2": { "total_emissions": 200.0, "source_breakdown": [ { "source": "Electricity", "emissions": 200.0 } ] }, "scope_3": { "total_emissions": 300.0, "source_breakdown": [ { "source": "Business Travel", "emissions": 100.0 }, { "source": "Waste Disposal", "emissions": 200.0 } ] } } } `
Error handling shall be implemented to ensure that clients receive meaningful feedback in case of errors. The following guidelines shall be adhered to:
All error responses shall follow a standard format as illustrated below: `json { "error": { "code": "string", "message": "string", "details": "string" } } `
400 Bad Request: The request was malformed or contained invalid parameters.401 Unauthorized: The request lacks valid authentication credentials.403 Forbidden: The server understood the request, but refuses to authorize it.404 Not Found: The requested resource could not be found.500 Internal Server Error: An unexpected condition was encountered.All errors shall be logged for monitoring purposes. The logs shall include:
To ensure fair usage and optimal performance, the following rate limits shall be enforced on the API:
When the rate limit is exceeded, the API shall respond with: `json { "error": { "code": "429 Too Many Requests", "message": "Rate limit exceeded. Please try again later." } } `
Clients should monitor their usage and implement exponential backoff strategies when encountering rate limit errors.
This GHG Protocol API Integration Specification provides comprehensive guidelines for the technical integration of DaedArch Corporation’s MRV platform with the GHG Protocol’s systems. Compliance with these specifications is essential for ensuring secure, efficient, and standardized data exchange in alignment with global GHG accounting standards. All stakeholders are encouraged to review and adhere to these guidelines to facilitate effective collaboration and reporting within the carbon markets.
For further inquiries or clarifications regarding this specification, please contact the GHG Protocol technical support team.