Skip to main content
GET
/
organizations
/
{organization_id}
/
metrics
/
carbon
Query project carbon emissions metrics for an entire organization
curl --request GET \
  --url {schemes}://api.upsun.com/organizations/{organization_id}/metrics/carbon \
  --header 'Authorization: Bearer <token>'
{
  "organization_id": "<string>",
  "meta": {
    "from": "<unknown>",
    "to": "<unknown>",
    "interval": "<unknown>",
    "units": "<unknown>"
  },
  "projects": [
    {
      "project_id": "<string>",
      "project_title": "<string>",
      "values": [
        {
          "value": "<unknown>",
          "start_time": "<unknown>"
        }
      ],
      "total": 123
    }
  ],
  "total": 123
}

Authorizations

Authorization
string
header
required

Path Parameters

organization_id
string<ulid>
required

The ID of the organization.

Query Parameters

from
object

The start of the time frame for the query. Inclusive.

to
object

The end of the time frame for the query. Exclusive.

interval
enum<string>

The interval by which the query groups the results. of the time frame for the query. Exclusive.

Available options:
day,
month,
year

Response

OK

organization_id
string

The ID of the organization.

meta
object
projects
object[]
total
number

The calculated total of the metric for the given interval.