Customer portal
Generated at build time from packages/core/src/operations/portal.ts. Every operation below isPOST /v1/ops/{name} over HTTP, env.API.invoke(actor, name, input) over RPC, and, when staff may call it, an MCP tool. See the API overview for authentication and errors.
portal.me
Portal: my account
The signed-in customer's own account: company name and address, their contact details, and Cemco's service contact.
Input (empty object)
No input. Send {}.
Output (object)
| Field | Type | Description |
|---|---|---|
userrequired | object | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
namerequired | string | |
emailrequired | string | |
accountrequired | object | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
namerequired | string | |
phonerequired | string | null | |
hqLine1required | string | null | |
hqLine2required | string | null | |
hqCityrequired | string | null | |
hqStaterequired | string | null | Two-letter US state or region code |
hqPostalCoderequired | string | null | |
hqCountryrequired | string | null | |
contactrequired | object | null | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
firstNamerequired | string | |
lastNamerequired | string | |
rolerequired | string | null | Job title or role at the customer, for example Plant manager |
emailrequired | string | null | |
mobilerequired | string | null | |
phonerequired | string | null | |
preferredChannelrequired | "email" | "phone" | "text" | |
cemcoContactrequired | object | |
namerequired | string | |
emailrequired | string | |
phonerequired | string | null | |
countsrequired | object | |
openOrdersrequired | integer | min -9007199254740991, max 9007199254740991 |
machinesrequired | integer | min -9007199254740991, max 9007199254740991 |
openTicketsrequired | integer | min -9007199254740991, max 9007199254740991 |
ordersNeedingSignaturerequired | integer | min -9007199254740991, max 9007199254740991 |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"user": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"name": {
"type": "string"
},
"email": {
"type": "string"
}
},
"required": [
"id",
"name",
"email"
],
"additionalProperties": false
},
"account": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"name": {
"type": "string"
},
"phone": {
"type": [
"string",
"null"
]
},
"hqLine1": {
"type": [
"string",
"null"
]
},
"hqLine2": {
"type": [
"string",
"null"
]
},
"hqCity": {
"type": [
"string",
"null"
]
},
"hqState": {
"description": "Two-letter US state or region code",
"type": [
"string",
"null"
]
},
"hqPostalCode": {
"type": [
"string",
"null"
]
},
"hqCountry": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"name",
"phone",
"hqLine1",
"hqLine2",
"hqCity",
"hqState",
"hqPostalCode",
"hqCountry"
],
"additionalProperties": false
},
"contact": {
"anyOf": [
{
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"firstName": {
"type": "string"
},
"lastName": {
"type": "string"
},
"role": {
"description": "Job title or role at the customer, for example Plant manager",
"type": [
"string",
"null"
]
},
"email": {
"type": [
"string",
"null"
]
},
"mobile": {
"type": [
"string",
"null"
]
},
"phone": {
"type": [
"string",
"null"
]
},
"preferredChannel": {
"type": "string",
"enum": [
"email",
"phone",
"text"
]
}
},
"required": [
"id",
"firstName",
"lastName",
"role",
"email",
"mobile",
"phone",
"preferredChannel"
],
"additionalProperties": false
},
{
"type": "null"
}
]
},
"cemcoContact": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"email": {
"type": "string"
},
"phone": {
"type": [
"string",
"null"
]
}
},
"required": [
"name",
"email",
"phone"
],
"additionalProperties": false
},
"counts": {
"type": "object",
"properties": {
"openOrders": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"machines": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"openTickets": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
"ordersNeedingSignature": {
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
}
},
"required": [
"openOrders",
"machines",
"openTickets",
"ordersNeedingSignature"
],
"additionalProperties": false
}
},
"required": [
"user",
"account",
"contact",
"cemcoContact",
"counts"
],
"additionalProperties": false
}
}
portal.orders
Portal: my orders
The customer's own orders, newest first, with the current stage and whether a quote is waiting for signature.
Input (object)
| Field | Type | Description |
|---|---|---|
open | boolean |
Output (object)
| Field | Type | Description |
|---|---|---|
itemsrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | |
titlerequired | string | null | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
stageLabelrequired | string | |
totalCentsrequired | integer | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
balanceRemainingCentsrequired | integer | null | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
financingPartnerrequired | "none" | "commercial_capital" | "northland_capital" | "other" | |
financingStatusrequired | "not_applicable" | "pending" | "approved" | "declined" | "funded" | |
poNumberrequired | string | null | |
expectedShipOnrequired | string (date) | null | Date as YYYY-MM-DD |
siteNamerequired | string | null | |
quoteSignedrequired | boolean | |
quoteSignedOnrequired | string (date) | null | Date as YYYY-MM-DD |
needsSignaturerequired | boolean | True when a quote is waiting for the customer's signature |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"open": {
"type": "boolean"
}
}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"orderNumber": {
"type": "string"
},
"title": {
"type": [
"string",
"null"
]
},
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"stageLabel": {
"type": "string"
},
"totalCents": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
"balanceRemainingCents": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
{
"type": "null"
}
]
},
"financingPartner": {
"type": "string",
"enum": [
"none",
"commercial_capital",
"northland_capital",
"other"
]
},
"financingStatus": {
"type": "string",
"enum": [
"not_applicable",
"pending",
"approved",
"declined",
"funded"
]
},
"poNumber": {
"type": [
"string",
"null"
]
},
"expectedShipOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"siteName": {
"type": [
"string",
"null"
]
},
"quoteSigned": {
"type": "boolean"
},
"quoteSignedOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"needsSignature": {
"type": "boolean",
"description": "True when a quote is waiting for the customer's signature"
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
}
},
"required": [
"id",
"orderNumber",
"title",
"stage",
"stageLabel",
"totalCents",
"balanceRemainingCents",
"financingPartner",
"financingStatus",
"poNumber",
"expectedShipOn",
"siteName",
"quoteSigned",
"quoteSignedOn",
"needsSignature",
"createdAt"
],
"additionalProperties": false
}
}
},
"required": [
"items"
],
"additionalProperties": false
}
}
portal.order
Portal: one order
One of the customer's own orders with line items, the status timeline, documents and the machines built for it. Not found if the order belongs to another account.
Input (object)
| Field | Type | Description |
|---|---|---|
idrequired | string | Record id (UUID)min length 1, max length 64 |
Output (object)
| Field | Type | Description |
|---|---|---|
idrequired | string | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | |
titlerequired | string | null | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
stageLabelrequired | string | |
totalCentsrequired | integer | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
balanceRemainingCentsrequired | integer | null | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
financingPartnerrequired | "none" | "commercial_capital" | "northland_capital" | "other" | |
financingStatusrequired | "not_applicable" | "pending" | "approved" | "declined" | "funded" | |
poNumberrequired | string | null | |
expectedShipOnrequired | string (date) | null | Date as YYYY-MM-DD |
siteNamerequired | string | null | |
quoteSignedrequired | boolean | |
quoteSignedOnrequired | string (date) | null | Date as YYYY-MM-DD |
needsSignaturerequired | boolean | True when a quote is waiting for the customer's signature |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
linesrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
skurequired | string | null | |
descriptionrequired | string | |
quantityrequired | integer | min 1, max 9007199254740991 |
unitPriceCentsrequired | integer | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
totalCentsrequired | integer | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
timelinerequired | object[] | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
labelrequired | string | |
staterequired | "done" | "current" | "upcoming" | |
daterequired | string (date) | null | Date as YYYY-MM-DD |
documentsrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
kindrequired | "signed_quote" | "quote" | "purchase_order" | "drawing" | "manual" | "inspection_report" | "photo" | "training_record" | "invoice" | "email_attachment" | "export" | "other" | |
titlerequired | string | |
filenamerequired | string | |
contentTyperequired | string | |
sizeBytesrequired | integer | min 0, max 9007199254740991 |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
orderIdrequired | string | null | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | null | |
machinesrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
serialNumberrequired | string | |
typerequired | "plant" | "mixer" | "silo" | "feeder" | "power_pack" | |
modelrequired | string | |
configurationrequired | string | null | |
optionsrequired | string[] | |
statusrequired | "in_build" | "in_transit" | "operating" | "down" | "idle" | "retired" | |
siteNamerequired | string | null | |
siteCityrequired | string | null | |
siteStaterequired | string | null | |
commissionedOnrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyStartrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyEndrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyStaterequired | "none" | "active" | "expiring" | "expired" | |
warrantyDaysLeftrequired | integer | null | min -9007199254740991, max 9007199254740991 |
orderIdrequired | string | null | Record id (UUID)min length 1, max length 64 |
quoteDocumentIdrequired | string | null | The quote to review and sign, if one is waitingmin length 1, max length 64 |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
}
},
"required": [
"id"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"orderNumber": {
"type": "string"
},
"title": {
"type": [
"string",
"null"
]
},
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"stageLabel": {
"type": "string"
},
"totalCents": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
"balanceRemainingCents": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
{
"type": "null"
}
]
},
"financingPartner": {
"type": "string",
"enum": [
"none",
"commercial_capital",
"northland_capital",
"other"
]
},
"financingStatus": {
"type": "string",
"enum": [
"not_applicable",
"pending",
"approved",
"declined",
"funded"
]
},
"poNumber": {
"type": [
"string",
"null"
]
},
"expectedShipOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"siteName": {
"type": [
"string",
"null"
]
},
"quoteSigned": {
"type": "boolean"
},
"quoteSignedOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"needsSignature": {
"type": "boolean",
"description": "True when a quote is waiting for the customer's signature"
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"lines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"sku": {
"type": [
"string",
"null"
]
},
"description": {
"type": "string"
},
"quantity": {
"type": "integer",
"minimum": 1,
"maximum": 9007199254740991
},
"unitPriceCents": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
"totalCents": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
}
},
"required": [
"id",
"sku",
"description",
"quantity",
"unitPriceCents",
"totalCents"
],
"additionalProperties": false
}
},
"timeline": {
"type": "array",
"items": {
"type": "object",
"properties": {
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"label": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"done",
"current",
"upcoming"
]
},
"date": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
}
},
"required": [
"stage",
"label",
"state",
"date"
],
"additionalProperties": false
}
},
"documents": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"kind": {
"type": "string",
"enum": [
"signed_quote",
"quote",
"purchase_order",
"drawing",
"manual",
"inspection_report",
"photo",
"training_record",
"invoice",
"email_attachment",
"export",
"other"
]
},
"title": {
"type": "string"
},
"filename": {
"type": "string"
},
"contentType": {
"type": "string"
},
"sizeBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"orderId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
]
},
"orderNumber": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"kind",
"title",
"filename",
"contentType",
"sizeBytes",
"createdAt",
"orderId",
"orderNumber"
],
"additionalProperties": false
}
},
"machines": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"serialNumber": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"plant",
"mixer",
"silo",
"feeder",
"power_pack"
]
},
"model": {
"type": "string"
},
"configuration": {
"type": [
"string",
"null"
]
},
"options": {
"type": "array",
"items": {
"type": "string"
}
},
"status": {
"type": "string",
"enum": [
"in_build",
"in_transit",
"operating",
"down",
"idle",
"retired"
]
},
"siteName": {
"type": [
"string",
"null"
]
},
"siteCity": {
"type": [
"string",
"null"
]
},
"siteState": {
"type": [
"string",
"null"
]
},
"commissionedOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyStart": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyEnd": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyState": {
"type": "string",
"enum": [
"none",
"active",
"expiring",
"expired"
]
},
"warrantyDaysLeft": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"orderId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"serialNumber",
"type",
"model",
"configuration",
"options",
"status",
"siteName",
"siteCity",
"siteState",
"commissionedOn",
"warrantyStart",
"warrantyEnd",
"warrantyState",
"warrantyDaysLeft",
"orderId"
],
"additionalProperties": false
}
},
"quoteDocumentId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
],
"description": "The quote to review and sign, if one is waiting"
}
},
"required": [
"id",
"orderNumber",
"title",
"stage",
"stageLabel",
"totalCents",
"balanceRemainingCents",
"financingPartner",
"financingStatus",
"poNumber",
"expectedShipOn",
"siteName",
"quoteSigned",
"quoteSignedOn",
"needsSignature",
"createdAt",
"lines",
"timeline",
"documents",
"machines",
"quoteDocumentId"
],
"additionalProperties": false
}
}
portal.order_timeline
Portal: order status timeline
The nine lifecycle stages of one of the customer's own orders, each marked done, current or upcoming, with the date reached.
Input (object)
| Field | Type | Description |
|---|---|---|
idrequired | string | Record id (UUID)min length 1, max length 64 |
Output (object)
| Field | Type | Description |
|---|---|---|
orderIdrequired | string | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
timelinerequired | object[] | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
labelrequired | string | |
staterequired | "done" | "current" | "upcoming" | |
daterequired | string (date) | null | Date as YYYY-MM-DD |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
}
},
"required": [
"id"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"orderId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"orderNumber": {
"type": "string"
},
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"timeline": {
"type": "array",
"items": {
"type": "object",
"properties": {
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"label": {
"type": "string"
},
"state": {
"type": "string",
"enum": [
"done",
"current",
"upcoming"
]
},
"date": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
}
},
"required": [
"stage",
"label",
"state",
"date"
],
"additionalProperties": false
}
}
},
"required": [
"orderId",
"orderNumber",
"stage",
"timeline"
],
"additionalProperties": false
}
}
portal.sign_quote
Portal: sign the quote
The customer signs the quote (the contract) for one of their own orders. Stores a signed record containing the quote reference, the signer's typed name and title, the drawn signature, the time and the signer's login, as the order's signed quote document, and sets the signed-quote received date to today. Fails with a conflict if the order already has a signed quote.
Input (object)
| Field | Type | Description |
|---|---|---|
orderIdrequired | string | Record id (UUID)min length 1, max length 64 |
signerNamerequired | string | min length 2, max length 200 |
signerTitle | string | null | max length 200 |
signatureDataUrl | string | Drawn signature as a PNG or SVG data URLmax length 500000, pattern ^data:image\/(png|svg\+xml);base64, |
agreerequired | true | The customer ticked the box agreeing to the quote's terms |
Output (object)
| Field | Type | Description |
|---|---|---|
orderrequired | object | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | |
titlerequired | string | null | |
stagerequired | "received" | "in_build" | "ready_to_ship" | "shipped" | "delivered" | "set_up" | "commissioned" | "trained" | "closed" | |
stageLabelrequired | string | |
totalCentsrequired | integer | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
balanceRemainingCentsrequired | integer | null | Amount in integer US cents (zero or more)min 0, max 9007199254740991 |
financingPartnerrequired | "none" | "commercial_capital" | "northland_capital" | "other" | |
financingStatusrequired | "not_applicable" | "pending" | "approved" | "declined" | "funded" | |
poNumberrequired | string | null | |
expectedShipOnrequired | string (date) | null | Date as YYYY-MM-DD |
siteNamerequired | string | null | |
quoteSignedrequired | boolean | |
quoteSignedOnrequired | string (date) | null | Date as YYYY-MM-DD |
needsSignaturerequired | boolean | True when a quote is waiting for the customer's signature |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
documentrequired | object | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
kindrequired | "signed_quote" | "quote" | "purchase_order" | "drawing" | "manual" | "inspection_report" | "photo" | "training_record" | "invoice" | "email_attachment" | "export" | "other" | |
titlerequired | string | |
filenamerequired | string | |
contentTyperequired | string | |
sizeBytesrequired | integer | min 0, max 9007199254740991 |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
orderIdrequired | string | null | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | null | |
signedOnrequired | string (date) | Date as YYYY-MM-DD |
orderIsValidrequired | boolean | Whether the order now has everything it needs to go into build |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"orderId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"signerName": {
"type": "string",
"minLength": 2,
"maxLength": 200
},
"signerTitle": {
"anyOf": [
{
"type": "string",
"maxLength": 200
},
{
"type": "null"
}
]
},
"signatureDataUrl": {
"description": "Drawn signature as a PNG or SVG data URL",
"type": "string",
"maxLength": 500000,
"pattern": "^data:image\\/(png|svg\\+xml);base64,"
},
"agree": {
"type": "boolean",
"const": true,
"description": "The customer ticked the box agreeing to the quote's terms"
}
},
"required": [
"orderId",
"signerName",
"agree"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"order": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"orderNumber": {
"type": "string"
},
"title": {
"type": [
"string",
"null"
]
},
"stage": {
"type": "string",
"enum": [
"received",
"in_build",
"ready_to_ship",
"shipped",
"delivered",
"set_up",
"commissioned",
"trained",
"closed"
]
},
"stageLabel": {
"type": "string"
},
"totalCents": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
"balanceRemainingCents": {
"anyOf": [
{
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991,
"description": "Amount in integer US cents (zero or more)"
},
{
"type": "null"
}
]
},
"financingPartner": {
"type": "string",
"enum": [
"none",
"commercial_capital",
"northland_capital",
"other"
]
},
"financingStatus": {
"type": "string",
"enum": [
"not_applicable",
"pending",
"approved",
"declined",
"funded"
]
},
"poNumber": {
"type": [
"string",
"null"
]
},
"expectedShipOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"siteName": {
"type": [
"string",
"null"
]
},
"quoteSigned": {
"type": "boolean"
},
"quoteSignedOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"needsSignature": {
"type": "boolean",
"description": "True when a quote is waiting for the customer's signature"
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
}
},
"required": [
"id",
"orderNumber",
"title",
"stage",
"stageLabel",
"totalCents",
"balanceRemainingCents",
"financingPartner",
"financingStatus",
"poNumber",
"expectedShipOn",
"siteName",
"quoteSigned",
"quoteSignedOn",
"needsSignature",
"createdAt"
],
"additionalProperties": false
},
"document": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"kind": {
"type": "string",
"enum": [
"signed_quote",
"quote",
"purchase_order",
"drawing",
"manual",
"inspection_report",
"photo",
"training_record",
"invoice",
"email_attachment",
"export",
"other"
]
},
"title": {
"type": "string"
},
"filename": {
"type": "string"
},
"contentType": {
"type": "string"
},
"sizeBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"orderId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
]
},
"orderNumber": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"kind",
"title",
"filename",
"contentType",
"sizeBytes",
"createdAt",
"orderId",
"orderNumber"
],
"additionalProperties": false
},
"signedOn": {
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
"orderIsValid": {
"type": "boolean",
"description": "Whether the order now has everything it needs to go into build"
}
},
"required": [
"order",
"document",
"signedOn",
"orderIsValid"
],
"additionalProperties": false
}
}
portal.export_order
Portal: export an order
Download one of the customer's own orders as printable HTML, CSV of the line items, or JSON.
Input (object)
| Field | Type | Description |
|---|---|---|
idrequired | string | Record id (UUID)min length 1, max length 64 |
format | "json" | "csv" | "html" | default "html" |
Output (object)
| Field | Type | Description |
|---|---|---|
filenamerequired | string | |
contentTyperequired | string | |
contentrequired | string | The exported file as text (JSON, CSV or printable HTML) |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"format": {
"default": "html",
"type": "string",
"enum": [
"json",
"csv",
"html"
]
}
},
"required": [
"id"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"filename": {
"type": "string"
},
"contentType": {
"type": "string"
},
"content": {
"type": "string",
"description": "The exported file as text (JSON, CSV or printable HTML)"
}
},
"required": [
"filename",
"contentType",
"content"
],
"additionalProperties": false
}
}
portal.machines
Portal: my machines
The customer's installed machines with serial number, model, site, status and warranty start, end and days left.
Input (empty object)
No input. Send {}.
Output (object)
| Field | Type | Description |
|---|---|---|
itemsrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
serialNumberrequired | string | |
typerequired | "plant" | "mixer" | "silo" | "feeder" | "power_pack" | |
modelrequired | string | |
configurationrequired | string | null | |
optionsrequired | string[] | |
statusrequired | "in_build" | "in_transit" | "operating" | "down" | "idle" | "retired" | |
siteNamerequired | string | null | |
siteCityrequired | string | null | |
siteStaterequired | string | null | |
commissionedOnrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyStartrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyEndrequired | string (date) | null | Date as YYYY-MM-DD |
warrantyStaterequired | "none" | "active" | "expiring" | "expired" | |
warrantyDaysLeftrequired | integer | null | min -9007199254740991, max 9007199254740991 |
orderIdrequired | string | null | Record id (UUID)min length 1, max length 64 |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"serialNumber": {
"type": "string"
},
"type": {
"type": "string",
"enum": [
"plant",
"mixer",
"silo",
"feeder",
"power_pack"
]
},
"model": {
"type": "string"
},
"configuration": {
"type": [
"string",
"null"
]
},
"options": {
"type": "array",
"items": {
"type": "string"
}
},
"status": {
"type": "string",
"enum": [
"in_build",
"in_transit",
"operating",
"down",
"idle",
"retired"
]
},
"siteName": {
"type": [
"string",
"null"
]
},
"siteCity": {
"type": [
"string",
"null"
]
},
"siteState": {
"type": [
"string",
"null"
]
},
"commissionedOn": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyStart": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyEnd": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"warrantyState": {
"type": "string",
"enum": [
"none",
"active",
"expiring",
"expired"
]
},
"warrantyDaysLeft": {
"anyOf": [
{
"type": "integer",
"minimum": -9007199254740991,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
},
"orderId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
]
}
},
"required": [
"id",
"serialNumber",
"type",
"model",
"configuration",
"options",
"status",
"siteName",
"siteCity",
"siteState",
"commissionedOn",
"warrantyStart",
"warrantyEnd",
"warrantyState",
"warrantyDaysLeft",
"orderId"
],
"additionalProperties": false
}
}
},
"required": [
"items"
],
"additionalProperties": false
}
}
portal.documents
Portal: my documents
Documents shared with the customer: quotes, signed quotes, drawings, manuals and inspection reports on their own orders and machines.
Input (object)
| Field | Type | Description |
|---|---|---|
orderId | string | Record id (UUID)min length 1, max length 64 |
machineId | string | Record id (UUID)min length 1, max length 64 |
kind | "signed_quote" | "quote" | "purchase_order" | "drawing" | "manual" | "inspection_report" | "photo" | "training_record" | "invoice" | "email_attachment" | "export" | "other" |
Output (object)
| Field | Type | Description |
|---|---|---|
itemsrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
kindrequired | "signed_quote" | "quote" | "purchase_order" | "drawing" | "manual" | "inspection_report" | "photo" | "training_record" | "invoice" | "email_attachment" | "export" | "other" | |
titlerequired | string | |
filenamerequired | string | |
contentTyperequired | string | |
sizeBytesrequired | integer | min 0, max 9007199254740991 |
createdAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
orderIdrequired | string | null | Record id (UUID)min length 1, max length 64 |
orderNumberrequired | string | null |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"orderId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"machineId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"kind": {
"type": "string",
"enum": [
"signed_quote",
"quote",
"purchase_order",
"drawing",
"manual",
"inspection_report",
"photo",
"training_record",
"invoice",
"email_attachment",
"export",
"other"
]
}
}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"kind": {
"type": "string",
"enum": [
"signed_quote",
"quote",
"purchase_order",
"drawing",
"manual",
"inspection_report",
"photo",
"training_record",
"invoice",
"email_attachment",
"export",
"other"
]
},
"title": {
"type": "string"
},
"filename": {
"type": "string"
},
"contentType": {
"type": "string"
},
"sizeBytes": {
"type": "integer",
"minimum": 0,
"maximum": 9007199254740991
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"orderId": {
"anyOf": [
{
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
{
"type": "null"
}
]
},
"orderNumber": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"kind",
"title",
"filename",
"contentType",
"sizeBytes",
"createdAt",
"orderId",
"orderNumber"
],
"additionalProperties": false
}
}
},
"required": [
"items"
],
"additionalProperties": false
}
}
portal.document_link
Portal: open a document
A 15-minute signed link to one of the customer's own documents. Not found if the document belongs to another account or is not shared with customers.
Input (object)
| Field | Type | Description |
|---|---|---|
idrequired | string | Record id (UUID)min length 1, max length 64 |
disposition | "inline" | "attachment" | default "inline" |
Output (object)
| Field | Type | Description |
|---|---|---|
documentIdrequired | string | Record id (UUID)min length 1, max length 64 |
urlrequired | string | Absolute URL that opens the file without signing in; valid for 15 minutes |
expiresAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
filenamerequired | string | |
contentTyperequired | string |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"disposition": {
"default": "inline",
"type": "string",
"enum": [
"inline",
"attachment"
]
}
},
"required": [
"id"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"documentId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"url": {
"type": "string",
"description": "Absolute URL that opens the file without signing in; valid for 15 minutes"
},
"expiresAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"filename": {
"type": "string"
},
"contentType": {
"type": "string"
}
},
"required": [
"documentId",
"url",
"expiresAt",
"filename",
"contentType"
],
"additionalProperties": false
}
}
portal.request_service
Portal: request service
The customer asks for service on one of their own machines. Opens a service ticket for Cemco (source portal) and emails a confirmation. Saying the plant is down sets priority down, which marks the machine down.
Input (object)
| Field | Type | Description |
|---|---|---|
machineIdrequired | string | Record id (UUID)min length 1, max length 64 |
titlerequired | string | Short summary of the problemmin length 3, max length 200 |
description | string | null | max length 10000 |
plantDown | boolean | The machine cannot producedefault false |
category | "mechanical" | "electrical" | "controls" | "hydraulic" | "pneumatic" | "structural" | "calibration" | "operator_training" | "other" | default "other" |
preferredContact | string | null | Best phone number or time to reach themmax length 200 |
Output (object)
| Field | Type | Description |
|---|---|---|
ticketrequired | object | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
ticketNumberrequired | string | |
titlerequired | string | |
descriptionrequired | string | null | |
categoryrequired | "mechanical" | "electrical" | "controls" | "hydraulic" | "pneumatic" | "structural" | "calibration" | "operator_training" | "other" | |
priorityrequired | "low" | "normal" | "high" | "down" | |
statusrequired | "new" | "diagnosing" | "parts_on_order" | "scheduled" | "waiting_on_customer" | "resolved" | "follow_up_complete" | |
statusLabelrequired | string | |
machineIdrequired | string | Record id (UUID)min length 1, max length 64 |
machineSerialNumberrequired | string | |
machineModelrequired | string | |
openedAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
scheduledForrequired | string (date) | null | Date as YYYY-MM-DD |
resolvedAtrequired | string (date-time) | null | UTC timestamp, ISO 8601 with Z |
resolutionrequired | string | null |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"machineId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"title": {
"type": "string",
"minLength": 3,
"maxLength": 200,
"description": "Short summary of the problem"
},
"description": {
"anyOf": [
{
"type": "string",
"maxLength": 10000
},
{
"type": "null"
}
]
},
"plantDown": {
"default": false,
"description": "The machine cannot produce",
"type": "boolean"
},
"category": {
"default": "other",
"type": "string",
"enum": [
"mechanical",
"electrical",
"controls",
"hydraulic",
"pneumatic",
"structural",
"calibration",
"operator_training",
"other"
]
},
"preferredContact": {
"description": "Best phone number or time to reach them",
"anyOf": [
{
"type": "string",
"maxLength": 200
},
{
"type": "null"
}
]
}
},
"required": [
"machineId",
"title"
]
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"ticket": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"ticketNumber": {
"type": "string"
},
"title": {
"type": "string"
},
"description": {
"type": [
"string",
"null"
]
},
"category": {
"type": "string",
"enum": [
"mechanical",
"electrical",
"controls",
"hydraulic",
"pneumatic",
"structural",
"calibration",
"operator_training",
"other"
]
},
"priority": {
"type": "string",
"enum": [
"low",
"normal",
"high",
"down"
]
},
"status": {
"type": "string",
"enum": [
"new",
"diagnosing",
"parts_on_order",
"scheduled",
"waiting_on_customer",
"resolved",
"follow_up_complete"
]
},
"statusLabel": {
"type": "string"
},
"machineId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"machineSerialNumber": {
"type": "string"
},
"machineModel": {
"type": "string"
},
"openedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"scheduledFor": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"resolvedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
{
"type": "null"
}
]
},
"resolution": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"ticketNumber",
"title",
"description",
"category",
"priority",
"status",
"statusLabel",
"machineId",
"machineSerialNumber",
"machineModel",
"openedAt",
"scheduledFor",
"resolvedAt",
"resolution"
],
"additionalProperties": false
}
},
"required": [
"ticket"
],
"additionalProperties": false
}
}
portal.tickets
Portal: my service requests
Service tickets on the customer's own machines with their current status.
Input (object)
| Field | Type | Description |
|---|---|---|
open | boolean | |
machineId | string | Record id (UUID)min length 1, max length 64 |
Output (object)
| Field | Type | Description |
|---|---|---|
itemsrequired | object[] | |
idrequired | string | Record id (UUID)min length 1, max length 64 |
ticketNumberrequired | string | |
titlerequired | string | |
descriptionrequired | string | null | |
categoryrequired | "mechanical" | "electrical" | "controls" | "hydraulic" | "pneumatic" | "structural" | "calibration" | "operator_training" | "other" | |
priorityrequired | "low" | "normal" | "high" | "down" | |
statusrequired | "new" | "diagnosing" | "parts_on_order" | "scheduled" | "waiting_on_customer" | "resolved" | "follow_up_complete" | |
statusLabelrequired | string | |
machineIdrequired | string | Record id (UUID)min length 1, max length 64 |
machineSerialNumberrequired | string | |
machineModelrequired | string | |
openedAtrequired | string (date-time) | UTC timestamp, ISO 8601 with Z |
scheduledForrequired | string (date) | null | Date as YYYY-MM-DD |
resolvedAtrequired | string (date-time) | null | UTC timestamp, ISO 8601 with Z |
resolutionrequired | string | null |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"open": {
"type": "boolean"
},
"machineId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
}
}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"ticketNumber": {
"type": "string"
},
"title": {
"type": "string"
},
"description": {
"type": [
"string",
"null"
]
},
"category": {
"type": "string",
"enum": [
"mechanical",
"electrical",
"controls",
"hydraulic",
"pneumatic",
"structural",
"calibration",
"operator_training",
"other"
]
},
"priority": {
"type": "string",
"enum": [
"low",
"normal",
"high",
"down"
]
},
"status": {
"type": "string",
"enum": [
"new",
"diagnosing",
"parts_on_order",
"scheduled",
"waiting_on_customer",
"resolved",
"follow_up_complete"
]
},
"statusLabel": {
"type": "string"
},
"machineId": {
"type": "string",
"minLength": 1,
"maxLength": 64,
"description": "Record id (UUID)"
},
"machineSerialNumber": {
"type": "string"
},
"machineModel": {
"type": "string"
},
"openedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
"scheduledFor": {
"anyOf": [
{
"type": "string",
"format": "date",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))$",
"description": "Date as YYYY-MM-DD"
},
{
"type": "null"
}
]
},
"resolvedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d(?:\\.\\d+)?(?:Z))$",
"description": "UTC timestamp, ISO 8601 with Z"
},
{
"type": "null"
}
]
},
"resolution": {
"type": [
"string",
"null"
]
}
},
"required": [
"id",
"ticketNumber",
"title",
"description",
"category",
"priority",
"status",
"statusLabel",
"machineId",
"machineSerialNumber",
"machineModel",
"openedAt",
"scheduledFor",
"resolvedAt",
"resolution"
],
"additionalProperties": false
}
}
},
"required": [
"items"
],
"additionalProperties": false
}
}
portal.update_profile
Portal: update my contact details
The customer changes their own name, phone numbers and preferred contact channel.
Input (object)
| Field | Type | Description |
|---|---|---|
name | string | min length 1, max length 200 |
mobile | string | null | max length 40 |
phone | string | null | max length 40 |
preferredChannel | "email" | "phone" | "text" |
Output (object)
| Field | Type | Description |
|---|---|---|
okrequired | true |
JSON Schema
{
"input": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"name": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"mobile": {
"anyOf": [
{
"type": "string",
"maxLength": 40
},
{
"type": "null"
}
]
},
"phone": {
"anyOf": [
{
"type": "string",
"maxLength": 40
},
{
"type": "null"
}
]
},
"preferredChannel": {
"type": "string",
"enum": [
"email",
"phone",
"text"
]
}
}
},
"output": {
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"ok": {
"type": "boolean",
"const": true
}
},
"required": [
"ok"
],
"additionalProperties": false
}
}