Ready made scripts
Hyra provides some out of the box solutions for order logging for popular solutions.Order Status Lifecycle
Each order must have a status associated with it. Depending on your system, you may decide to use different statuses. The following statuses are available:handed_to- The order has been handed to the customersubmitted- The order has been submitted by the cashierwaiting_for_preparation- The order is waiting for preparation by a chef or other staff memberfinding_new_colleague- The order is waiting for a new colleague to take over preparation (for example, if the previous chef left the game)preparing- The order is being prepared by a chef or other staff membercompleted- The order has been completedwaiting_for_pickup- The order is waiting for pickup by the customer or a delivery personcancelled- The order has been cancelled
Requiring the module
The module used for Order Logging is stateful and persists its authentication state with the Hyra API. If you use a single script order solution, you can directly require the module as follows:Authentication
To authenticate, input your uniqueapiKey and workspaceId at the beginning of your main script:
Interacting with the module
Creating an order
Creating an order
To log a new order, input the customer and actor as player objects, along
with an argument table that can include an array of Once an order has been created, you will receive a response object that includes the unique If there is anything wrong with the request, you will receive an error message.When creating an order, you will need to specify a valid
items and the initial
status.The customer and the actor are both Player instances.id and order_number for the order.actor. In some cases, you may not have a valid player, for example if the order was submitted via a kiosk. In this case, there are a few system IDs you can use:1- POS (Point of Sale System)2- Kiosk3- Mobile Ordering4- NPC
Updating order status
Updating order status
Using the unique order
id (not the order_number) you can update the status of an order