---
title: "Trigger filament consumption recording"
method: POST
path: "/v1/filament-consumption/trigger"
tags: ["Filament Consumption", "Debug"]
---

# Trigger filament consumption recording

`POST /v1/filament-consumption/trigger`

Triggers filament consumption recording for an existing print job or all eligible jobs. Use `trigger_all: true` to queue all jobs without consumption records. Jobs can be re-triggered to update existing consumption data (e.g., after correcting material mappings). Worker uses upsert logic to prevent duplicates. Useful for testing and backfilling consumption data. For users in multiple organizations, specify organizationId to select which organization's jobs to trigger.

## Request body

- object
  - `organizationId` string, uuid — Organization ID to trigger jobs for. User must be a member of the organization. Defaults to user's first organization if not specified.
  - `print_job_id` number — The print job ID to record consumption for (required if trigger_all is false)
  - `status_override` 'COMPLETED' | 'FAILED' | 'CANCELLED' — Override the job status (uses actual job status if not provided)
  - `trigger_all` boolean — If true, queue all eligible jobs without consumption records
  - `backfill_unknown` boolean — If true, re-queue jobs that have consumption records with null material_id (Unknown Material). Uses upsert to update existing records.
  - `limit` number — Maximum number of jobs to queue when trigger_all is true

## Response `200`

Default Response

- object
  - `queue_job_id` string
  - `print_job_id` number
  - `queued` number
  - `failed` number
  - `jobs` object[]
    - `print_job_id` number
    - `queue_job_id` unknown
    - `error` string

## Other responses

- `400` — Default Response
- `404` — Default Response
- `503` — Default Response

---

[API](https://skmtc.net/printhiv3d/apis/hive-api-documentation.md) · [All operations](https://skmtc.net/printhiv3d/apis/hive-api-documentation/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/printhiv3d/hive-api-documentation/revisions/7ce1b00726fd/schema)
