Order Management Guide
This guide is designed to help you understand how orders can be created and linked with either an existing patient or an existing site, and the required as well as optional attributes for order creation.
Understanding Patients and Sites
Before we dive into the order creation process, it’s important to understand the entities associated with an order:
-
Patient: A patient profile is stored within Impilo and is managed by the customer. These profiles are essential for personalizing and managing patient-related orders.
-
Site: A site represents a customer-managed location that engages with Impilo’s services. Patients can be associated with a site for the purpose of orders and inventory management. The customer is responsible for managing the set of sites within their account, which can interact with Impilo’s services.
Create Order Endpoint
To create an order, you’ll interact with a specific endpoint designed for this purpose. This endpoint allows you to initiate and configure orders based on your requirements.
Required Attributes
For a successful order creation, you must ensure the following required attributes are correctly provided:
-
Association: Your order must be associated with either an existing patient or an site. It is crucial that exactly one of these is specified for an order, and only the
id
property of the patient or site is required. -
Order Content: Your order must include at least one of the following:
-
orderItems
: A list of items to be ordered. You must provide at least one item with only theid
property required. -
orderKits
: A list of kits to be ordered. Similar to order items, at least one kit must be specified with only theid
property required.
Create Patient Order Example
The following request contains the bare minimum for creating an order for an existing patient.
Below is an example response containing sample data.
Create Site Order Example
The following request contains the bare minimum for creating an order for an existing site.
Below is an example response containing sample data.
Optional Attributes
In addition to the required attributes, the following optional attributes can be specified to further customize your order:
- External Order IDs (
externalOrderIds
): An array of strings allowing the client to associate one or more of their own order IDs with the Impilo order record. This is particularly useful for tracking and management purposes on the client’s end.
Listing Orders
This functionality allows you to retrieve a list of orders made within the system. It supports pagination to help manage and navigate through large sets of orders effectively. This endpoint is particularly useful for overviewing all orders and analyzing order trends or statuses within a specific timeframe or criteria.
Fetching a Single Order
For detailed analysis or management of a specific order, the system provides an endpoint to fetch the details of a single order using its unique identifier.