Skip to main content
GET
/
v1
/
organizations
/
{organization_id}
/
metrics
Organization Metrics
const options = {
  method: 'GET',
  headers: {'x-api-key': '<x-api-key>', 'x-organization-id': '<x-organization-id>'}
};

fetch('https://api.dcycle.io/v1/organizations/{organization_id}/metrics', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "limits": {
    "facilities": 123,
    "vehicles": 123,
    "employees": 123,
    "business_travels": 123,
    "users": 123,
    "shipments": 123,
    "deliveries": 123,
    "purchases": 123
  },
  "facilities": 123,
  "vehicles": 123,
  "employees": 123,
  "business_travels": 123,
  "hotel_stays": 123,
  "purchases": 123,
  "transport_downstream": 123,
  "transport_upstream": 123,
  "logistic_hubs": 123,
  "logistic_requests": 123,
  "logistic_recharges": 123,
  "sold_products": 123,
  "own_workforce": 123,
  "custom_emission_groups": 123,
  "certification": 123,
  "policy": 123,
  "strategy": 123,
  "action": 123,
  "plan": 123,
  "trend": 123,
  "business_model": 123,
  "market": 123,
  "intensity_metric_groups": 123,
  "sot_organization_measurement_campaign": 123,
  "funds": 123,
  "social_governance": 123,
  "events": 123,
  "ms_risks": 123,
  "ms_opportunities": 123,
  "ms_nc_types": 123
}

Organization Metrics

Retrieve a high-level summary of all entity counts for an organization — facilities, vehicles, employees, invoices, and more. Also returns the organization’s plan limits. Useful for building dashboards or checking data completeness before running calculations.

Request

Headers

x-api-key
string
required
Your API key for authenticationExample: sk_live_1234567890abcdef
x-organization-id
string
required
Your organization UUIDExample: a8315ef3-dd50-43f8-b7ce-d839e68d51fa

Path Parameters

organization_id
string
required
UUID of the organization to query

Response

limits
object
Plan limits for the organization
facilities
integer
Maximum facilities allowed
vehicles
integer
Maximum vehicles allowed
employees
integer
Maximum employees allowed
business_travels
integer
Maximum business travels allowed
users
integer
Maximum users allowed
shipments
integer
Maximum shipments allowed
deliveries
integer
Maximum deliveries allowed
purchases
integer
Maximum purchases allowed
facilities
integer
Number of active facilities (excluding logistic hubs)
vehicles
integer
Number of vehicles
employees
integer
Number of employees
business_travels
integer
Number of business travel records
hotel_stays
integer
Number of hotel stay records
purchases
integer
Number of purchase records
transport_downstream
integer
Number of downstream transport routes
transport_upstream
integer
Number of upstream transport routes
logistic_hubs
integer
Number of active logistic hubs
logistic_requests
integer
Number of active logistics requests
logistic_recharges
integer
Number of logistics recharge records
sold_products
integer
Number of sold product records
own_workforce
integer
Number of own workforce records
custom_emission_groups
integer
Number of custom emission factor groups
certification
integer
Number of certification records (ESRS governance)
policy
integer
Number of policy records (ESRS governance)
strategy
integer
Number of strategy records (ESRS governance)
action
integer
Number of action plan records (ESRS governance)
plan
integer
Number of plan records (ESRS governance)
trend
integer
Number of trend records (ESRS governance)
business_model
integer
Number of business model records (ESRS governance)
market
integer
Number of market records (ESRS governance)
intensity_metric_groups
integer
Number of intensity metric groups
sot_organization_measurement_campaign
integer
Number of SOT organization measurement campaigns
funds
integer
Number of fund records (ESRS governance)
social_governance
integer
Number of social governance records
events
integer
Number of event records
ms_risks
integer
Number of management system risk records
ms_opportunities
integer
Number of management system opportunity records
ms_nc_types
integer
Number of management system non-conformity type records

Example

curl "https://api.dcycle.io/v1/organizations/${ORG_ID}/metrics" \
  -H "x-api-key: ${DCYCLE_API_KEY}" \
  -H "x-organization-id: ${DCYCLE_ORG_ID}"

Successful Response

{
  "limits": {
    "facilities": 50,
    "vehicles": 200,
    "employees": 1000,
    "business_travels": 5000,
    "users": 25,
    "shipments": 10000,
    "deliveries": 10000,
    "purchases": 5000
  },
  "facilities": 12,
  "logistic_hubs": 3,
  "logistic_requests": 145,
  "logistic_recharges": 28,
  "vehicles": 45,
  "employees": 320,
  "business_travels": 89,
  "hotel_stays": 34,
  "purchases": 1250,
  "transport_downstream": 67,
  "transport_upstream": 23,
  "own_workforce": 0,
  "custom_emission_groups": 2,
  "sold_products": 15,
  "certification": 1,
  "policy": 3,
  "strategy": 2,
  "action": 5,
  "plan": 1,
  "trend": 0,
  "business_model": 1,
  "market": 0,
  "intensity_metric_groups": 1,
  "sot_organization_measurement_campaign": 0,
  "funds": 0,
  "social_governance": 0,
  "events": 0,
  "ms_risks": 0,
  "ms_opportunities": 0,
  "ms_nc_types": 0
}

Common Errors

401 Unauthorized

Cause: Missing or invalid API key
{"detail": "Invalid API key for organization", "code": "INVALID_API_KEY"}

403 Forbidden

Cause: The authenticated user is not a member of the organization
{"detail": "Logged User is not Member of Organization", "code": "LOGGED_USER_NOT_MEMBER"}

404 Not Found

Cause: The organization does not exist or you are not a member
{"detail": "Organization not found"}

Organization Tree

View the organization hierarchy

Emissions Summary

Get aggregated emission data