Skip to main content
GET
/
v1
/
logistics
/
hocs
Get HOCs
const options = {
  method: 'GET',
  headers: {'x-api-key': '<x-api-key>', 'x-organization-id': '<x-organization-id>'}
};

fetch('https://api.dcycle.io/v1/logistics/hocs', options)
  .then(res => res.json())
  .then(res => console.log(res))
  .catch(err => console.error(err));
{
  "id": "<string>",
  "category": "<string>",
  "iv": 123,
  "status": "<string>",
  "created_at": {},
  "updated_at": {}
}

Get HOCs

Retrieve all active logistics HOCs (Handling and Other Costs). HOCs represent additional logistics operations — like warehousing, loading, or customs handling — that contribute to the overall emission footprint.

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

Response

Returns an array of HOC objects with HTTP 200. Each item contains:
id
string
HOC UUID
category
string
HOC category (e.g. warehousing, loading, customs)
iv
number
Emission intensity value (kgCO2e per tonne)
status
string
Record status: active or deleted
created_at
datetime
Creation timestamp (ISO 8601)
updated_at
string | null
Last update timestamp (ISO 8601)

Example

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

Successful Response

[
  {
    "id": "a1b2c3d4-e5f6-7890-abcd-ef1234567890",
    "category": "transshipment_ambient",
    "iv": 0.0052,
    "status": "active",
    "created_at": "2024-01-15T10:00:00Z",
    "updated_at": "2024-01-15T10:00:00Z"
  },
  {
    "id": "b2c3d4e5-f6a7-8901-bcde-f12345678901",
    "category": "transshipment_mixed",
    "iv": 0.0078,
    "status": "active",
    "created_at": "2024-01-15T10:00:00Z",
    "updated_at": "2024-01-15T10:00:00Z"
  }
]
id
string
HOC UUID.
category
string
HOC category describing the type of handling operation (e.g. transshipment_ambient, transshipment_mixed).
iv
number
Emission intensity value in kg CO2e per tonne.

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"}

Get TOCs

List transport operation categories

Logistics Overview

Module overview