← Guidewheel integration

Guidewheel data model & endpoint map

Everything below was checked against a live tenant, not inferred from the marketing docs.

Where the data comes from

Guidewheel's core sensor is a non-invasive clip-on current transducer (CT clamp) around a machine's power line — no PLC integration, no network port on the machine. From that single current signal the platform derives:

  • Load statesonline (running), idle, offline (down), planned downtime, noData
  • Cycles and cycle time
  • Energy — per-second active power; other metrics per-minute

On top of the sensed signal sit operator- and platform-generated records: downtime issues with tagged reasons, production entries, scrap events, shifts, and tags (standardized reason codes).

Knowing this genealogy matters: everything state-like is inferred from power draw — robust, but blind to machine internals like alarm codes or process parameters — while issues, production and scrap are human- or rule-entered records with the usual bookkeeping caveats.

Two time conventions, and they are not interchangeable

The API rejects the wrong one with a 400. There is no endpoint that accepts both.

ConventionParametersEndpoints
Unix epoch milliseconds (number)from_ts / to_tsload states, uptime, energy, issues, production entries
ISO 8601 stringfrom / totelemetry, scraps

group_by=day is accepted only on uptime and energy. There is no limit, page, or offset parameter anywhere — list endpoints return everything, and filtering is the caller's job. Every endpoint takes an optional company_id.

Entities and their real field names

EntityIdentity fieldNotable fields
Devicedeviceid (a string like acme_press4_prs4)nickname is the human name, status, thresholds[], target
Load state spanstart, end (unix ms), state, color
Issueid (uuid)deviceid, status, startedAt, issuetype, tags[].tagname is the downtime reason, comments.action, changelog[]
Production entryiddevice_id, quantities, waste, a computed oee block
SKUidcompanyid, skucode, status
Tagidtagname, tagcolor, tagtype, tagplanned
Shiftidname, startTime, endTime, minutesFromMidnight, durationMinutes, crossesMidnight, status
Device listidname, devices[] — and a site-level list's id is the plant id
Scrapiddevice_id

Field naming is inconsistent across endpoints (companyid vs companyId, deviceid vs device_id); take each entity as it comes.

Response envelopes

Also inconsistent, so unwrap defensively:

  • Most endpoints: { "data": [ … ] }
  • /skus and device energy: a bare array
  • Load states: { "data": { "<deviceid>": [ …spans ] } } — an object keyed by device, not a list

Endpoints (/api/v1)

PathVerbsNotes
/devicesGET, POSTthe roster
/devices/{id}GETone machine
/devices/loadStatesGETevery machine in one call — prefer this
/devices/{id}/loadStatesGETone machine
/devices/{id}/uptime, /devices/uptimeGETgroup_by=day; returns computedLoadStates.percentages incl. availability
/devices/{id}/energy, /devices/energyGETgroup_by=day
/devices/{id}/telemetryGETrequires metric, granularity (minute\second), ISO from/to
/devices/{id}/thresholds-changesGETnote the plural thresholds-
/issuesGET, POSTfrom_ts/to_ts, updated, comments
/issues/{id}GET, PATCH, DELETEPATCH is the write-back hook
/issues/{issueId}/commentsPOST
/issues/{issueId}/tags/{tagId}PUT, DELETE
/production-entriesGET, POST, DELETEsku, device_id filters
/production-entries/{id}GET, PUTnote PUT, not PATCH
/production-entries/upload, /csv/statusPOST, GETbulk CSV
/skus, /skus/{id}GET, POST / GET
/tagsGET, POST
/device-lists, /device-lists/{id}GET
/plants/{plantId}/current-shiftGETplantId is a positive integer — a device-list id
/plants/{plantId}/scheduleGET
/shiftsGETdefinitions, not occurrences; status is A or D
/scrapsGET, POSTISO from/to required
/metrics, /metrics/all, /metrics/device_metricsGET, POSTundocumented in the vendor guide

There is no /plants list endpoint and no /devices/{id}/state — a natural-looking guess that returns 404.

Gaps to plan around

  • No webhooks or streaming. Everything is polled. Reacting to downtime needs a polling loop against the 1000 calls/day budget — use /devices/loadStates to cover the whole fleet in one request rather than one call per machine.
  • No computed-OEE endpoint. Uptime gives availability via computedLoadStates.percentages; combine with production entries and scrap for the rest. Production entries do carry a per-entry oee block.
  • No alert-rule or anomaly-output API. Alert configuration and anomaly detection are platform-UI features; their outputs surface only as issues.
  • Production entries degrade with range width. No paging, and the endpoint slows sharply as the window grows — roughly 2s for a shift, 4s for a day, 11s for three days, and a seven-day range has been seen to fail with a bodyless 500. Read shift by shift, not week by week.
  • Schemas are tenant-flavored. Field names vary with tenant configuration, and the field-level guide is distributed on request. Every read tool takes a passthrough, every write tool takes a fields object, and guidewheel_api_get probes any path so an agent can learn the live surface empirically.