Skip to main content
PATCH
/
periodic-emission-logs
/
{id}
Partially update a periodic emission log
curl --request PATCH \
  --url https://api.demo.cula.earth/tracking/v1/periodic-emission-logs/{id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --header 'Cula-Organisation-Id: <cula-organisation-id>' \
  --data '
{
  "external_id": "<string>",
  "display_key": "<string>",
  "site": {
    "id": "ste_01kqzcjrpyf27tge6smsbnhkh5"
  },
  "period_start": "2023-12-25",
  "period_end": "2023-12-25",
  "data_points": [
    {
      "config_id": "dpc_01kqzcjrpyf27tgey9d27c4edu",
      "input_value": {
        "value": 47079.76,
        "unit": "lbs"
      }
    }
  ],
  "file_ids": [
    "<string>"
  ]
}
'
{
  "id": "eml_01kqzcjrpyf27tgebyhvvmf20z",
  "config_id": "elc_01kqzcjrpyf27tgekeyq3qzm7d",
  "site": {
    "id": "<string>",
    "external_id": "<string>"
  },
  "period_start": "2025-10-01T00:00:00.000Z",
  "period_end": "2025-10-31T00:00:00.000Z",
  "status": "completed",
  "data_points": [
    {
      "config_id": "dpc_01kqzcjrpyf27tgey9d27c4edu",
      "config_version_id": "dpv_01kqzcjrpyf27tgeyv9d27c4edu",
      "name": "Weight net",
      "input_value": {
        "value": 47079.76,
        "unit": "lbs"
      },
      "result_value": {
        "value": 21353.12,
        "unit": "kg"
      }
    }
  ],
  "file_ids": [],
  "created_at": "2026-05-06T19:34:00Z",
  "updated_at": "2026-05-06T19:34:00Z",
  "external_id": "GC-ELEC-2025-10",
  "display_key": "GC-ELEC-2025-10",
  "emissions_in_kg_co2e": 8942.37
}

Authorizations

Authorization
string
header
required

OAuth2 client credentials flow. Exchange your client_id and client_secret for a short-lived access token, then pass it as a Bearer token in the Authorization header.

Headers

Cula-Organisation-Id
string
required

Organisation ID that scopes this request. The authenticated consumer must be authorized for this organisation. Omitting this header returns 400; passing an unauthorised org returns 403.

Path Parameters

id
string
required

Cula-assigned resource ID in TypeID format (e.g. stp_01kqzcjrpxf27tge33jwvjhkff). Alternatively, pass your external ID prefixed with ext- (e.g. ext-MY-STEP-001). The ext- prefix is unambiguous because TypeIDs use _ separators and never start with ext-.

Body

application/json

Request body for partially updating a periodic emission log. All fields optional. Triggers a recalculation.

external_id
string
display_key
string
site
object

The site where the emissions occurred.

Example:
{ "id": "ste_01kqzcjrpyf27tge6smsbnhkh5" }
period_start
string<date>
period_end
string<date>
data_points
object[]
file_ids
string[]

Complete replacement for the linked file array. Provide the full set of file IDs that should remain linked after the PATCH. Omit this field to leave existing file links unchanged.

Response

Periodic emission log updated. Recalculation triggered.

A periodic emission log as returned in responses. After creation, the server triggers a background emission calculation. The status field reflects the calculation state and emissions_in_kg_co2e contains the result once calculation completes.

id
string
required

Cula-assigned TypeID.

Example:

"eml_01kqzcjrpyf27tgebyhvvmf20z"

config_id
string
required

Root emission log config ID.

Example:

"elc_01kqzcjrpyf27tgekeyq3qzm7d"

site
object
required

A resolved resource reference as returned in responses.

period_start
string<date>
required

Start of the measurement period.

Example:

"2025-10-01T00:00:00.000Z"

period_end
string<date>
required

End of the measurement period.

Example:

"2025-10-31T00:00:00.000Z"

status
enum<string>
required

State of the background emission calculation.

  • calculating — calculation is in progress.
  • completed — calculation finished, emissions_in_kg_co2e is populated.
  • failed — calculation failed (contact support).
Available options:
calculating,
completed,
failed
Example:

"completed"

data_points
object[]
required

Resolved emission measurement data points.

file_ids
string[]
required

IDs of files linked to this emission log.

Example:
[]
created_at
string<date-time>
required
read-only
Example:

"2026-05-06T19:34:00Z"

updated_at
string<date-time>
required
read-only
Example:

"2026-05-06T19:34:00Z"

external_id
string | null

Partner-assigned external identifier.

Example:

"GC-ELEC-2025-10"

display_key
string | null

Human-readable display identifier.

Example:

"GC-ELEC-2025-10"

emissions_in_kg_co2e
number | null
read-only

Total emissions for this period in kg CO2 equivalent. Null while status is calculating. Populated once calculation completes.

Example:

8942.37