Create header for carbon reporting that can be used across entire enterprise. Configurable with branding options. This could be a plugin but think its best inside core as a library.
It would be ideal to have this ready for bloodhound and implemented.
We can pull hedge sci directly from opensearch but statsy will likely require a proxy. We also need to figure out how to pull offset from vendor api. That will likely need to be part of proxy as well.
It appears that when an order is placed using patch meta data can be associated. That meta data can be used to filter when fetching orders.
Need a proxy end-point. Different tokens would be required for other orgs using the platform.
Fetch carbon footprint of a given site for an account. Example: rollthecloudinc:carbonintense.world
Emissions
Emissions are calculated by combining statsy and hedge metrics.
Offset
Offset is calculated by aggregating all Patch order for a site. Although other vendors could also be supported, combined.
Remaining
Remaining emissions are calculated by subtracting offset from emissions.
Contribute
The contribute button opens the patch pop-up/modal.
We are going to do this by using periodical jobs to push data to our opensearch cluster. Once in opensearch we can easily query. Not to mention we can circumvent throttles, api outages on behalf of vendor.
We can use e-tags to make the fetch even more sustainable.
Create header for carbon reporting that can be used across entire enterprise. Configurable with branding options. This could be a plugin but think its best inside core as a library.
It would be ideal to have this ready for bloodhound and implemented.
We can pull hedge sci directly from opensearch but statsy will likely require a proxy. We also need to figure out how to pull offset from vendor api. That will likely need to be part of proxy as well.
It appears that when an order is placed using patch meta data can be associated. That meta data can be used to filter when fetching orders.
https://api.patch.io/api-docs/index.html
Need a proxy end-point. Different tokens would be required for other orgs using the platform.
Put the site ie. rollthecloudinc/carbonintense.world in metadata. That way the purchased offsets can be calculated easily.
Statsy api docs
https://statsy.com/rest-api#timeseries
Need a proxy end-point. Different tokens would be required for other orgs using the platform.
Fetch carbon footprint of a given site for an account. Example: rollthecloudinc:carbonintense.world
Emissions
Emissions are calculated by combining statsy and hedge metrics.
Offset
Offset is calculated by aggregating all Patch order for a site. Although other vendors could also be supported, combined.
Remaining
Remaining emissions are calculated by subtracting offset from emissions.
Contribute
The contribute button opens the patch pop-up/modal.
We are going to do this by using periodical jobs to push data to our opensearch cluster. Once in opensearch we can easily query. Not to mention we can circumvent throttles, api outages on behalf of vendor.
We can use e-tags to make the fetch even more sustainable.
Concerns:
HEDGE:
GET /org/repo/metrics/header
separate service