Material flows, transfers and an operating journal that closesAll articles

Material flows, transfers and an operating journal that closes

An operating journal only created for the audit is not a journal. This case shows the chain that closes daily and is signed weekly.

Published: 2026-09-12Reading time: 5 mintapinomahub API & workflows
API & processesAPI

A day’s quantities sit on a slip by the weighbridge, the transfers in emails, and the operating journal is created from both on the evening before the audit. That works as long as nobody asks where a figure comes from — and it fails exactly once.

Material flows, transfers and an operating journal that closesInput: the quantities of one operating day at one site 1. Record the movement (POST /compliance/material-movements): materialCode, mass and unit per movement, with measurement time 2. Evidence the transfer (POST /compliance/downstream-transfers): the recipient’s permitSnapshotId and at least one mass entry 3. Close the day (POST /compliance/journal-periods/{date}/close-daily): closure with an attestation, attributed to a person in the journal role 4. Sign off the week (POST /compliance/journal-periods/{week}/sign-off-weekly): dailyClosureIds and an attestation; the sign-off is attributable to a person 5. Pull the audit export (GET /compliance/audit-exports/{case_or_period}): Events with hash and previousHash — a chain that reveals a gap Output: a period that withstands an audit, because it is not narrated after the fact The hash chain makes a gap visible, not impossible. Its value is that what is missing shows up.Material flows, transfers and an operating journal thatclosesInput: the quantities of one operating day at one site01Record the movementPOST /compliance/material-movementsmaterialCode, mass and unit per movement, with measurement time02Evidence the transferPOST /compliance/downstream-transfersthe recipient’s permitSnapshotId and at least one mass entry03Close the dayPOST /compliance/journal-periods/{date}/close-dailyclosure with an attestation, attributed to a person in the journal role04Sign off the weekPOST /compliance/journal-periods/{week}/sign-off-weeklydailyClosureIds and an attestation; the sign-off is attributable to a person05Pull the audit exportGET /compliance/audit-exports/{case_or_period}Events with hash and previousHash — a chain that reveals a gapOutput: a period that withstands an audit, because it is not narrated after the factThe hash chain makes a gap visible, not impossible. Its value is that what is missing shows up.
Five calls from weighing to the audit export. The daily closure is attributed to a person.

The contract therefore requires daily closure and weekly sign-off by a signed-in person in the journal role; tapinoma does not sign in its own name. The events carry hash and previousHash: that does not make a gap impossible, but it makes it visible — and that is precisely the purpose.

SurfaceRoles
ComplianceVehicle recyclers

What this case requires

  • Masses that are measured, not estimated. Mass is given with the unit kg or t.
  • A material code per movement. Without it a quantity is a number without an object.
  • The recipient’s permit. A transfer references a permit snapshot; without it the recipient is not evidenced.
  • A person authorised to sign for the week. The sign-off is attributable to a person and not a batch run.

The sequence

The table names the responsible call per stage and what exists afterwards. The reasoning for why a stage cannot be skipped follows below it.

The call chain of this use case
StageCallWhat exists afterwards
Record the movementPOST /compliance/material-movementsmaterialCode, mass and unit per movement, with measurement time
Evidence the transferPOST /compliance/downstream-transfersthe recipient’s permitSnapshotId and at least one mass entry
Close the dayPOST /compliance/journal-periods/{date}/close-dailyclosure with an attestation, attributed to a person in the journal role
Sign off the weekPOST /compliance/journal-periods/{week}/sign-off-weeklydailyClosureIds and an attestation; the sign-off is attributable to a person
Pull the audit exportGET /compliance/audit-exports/{case_or_period}Events with hash and previousHash — a chain that reveals a gap

Why each stage is needed

  1. Record the movement. POST /compliance/material-movements takes facilityId, movementType, materialCode, mass and unit plus source and destination location and the measurement time measuredAt. Recording happens at the weighbridge, not at reporting time — that is the only difference that decides reliability.
  2. Evidence the transfer. POST /compliance/downstream-transfers references the transferred assetRefs, the recipient organisation and facility, their permit snapshot in permitSnapshotId and the transport, and requires at least one entry in masses. The permit snapshot is the point: it records which of the recipient’s entitlements the transfer relied on.
  3. Close the day. POST /compliance/journal-periods/{date}/close-daily takes facilityId, timeZone, closedAt and an attestationId. The closure is attributed to the signed-in person and their journal role; they re-confirm their login for it, and tapinoma does not sign in its own name.
  4. Sign off the week. POST /compliance/journal-periods/{week}/sign-off-weekly references the week’s daily closures and carries an attestation. The sign-off rests with a person.
  5. Pull the audit export. GET /compliance/audit-exports/{case_or_period} emits the events with their hashes — for a case or for a period. That is where a gap shows up, and it shows up to you rather than first to the auditor.
Close an operating day
curl -X POST \
  -H 'Cookie: __Host-tapinomahub_session=<SITZUNG>' \
  -H 'X-CSRF-Token: <CSRF_TOKEN>' \
  -H 'X-Compliance-Organisation-Id: <ORGANISATION>' \
  -H 'Idempotency-Key: tagesabschluss-2026-09-12' \
  -H 'Content-Type: application/json' \
  -d '{"facilityId":"<facilityId>","timeZone":"Europe/Berlin","closedAt":"2026-09-12T18:00:00Z","attestationId":"<attestationId>"}' \
  'https://api.tapinomahub.com/compliance/journal-periods/2026-09-12/close-daily'

What you end up with

What remains is a period that withstands an audit, because it is not narrated after the fact: quantities recorded at the weighbridge, transfers evidenced against the recipient’s permit, days closed and weeks signed by a person.

Where to find this in the documentation

The binding field lists, error codes and sample responses live in this surface’s OpenAPI contract at docs.tapinomahub.com (tapinoma-compliance). All use cases arranged by surface and role: overview of the use cases.

Frequently asked

Who closes the day?

A signed-in person in the journal role who re-confirms their login for it. The closure is attributed to them; tapinoma does not sign in its own name.

Can I sign off a week before all days are closed?

The contract does not state this explicitly. The sign-off references at least one daily closure in dailyClosureIds. The contract also lists the error code journal_daily_closures_invalid, but does not describe its conditions.

How do I find a gap?

Through the audit export. It emits the events with hash and previous hash; an interrupted chain is recognisable from that.