{"openapi":"3.1.0","info":{"title":"Torgix API","version":"v2","description":"Read and write your Torgix equipment data, and subscribe to webhooks. The API is included with every Torgix account at no extra cost; an admin enables it and issues keys under Settings, API & Webhooks in the app. All requests are tenant-scoped to the key’s account.\n\nThe path is `/v1`; the service root reports engine version `v2`, the second, additive generation of the same surface. 51 resources are exposed through one engine: every resource supports list, get, export and aggregate; writable ones add create, batch, update and soft delete. Fields mirror the record as it appears in the app, including any custom fields an admin has defined. Pull one record to learn its shape.\n\nLimits: 10 requests per second per key, pages of up to 200, exports of up to 2000 rows per call, batches of up to 200, request bodies up to 1 MB.","contact":{"name":"Torgix","url":"https://torgix.ai"},"x-generated":"lib/api_openapi.js from lib/api_resources.js; served live at /v1/openapi.json"},"servers":[{"url":"https://app.torgix.ai/v1","description":"Production"}],"security":[{"ApiKeyAuth":[]},{"OAuth2":[]}],"paths":{"/":{"get":{"summary":"Service root","description":"Returns the API version and the list of available resources.","security":[{"ApiKeyAuth":[]},{"OAuth2":[]}],"responses":{"200":{"description":"Service metadata.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"service":{"type":"string"},"version":{"type":"string"},"resources":{"type":"array","items":{"type":"string"}}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/openapi.json":{"get":{"summary":"This document","tags":["Reference"],"description":"The OpenAPI document for the running API, generated from its resource registry. No credentials needed.","security":[],"responses":{"200":{"description":"The OpenAPI 3.1 document.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}}}}},"/events":{"get":{"summary":"Poll events","tags":["Events"],"description":"Pull recent events without a webhook. Cursor forward with the `cursor` field of the last item. Events are recorded for every create, update and delete made through the API (`<resource>.created`, `.updated`, `.deleted`).","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/page_size"},{"name":"cursor","in":"query","schema":{"type":"string"},"description":"Return events after this cursor."},{"name":"event_type","in":"query","schema":{"type":"string"},"description":"Filter to one event type, e.g. assets.created."}],"responses":{"200":{"description":"A page of events.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/EventList"}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/assets":{"get":{"tags":["assets"],"summary":"List assets","description":"Returns a page of assets. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of assets.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["assets"],"summary":"Create assets","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe. Accepts `custom_fields` keyed by API key.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/assets/batch":{"post":{"tags":["assets"],"summary":"Batch assets","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/assets/export":{"get":{"tags":["assets"],"summary":"Export assets","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/assets/aggregate":{"get":{"tags":["assets"],"summary":"Aggregate assets","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/assets/{id}":{"get":{"tags":["assets"],"summary":"Get assets","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["assets"],"summary":"Update assets","description":"Patches the supplied fields on one record. `asset_id` cannot be changed. `custom_fields` may be included.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["assets"],"summary":"Delete assets","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/locations":{"get":{"tags":["locations"],"summary":"List locations","description":"Returns a page of locations. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of locations.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["locations"],"summary":"Create locations","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/locations/batch":{"post":{"tags":["locations"],"summary":"Batch locations","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/locations/export":{"get":{"tags":["locations"],"summary":"Export locations","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/locations/aggregate":{"get":{"tags":["locations"],"summary":"Aggregate locations","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/locations/{id}":{"get":{"tags":["locations"],"summary":"Get locations","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["locations"],"summary":"Update locations","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["locations"],"summary":"Delete locations","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/work_orders":{"get":{"tags":["work_orders"],"summary":"List work orders","description":"Returns a page of work orders. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of work orders.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["work_orders"],"summary":"Create work orders","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe. Accepts `custom_fields` keyed by API key.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/work_orders/batch":{"post":{"tags":["work_orders"],"summary":"Batch work orders","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/work_orders/export":{"get":{"tags":["work_orders"],"summary":"Export work orders","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/work_orders/aggregate":{"get":{"tags":["work_orders"],"summary":"Aggregate work orders","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/work_orders/{id}":{"get":{"tags":["work_orders"],"summary":"Get work orders","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["work_orders"],"summary":"Update work orders","description":"Patches the supplied fields on one record. `asset_id` cannot be changed. `custom_fields` may be included.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["work_orders"],"summary":"Delete work orders","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/maintenance":{"get":{"tags":["maintenance"],"summary":"List maintenance logs","description":"Returns a page of maintenance logs. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of maintenance logs.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["maintenance"],"summary":"Create maintenance logs","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/maintenance/batch":{"post":{"tags":["maintenance"],"summary":"Batch maintenance logs","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/maintenance/export":{"get":{"tags":["maintenance"],"summary":"Export maintenance logs","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/maintenance/aggregate":{"get":{"tags":["maintenance"],"summary":"Aggregate maintenance logs","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/maintenance/{id}":{"get":{"tags":["maintenance"],"summary":"Get maintenance logs","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["maintenance"],"summary":"Delete maintenance logs","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/pm_schedules":{"get":{"tags":["pm_schedules"],"summary":"List pm schedules","description":"Returns a page of pm schedules. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of pm schedules.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/pm_schedules/export":{"get":{"tags":["pm_schedules"],"summary":"Export pm schedules","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/pm_schedules/aggregate":{"get":{"tags":["pm_schedules"],"summary":"Aggregate pm schedules","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/pm_schedules/{id}":{"get":{"tags":["pm_schedules"],"summary":"Get pm schedules","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspections":{"get":{"tags":["inspections"],"summary":"List inspections","description":"Returns a page of inspections. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of inspections.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["inspections"],"summary":"Create inspections","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspections/batch":{"post":{"tags":["inspections"],"summary":"Batch inspections","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspections/export":{"get":{"tags":["inspections"],"summary":"Export inspections","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspections/aggregate":{"get":{"tags":["inspections"],"summary":"Aggregate inspections","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspections/{id}":{"get":{"tags":["inspections"],"summary":"Get inspections","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["inspections"],"summary":"Delete inspections","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/issues":{"get":{"tags":["issues"],"summary":"List issues","description":"Returns a page of issues. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of issues.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["issues"],"summary":"Create issues","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/issues/batch":{"post":{"tags":["issues"],"summary":"Batch issues","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/issues/export":{"get":{"tags":["issues"],"summary":"Export issues","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/issues/aggregate":{"get":{"tags":["issues"],"summary":"Aggregate issues","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/issues/{id}":{"get":{"tags":["issues"],"summary":"Get issues","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["issues"],"summary":"Update issues","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["issues"],"summary":"Delete issues","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/activities":{"get":{"tags":["activities"],"summary":"List activities","description":"Returns a page of activities. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of activities.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/activities/export":{"get":{"tags":["activities"],"summary":"Export activities","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/activities/aggregate":{"get":{"tags":["activities"],"summary":"Aggregate activities","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/activities/{id}":{"get":{"tags":["activities"],"summary":"Get activities","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/projects":{"get":{"tags":["projects"],"summary":"List projects","description":"Returns a page of projects. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of projects.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/projects/export":{"get":{"tags":["projects"],"summary":"Export projects","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/projects/aggregate":{"get":{"tags":["projects"],"summary":"Aggregate projects","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/projects/{id}":{"get":{"tags":["projects"],"summary":"Get projects","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rentals":{"get":{"tags":["rentals"],"summary":"List rental contracts","description":"Returns a page of rental contracts. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of rental contracts.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rentals/export":{"get":{"tags":["rentals"],"summary":"Export rental contracts","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rentals/aggregate":{"get":{"tags":["rentals"],"summary":"Aggregate rental contracts","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rentals/{id}":{"get":{"tags":["rentals"],"summary":"Get rental contracts","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["rentals"],"summary":"Update rental contracts","description":"This resource is read-only for columns, but its custom fields can be written: the body must be exactly `{\"custom_fields\": {...}}`. Any other body returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customers":{"get":{"tags":["customers"],"summary":"List customers","description":"Returns a page of customers. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of customers.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customers/export":{"get":{"tags":["customers"],"summary":"Export customers","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customers/aggregate":{"get":{"tags":["customers"],"summary":"Aggregate customers","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customers/{id}":{"get":{"tags":["customers"],"summary":"Get customers","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["customers"],"summary":"Update customers","description":"This resource is read-only for columns, but its custom fields can be written: the body must be exactly `{\"custom_fields\": {...}}`. Any other body returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts":{"get":{"tags":["parts"],"summary":"List parts requests","description":"Returns a page of parts requests. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of parts requests.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts/export":{"get":{"tags":["parts"],"summary":"Export parts requests","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts/aggregate":{"get":{"tags":["parts"],"summary":"Aggregate parts requests","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts/{id}":{"get":{"tags":["parts"],"summary":"Get parts requests","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts_orders":{"get":{"tags":["parts_orders"],"summary":"List parts orders","description":"Returns a page of parts orders. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of parts orders.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts_orders/export":{"get":{"tags":["parts_orders"],"summary":"Export parts orders","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts_orders/aggregate":{"get":{"tags":["parts_orders"],"summary":"Aggregate parts orders","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/parts_orders/{id}":{"get":{"tags":["parts_orders"],"summary":"Get parts orders","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["parts_orders"],"summary":"Update parts orders","description":"This resource is read-only for columns, but its custom fields can be written: the body must be exactly `{\"custom_fields\": {...}}`. Any other body returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory":{"get":{"tags":["inventory"],"summary":"List inventory","description":"Returns a page of inventory. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of inventory.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory/export":{"get":{"tags":["inventory"],"summary":"Export inventory","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory/aggregate":{"get":{"tags":["inventory"],"summary":"Aggregate inventory","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory/{id}":{"get":{"tags":["inventory"],"summary":"Get inventory","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record. Includes `custom_fields`.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["inventory"],"summary":"Update inventory","description":"This resource is read-only for columns, but its custom fields can be written: the body must be exactly `{\"custom_fields\": {...}}`. Any other body returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranties":{"get":{"tags":["warranties"],"summary":"List warranties","description":"Returns a page of warranties. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of warranties.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranties/export":{"get":{"tags":["warranties"],"summary":"Export warranties","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranties/aggregate":{"get":{"tags":["warranties"],"summary":"Aggregate warranties","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranties/{id}":{"get":{"tags":["warranties"],"summary":"Get warranties","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fuel_logs":{"get":{"tags":["fuel_logs"],"summary":"List fuel logs","description":"Returns a page of fuel logs. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of fuel logs.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["fuel_logs"],"summary":"Create fuel logs","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fuel_logs/batch":{"post":{"tags":["fuel_logs"],"summary":"Batch fuel logs","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fuel_logs/export":{"get":{"tags":["fuel_logs"],"summary":"Export fuel logs","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fuel_logs/aggregate":{"get":{"tags":["fuel_logs"],"summary":"Aggregate fuel logs","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fuel_logs/{id}":{"get":{"tags":["fuel_logs"],"summary":"Get fuel logs","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["fuel_logs"],"summary":"Delete fuel logs","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/meter_readings":{"get":{"tags":["meter_readings"],"summary":"List meter readings","description":"Returns a page of meter readings. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of meter readings.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["meter_readings"],"summary":"Create meter readings","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_readings/batch":{"post":{"tags":["meter_readings"],"summary":"Batch meter readings","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_readings/export":{"get":{"tags":["meter_readings"],"summary":"Export meter readings","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_readings/aggregate":{"get":{"tags":["meter_readings"],"summary":"Aggregate meter readings","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_readings/{id}":{"get":{"tags":["meter_readings"],"summary":"Get meter readings","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["meter_readings"],"summary":"Delete meter readings","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/tire_readings":{"get":{"tags":["tire_readings"],"summary":"List tire readings","description":"Returns a page of tire readings. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of tire readings.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["tire_readings"],"summary":"Create tire readings","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/tire_readings/batch":{"post":{"tags":["tire_readings"],"summary":"Batch tire readings","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/tire_readings/export":{"get":{"tags":["tire_readings"],"summary":"Export tire readings","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/tire_readings/aggregate":{"get":{"tags":["tire_readings"],"summary":"Aggregate tire readings","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/tire_readings/{id}":{"get":{"tags":["tire_readings"],"summary":"Get tire readings","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["tire_readings"],"summary":"Delete tire readings","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/users":{"get":{"tags":["users"],"summary":"List users","description":"Returns a page of users. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of users.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/users/export":{"get":{"tags":["users"],"summary":"Export users","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/users/aggregate":{"get":{"tags":["users"],"summary":"Aggregate users","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/users/{id}":{"get":{"tags":["users"],"summary":"Get users","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/audit_events":{"get":{"tags":["audit_events"],"summary":"List audit log","description":"Returns a page of audit log. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of audit log.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/audit_events/export":{"get":{"tags":["audit_events"],"summary":"Export audit log","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/audit_events/aggregate":{"get":{"tags":["audit_events"],"summary":"Aggregate audit log","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/audit_events/{id}":{"get":{"tags":["audit_events"],"summary":"Get audit log","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance":{"get":{"tags":["compliance"],"summary":"List compliance records","description":"Returns a page of compliance records. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of compliance records.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["compliance"],"summary":"Create compliance records","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance/batch":{"post":{"tags":["compliance"],"summary":"Batch compliance records","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance/export":{"get":{"tags":["compliance"],"summary":"Export compliance records","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance/aggregate":{"get":{"tags":["compliance"],"summary":"Aggregate compliance records","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance/{id}":{"get":{"tags":["compliance"],"summary":"Get compliance records","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["compliance"],"summary":"Update compliance records","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["compliance"],"summary":"Delete compliance records","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/insurance":{"get":{"tags":["insurance"],"summary":"List insurance","description":"Returns a page of insurance. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of insurance.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["insurance"],"summary":"Create insurance","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/insurance/batch":{"post":{"tags":["insurance"],"summary":"Batch insurance","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/insurance/export":{"get":{"tags":["insurance"],"summary":"Export insurance","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/insurance/aggregate":{"get":{"tags":["insurance"],"summary":"Aggregate insurance","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/insurance/{id}":{"get":{"tags":["insurance"],"summary":"Get insurance","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["insurance"],"summary":"Update insurance","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["insurance"],"summary":"Delete insurance","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/documents":{"get":{"tags":["documents"],"summary":"List documents","description":"Returns a page of documents. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of documents.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/documents/export":{"get":{"tags":["documents"],"summary":"Export documents","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/documents/aggregate":{"get":{"tags":["documents"],"summary":"Aggregate documents","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/documents/{id}":{"get":{"tags":["documents"],"summary":"Get documents","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/costs":{"get":{"tags":["costs"],"summary":"List true cost","description":"Returns a page of true cost. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of true cost.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/costs/export":{"get":{"tags":["costs"],"summary":"Export true cost","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/costs/aggregate":{"get":{"tags":["costs"],"summary":"Aggregate true cost","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/costs/{id}":{"get":{"tags":["costs"],"summary":"Get true cost","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/cost_inputs":{"get":{"tags":["cost_inputs"],"summary":"List cost inputs","description":"Returns a page of cost inputs. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of cost inputs.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["cost_inputs"],"summary":"Create cost inputs","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/cost_inputs/batch":{"post":{"tags":["cost_inputs"],"summary":"Batch cost inputs","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/cost_inputs/export":{"get":{"tags":["cost_inputs"],"summary":"Export cost inputs","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/cost_inputs/aggregate":{"get":{"tags":["cost_inputs"],"summary":"Aggregate cost inputs","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/cost_inputs/{id}":{"get":{"tags":["cost_inputs"],"summary":"Get cost inputs","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["cost_inputs"],"summary":"Update cost inputs","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["cost_inputs"],"summary":"Delete cost inputs","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/downtime":{"get":{"tags":["downtime"],"summary":"List downtime","description":"Returns a page of downtime. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of downtime.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["downtime"],"summary":"Create downtime","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/downtime/batch":{"post":{"tags":["downtime"],"summary":"Batch downtime","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/downtime/export":{"get":{"tags":["downtime"],"summary":"Export downtime","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/downtime/aggregate":{"get":{"tags":["downtime"],"summary":"Aggregate downtime","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/downtime/{id}":{"get":{"tags":["downtime"],"summary":"Get downtime","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["downtime"],"summary":"Delete downtime","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/telematics":{"get":{"tags":["telematics"],"summary":"List telematics","description":"Returns a page of telematics. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of telematics.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/telematics/export":{"get":{"tags":["telematics"],"summary":"Export telematics","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/telematics/aggregate":{"get":{"tags":["telematics"],"summary":"Aggregate telematics","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/telematics/{id}":{"get":{"tags":["telematics"],"summary":"Get telematics","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/idle_time":{"get":{"tags":["idle_time"],"summary":"List idle time","description":"Returns a page of idle time. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of idle time.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/idle_time/export":{"get":{"tags":["idle_time"],"summary":"Export idle time","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/idle_time/aggregate":{"get":{"tags":["idle_time"],"summary":"Aggregate idle time","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/idle_time/{id}":{"get":{"tags":["idle_time"],"summary":"Get idle time","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customer_contacts":{"get":{"tags":["customer_contacts"],"summary":"List customer contacts","description":"Returns a page of customer contacts. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of customer contacts.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["customer_contacts"],"summary":"Create customer contacts","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customer_contacts/batch":{"post":{"tags":["customer_contacts"],"summary":"Batch customer contacts","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customer_contacts/export":{"get":{"tags":["customer_contacts"],"summary":"Export customer contacts","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customer_contacts/aggregate":{"get":{"tags":["customer_contacts"],"summary":"Aggregate customer contacts","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/customer_contacts/{id}":{"get":{"tags":["customer_contacts"],"summary":"Get customer contacts","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["customer_contacts"],"summary":"Update customer contacts","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["customer_contacts"],"summary":"Delete customer contacts","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/inventory_usage":{"get":{"tags":["inventory_usage"],"summary":"List inventory usage","description":"Returns a page of inventory usage. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of inventory usage.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory_usage/export":{"get":{"tags":["inventory_usage"],"summary":"Export inventory usage","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory_usage/aggregate":{"get":{"tags":["inventory_usage"],"summary":"Aggregate inventory usage","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inventory_usage/{id}":{"get":{"tags":["inventory_usage"],"summary":"Get inventory usage","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/project_assets":{"get":{"tags":["project_assets"],"summary":"List project assets","description":"Returns a page of project assets. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of project assets.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["project_assets"],"summary":"Create project assets","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/project_assets/batch":{"post":{"tags":["project_assets"],"summary":"Batch project assets","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/project_assets/export":{"get":{"tags":["project_assets"],"summary":"Export project assets","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/project_assets/aggregate":{"get":{"tags":["project_assets"],"summary":"Aggregate project assets","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/project_assets/{id}":{"get":{"tags":["project_assets"],"summary":"Get project assets","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["project_assets"],"summary":"Delete project assets","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/faults":{"get":{"tags":["faults"],"summary":"List fault codes","description":"Returns a page of fault codes. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of fault codes.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["faults"],"summary":"Create fault codes","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/faults/batch":{"post":{"tags":["faults"],"summary":"Batch fault codes","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/faults/export":{"get":{"tags":["faults"],"summary":"Export fault codes","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/faults/aggregate":{"get":{"tags":["faults"],"summary":"Aggregate fault codes","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/faults/{id}":{"get":{"tags":["faults"],"summary":"Get fault codes","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["faults"],"summary":"Delete fault codes","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/recalls":{"get":{"tags":["recalls"],"summary":"List recalls and bulletins","description":"Returns a page of recalls and bulletins. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of recalls and bulletins.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["recalls"],"summary":"Create recalls and bulletins","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/recalls/batch":{"post":{"tags":["recalls"],"summary":"Batch recalls and bulletins","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/recalls/export":{"get":{"tags":["recalls"],"summary":"Export recalls and bulletins","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/recalls/aggregate":{"get":{"tags":["recalls"],"summary":"Aggregate recalls and bulletins","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/recalls/{id}":{"get":{"tags":["recalls"],"summary":"Get recalls and bulletins","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["recalls"],"summary":"Delete recalls and bulletins","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/charge_logs":{"get":{"tags":["charge_logs"],"summary":"List ev charge sessions","description":"Returns a page of ev charge sessions. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of ev charge sessions.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["charge_logs"],"summary":"Create ev charge sessions","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/charge_logs/batch":{"post":{"tags":["charge_logs"],"summary":"Batch ev charge sessions","description":"Up to 200 operations in one call; each item reports its own status. This resource accepts `create` operations only; an `update` item returns 405.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/charge_logs/export":{"get":{"tags":["charge_logs"],"summary":"Export ev charge sessions","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/charge_logs/aggregate":{"get":{"tags":["charge_logs"],"summary":"Aggregate ev charge sessions","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/charge_logs/{id}":{"get":{"tags":["charge_logs"],"summary":"Get ev charge sessions","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["charge_logs"],"summary":"Delete ev charge sessions","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/checkouts":{"get":{"tags":["checkouts"],"summary":"List tool checkouts","description":"Returns a page of tool checkouts. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of tool checkouts.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/checkouts/export":{"get":{"tags":["checkouts"],"summary":"Export tool checkouts","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/checkouts/aggregate":{"get":{"tags":["checkouts"],"summary":"Aggregate tool checkouts","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/checkouts/{id}":{"get":{"tags":["checkouts"],"summary":"Get tool checkouts","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/employees":{"get":{"tags":["employees"],"summary":"List employees","description":"Returns a page of employees. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of employees.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}},"post":{"tags":["employees"],"summary":"Create employees","description":"Creates one record. `company_id` and internal columns are set by Torgix and cannot be supplied; for asset-scoped resources `asset_id` is required and verified to belong to your account. Send `Idempotency-Key` to make retries safe.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"$ref":"#/components/parameters/IdempotencyKey"}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true,"description":"Writable fields for the record."}}}},"responses":{"201":{"description":"Created.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"409":{"$ref":"#/components/responses/Conflict"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/employees/batch":{"post":{"tags":["employees"],"summary":"Batch employees","description":"Up to 200 operations in one call; each item reports its own status. Operations may be `create` or `update`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchRequest"}}}},"responses":{"200":{"description":"Per-item results.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BatchResponse"}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/employees/export":{"get":{"tags":["employees"],"summary":"Export employees","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/employees/aggregate":{"get":{"tags":["employees"],"summary":"Aggregate employees","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/employees/{id}":{"get":{"tags":["employees"],"summary":"Get employees","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}},"patch":{"tags":["employees"],"summary":"Update employees","description":"Patches the supplied fields on one record. `asset_id` cannot be changed.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"responses":{"200":{"description":"Updated.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"405":{"$ref":"#/components/responses/ReadOnly"},"422":{"$ref":"#/components/responses/Unprocessable"},"429":{"$ref":"#/components/responses/RateLimited"}}},"delete":{"tags":["employees"],"summary":"Delete employees","description":"Soft delete: stamps `deleted_at`; the row disappears from reads unless `?include_deleted=true`. Nothing is ever hard-deleted. Repeating the call returns 200 with `already_deleted`. Supported where the underlying table keeps a `deleted_at` column; otherwise 501 `delete_not_supported`.","security":[{"ApiKeyAuth":["write"]},{"OAuth2":["write"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}}],"responses":{"200":{"description":"Deleted (or already deleted).","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","properties":{"id":{"type":"integer"},"deleted":{"type":"boolean"},"already_deleted":{"type":"boolean"}}},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"},"501":{"$ref":"#/components/responses/NotSupported"}}}},"/service_trips":{"get":{"tags":["service_trips"],"summary":"List road calls","description":"Returns a page of road calls. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of road calls.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trips/export":{"get":{"tags":["service_trips"],"summary":"Export road calls","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trips/aggregate":{"get":{"tags":["service_trips"],"summary":"Aggregate road calls","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trips/{id}":{"get":{"tags":["service_trips"],"summary":"Get road calls","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trip_stops":{"get":{"tags":["service_trip_stops"],"summary":"List road call stops","description":"Returns a page of road call stops. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of road call stops.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trip_stops/export":{"get":{"tags":["service_trip_stops"],"summary":"Export road call stops","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trip_stops/aggregate":{"get":{"tags":["service_trip_stops"],"summary":"Aggregate road call stops","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/service_trip_stops/{id}":{"get":{"tags":["service_trip_stops"],"summary":"Get road call stops","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/vendor_orders":{"get":{"tags":["vendor_orders"],"summary":"List vendor orders","description":"Returns a page of vendor orders. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of vendor orders.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/vendor_orders/export":{"get":{"tags":["vendor_orders"],"summary":"Export vendor orders","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/vendor_orders/aggregate":{"get":{"tags":["vendor_orders"],"summary":"Aggregate vendor orders","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/vendor_orders/{id}":{"get":{"tags":["vendor_orders"],"summary":"Get vendor orders","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_classes":{"get":{"tags":["rental_classes"],"summary":"List rental classes","description":"Returns a page of rental classes. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of rental classes.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_classes/export":{"get":{"tags":["rental_classes"],"summary":"Export rental classes","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_classes/aggregate":{"get":{"tags":["rental_classes"],"summary":"Aggregate rental classes","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_classes/{id}":{"get":{"tags":["rental_classes"],"summary":"Get rental classes","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_catalog":{"get":{"tags":["rental_catalog"],"summary":"List rental catalog","description":"Returns a page of rental catalog. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of rental catalog.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_catalog/export":{"get":{"tags":["rental_catalog"],"summary":"Export rental catalog","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_catalog/aggregate":{"get":{"tags":["rental_catalog"],"summary":"Aggregate rental catalog","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_catalog/{id}":{"get":{"tags":["rental_catalog"],"summary":"Get rental catalog","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_logistics":{"get":{"tags":["rental_logistics"],"summary":"List rental logistics","description":"Returns a page of rental logistics. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of rental logistics.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_logistics/export":{"get":{"tags":["rental_logistics"],"summary":"Export rental logistics","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_logistics/aggregate":{"get":{"tags":["rental_logistics"],"summary":"Aggregate rental logistics","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/rental_logistics/{id}":{"get":{"tags":["rental_logistics"],"summary":"Get rental logistics","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_daily":{"get":{"tags":["meter_daily"],"summary":"List daily telematics meters","description":"Returns a page of daily telematics meters. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of daily telematics meters.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_daily/export":{"get":{"tags":["meter_daily"],"summary":"Export daily telematics meters","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_daily/aggregate":{"get":{"tags":["meter_daily"],"summary":"Aggregate daily telematics meters","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/meter_daily/{id}":{"get":{"tags":["meter_daily"],"summary":"Get daily telematics meters","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fleet_briefs":{"get":{"tags":["fleet_briefs"],"summary":"List fleet briefs","description":"Returns a page of fleet briefs. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of fleet briefs.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fleet_briefs/export":{"get":{"tags":["fleet_briefs"],"summary":"Export fleet briefs","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fleet_briefs/aggregate":{"get":{"tags":["fleet_briefs"],"summary":"Aggregate fleet briefs","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/fleet_briefs/{id}":{"get":{"tags":["fleet_briefs"],"summary":"Get fleet briefs","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/module_briefs":{"get":{"tags":["module_briefs"],"summary":"List module briefs","description":"Returns a page of module briefs. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of module briefs.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/module_briefs/export":{"get":{"tags":["module_briefs"],"summary":"Export module briefs","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/module_briefs/aggregate":{"get":{"tags":["module_briefs"],"summary":"Aggregate module briefs","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/module_briefs/{id}":{"get":{"tags":["module_briefs"],"summary":"Get module briefs","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_assessments":{"get":{"tags":["warranty_assessments"],"summary":"List warranty assessments","description":"Returns a page of warranty assessments. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of warranty assessments.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_assessments/export":{"get":{"tags":["warranty_assessments"],"summary":"Export warranty assessments","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_assessments/aggregate":{"get":{"tags":["warranty_assessments"],"summary":"Aggregate warranty assessments","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_assessments/{id}":{"get":{"tags":["warranty_assessments"],"summary":"Get warranty assessments","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspection_templates":{"get":{"tags":["inspection_templates"],"summary":"List inspection templates","description":"Returns a page of inspection templates. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of inspection templates.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspection_templates/export":{"get":{"tags":["inspection_templates"],"summary":"Export inspection templates","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspection_templates/aggregate":{"get":{"tags":["inspection_templates"],"summary":"Aggregate inspection templates","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/inspection_templates/{id}":{"get":{"tags":["inspection_templates"],"summary":"Get inspection templates","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance_requirements":{"get":{"tags":["compliance_requirements"],"summary":"List state compliance requirements","description":"Returns a page of state compliance requirements. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of state compliance requirements.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance_requirements/export":{"get":{"tags":["compliance_requirements"],"summary":"Export state compliance requirements","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance_requirements/aggregate":{"get":{"tags":["compliance_requirements"],"summary":"Aggregate state compliance requirements","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/compliance_requirements/{id}":{"get":{"tags":["compliance_requirements"],"summary":"Get state compliance requirements","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_compliance_requirements":{"get":{"tags":["asset_compliance_requirements"],"summary":"List asset compliance requirements","description":"Returns a page of asset compliance requirements. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of asset compliance requirements.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_compliance_requirements/export":{"get":{"tags":["asset_compliance_requirements"],"summary":"Export asset compliance requirements","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_compliance_requirements/aggregate":{"get":{"tags":["asset_compliance_requirements"],"summary":"Aggregate asset compliance requirements","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_compliance_requirements/{id}":{"get":{"tags":["asset_compliance_requirements"],"summary":"Get asset compliance requirements","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_skus":{"get":{"tags":["warranty_skus"],"summary":"List warranty skus","description":"Returns a page of warranty skus. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of warranty skus.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_skus/export":{"get":{"tags":["warranty_skus"],"summary":"Export warranty skus","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_skus/aggregate":{"get":{"tags":["warranty_skus"],"summary":"Aggregate warranty skus","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/warranty_skus/{id}":{"get":{"tags":["warranty_skus"],"summary":"Get warranty skus","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_photos":{"get":{"tags":["asset_photos"],"summary":"List asset photos","description":"Returns a page of asset photos. Without `sort`, pages are keyset (pass `next_cursor` back as `cursor`); with `sort`, pages are numbered (`page`, `page_size`, `next_page`). Filter on any field: `?status=active` (exact), or an operator in brackets, `?hours[gte]=500`, `?status[in]=open,active`, `?name[like]=%320%`, `?cleared_at[null]=true` (operators: eq, ne, gt, gte, lt, lte, in, nin, like, nlike, null). Add `?changed_since=` for incremental sync and `?fields=` to project columns. Soft-deleted rows are hidden unless `?include_deleted=true`.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/cursor"},{"$ref":"#/components/parameters/page_size"},{"$ref":"#/components/parameters/sort"},{"$ref":"#/components/parameters/page"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"A page of asset photos.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"next_cursor":{"type":["string","null"],"description":"Keyset mode: pass back as ?cursor= for the next page; null when no more."},"page":{"type":"integer","description":"Sorted mode only."},"page_size":{"type":"integer","description":"Sorted mode only."},"next_page":{"type":["integer","null"],"description":"Sorted mode only."},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_photos/export":{"get":{"tags":["asset_photos"],"summary":"Export asset photos","description":"Bulk pull (JSON array, or `?format=ndjson` with an `X-Truncated` header), capped at 2000 rows per call with a `truncated` flag. The same filters, `fields` and `changed_since` apply.","security":[{"ApiKeyAuth":["export"]},{"OAuth2":["export"]}],"parameters":[{"$ref":"#/components/parameters/fields"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"},{"name":"format","in":"query","schema":{"type":"string","enum":["json","ndjson"]}}],"responses":{"200":{"description":"Exported rows.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","additionalProperties":true}},"count":{"type":"integer"},"truncated":{"type":"boolean"},"max":{"type":"integer"},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_photos/aggregate":{"get":{"tags":["asset_photos"],"summary":"Aggregate asset photos","description":"One number, or one number per group, over the same filters as the list. `metric` is `count` or `sum:col`, `avg:col`, `min:col`, `max:col`; add `group_by=col` for up to 1000 groups, largest first.","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"$ref":"#/components/parameters/metric"},{"$ref":"#/components/parameters/group_by"},{"$ref":"#/components/parameters/changed_since"},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"The metric.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"oneOf":[{"type":"object","properties":{"value":{"type":"number"}}},{"type":"array","items":{"type":"object","properties":{"group":{},"value":{"type":"number"}}}}]},"metric":{"type":"string"},"group_by":{"type":"string"},"request_id":{"type":"string"}}}}}},"400":{"$ref":"#/components/responses/BadRequest"},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"429":{"$ref":"#/components/responses/RateLimited"}}}},"/asset_photos/{id}":{"get":{"tags":["asset_photos"],"summary":"Get asset photos","security":[{"ApiKeyAuth":["read"]},{"OAuth2":["read"]}],"parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"integer"}},{"$ref":"#/components/parameters/include_deleted"}],"responses":{"200":{"description":"One record.","headers":{"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}},"content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"object","additionalProperties":true},"request_id":{"type":"string"}}}}}},"401":{"$ref":"#/components/responses/Unauthorized"},"403":{"$ref":"#/components/responses/Forbidden"},"404":{"$ref":"#/components/responses/NotFound"},"429":{"$ref":"#/components/responses/RateLimited"}}}}},"tags":[{"name":"Reference"},{"name":"Events"},{"name":"assets","x-displayName":"Assets","description":"Create, update, delete."},{"name":"locations","x-displayName":"Locations","description":"Create, update, delete."},{"name":"work_orders","x-displayName":"Work orders","description":"Create, update, delete."},{"name":"maintenance","x-displayName":"Maintenance logs","description":"Completed service history. Append-only: a log is a record of work already done. Create only (append log)."},{"name":"pm_schedules","x-displayName":"PM schedules","description":"Preventive maintenance schedules per asset (interval, last done, next due). Read-only."},{"name":"inspections","x-displayName":"Inspections","description":"Create only (append log)."},{"name":"issues","x-displayName":"Issues","description":"Create, update, delete."},{"name":"activities","x-displayName":"Activities","description":"Read-only."},{"name":"projects","x-displayName":"Projects","description":"Read-only."},{"name":"rentals","x-displayName":"Rental contracts","description":"Read-only."},{"name":"customers","x-displayName":"Customers","description":"Read-only."},{"name":"parts","x-displayName":"Parts requests","description":"Read-only."},{"name":"parts_orders","x-displayName":"Parts orders","description":"Read-only."},{"name":"inventory","x-displayName":"Inventory","description":"Read-only."},{"name":"warranties","x-displayName":"Warranties","description":"Read-only."},{"name":"fuel_logs","x-displayName":"Fuel logs","description":"Create only (append log)."},{"name":"meter_readings","x-displayName":"Meter readings","description":"Create only (append log)."},{"name":"tire_readings","x-displayName":"Tire readings","description":"Create only (append log)."},{"name":"users","x-displayName":"Users","description":"Read-only."},{"name":"audit_events","x-displayName":"Audit log","description":"The account audit log, for pulling into a SIEM. Filter by created_at, cursor by id. Read-only."},{"name":"compliance","x-displayName":"Compliance records","description":"Create, update, delete."},{"name":"insurance","x-displayName":"Insurance","description":"Create, update, delete."},{"name":"documents","x-displayName":"Documents","description":"Document metadata; the storage path is not exposed and uploads go through the app. Read-only."},{"name":"costs","x-displayName":"True Cost","description":"Computed True Cost rows per asset, including the CFO fields; read-only because they are derived. Read-only."},{"name":"cost_inputs","x-displayName":"Cost inputs","description":"The per-asset inputs True Cost is computed from (purchase, salvage, finance, insurance, storage). Create, update, delete."},{"name":"downtime","x-displayName":"Downtime","description":"Create only (append log)."},{"name":"telematics","x-displayName":"Telematics","description":"Latest GPS and engine snapshot per asset, fed by the connected telematics provider. Read-only."},{"name":"idle_time","x-displayName":"Idle time","description":"Idle events derived from telematics. Read-only."},{"name":"customer_contacts","x-displayName":"Customer contacts","description":"Create, update, delete."},{"name":"inventory_usage","x-displayName":"Inventory usage","description":"Read-only."},{"name":"project_assets","x-displayName":"Project assets","description":"Create only (append log)."},{"name":"faults","x-displayName":"Fault codes","description":"Diagnostic trouble codes per asset (OBD-II, J1939, J1587) from telematics, import, or manual entry. Post one to record a code read off the machine. Create only (append log)."},{"name":"recalls","x-displayName":"Recalls and bulletins","description":"NHTSA recalls, OEM bulletins and manual notices matched to an asset, with a status workflow. Create only (append log)."},{"name":"charge_logs","x-displayName":"EV charge sessions","description":"EV charging sessions: state of charge in and out, kWh added, duration. Fed by Samsara; post one for a charger that is not connected. Create only (append log)."},{"name":"checkouts","x-displayName":"Tool checkouts","description":"Small-tool checkouts: what left the shop, where it went, when it came back, what was charged. Read-only."},{"name":"employees","x-displayName":"Employees","description":"People for labor costing: position, pay basis, burden. Includes pay fields; issue keys accordingly. Create, update, delete."},{"name":"service_trips","x-displayName":"Road calls","description":"Job-site repair trips by a service truck, costed by miles and mechanic time. Read-only."},{"name":"service_trip_stops","x-displayName":"Road call stops","description":"The stops on a road call, each tied to a work order with its share of the trip cost. Read-only."},{"name":"vendor_orders","x-displayName":"Vendor orders","description":"Parts orders placed through Commerce Connect vendors, with totals and status. Read-only."},{"name":"rental_classes","x-displayName":"Rental classes","description":"Rental classes an asset can belong to (rate setup follows the rental billing release). Read-only."},{"name":"rental_catalog","x-displayName":"Rental catalog","description":"Rentable items and services with their rates. Read-only."},{"name":"rental_logistics","x-displayName":"Rental logistics","description":"Deliveries and pickups scheduled against a rental contract. Read-only."},{"name":"meter_daily","x-displayName":"Daily telematics meters","description":"One row per asset per day: engine hours, idle, odometer, fuel, PTO and regen hours, payload. Fed by Samsara, Motive or Rovi. Read-only."},{"name":"fleet_briefs","x-displayName":"Fleet briefs","description":"AI fleet briefs generated for the account, by date. Read-only."},{"name":"module_briefs","x-displayName":"Module briefs","description":"AI briefs generated per module and record. Read-only."},{"name":"warranty_assessments","x-displayName":"Warranty assessments","description":"AI warranty verdict per work order: covered items, exclusions, rationale, confidence. Read-only."},{"name":"inspection_templates","x-displayName":"Inspection templates","description":"Inspection checklists defined by the account. Read-only."},{"name":"compliance_requirements","x-displayName":"State compliance requirements","description":"State compliance requirements the account tracks, with authority, cadence and verification status. Read-only."},{"name":"asset_compliance_requirements","x-displayName":"Asset compliance requirements","description":"Which requirements apply to which asset, and whether each is satisfied. Read-only."},{"name":"warranty_skus","x-displayName":"Warranty SKUs","description":"Warranty products the account sells or tracks. Read-only."},{"name":"asset_photos","x-displayName":"Asset photos","description":"Photo metadata per asset (name, type, size, caption). The image itself is not served by the API. Read-only."}],"x-tagGroups":[{"name":"Reference","tags":["Reference","Events"]},{"name":"Resources","tags":["assets","locations","work_orders","maintenance","pm_schedules","inspections","issues","activities","projects","rentals","customers","parts","parts_orders","inventory","warranties","fuel_logs","meter_readings","tire_readings","users","audit_events","compliance","insurance","documents","costs","cost_inputs","downtime","telematics","idle_time","customer_contacts","inventory_usage","project_assets","faults","recalls","charge_logs","checkouts","employees","service_trips","service_trip_stops","vendor_orders","rental_classes","rental_catalog","rental_logistics","meter_daily","fleet_briefs","module_briefs","warranty_assessments","inspection_templates","compliance_requirements","asset_compliance_requirements","warranty_skus","asset_photos"]}],"webhooks":{"event":{"post":{"summary":"Event delivered to your endpoint","description":"Torgix POSTs this body to each matching subscription. Verify `X-Torgix-Signature` (format `t=<unix>,v1=<hex>`) as HMAC-SHA256 of `\"{t}.{rawBody}\"` using the endpoint signing secret; reject timestamps older than 300s. Respond 2xx within 8s or delivery is retried (60s, 300s, 1800s, 7200s, 21600s) then dead-lettered. Write-backs you make in response can carry `X-Torgix-Skip-Webhook: 1` to suppress a further event.","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/Event"}}}},"responses":{"2XX":{"description":"Acknowledged."}}}}},"components":{"headers":{"X-RateLimit-Limit":{"schema":{"type":"integer"},"description":"Requests allowed per second."},"X-RateLimit-Remaining":{"schema":{"type":"integer"},"description":"Tokens left in the current second."},"X-Request-Id":{"schema":{"type":"string"},"description":"Echoed on every response for support/correlation."}},"securitySchemes":{"ApiKeyAuth":{"type":"http","scheme":"bearer","description":"Send an API key as `Authorization: Bearer tgx_live_...`. Scopes (read, write, export) are set per key."},"OAuth2":{"type":"oauth2","description":"Authorization-code flow with PKCE (S256 required). Register a client in the app under Settings, API & Webhooks; the access token is a Bearer credential accepted on every endpoint.","flows":{"authorizationCode":{"authorizationUrl":"https://app.torgix.ai/oauth/authorize","tokenUrl":"https://app.torgix.ai/oauth/token","refreshUrl":"https://app.torgix.ai/oauth/token","scopes":{"read":"Read your equipment data","write":"Create and update records","export":"Export data in bulk"}}}}},"parameters":{"fields":{"name":"fields","in":"query","schema":{"type":"string"},"description":"Comma-separated fields to return (projection)."},"changed_since":{"name":"changed_since","in":"query","schema":{"type":"string","format":"date-time"},"description":"Only records updated/created at or after this ISO-8601 time."},"cursor":{"name":"cursor","in":"query","schema":{"type":"string"},"description":"Opaque forward cursor (use next_cursor from the previous page). Keyset mode only."},"page_size":{"name":"page_size","in":"query","schema":{"type":"integer","default":50,"maximum":200},"description":"Items per page (max 200)."},"sort":{"name":"sort","in":"query","schema":{"type":"string"},"description":"Comma-separated columns, `-` prefix for descending, up to 3 (e.g. `-created_at,name`). Switches paging to page numbers."},"page":{"name":"page","in":"query","schema":{"type":"integer","default":1},"description":"Page number, sorted mode only."},"include_deleted":{"name":"include_deleted","in":"query","schema":{"type":"boolean","default":false},"description":"Include soft-deleted rows."},"metric":{"name":"metric","in":"query","required":true,"schema":{"type":"string","default":"count"},"description":"`count`, or `sum:col`, `avg:col`, `min:col`, `max:col`."},"group_by":{"name":"group_by","in":"query","schema":{"type":"string"},"description":"Column to group by."},"IdempotencyKey":{"name":"Idempotency-Key","in":"header","schema":{"type":"string"},"description":"Optional. Repeat a create safely; the first result is replayed for the same key (response carries `Idempotent-Replayed: true`)."}},"responses":{"BadRequest":{"description":"Malformed request: bad JSON, empty body, bad batch, bad id, or an invalid metric or group_by.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"Unauthorized":{"description":"Missing or invalid credentials.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"Forbidden":{"description":"API access not enabled for the account, missing scope, or IP not allowlisted.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"NotFound":{"description":"Resource not found in this account.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"ReadOnly":{"description":"This resource does not accept that write in v1.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"Conflict":{"description":"A request with this Idempotency-Key is still being processed.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"RateLimited":{"description":"Per-second rate limit exceeded.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"headers":{"Retry-After":{"schema":{"type":"integer"},"description":"Seconds to wait."},"X-RateLimit-Limit":{"$ref":"#/components/headers/X-RateLimit-Limit"},"X-RateLimit-Remaining":{"$ref":"#/components/headers/X-RateLimit-Remaining"},"X-Request-Id":{"$ref":"#/components/headers/X-Request-Id"}}},"Unprocessable":{"description":"The write was rejected (e.g. a required field is missing); `field` names the column.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"NotSupported":{"description":"The resource or operation is not available (table not provisioned, or no deleted_at column for delete).","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}},"schemas":{"Error":{"type":"object","properties":{"error":{"type":"object","properties":{"code":{"type":"string"},"message":{"type":"string"},"field":{"type":["string","null"]},"request_id":{"type":"string"}}}}},"Event":{"type":"object","properties":{"id":{"type":"string","example":"evt_4f1c..."},"type":{"type":"string","example":"assets.updated"},"resource":{"type":"string","example":"assets"},"resource_id":{"type":["string","null"]},"data":{"type":["object","null"],"additionalProperties":true},"created_at":{"type":"string","format":"date-time"}}},"EventList":{"type":"object","properties":{"data":{"type":"array","items":{"type":"object","properties":{"cursor":{"type":"string"},"id":{"type":"string"},"type":{"type":"string"},"resource":{"type":"string"},"resource_id":{"type":["string","null"]},"data":{"type":["object","null"]},"created_at":{"type":"string","format":"date-time"}}}},"next_cursor":{"type":["string","null"]},"request_id":{"type":"string"}}},"BatchRequest":{"type":"object","required":["operations"],"properties":{"operations":{"type":"array","maxItems":200,"items":{"type":"object","properties":{"method":{"type":"string","enum":["create","update"],"default":"create"},"id":{"type":"integer","description":"Required for update."},"data":{"type":"object","additionalProperties":true}}}}}},"BatchResponse":{"type":"object","properties":{"results":{"type":"array","items":{"type":"object","properties":{"status":{"type":"integer"},"data":{"type":"object","additionalProperties":true},"error":{"$ref":"#/components/schemas/Error"}}}},"request_id":{"type":"string"}}}}},"x-resources":[{"name":"assets","label":"Assets","write":"cru","note":null},{"name":"locations","label":"Locations","write":"cru","note":null},{"name":"work_orders","label":"Work orders","write":"cru","note":null},{"name":"maintenance","label":"Maintenance logs","write":"create","note":"Completed service history. Append-only: a log is a record of work already done."},{"name":"pm_schedules","label":"PM schedules","write":null,"note":"Preventive maintenance schedules per asset (interval, last done, next due)."},{"name":"inspections","label":"Inspections","write":"create","note":null},{"name":"issues","label":"Issues","write":"cru","note":null},{"name":"activities","label":"Activities","write":null,"note":null},{"name":"projects","label":"Projects","write":null,"note":null},{"name":"rentals","label":"Rental contracts","write":null,"note":null},{"name":"customers","label":"Customers","write":null,"note":null},{"name":"parts","label":"Parts requests","write":null,"note":null},{"name":"parts_orders","label":"Parts orders","write":null,"note":null},{"name":"inventory","label":"Inventory","write":null,"note":null},{"name":"warranties","label":"Warranties","write":null,"note":null},{"name":"fuel_logs","label":"Fuel logs","write":"create","note":null},{"name":"meter_readings","label":"Meter readings","write":"create","note":null},{"name":"tire_readings","label":"Tire readings","write":"create","note":null},{"name":"users","label":"Users","write":null,"note":null},{"name":"audit_events","label":"Audit log","write":null,"note":"The account audit log, for pulling into a SIEM. Filter by created_at, cursor by id."},{"name":"compliance","label":"Compliance records","write":"cru","note":null},{"name":"insurance","label":"Insurance","write":"cru","note":null},{"name":"documents","label":"Documents","write":null,"note":"Document metadata; the storage path is not exposed and uploads go through the app."},{"name":"costs","label":"True Cost","write":null,"note":"Computed True Cost rows per asset, including the CFO fields; read-only because they are derived."},{"name":"cost_inputs","label":"Cost inputs","write":"cru","note":"The per-asset inputs True Cost is computed from (purchase, salvage, finance, insurance, storage)."},{"name":"downtime","label":"Downtime","write":"create","note":null},{"name":"telematics","label":"Telematics","write":null,"note":"Latest GPS and engine snapshot per asset, fed by the connected telematics provider."},{"name":"idle_time","label":"Idle time","write":null,"note":"Idle events derived from telematics."},{"name":"customer_contacts","label":"Customer contacts","write":"cru","note":null},{"name":"inventory_usage","label":"Inventory usage","write":null,"note":null},{"name":"project_assets","label":"Project assets","write":"create","note":null},{"name":"faults","label":"Fault codes","write":"create","note":"Diagnostic trouble codes per asset (OBD-II, J1939, J1587) from telematics, import, or manual entry. Post one to record a code read off the machine."},{"name":"recalls","label":"Recalls and bulletins","write":"create","note":"NHTSA recalls, OEM bulletins and manual notices matched to an asset, with a status workflow."},{"name":"charge_logs","label":"EV charge sessions","write":"create","note":"EV charging sessions: state of charge in and out, kWh added, duration. Fed by Samsara; post one for a charger that is not connected."},{"name":"checkouts","label":"Tool checkouts","write":null,"note":"Small-tool checkouts: what left the shop, where it went, when it came back, what was charged."},{"name":"employees","label":"Employees","write":"cru","note":"People for labor costing: position, pay basis, burden. Includes pay fields; issue keys accordingly."},{"name":"service_trips","label":"Road calls","write":null,"note":"Job-site repair trips by a service truck, costed by miles and mechanic time."},{"name":"service_trip_stops","label":"Road call stops","write":null,"note":"The stops on a road call, each tied to a work order with its share of the trip cost."},{"name":"vendor_orders","label":"Vendor orders","write":null,"note":"Parts orders placed through Commerce Connect vendors, with totals and status."},{"name":"rental_classes","label":"Rental classes","write":null,"note":"Rental classes an asset can belong to (rate setup follows the rental billing release)."},{"name":"rental_catalog","label":"Rental catalog","write":null,"note":"Rentable items and services with their rates."},{"name":"rental_logistics","label":"Rental logistics","write":null,"note":"Deliveries and pickups scheduled against a rental contract."},{"name":"meter_daily","label":"Daily telematics meters","write":null,"note":"One row per asset per day: engine hours, idle, odometer, fuel, PTO and regen hours, payload. Fed by Samsara, Motive or Rovi."},{"name":"fleet_briefs","label":"Fleet briefs","write":null,"note":"AI fleet briefs generated for the account, by date."},{"name":"module_briefs","label":"Module briefs","write":null,"note":"AI briefs generated per module and record."},{"name":"warranty_assessments","label":"Warranty assessments","write":null,"note":"AI warranty verdict per work order: covered items, exclusions, rationale, confidence."},{"name":"inspection_templates","label":"Inspection templates","write":null,"note":"Inspection checklists defined by the account."},{"name":"compliance_requirements","label":"State compliance requirements","write":null,"note":"State compliance requirements the account tracks, with authority, cadence and verification status."},{"name":"asset_compliance_requirements","label":"Asset compliance requirements","write":null,"note":"Which requirements apply to which asset, and whether each is satisfied."},{"name":"warranty_skus","label":"Warranty SKUs","write":null,"note":"Warranty products the account sells or tracks."},{"name":"asset_photos","label":"Asset photos","write":null,"note":"Photo metadata per asset (name, type, size, caption). The image itself is not served by the API."}]}