API
Documentation
  • Welcome!
  • REST API
    • Overview
    • Authentication
    • Swagger docs
    • Query an endpoint
    • Filter query results
    • Handling timestamps
    • Backward compatibility
    • Exporting Data using ODATA
    • Power BI Incremental refresh
    • Data Lake Transfer Gateway
    • EXAMPLES
      • Upload production schedule
      • Find all Running Orders
      • Interact with the Order Lifecycle
      • Consume and Submit an Activity
      • Raise an Event in TilliT
  • MQTT API
    • Overview
    • Connect to the TilliT Broker
    • Subscribe to a TilliT Topic
    • Setting a MQTT Integration
    • Publish Timeseries
    • Publish Order Progress
  • Activity API
    • Overview
    • JavaScript Basics
    • Using $scope and OnLoad Scripts
    • JavaScript Object Schema
  • Release Notes
    • 2024
      • April
Powered by GitBook
On this page
  1. REST API
  2. EXAMPLES

Find all Running Orders

Overview

Some external may need to know the current order being executed by TilliT and also recieve the progress of the order. This article will describe that process

Order-Stats Endpoint

The /core/order-stats endpoint is a special path that does not directly relate to an entity. You can only use the GET method which will return the following skeleton payload.

id: number,
name: string,
assetName: string,
orderNumber: string,
operation: string,
status: string,
quantityCompleted: number,
quantityTarget: number,
orderDate: number,
scheduledStart: string,
scheduledEnd: string,
actualStart: string,
actualEnd: string,
assetId: string,
uom: string,
currentRate: number,
defaultRunRate: number,
representsLineProduction: boolean,
quality: string,
performance: string,
availability: string,
quantityRejected: string,
siteId: number,
parentId: number,
actualChangeOverStart: string,
actualChangeOverEnd: string,
scheduledChangeoverDuration: number

As you can see, this describe the current status of the order including the quantityCompleted, oee metrics and start stop times. If you want to query this endpoint, you will need to supply some required params. Use the filter param status to only get those that are in the running stateGET:/core/orders-stats?status=RUNNING. This endpoint can also be supplied the following to further filter the response you need.

assetId - GET:/core/orders-stats?status=RUNNING&assetId=5
orderId - GET:/core/orders-stats?status=RUNNING&orderId=10
materialId - GET:/core/orders-stats?status=RUNNING&&materialId=2
orderDate - GET:/core/orders-stats?orderDate=2020-01-01
siteId - GET:/core/orders-stats?siteId=1
page - GET:/core/orders-stats?siteId=1&page=1
size - GET:/core/orders-stats?siteId=1&size=5
PreviousUpload production scheduleNextInteract with the Order Lifecycle

Last updated 2 years ago