24/7 Support: 800.608.6482

Get Started

Navigation


Order Queues and Order Workflows

  1. Order Queues
  2. Managing Order Queues in Admin
  3. Order Workflows
  4. Triggers
  5. Conditions
  6. Actions
  7. Webhooks

Overview

Order Queues give you the ability to group orders together. For example you can create an order queue which only shows new orders which have not been shipped. Or an order queue for certain orders which need to be manually reviewed by customer service before being sent to be fulfilled.

You can create an unlimited number of order queues which can both be managed via the admin as well as tied in to the API so any external system can pull orders from a specific queue.

Say for example you want to process all your next day air orders ahead of all others. You can create an order queue specifically for them and leverage an order workflow to automatically put orders in that queue. This way your warehouse team can look at the “Next Day Air” queue first ahead of the other orders which need to be processed that day.

order queues

There are two default queues which are used for API requests:

  1. New & Updated Orders - Keeps track of all new and updated orders for an external API to pull from
  2. Successfully Retrieved Orders - These are orders which have successfully been pulled into an external system (Order Management, ERP, Accounting, ect)

Managing Order Queues in Admin

Once Order Queues have been setup, you can leverage the Miva admin to view which orders are in each queue and move orders from one queue to another both individually and in bulk.

To see which orders are in each queue its best to use Advanced Search on the orders batch list and set up a Saved Search for each queue.

There is a yes/no flag on each order to determine if an order is in that particular queue.

Advanced Search

Once you’ve done the advanced search on the Order Batch List, you can save it for future use:

Saved Search - Queue

When editing an individual order you can see which queues it is in and easily add or remove it from an order:

Order Detail - Queue - Queue

Order Workflows

Order Workflows are a way to setup automated rules to perform some action to an order when an event occurs. For example you can setup a workflow to move all new orders into the “New & Updated Orders” queue. There are 3 key components to an order workflow:

  • Trigger - An event which happens in Miva to start to workflow
  • Conditions - Conditional statements run against the order level data to determine if an action to should be run.
  • Actions - The action to perform if the conditions are true.

Creating a new Order Workflow

Each order workflow has a name, active flag and an option setting for "Wait Until True"

Create Order Workflow

Wait Until True

This settings allow you to automatically have Miva re-check the order at any internal you want for any time period to see if the conditions have been met to run the action. For example say you are creating order in the admin and in our workflow we want all orders with next day air shipping to be moved into the next day shipping queue. However the order create trigger runs immediately after you click new order in the admin. In this case we would want to leverage a Wait Until True setting to have Miva periodically check in the conditions are met. Once we have a shipping method, then we can proceed.

Note: The default settings are to re-check the order every 5 minutes for 60 minutes. Keep in mind that adjusting these settings too high could cause the Wait Until True queue to get extremely large.

Wait Until True

Triggers

Triggers are the fixed events Miva gives you access to tie into based on events which occur in Miva.

Triggers

Trigger Descriptions

Note: All triggers happen whether the event occured by the shopper, in the admin, via XML provisioning or the JSON API.

Order Retrieved This is called when an external system pulls an order from a queue using the QueueOrderList_Load_Query function.
Order Acknowledged This is called when an external API confirms it was able to successfully pull and order from a queue using thee function.
Order Created This gets called when an order is placed via the front end by the shopper, in the admin (by a customer service rep) or by a subscription.
Order Status Change Called any time the order status changes.
Order Total Change Called any time the order total changes.
Order Shipment Created Called when a shipment is created.
Order Shipment Deleted Called when a shipment is deleted.
Order Shipment Status Change Called when a shipment moves from picking to shipped.
Order Item Created Called when a new item is added to the order
Order Item Updated Called when a item is updated (price, attributes, quantity, etc)
Order Item Status Change Called when an item status changes.
Order Item Deleted Called when an Item gets deleted.
Order Return Called when an RMA is created.
Order Return Deleted Called when a RMA is deleted.
Order Return Status Change When a return status changes.

Conditions

Conditions allow you to create flexible conditional statements to run against the order data. For example, is there is shipping method on the order and and does it equal "Next Day Air"

Conditions

There are two types of conditions:

  • Conditions - Operations against a single data point
  • List Conditions - Operations against an array of data (items, options, charges, payment, etc)

Conditional can be nested and chained together to create very custom rules. In the example below we are checking if the length of the order:charges array is greater than 0 (ie Charges exist) and if any of the order charges have a description which contain the text "Next Day Air")

Conditions

The length() can be use in both the Conditions and List Conditions to check the length of an array or field.

Because we have the "Wait Until True" option selected, all orders placed will go into a special internal queue. Miva will then re-check the conditions based on the settings configured. In this case it will re-check the order every 5 minutes for 60 minutes ( 12 times) to see if the conditions described are met.

Actions

The actions are what occur if the conditions are met. In this case we want to move the order into a Queue:

Actions

Multiple actions can be added to each workflow so its possible to add an order to a queue, add a note to the order and sent a webhook all within the same workflow.

Actions Available

  • Add to Queue
  • Move to Queue
  • Remove from Queue
  • Remove from All Queues
  • Add Note
  • Set Custom Field
  • Webhook (GET)
  • Webhook (POST)

Workflow Overview

Webhooks

Webhooks are a way to have miva push order data to any external API endpoint either as a GET request or a POST request.

The entire order object is sent with a webhook. There is no way to send a partial object, for example just sent the item data.

This website uses cookies to identify visitors, track visitors to our website, store login session information and to remember your user preferences. By continuing to use this site you agree to our use of cookies. Learn More.

This website uses cookies. By continuing to use this site you agree to our use of cookies. Learn More.

Accept

Miva believes that all online businesses should have access to a scalable ecommerce platform that can meet their unique business requirements. Miva offers PCI compliant ecommerce, hosting, and custom website design and development solutions. Miva customers have processed over $100 billion in online sales since 1997.

Copyright © 2016 Miva, Inc - All Rights Reserved   Privacy Policy | Store Policy

Links
Contact Us
Receive Tips & Updates

Copyright © 2017 Miva, Inc - All Rights Reserved

Back To The Top