Distru API
Stay Up To Date
To stay up to date with the latest breaking changes to the Distru public API, please sign up for our email list.
Overview
Distru's public API allows you to easily access and manipulate your data in our system automatically.
- Integrate your supply chain with the rest of your business Build your own custom connectors that support your most important workflows.
- Extend your reports Take data from Distru and pipe it into other systems for a unified view of your business.
- Maximize your efficiency Automate tasks based on changes in your distribution, manufacturing, and sales.
Base URL
All API requests should be made to the base URL: https://app.distru.com
Getting Started
To integrate with Distru, you'll need to contact a representative that will can enable your account's API access. From there, have a look at the following information on how to authenticate with Distru.
Authentication
An admin user can generate API keys in the Distru app by following these steps.
Steps:
- Log in to Distru with your admin account.
- Navigate to the Settings page from the left menu.
- Click on Distru API under the Integrations section.
- Use the Create API Key option to generate your API token.
Models
Strain
A strain as shown in Distru
{
"id": "12345",
"name": "Strain 123"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this strain | string | false |
name | Name of the strain | string | false |
StockAdjustments
A collection of Stock Adjustments
Property | Description | Type | Required |
---|
Product
A product as shown in Distru
{
"brand": {
"name": "Brand 123"
},
"category": {
"id": "89c8323f-aaaa-45v3-88f9-64009d68h3n8",
"name": "Super Dank Buds"
},
"external_name": "Blue Dream Preroll",
"id": "02c88a3f-d759-4973-88f9-60049d682524",
"images": [
{
"id": "12345",
"name": "image.jpg",
"url": "https://example.com/image.jpg"
}
],
"is_active": true,
"msrp": 100.1,
"name": "Blue Dream Preroll 1G",
"sku": "BDP-1G",
"unit_price": 1.5,
"unit_type": {
"name": "Gram"
},
"units_per_case": 6
}
Property | Description | Type | Required |
---|---|---|---|
brand | A brand as shown in Distru | Brand | false |
category | A product category as shown in Distru | ProductCategory | false |
company | A company as shown in Distru | Company | false |
custom_data | The custom data for this product | array(CustomField) | false |
description | The description of this product | string | false |
external_name | Customer-facing name for DistruCommerce menus and Order Tracker | string | false |
id | Unique ID for this product | string | false |
images | The images associated with the product | array(Image) | false |
is_active | Is this product active? | boolean | false |
msrp | The MSRP of the product | number | false |
name | Human readable name for this product | string | false |
sku | The SKU configured for the product | string | false |
strain | A strain as shown in Distru | Strain | false |
subcategory | A product subcategory as shown in Distru | ProductSubcategory | false |
unit_price | The price of one unit of this product | number | false |
unit_type | A unit type as shown in Distru | UnitType | false |
units_per_case | The number of units of this product that come in one case, if any | number | false |
updated_datetime | The datetime this product was last updated at | string | false |
AdditionalCost
An additional cost for an assembly as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
cost_per_unit | The cost per unit of the additional cost | number | false |
description | The description of the additional cost | string | false |
name | The name of the additional cost | string | false |
quantity | The quantity of the additional cost | number | false |
unit_type | A unit type as shown in Distru | UnitType | false |
Products
A collection of Products
Property | Description | Type | Required |
---|
Assembly
An assembly as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
completion_datetime | The datetime this assembly was completed at | string | false |
compliance_type | The compliance type for this assembly. Options include METRC, BIOTRACK or NONE | string | false |
creation_source | The creation source for this assembly | string | false |
custom_data | The custom data for this assembly | array(CustomField) | false |
description | The description for this assembly | string | false |
estimated_work_hours | The estimated work hours for this assembly | integer | false |
estimated_work_minutes | The estimated work minutes for this assembly | integer | false |
fulfilled | True if all assembly inputs have been fulfilled with batches or packages, false otherwise. | boolean | false |
id | Unique ID for this assembly | string | false |
is_metrc_processing_job | True if this assembly is associated with a Metrc processing job, false otherwise | boolean | false |
license | The license number for this assembly | string | false |
outputs | The outputs for this assembly | array(AssemblyOutput) | false |
owner_id | The ID of the user that owns this assembly | string | false |
status | The status of this assembly | string | false |
OrderItemsRequest
A collection of Order item params
Property | Description | Type | Required |
---|
Locations
A collection of Locations
Property | Description | Type | Required |
---|
Charge
A line representing a Tax, Discount, or Charge added to an order
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this charge | string | false |
name | The name for this charge | string | false |
percent | The percent to charge for this line if it is a percentage | number | false |
price | The price of this line if it is a flat charge | number | false |
type | What type of additional line is this | array(any) | false |
unit_type | Determines if this line is tracked as a percentage or a flat charge | array(any) | false |
tax.id | Unique ID for this Tax | string | false |
tax.name | The name of this tax | string | false |
tax.percent | The amount of tax levied | string | false |
Strains
A collection of Strains. Note: This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Property | Description | Type | Required |
---|
Role
A user role as shown in Distru
{
"id": "12345",
"name": "Admin"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this role | string | false |
name | Name of the role | string | false |
OrderTransferTemplateTransporterInfoRequest
A Metrc-specific Order transfer template transporter info
Property | Description | Type | Required |
---|---|---|---|
driver_license_number | The driver's license number | string | false |
driver_name | The driver's name | string | false |
driver_occupational_license_number | The driver's occupational license number | string | false |
driver_phone_number | The driver's phone number | string | false |
transporter_license_number | The transporter's license number | string | false |
vehicle_license_plate_number | The vehicle's license plate number | string | false |
vehicle_make | The vehicle's make | string | false |
vehicle_model | The vehicle's model | string | false |
InvoiceItemsRequest
A collection of invoice item params
Property | Description | Type | Required |
---|
InvoiceItem
A invoice line item as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch | A batch for a product as shown in Distru | Batch | false |
id | Unique ID for this invoice item | string | false |
package | A package as shown in Distru | Package | false |
price | Price per unit of this invoice item | number | false |
product | A product as shown in Distru | Product | false |
quantity | Quantity used on this invoice item | number | false |
returned_quantity | Quantity returned on this invoice item. This is the sum of all return items associated with this invoice item allocated proportionally based on the quantity |
of the invoice item relative to its associated order item. For example, if an invoice item with a quantity of 1 has an order item with a quantity of 2, and a return item with a quantity of 2, the returned_quantity would be 1, calculated as (1 ÷ 2) × 2. |number|false| |total_cost_actual|Total cost of the non-returned quantity in this order item, in other words, this is the total cost of order_item.quantity minus order_item.returned quantity. The cost is allocated proportionally based on the quantity of the invoice item relative to its associated order item. For example, if an invoice item with a quantity of 1 has an order item with a quantity of 2 and a total cost of $10, the total_cost_actual would be $5, calculated as (1 ÷ 2) × $10. |number|false| |total_cost_default|Default cost of the non-returned quantity in this order item, in other words, this is the default cost of order_item.quantity minus order_item.returned quantity. The cost is allocated proportionally based on the quantity of the invoice item relative to its associated order item. For example, if an invoice item with a quantity of 1 has an order item with a quantity of 2 and a total cost of $10, the total_cost_default would be $5, calculated as (1 ÷ 2) × $10. |number|false|
RelationshipType
A relationship type as shown in Distru
{
"id": "12345",
"name": "Supplier"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this relationship type | string | false |
name | Name of the relationship type | string | false |
OrderItemRequest
Order item params
Property | Description | Type | Required |
---|---|---|---|
batch_id | The ID of the batch (if the product is batch-tracked) | string | false |
id | Unique ID for this order item. If it exists, an update will be performed; otherwise, it will be used as the ID of a new order item record | string | false |
package_id | The ID of the package (if the product is package-tracked) | string | false |
price_base | Price per unit of this order item (prior to price tier items being applied) | number | true |
product_id | The ID of the product (if the product is product-tracked) | string | false |
quantity | Quantity used on this order item | number | true |
Batch
A batch for a product as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this batch | string | false |
name | Human readable name for this batch | string | false |
TestResults
A collection of Test Results
Property | Description | Type | Required |
---|
PurchaseChargesRequest
A collection of Invoice charge params
Property | Description | Type | Required |
---|
PurchaseItemRequest
Purchase item params
Property | Description | Type | Required |
---|---|---|---|
batch_id | The ID of the batch (if the product is batch-tracked) | string | false |
id | Unique ID for this order item. If it exists, an update will be performed; otherwise, it will be used as the ID of a new invoice item record | string | false |
price | Price per unit of the inventory being received on this line item | number | true |
product_id | The ID of the product (if the product is product-tracked) | string | false |
quantity | Quantity received in this order item | number | true |
OrderTransferTemplateTransporterInfosRequest
A collection of Metrc-specific Order transfer template transporter info params
Property | Description | Type | Required |
---|
InvoiceChargesRequest
A collection of Invoice charge params
Property | Description | Type | Required |
---|
FileAttachment
A file attachment
Property | Description | Type | Required |
---|
PurchaseOrderItem
An order line item as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch | A batch for a product as shown in Distru | Batch | false |
id | Unique ID for this order item | string | false |
package | A package as shown in Distru | Package | false |
price | Price per unit of this order item (with discounts applied) | number | false |
price_base | Price per unit of this order item | number | false |
product | A product as shown in Distru | Product | false |
quantity | Quantity used on this order item | number | false |
received_quantity | Quantity received on this order item. Less than or equal to the quantity field | number | false |
PageWithSize
Pagination information for a request
{
"number": 1,
"size": 100
}
Property | Description | Type | Required |
---|---|---|---|
number | Page number | integer | true |
size | Amount of records per page | integer | true |
InvoicePayment
An invoice payment as shown in Distru
{
"amount": 100.0,
"description": "Payment for invoice 12345",
"id": "12345",
"method_id": "12345",
"payment_datetime": "2024-12-12 20:26:19.297537",
"payment_number": "12345",
"quickbooks_deposit_account_id": "12345"
}
Property | Description | Type | Required |
---|---|---|---|
amount | The amount of the payment | number | false |
descriptiontime | The description of this payment | string | false |
id | Unique ID for this invoice payment | string | false |
invoice_id | The ID of the invoice this payment is for | string | false |
method_id | The ID of the payment method used for this payment | string | false |
payment_date | The date of this payment | string | false |
payment_number | The payment number for this payment | string | false |
quickbooks_deposit_account_id | The id of the Quickbooks deposit account used for this payment | string | false |
InvoiceItemRequest
Invoice item params
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this order item. If it exists, an update will be performed; otherwise, it will be used as the ID of a new invoice item record | string | false |
order_item_id | The ID of order item with which this invoice item is associated | string | false |
quantity | Quantity used on this order item | number | true |
CustomField
A custom field as shown in Distru
{
"id": "12345",
"name": "Custom Field 1",
"value": "Custom Field Value 1"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this custom field | string | false |
name | The name of this custom field | string | false |
value | The value of the custom field in the context of the object it's associated with | string | false |
Image
An image as shown in Distru
{
"id": "12345",
"name": "image.jpg",
"rank": 0,
"url": "https://example.com/image.jpg"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this image | string | false |
name | Name of the file for this image | string | false |
rank | The rank of this image in the list of images for the product | integer | false |
url | URL to the image file | string | false |
User
Information about a user in Distru
{
"banned": false,
"email": "jeanb@zorgindustries.com",
"full_name": "Jean-Baptiste Emanuel Zorg",
"id": "12345",
"role": "Admin"
}
Property | Description | Type | Required |
---|---|---|---|
banned | Is this user banned by Distru? | boolean | false |
The email address of this user | string | false | |
full_name | The full name of this user | string | false |
id | Unique ID for this user | string | false |
role | A user role as shown in Distru | Role | false |
AdditionalTestResult
An additional test result object for a test result as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
chlorfenapyr_ug_per_g | Pesticide | string | false |
dimethoxyethane_ug_per_g | Solvent | string | false |
etofenprox_ug_per_g | Pesticide | string | false |
formic_acid_ug_per_g | Other | string | false |
cbda_percentage | Cannabinoid | string | false |
methylcyclohexane_ug_per_g | Solvent | string | false |
cadmium_ug_per_g | Heavy Metal | string | false |
cbl_percentage | Cannabinoid | string | false |
daminozide_ug_per_g | Pesticide | string | false |
other_pesticides_ug_per_g | Pesticide | string | false |
diazinon_ug_per_g | Pesticide | string | false |
cannabinoids_mg_per_unit_total | Cannabinoid | string | false |
methiocarb_ug_per_g | Pesticide | string | false |
water_activity_aw | Water Activity | string | false |
cbt_percentage | Cannabinoid | string | false |
camphor_mg_per_unit | Terpene | string | false |
hexythiazox_ug_per_g | Pesticide | string | false |
linalool_mg_per_unit | Terpene | string | false |
ethoprophos_ug_per_g | Pesticide | string | false |
other_microbials_cfu_per_g | Microbial | string | false |
cbt_mg_per_unit | Cannabinoid | string | false |
ethylene_oxide_ug_per_g | Solvent | string | false |
thcva_percentage | Cannabinoid | string | false |
carbaryl_ug_per_g | Pesticide | string | false |
acetone_ug_per_g | Solvent | string | false |
ocimene_percentage | Terpene | string | false |
nickel_ug_per_g | Heavy Metal | string | false |
imidacloprid_ug_per_g | Pesticide | string | false |
acetic_acid_ug_per_g | Other | string | false |
beta_humulene_mg_per_unit | Terpene | string | false |
cypermethrin_ug_per_g | Pesticide | string | false |
pyrethrins_pyrethrin_ii_ug_per_g | Pesticide | string | false |
camphene_percentage | Terpene | string | false |
methoxybenzene_ug_per_g | Solvent | string | false |
limonene_percentage | Terpene | string | false |
nerolidol_percentage | Terpene | string | false |
fenchol_percentage | Terpene | string | false |
flonicamid_ug_per_g | Pesticide | string | false |
alpha_cyfluthrin_ug_per_g | Pesticide | string | false |
spinetoram_l_ug_per_g | Pesticide | string | false |
clothianidin_ug_per_g | Pesticide | string | false |
sabinene_percentage | Terpene | string | false |
chlormequat_chloride_ug_per_g | Other | string | false |
aflatoxins_ug_per_kg | Mycotoxin | string | false |
ethanol_ug_per_g | Solvent | string | false |
permethrin_trans_ug_per_g | Pesticide | string | false |
ethyl_acetate_ug_per_g | Solvent | string | false |
salmonella_cfu_per_g | Microbial | string | false |
valencene_percentage | Terpene | string | false |
beta_pinene_percentage | Terpene | string | false |
caryophyllene_oxide_mg_per_unit | Terpene | string | false |
pyridaben_ug_per_g | Pesticide | string | false |
beta_caryophyllene_percentage | Terpene | string | false |
oxamyl_ug_per_g | Pesticide | string | false |
methyl_butanol_ug_per_g | Solvent | string | false |
fenpyroximate_ug_per_g | Pesticide | string | false |
delta_8_thc_mg_per_unit | Cannabinoid | string | false |
cymene_percentage | Terpene | string | false |
caryophyllene_oxide_percentage | Terpene | string | false |
bifenthrin_ug_per_g | Pesticide | string | false |
methomyl_ug_per_g | Pesticide | string | false |
isopropyl_acetate_ug_per_g | Solvent | string | false |
alpha_myrcene_mg_per_unit | Terpene | string | false |
beta_cypermethrin_ug_per_g | Pesticide | string | false |
terpinolene_percentage | Terpene | string | false |
tert_butyl_methyl_ether_ug_per_g | Solvent | string | false |
acetic_acid_percentage | Other | string | false |
borneol_mg_per_unit | Terpene | string | false |
mercury_ug_per_g | Heavy Metal | string | false |
aflatoxin_g1_ug_per_kg | Mycotoxin | string | false |
linalool_percentage | Terpene | string | false |
pyrethrins_ug_per_g | Pesticide | string | false |
beta_myrcene_mg_per_unit | Terpene | string | false |
terpenes_percentage_total | Terpene | string | false |
aflatoxin_b1_ug_per_kg | Mycotoxin | string | false |
dimethyl_sulfoxide_ug_per_g | Solvent | string | false |
naled_ug_per_g | Pesticide | string | false |
spirotetramat_ug_per_g | Pesticide | string | false |
boscalid_ug_per_g | Pesticide | string | false |
geraniol_percentage | Terpene | string | false |
cbc_mg_per_unit | Cannabinoid | string | false |
butane_ug_per_g | Solvent | string | false |
cumene_ug_per_g | Solvent | string | false |
dimethomorph_ug_per_g | Pesticide | string | false |
piperonylbutoxide_ug_per_g | Pesticide | string | false |
moisture_percentage | Moisture | string | false |
cbn_percentage | Cannabinoid | string | false |
prallethrin_trans_ug_per_g | Pesticide | string | false |
aspergillus_cfu_per_g | Microbial | string | false |
lead_ug_per_g | Heavy Metal | string | false |
ancymidol_ug_per_g | Pesticide | string | false |
acephate_ug_per_g | Pesticide | string | false |
dimethylformamide_ug_per_g | Solvent | string | false |
candida_albicans_cfu_per_g | Microbial | string | false |
nitromethane_ug_per_g | Solvent | string | false |
pyrethrins_cinerin_i_ug_per_g | Pesticide | string | false |
mevinphos_ii_ug_per_g | Pesticide | string | false |
kresoxim_methyl_ug_per_g | Pesticide | string | false |
spinetoram_j_ug_per_g | Pesticide | string | false |
cyclohexane_ug_per_g | Solvent | string | false |
alpha_phellandrene_percentage | Terpene | string | false |
chloroform_ug_per_g | Solvent | string | false |
beta_cyfluthrin_ug_per_g | Pesticide | string | false |
borneol_percentage | Terpene | string | false |
propyl_acetate_ug_per_g | Solvent | string | false |
cyfluthrin_ug_per_g | Pesticide | string | false |
fenhexamid_ug_per_g | Pesticide | string | false |
cbdv_mg_per_unit | Cannabinoid | string | false |
alpha_humulene_percentage | Terpene | string | false |
pentachloronitrobenzene_ug_per_g | Pesticide | string | false |
xylene_ug_per_g_total | Solvent | string | false |
tebuconazole_ug_per_g | Pesticide | string | false |
propiconazole_cis_ug_per_g | Pesticide | string | false |
butanol_ug_per_g | Solvent | string | false |
fenoxycarb_ug_per_g | Pesticide | string | false |
antimony_ug_per_g | Heavy Metal | string | false |
alpha_cypermethrin_ug_per_g | Pesticide | string | false |
chromium_ug_per_g | Heavy Metal | string | false |
zinc_ug_per_g | Heavy Metal | string | false |
heptane_ug_per_g | Solvent | string | false |
spiromesifen_ug_per_g | Pesticide | string | false |
thca_percentage | Cannabinoid | string | false |
spiroxamine_ug_per_g | Pesticide | string | false |
nerolidol_mg_per_unit | Terpene | string | false |
tetrahydrofuran_ug_per_g | Solvent | string | false |
chlordane_cis_ug_per_g | Pesticide | string | false |
propanol_ug_per_g | Solvent | string | false |
yeast_cfu_per_g | Microbial | string | false |
beta_caryophyllene_mg_per_unit | Terpene | string | false |
enterobacteriacaea_cfu_per_g | Microbial | string | false |
dimethoate_ug_per_g | Pesticide | string | false |
pulegone_percentage | Terpene | string | false |
vitamin_e_acetate_percentage | Other | string | false |
pentanol_ug_per_g | Solvent | string | false |
formic_acid_percentage | Other | string | false |
isopulegol_percentage | Terpene | string | false |
other_terpenes_mg_per_unit | Terpene | string | false |
gamma_terpinene_percentage | Terpene | string | false |
spinosad_d_ug_per_g | Pesticide | string | false |
l_monocytogenes_cfu_per_g | Microbial | string | false |
thiabendazole_ug_per_g | Pesticide | string | false |
formamide_ug_per_g | Pesticide | string | false |
ethyl_formate_percentage | Other | string | false |
ethylene_glycol_ug_per_g | Other | string | false |
methyl_propanol_ug_per_g | Solvent | string | false |
eucalyptol_percentage | Terpene | string | false |
alpha_myrcene_percentage | Terpene | string | false |
thca_mg_per_unit | Cannabinoid | string | false |
cbg_percentage | Cannabinoid | string | false |
ethylene_glycol_percentage | Other | string | false |
copper_ug_per_g | Heavy Metal | string | false |
mold_cfu_per_g | Microbial | string | false |
phytol_mg_per_unit | Terpene | string | false |
thcv_percentage | Cannabinoid | string | false |
phosmet_ug_per_g | Pesticide | string | false |
trifloxystrobin_ug_per_g | Pesticide | string | false |
dichloromethane_ug_per_g | Solvent | string | false |
thcv_mg_per_unit | Cannabinoid | string | false |
delta_8_thc_percentage | Cannabinoid | string | false |
fenchol_mg_per_unit | Terpene | string | false |
bifenazate_ug_per_g | Pesticide | string | false |
cannabinoids_percentage_total | Cannabinoid | string | false |
eucalyptol_mg_per_unit | Terpene | string | false |
cbdv_percentage | Cannabinoid | string | false |
dichloroethane_ug_per_g | Solvent | string | false |
propiconazole_ug_per_g | Pesticide | string | false |
paclobutrazol_ug_per_g | Pesticide | string | false |
cbl_mg_per_unit | Cannabinoid | string | false |
delta_3_carene_percentage | Terpene | string | false |
myclobutanil_ug_per_g | Pesticide | string | false |
dichlorvos_ug_per_g | Pesticide | string | false |
pulegone_mg_per_unit | Terpene | string | false |
butyl_acetate_ug_per_g | Solvent | string | false |
aflatoxin_b2_ug_per_kg | Mycotoxin | string | false |
isopulegol_mg_per_unit | Terpene | string | false |
trichloroethylene_ug_per_g | Solvent | string | false |
sulfolane_ug_per_g | Solvent | string | false |
benzene_ug_per_g | Solvent | string | false |
terpineol_mg_per_unit | Terpene | string | false |
guaiol_percentage | Terpene | string | false |
acetonitrile_ug_per_g | Solvent | string | false |
chlordane_trans_ug_per_g | Pesticide | string | false |
camphene_mg_per_unit | Terpene | string | false |
alpha_humulene_mg_per_unit | Terpene | string | false |
isopropanol_ug_per_g | Solvent | string | false |
spinetoram_ug_per_g | Pesticide | string | false |
chlorpyrifos_ug_per_g | Pesticide | string | false |
permethrin_cis_ug_per_g | Pesticide | string | false |
methyl_butyl_ketone_ug_per_g | Solvent | string | false |
aspergillus_terreus_cfu_per_g | Microbial | string | false |
aflatoxin_g2_ug_per_kg | Mycotoxin | string | false |
metalaxyl_ug_per_g | Pesticide | string | false |
alpha_terpinene_mg_per_unit | Terpene | string | false |
spiroxamine_b_ug_per_g | Pesticide | string | false |
dimethomorph_e_ug_per_g | Pesticide | string | false |
tetralin_ug_per_g | Solvent | string | false |
n_methylpyrrolidone_ug_per_g | Solvent | string | false |
ethyl_formate_ug_per_g | Other | string | false |
dinotefuran_ug_per_g | Pesticide | string | false |
methanol_ug_per_g | Solvent | string | false |
dimethylacetamide_ug_per_g | Solvent | string | false |
fipronil_ug_per_g | Pesticide | string | false |
flurprimidol_ug_per_g | Pesticide | string | false |
dimethomorph_z_ug_per_g | Pesticide | string | false |
m_and_p_xylene_ug_per_g | Solvent | string | false |
sand_and_soil_and_cinders_and_dirt_percentage | Other | string | false |
terpineol_percentage | Terpene | string | false |
imazalil_ug_per_g | Pesticide | string | false |
filth_and_foreign_material_percentage | Other | string | false |
ethyl_ether_ug_per_g | Solvent | string | false |
alpha_bisabolol_percentage | Terpene | string | false |
acequinocyl_ug_per_g | Pesticide | string | false |
cbda_mg_per_unit | Cannabinoid | string | false |
permethrin_ug_per_g | Pesticide | string | false |
cymene_mg_per_unit | Terpene | string | false |
azoxystrobin_ug_per_g | Pesticide | string | false |
malathion_ug_per_g | Pesticide | string | false |
gamma_terpinene_mg_per_unit | Terpene | string | false |
methyl_parathion_ug_per_g | Pesticide | string | false |
clofentezine_ug_per_g | Pesticide | string | false |
alpha_pinene_percentage | Terpene | string | false |
terpenes_mg_per_unit_total | Terpene | string | false |
alpha_terpinene_percentage | Terpene | string | false |
coumaphos_ug_per_g | Pesticide | string | false |
acetamiprid_ug_per_g | Pesticide | string | false |
ocimene_mg_per_unit | Terpene | string | false |
ethephon_ug_per_g | Pesticide | string | false |
geraniol_mg_per_unit | Terpene | string | false |
cbc_percentage | Cannabinoid | string | false |
pyriproxyfen_ug_per_g | Pesticide | string | false |
cbga_mg_per_unit | Cannabinoid | string | false |
cbga_percentage | Cannabinoid | string | false |
phytol_percentage | Terpene | string | false |
chlordane_ug_per_g | Pesticide | string | false |
beta_humulene_percentage | Terpene | string | false |
terpinolene_mg_per_unit | Terpene | string | false |
thcva_mg_per_unit | Cannabinoid | string | false |
farnesene_mg_per_unit | Terpene | string | false |
camphor_percentage | Terpene | string | false |
lambda_cyhalothrin_ug_per_g | Pesticide | string | false |
e_coli_cfu_per_g | Microbial | string | false |
alpha_bisabolol_mg_per_unit | Terpene | string | false |
valencene_mg_per_unit | Terpene | string | false |
methoxyethanol_ug_per_g | Solvent | string | false |
isobutyl_acetate_ug_per_g | Solvent | string | false |
farnesene_percentage | Terpene | string | false |
propiconazole_trans_ug_per_g | Pesticide | string | false |
dioxane_ug_per_g | Solvent | string | false |
chlorobenzene_ug_per_g | Solvent | string | false |
alpha_phellandrene_mg_per_unit | Terpene | string | false |
cbg_mg_per_unit | Cannabinoid | string | false |
other_heavy_metals_ug_per_g | Heavy Metal | string | false |
diuron_ug_per_g | Pesticide | string | false |
delta_3_carene_mg_per_unit | Terpene | string | false |
ethoxyethanol_ug_per_g | Solvent | string | false |
aldicarb_ug_per_g | Pesticide | string | false |
aspergillus_fumigatus_cfu_per_g | Microbial | string | false |
captan_ug_per_g | Pesticide | string | false |
chlorantraniliprole_ug_per_g | Pesticide | string | false |
propane_ug_per_g | Solvent | string | false |
hexane_ug_per_g | Solvent | string | false |
other_terpenes_percentage | Terpene | string | false |
pyrethrins_pyrethrin_i_ug_per_g | Pesticide | string | false |
prallethrin_cis_ug_per_g | Pesticide | string | false |
chlormequat_chloride_percentage | Other | string | false |
spinosad_a_ug_per_g | Pesticide | string | false |
pyrethrins_jasmolin_ii_ug_per_g | Pesticide | string | false |
spiroxamine_a_ug_per_g | Pesticide | string | false |
guaiol_mg_per_unit | Terpene | string | false |
methyl_acetate_ug_per_g | Solvent | string | false |
aspergillus_flavus_cfu_per_g | Microbial | string | false |
etoxazole_ug_per_g | Pesticide | string | false |
methylisobutyl_ketone_ug_per_g | Solvent | string | false |
vitamin_e_acetate_ug_per_g | Other | string | false |
pyrethrins_cinerin_ii_ug_per_g | Pesticide | string | false |
cbn_mg_per_unit | Cannabinoid | string | false |
prallethrin_ug_per_g | Pesticide | string | false |
mgk_264_ug_per_g | Pesticide | string | false |
arsenic_ug_per_g | Heavy Metal | string | false |
limonene_mg_per_unit | Terpene | string | false |
alpha_pinene_mg_per_unit | Terpene | string | false |
mevinphos_ug_per_g | Pesticide | string | false |
pyridine_ug_per_g | Solvent | string | false |
thiamethoxam_ug_per_g | Pesticide | string | false |
toluene_ug_per_g | Solvent | string | false |
spinosad_ug_per_g | Pesticide | string | false |
pentane_ug_per_g | Solvent | string | false |
propoxur_ug_per_g | Pesticide | string | false |
ochratoxin_a_ug_per_kg | Mycotoxin | string | false |
fludioxonil_ug_per_g | Pesticide | string | false |
beta_myrcene_percentage | Terpene | string | false |
thiacloprid_ug_per_g | Pesticide | string | false |
aspergillus_niger_cfu_per_g | Microbial | string | false |
mevinphos_i_ug_per_g | Pesticide | string | false |
sabinene_mg_per_unit | Terpene | string | false |
other_solvents_ug_per_g | Solvent | string | false |
carbofuran_ug_per_g | Pesticide | string | false |
beta_pinene_mg_per_unit | Terpene | string | false |
other_mycotoxins_ug_per_kg | Mycotoxin | string | false |
pyrethrins_jasmolin_i_ug_per_g | Pesticide | string | false |
methyl_ethyl_ketone_ug_per_g | Solvent | string | false |
OrderChargeRequest
Order charge params
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this order charge. If it exists, an update will be performed; otherwise, it will be used as the ID of a new order charge record | string | false |
name | The ID of the batch (if the product is batch-tracked) | string | false |
percent | The ID of the package (if the product is package-tracked) | number | false |
price | The ID of the product (if the product is product-tracked) | number | false |
type | What type of additional line is this | string | true |
unit_type | Determines if this line is tracked as a percentage or a flat charge | string | true |
PurchasePayment
A purchase payment as shown in Distru
{
"amount": 100.0,
"description": "Payment for invoice 12345",
"id": "12345",
"method_id": "12345",
"payment_datetime": "2024-12-12 20:26:19.297537",
"payment_number": "12345",
"quickbooks_deposit_account_id": "12345"
}
Property | Description | Type | Required |
---|---|---|---|
amount | The amount of the payment | number | false |
descriptiontime | The description of this payment | string | false |
id | Unique ID for this purchase payment | string | false |
method_id | The ID of the payment method used for this payment | string | false |
payment_date | The date of this payment | string | false |
payment_number | The payment number for this payment | string | false |
purchase_id | The ID of the purchase this payment is for | string | false |
quickbooks_deposit_account_id | The id of the Quickbooks deposit account used for this payment | string | false |
Packages
A collection of Packages
Property | Description | Type | Required |
---|
StockAdjustment
A stock adjustment as shown in Distru
{
"batch_id": "12345",
"completion_datetime": "2024-12-12 20:26:19.297537",
"compliance_quantity": 10,
"description": "The description for this adjustment",
"id": "12345",
"license_id": "12345",
"location_id": "12345",
"owner_id": "12345",
"package_id": "12345",
"product_id": "12345",
"quantity": 10,
"reason": "Waste",
"total_cost": 100
}
Property | Description | Type | Required |
---|---|---|---|
batch_id | The ID of this adjustment's batch. Null if this adjustment is not associated with a batch-tracked product | string | false |
completion_datetime | The datetime this adjustment was completed at | datetime | false |
compliance_quantity | The quantity of this adjustment expressed in it's package's unit type. Null if this adjustment is not associated with a package-tracked product. | number | false |
description | The description for this adjustment | string | false |
id | Unique ID for this stock adjustment | string | false |
license_id | ID of the license that this adjustment is associated with | string | false |
location_id | ID of the location that this adjustment is associated with | string | false |
owner_id | The ID of the user that owns this adjustment | string | false |
package_id | The ID of this adjustment's package. Null if this adjustment is not associated with a package-tracked product | string | false |
product_id | The ID of this adjustment's product. Populated regardless of the product's inventory tracking method. | string | false |
quantity | The quantity of the adjustment | number | false |
reason | The reason for this adjustment | string | false |
total_cost | The total cost of this adjustment | number | false |
Batches
A collection of Batches
Property | Description | Type | Required |
---|
Inventory
{
"active": "500.000000000",
"available": "400.000000000",
"batch_number": "1234",
"location_id": "1764da45-c1be-425c-9b31-b860cdb93e98",
"product_id": "67ae9080-8dc2-4ab7-9704-19673f4d9f21"
}
Property | Description | Type | Required |
---|---|---|---|
active | Active quantity | number | true |
available | Available quantity (active - reserved) | number | true |
batch_number | The batch number of the batch or the package | string | false |
location_id | ID of the location | string | false |
product_id | ID of the product | string | true |
Order
A sales order as shown in Distru. Ordered by order date
{
"billing_location": {
"address": "123 Compton Street, CA, USA, 12345",
"id": "d06a5135-dccf-4d62-a922-804190213c10",
"name": "Warehouse 1"
},
"charges": [
{
"id": "8h7512d2-g4h6-jj89-92h7-12f9ed9ls8f5",
"name": "Friends and Family",
"percent": -10,
"type": "DISCOUNT",
"unit_type": "PERCENT"
},
{
"id": "duy67x9r-0d4k-mmk5-8u9u-l3k8ed9lj900",
"name": "Excise Tax",
"percent": 27,
"tax": {
"id": "9876",
"name": "Excise Tax - CA 27%",
"percent": 27.0
},
"type": "TAX",
"unit_type": "PERCENT"
},
{
"id": "ko38h9ju-ndn7-76h8-jio9-j98yhd93h6fh",
"name": "Membership Fee",
"price": 25.0,
"type": "CHARGE",
"unit_type": "PRICE"
}
],
"creator": {
"banned": false,
"email": "jeanb@zorgindustries.com",
"full_name": "Jean-Baptiste Emanuel Zorg",
"id": "3e98e590-85b6-4247-b2e9-96fc2f45802e"
},
"delivery_datetime": "2022‐07‐02T00:00:00Z",
"due_datetime": "2022‐07‐02T00:00:00Z",
"id": "193c12d2-bc68-46fa-a221-12f9ed958ef4",
"inserted_datetime": "2022‐07‐02T00:00:00Z",
"internal_notes": "Internal note example",
"items": [
{
"id": "3e98e590-85b6-4247-b2e9-96fc2f45802e",
"price": 0.006,
"price_base": 0.006,
"product": {
"id": "4ec0ac89-a382-409c-ae67-4478e7e681ac",
"name": "Crawdad Crippler - 1g - PreRoll",
"sku": "WHODAT"
},
"quantity": 786
}
],
"order_datetime": "2022‐07‐02T00:00:00Z",
"order_number": "SO-00012345",
"shipping_location": {
"address": "123 Compton Street, CA, USA, 12345",
"id": "d06a5135-dccf-4d62-a922-804190213c10",
"name": "Warehouse 1"
},
"status": "PENDING",
"total": 150.23,
"updated_datetime": "2022‐07‐02T00:00:00Z"
}
Property | Description | Type | Required |
---|---|---|---|
billing_location | A location as shown in Distru | Location | false |
biotrack_id | The ID of the BioTrack manifest associated with this order | string | false |
charges | A collection of Charges | array(Charge) | false |
company | A company as shown in Distru | Company | false |
creator | Information about a user in Distru | User | false |
custom_data | A collection of CustomData | array(CustomData) | false |
delivery_datetime | The datetime on which the order was / will be delivered | string | false |
due_datetime | The datetime by which the order should be completed for the customer | string | false |
id | Unique ID for this order | string | false |
inserted_datetime | The datetime at which the order was created in Distru | string | false |
internal_notes | Internal notes for this order | string | false |
items | A collection of SalesOrderItems | array(SalesOrderItem) | false |
leaflink_order_number | The LeafLink order number for this order | string | false |
metrc_transfer_id | The ID of the Metrc transfer associated with this order | string | false |
order_datetime | The datetime on which the order was placed | string | false |
order_number | The order number as shown in the Distru UI | string | false |
owner | Information about a user in Distru | User | false |
shipping_location | A location as shown in Distru | Location | false |
status | The status of this sales order | string | false |
total | The total for this order including taxes, discounts, and all line items | number | false |
updated_datetime | The datetime at which the order was last updated in Distru | string | false |
Contacts
A collection of Contacts
Property | Description | Type | Required |
---|
Page
Pagination information for a request
{
"number": 1
}
Property | Description | Type | Required |
---|---|---|---|
number | Page number | integer | true |
Purchase
A purchase order as shown in Distru. Ordered by order date
{
"charges": [
{
"id": "8h7512d2-g4h6-jj89-92h7-12f9ed9ls8f5",
"name": "Friends and Family",
"percent": -10,
"type": "Discount",
"unit_type": "Percent"
},
{
"id": "duy67x9r-0d4k-mmk5-8u9u-l3k8ed9lj900",
"name": "Excise Tax",
"percent": 27,
"tax": {
"id": "9876",
"name": "Excise Tax - CA 27%",
"percent": 27.0
},
"type": "Tax",
"unit_type": "Percent"
},
{
"id": "ko38h9ju-ndn7-76h8-jio9-j98yhd93h6fh",
"name": "Membership Fee",
"price": 25.0,
"type": "Charge",
"unit_type": "Price"
}
],
"due_datetime": "2022‐07‐02T00:00:00Z",
"id": "193c12d2-bc68-46fa-a221-12f9ed958ef4",
"inserted_datetime": "2022‐07‐02T00:00:00Z",
"items": [
{
"id": "3e98e590-85b6-4247-b2e9-96fc2f45802e",
"price": 0.006,
"product": {
"id": "4ec0ac89-a382-409c-ae67-4478e7e681ac",
"name": "Crawdad Crippler - 1g - PreRoll",
"sku": "WHODAT"
},
"quantity": 786,
"received_quantity": 786
}
],
"order_datetime": "2022‐07‐02T00:00:00Z",
"purchase_number": "PO-00012345",
"status": "Pending",
"total": 150.23,
"updated_datetime": "2022‐07‐02T00:00:00Z"
}
Property | Description | Type | Required |
---|---|---|---|
charges | A collection of Charges | array(Charge) | false |
company | A company as shown in Distru | Company | false |
creator | Information about a user in Distru | User | false |
custom_data | The custom data for this purchase order | array(CustomField) | false |
due_datetime | The datetime by which the order should be completed for the customer | string | false |
id | Unique ID for this order | string | false |
inserted_datetime | The datetime at which the order was created in Distru | string | false |
items | A collection of PurchaseOrderItems | array(PurchaseOrderItem) | false |
order_datetime | The datetime on which the order was placed | string | false |
order_number | The order number as shown in the Distru UI | string | false |
owner | Information about a user in Distru | User | false |
status | The status of this purchase order | string | false |
total | The total for this order including taxes, discounts, and all line items | number | false |
updated_datetime | The datetime at which the order was last updated in Distru | string | false |
PaymentMethod
A payment method as shown in Distru
{
"id": "12345",
"name": "Credit Card"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this payment method | string | false |
name | Name of the payment method | string | false |
Package
A package as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch_number | The non-compliance batch number for this package | string | false |
compliance_label | The compliance (e.g. Metrc) label for this package | string | false |
id | Unique ID for this package in Distru | string | false |
status | The status of this package | array(any) | false |
BatchFull
Extended details about a batch for a product as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch_number | The batch number for this batch | string | false |
custom_data | The custom data for this batch | array(CustomField) | false |
description | The description for this batch | string | false |
expiration_date | The expiration date for this batch | string | false |
id | Unique ID for this batch | string | false |
name | Human readable name for this batch | string | false |
owner_id | The ID of the user that owns this batch | string | false |
product_id | The ID of the batch's product | string | false |
Invoices
A collection of Invoices
Property | Description | Type | Required |
---|
ProductSubcategory
A product subcategory as shown in Distru
{
"id": "88c02a3f-57d9-9473-f8f9-40609d68bbh4",
"name": "High Grade Flower"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this subcategory | string | false |
name | Human readable name for this subcategory | string | false |
Orders
A collection of Orders
Property | Description | Type | Required |
---|
SalesOrderItem
An order line item as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch | A batch for a product as shown in Distru | Batch | false |
id | Unique ID for this order item | string | false |
package | A package as shown in Distru | Package | false |
price | Price per unit of this order item | number | false |
product | A product as shown in Distru | Product | false |
quantity | Quantity sold on this order item | number | false |
returned_quantity | Quantity returned on this order item | number | false |
total_cost_actual | Total cost of the non-returned quantity in this order item, in other words, this is the total cost of order_item.quantity minus order_item.returned quantity. | number | false |
total_cost_default | Default cost of the non-returned quantity in this order item, in other words, this is the default cost of order_item.quantity minus order_item.returned quantity. | number | false |
Assemblies
A collection of Assemblies
Property | Description | Type | Required |
---|
Invoice
An invoice as shown in Distru. Ordered by invoice date
{
"creator": {
"banned": false,
"email": "jeanb@zorgindustries.com",
"full_name": "Jean-Baptiste Emanuel Zorg",
"id": "12345"
},
"due_datetime": "2022‐07‐02T00:00:00Z",
"id": "193c12d2-bc68-46fa-a221-12f9ed958ef4",
"inserted_datetime": "2022‐07‐02T00:00:00Z",
"invoice_datetime": "2022‐07‐02T00:00:00Z",
"invoice_number": "INV-00012345",
"items": [
{
"id": "1",
"price": 3.0,
"product": {
"id": "543",
"name": "Crawdad Crippler - 1g - PreRoll",
"sku": "WHODAT"
},
"quantity": 5
}
],
"order": {
"id": "931c12d2-68bc-fa46-a221-12f9edcg5hd7",
"order_number": "SO-0000657",
"status": "Delivering",
"total": 999.99
},
"status": "Pending",
"total": 543.23,
"updated_datetime": "2022‐07‐02T00:00:00Z"
}
Property | Description | Type | Required |
---|---|---|---|
charges | A collection of Charges | array(Charge) | false |
company | A company as shown in Distru | Company | false |
creator | Information about a user in Distru | User | false |
custom_data | A collection of CustomData | array(CustomField) | false |
due_datetime | The datetime by which the invoice should be paid by the customer | string | false |
id | Unique ID for this invoice | string | false |
inserted_datetime | The datetime at which the invoice was created in Distru | string | false |
invoice_datetime | The datetime on which the invoice was placed | string | false |
invoice_number | The invoice number as shown in the Distru UI | string | false |
items | A collection of InvoiceItems | array(InvoiceItem) | false |
owner | Information about a user in Distru | User | false |
paid_amount | The payment amount recorded against this invoice so far. | number | false |
status | The status of this invoice | string | false |
total | The total for this invoice including taxes, discounts, and all line items | number | false |
updated_datetime | The datetime at which the invoice was last updated in Distru | string | false |
order.id | Unique ID for this order | string | false |
order.order_number | The order number for this sale as seen in the Distru UI | string | false |
order.status | Status of the associated order | string | false |
order.total | The total on the order | number | false |
PurchaseChargeRequest
Purchase charge params
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this purchase charge. If it exists, an update will be performed; otherwise, it will be used as the ID of a new purchase charge record | string | false |
name | The name of this charge | string | false |
percent | The percent (if it is percent-based) of this charge | number | false |
price | The flat price (if it is price-based) of this charge | number | false |
type | Determines if this is a charge or discount | string | true |
unit_type | Determines if this line is tracked as a percentage or a flat charge | string | true |
PackageFull
A package with extended details as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch_number | The non-compliance batch number for this package | string | false |
compliance_label | The compliance (e.g. Metrc) label for this package | string | false |
custom_data | The custom data for this package | array(CustomField) | false |
expiration_date | The date that this package expires | string | false |
id | Unique ID for this package in Distru | string | false |
is_trade_sample | True if this package is a Metrc trade sample | boolean | false |
license | A license as shown in Distru | License | false |
product_unit_quantity | The quantity of this package expressed in it's product's unit type | string | false |
product_unit_type | A unit type as shown in Distru | UnitType | false |
quantity | The last known accurate quantity of this package | string | false |
quantity_assembling | This quantity of this package currently allocated towards a pending assembly | string | false |
quantity_available | The quantity available for use of this package (i.e. inventory that is not held up on a sales order or assembly.) | string | false |
status | The status of this package | array(any) | false |
unit_type | A unit type as shown in Distru | UnitType | false |
location.id | Unique ID for this Location | string | false |
location.name | The name of this Location | string | false |
License
A license as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this license | string | false |
license_number | License number | string | false |
Purchases
A collection of Purchases
Property | Description | Type | Required |
---|
AssemblyOutput
An output for an assembly as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
additional_costs | The additional costs for this assembly output | array(AdditionalCost) | false |
batch | A batch for a product as shown in Distru | Batch | false |
compliance_label | The compliance label for this assembly output | string | false |
compliance_quantity | The quantity of this output expressed in the package's unit type. Null if this input is not package-tracked. | number | false |
expiration_date | The expiration date for this assembly output | string | false |
ingredients | The ingredients for this assembly output | array(AssemblyInput) | false |
is_production_batch | Is this output a production batch? | boolean | false |
location | A location as shown in Distru | Location | false |
package | A package as shown in Distru | Package | false |
package_date | The date that this package was created at | string | false |
package_unit_type | A unit type as shown in Distru | UnitType | false |
product | A product as shown in Distru | Product | false |
quantity | The quantity of this output in its product's unit | number | false |
PurchaseItemsRequest
A collection of purchase item params
Property | Description | Type | Required |
---|
Location
A location as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
address | Human readable address for this location | string | false |
company_id | ID of the company that owns this location | string | false |
id | Unique ID for this location | string | false |
license | A license as shown in Distru | License | false |
license_id | ID of the license that this location is associated with, if null, then this location is not associated to a license | string | false |
name | Human readable name for this location | string | false |
TestResult
A test result as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
additional_test_results | An additional test result object for a test result as shown in Distru | AdditionalTestResult | false |
cbd_mg_per_unit | The CBD mg per unit for this test result | string | false |
cbd_percentage | The CBD percentage for this test result | string | false |
id | Unique ID for this test result | string | false |
is_primary | True if this is the primary test result for the product | boolean | false |
lab_license_number | The license number for the lab that performed this test | string | false |
lab_name | The name of the lab that performed this test | string | false |
mg_per_unit_type | The unit type for the mg per unit fields | string | false |
name | The name of the test result | string | false |
release_date | The release date for this test result | string | false |
thc_mg_per_unit | The THC mg per unit for this test result | string | false |
thc_percentage | The THC percentage for this test result | string | false |
total_cbd_mg_per_unit | The total CBD mg per unit for this test result | string | false |
total_cbd_percentage | The total CBD percentage for this test result | string | false |
total_thc_mg_per_unit | The total THC mg per unit for this test result | string | false |
total_thc_percentage | The total THC percentage for this test result | string | false |
updated_datetime | The datetime this test result was updated at | string | false |
ProductCategory
A product category as shown in Distru
{
"id": "88c02a3f-57d9-9473-f8f9-40609d68bbh4",
"name": "Flower",
"type": "FLOWER"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this category | string | false |
name | Human readable name for this category | string | false |
type | The type of this category | string | false |
OrderChargesRequest
A collection of Order charge params
Property | Description | Type | Required |
---|
Contact
Information about a contact in Distru's CRM
{
"company": {
"id": "3f128a34-cc59-4b49-8883-23bf10e59c6c"
},
"email": "contact@example.com",
"full_name": "John Doe",
"id": "12345",
"owner": {
"id": "02c88a3f-d759-4973-88f9-60049d682524"
}
}
Property | Description | Type | Required |
---|---|---|---|
company | A company as shown in Distru | Company | false |
custom_data | The custom data for this contact | array(CustomField) | false |
The email address of this contact | string | false | |
full_name | The full name of this contact | string | false |
id | Unique ID for this contact | string | false |
owner | Information about a user in Distru | User | false |
phone_number | The phone number of this contact | string | false |
title | The title of this contact | string | false |
PaymentMethods
A collection of Payment Methods
Property | Description | Type | Required |
---|
InvoiceChargeRequest
Invoice charge params
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this invoice charge. If it exists, an update will be performed; otherwise, it will be used as the ID of a new invoice charge record | string | false |
name | The name of this charge | string | false |
percent | The percent (if it is percent-based) of this charge | number | false |
price | The flat price (if it is price-based) of this charge | number | false |
type | Determines if this is a charge or discount | string | true |
unit_type | Determines if this line is tracked as a percentage or a flat charge | string | true |
Companies
A collection of companies
Property | Description | Type | Required |
---|
UnitType
A unit type as shown in Distru
{
"name": "Gram"
}
Property | Description | Type | Required |
---|---|---|---|
id | Unique ID for this unit type | string | false |
name | Human readable name for this unit type | string | false |
Company
A company as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
category | The category of this company | string | false |
custom_data | The custom data for this company | array(CustomField) | false |
default_email | The default email for this company | string | false |
default_purchase_order_notes | The default notes that will be automatically added to purchase orders when this company is the supplier | string | false |
default_sales_order_notes | The default external notes that will be automatically added to sales orders when this company is the customer | string | false |
id | Unique ID for this company | string | false |
invoice_email | The email address where sales order invoices are delivered | string | false |
legal_business_name | The legal business name for this company | string | false |
licenses | The license for the company | array(License) | false |
locations | The location for the company | array(Location) | false |
name | Human readable name for this company | string | false |
order_shipment_email | The email address where sales order shipment packing slips are delivered | string | false |
outstanding_balance_threshold | Threshold that determines when a company is considered to have a too high an outstanding balance. When exceeded, Distru will show a warning banner in the company's page and when selling to this company. | integer | false |
owner_id | The ID of the user that owns this company | string | false |
phone_number | The phone number for this company | string | false |
purchase_order_email | The email address where purchase order slips are delivered | string | false |
relationship_type | A relationship type as shown in Distru | RelationshipType | false |
sales_order_email | The email address where sales order slips are delivered | string | false |
updated_datetime | The datetime this company was last updated at | string | false |
website | The website for this company | string | false |
AssemblyInput
An input for an assembly as shown in Distru
Property | Description | Type | Required |
---|---|---|---|
batch | A batch for a product as shown in Distru | Batch | false |
compliance_quantity | The quantity of this input expressed in the package's unit type. Null if this input is not package-tracked. | number | false |
cost | The cost of this input | number | false |
location | A location as shown in Distru | Location | false |
package | A package as shown in Distru | Package | false |
product | A product as shown in Distru | Product | false |
quantity | The quantity of this input in its product's unit | number | false |
Inventories
A list of active and available quantity for each group
Property | Description | Type | Required |
---|
Brand
A brand as shown in Distru
{
"name": "Brand 123"
}
Property | Description | Type | Required |
---|---|---|---|
name | Name of the brand | string | false |
Users
A collection of Users
Property | Description | Type | Required |
---|
Assembly
Get assemblies
GET /public/v1/assemblies returns proper data for non-compliance assembly
GET /public/v1/assemblies?creation_source=MANUALLY_CREATED&page[number]=1
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5NjIsImlhdCI6MTc0OTc0MjM2MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTkwOTkwYjAtN2E2NC00OGQxLWJlY2MtMzMyZTI5NzhhY2E2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzYxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MjkwNSIsInR5cCI6ImFjY2VzcyJ9.wBuCcLVxtQk47Lexpp1L7Qymq7hrDqcGGcMkVqPsOjQ
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: cd33ab35919070000000000000000001-85f68d5d26bc5777-0
{
"data": [
{
"completion_datetime": null,
"compliance_type": "NONE",
"creation_source": "MANUALLY_CREATED",
"custom_data": [
{
"id": 3,
"name": "Custom Field 33",
"value": "Custom Field Value"
}
],
"description": null,
"estimated_work_hours": 1,
"estimated_work_minutes": 5,
"fulfilled": true,
"id": "07d8b9e4-ea91-47ac-9109-144605179fbf",
"is_metrc_processing_job": false,
"license": null,
"outputs": [
{
"additional_costs": [
{
"cost_per_unit": "-1",
"description": null,
"name": "CostType 1",
"quantity": "1",
"total_cost_actual": "-1",
"total_cost_default": "0",
"unit_type": {
"id": "00000000-0000-0000-0000-00000000865e",
"name": "Unit Type 29"
}
}
],
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000033c",
"name": "B2565"
},
"compliance_label": null,
"compliance_quantity": null,
"expiration_datetime": null,
"ingredients": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000033c",
"name": "B2565"
},
"compliance_quantity": null,
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000009db",
"id": "00000000-0000-0000-0000-00000000033c",
"license_id": null,
"name": "Place 819"
},
"package": null,
"product": {
"id": "9a037336-22a2-4d9a-8d5a-da9f2ca3b068",
"name": "Product 2563",
"sku": "sku 2564",
"updated_datetime": "2025-06-12T15:32:42.334121Z"
},
"quantity": "1",
"total_cost_actual": null,
"total_cost_default": "1"
}
],
"is_production_batch": false,
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000009db",
"id": "00000000-0000-0000-0000-00000000033c",
"license_id": null,
"name": "Place 819"
},
"package": null,
"package_datetime": null,
"package_unit_type": null,
"product": {
"id": "9a037336-22a2-4d9a-8d5a-da9f2ca3b068",
"name": "Product 2563",
"sku": "sku 2564",
"updated_datetime": "2025-06-12T15:32:42.334121Z"
},
"quantity": "1"
}
],
"owner_id": "00000000-0000-0000-0000-000000000b59",
"status": "PENDING"
}
]
}
GET /public/v1/assemblies returns proper data for pending metrc assembly
GET /public/v1/assemblies?creation_source=MANUALLY_CREATED&license_number=CDPH-00000391&page[number]=1
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5NTUsImlhdCI6MTc0OTc0MjM1NSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZjM5ZDlhMzctNGFkNS00Nzg3LThhMjItOWI0NDNkYjdiYzYyIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzU0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTg4NiIsInR5cCI6ImFjY2VzcyJ9.K5RnIjrdD4tOjBmZo6fl45eFHagFfXb--fcyBHxzaWQ
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 0c4cf6c6a5f041000000000000000001-96ade62d05628f2b-0
{
"data": [
{
"completion_datetime": null,
"compliance_type": "METRC",
"creation_source": "MANUALLY_CREATED",
"custom_data": [
{
"id": 2,
"name": "Custom Field 32",
"value": null
}
],
"description": null,
"estimated_work_hours": null,
"estimated_work_minutes": null,
"fulfilled": true,
"id": "59274479-ca72-4638-8965-34287cb26b4c",
"is_metrc_processing_job": false,
"license": {
"id": "00000000-0000-0000-0000-000000000169",
"license_number": "CDPH-00000391"
},
"outputs": [
{
"additional_costs": [],
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000001cc",
"name": "B1485"
},
"compliance_label": "1A4010200001234000000047",
"compliance_quantity": "2",
"expiration_datetime": null,
"ingredients": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000001cc",
"name": "B1485"
},
"compliance_quantity": "0.0353",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000006bd",
"id": "00000000-0000-0000-0000-0000000001ee",
"license_id": "00000000-0000-0000-0000-000000000169",
"name": "Place 490"
},
"package": {
"batch_number": "1234567890",
"compliance_label": "ABCDEF012345670000000246",
"id": "00000000-0000-0000-0000-000000000070",
"metrc_label": "ABCDEF012345670000000246",
"status": "active"
},
"product": {
"id": "d54b89b5-da4f-4ee1-bea8-df09d0331f4e",
"name": "Product 1479",
"sku": "sku 1480",
"updated_datetime": "2025-06-12T15:32:35.893007Z"
},
"quantity": "1",
"total_cost_actual": null,
"total_cost_default": null
}
],
"is_production_batch": false,
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000006bd",
"id": "00000000-0000-0000-0000-0000000001ee",
"license_id": "00000000-0000-0000-0000-000000000169",
"name": "Place 490"
},
"package": null,
"package_datetime": "2025-06-12",
"package_unit_type": {
"id": "00000000-0000-0000-0000-000000005ad2",
"name": "Gram"
},
"product": {
"id": "d54b89b5-da4f-4ee1-bea8-df09d0331f4e",
"name": "Product 1479",
"sku": "sku 1480",
"updated_datetime": "2025-06-12T15:32:35.893007Z"
},
"quantity": "2"
}
],
"owner_id": "00000000-0000-0000-0000-00000000075e",
"status": "PENDING"
}
]
}
GET /public/v1/assemblies returns proper data for completed metrc assembly
GET /public/v1/assemblies?completion_datetime=2025-06-12+14%3A32%3A41.699081Z%2C2025-06-12+16%3A32%3A41.699081Z&creation_source=MANUALLY_CREATED&license_number=CDPH-00000547&page[number]=1
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5NjEsImlhdCI6MTc0OTc0MjM2MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMThkOGQ4MzQtOThlMC00MmQ0LTk3ODEtZGEzNjE1ODIzYjIzIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzYwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MjgwMCIsInR5cCI6ImFjY2VzcyJ9.jAj6BVqyAvRgw5teUzcEDDUtUosyiHzU9A8Z08PO74s
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ea066406e59c10000000000000000001-7b007ce477fdd82b-0
{
"data": [
{
"completion_datetime": "2025-06-12T15:32:41.699081Z",
"compliance_type": "METRC",
"creation_source": "MANUALLY_CREATED",
"custom_data": [],
"description": null,
"estimated_work_hours": null,
"estimated_work_minutes": null,
"fulfilled": true,
"id": "6c99bd56-b42c-4028-b6bf-85ca2e6a8451",
"is_metrc_processing_job": false,
"license": {
"id": "00000000-0000-0000-0000-000000000201",
"license_number": "CDPH-00000547"
},
"outputs": [
{
"additional_costs": [],
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000325",
"name": "B2498"
},
"compliance_label": "1A4010200001234000000067",
"compliance_quantity": "2",
"expiration_datetime": null,
"ingredients": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000325",
"name": "B2498"
},
"compliance_quantity": "0.0353",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000098a",
"id": "00000000-0000-0000-0000-000000000315",
"license_id": "00000000-0000-0000-0000-000000000201",
"name": "Place 781"
},
"package": {
"batch_number": "1234567890",
"compliance_label": "ABCDEF012345670000000467",
"id": "00000000-0000-0000-0000-0000000000ca",
"metrc_label": "ABCDEF012345670000000467",
"status": "active"
},
"product": {
"id": "1d9955db-3852-441a-873a-717270912f6c",
"name": "Product 2495",
"sku": "sku 2496",
"updated_datetime": "2025-06-12T15:32:41.389086Z"
},
"quantity": "1",
"total_cost_actual": null,
"total_cost_default": null
}
],
"is_production_batch": false,
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000098a",
"id": "00000000-0000-0000-0000-000000000315",
"license_id": "00000000-0000-0000-0000-000000000201",
"name": "Place 781"
},
"package": {
"batch_number": null,
"compliance_label": "1A4010200001234000000067",
"id": "00000000-0000-0000-0000-0000000000cb",
"metrc_label": "1A4010200001234000000067",
"status": "active"
},
"package_datetime": "2025-06-12",
"package_unit_type": {
"id": "00000000-0000-0000-0000-000000008082",
"name": "Gram"
},
"product": {
"id": "1d9955db-3852-441a-873a-717270912f6c",
"name": "Product 2495",
"sku": "sku 2496",
"updated_datetime": "2025-06-12T15:32:41.389086Z"
},
"quantity": "2"
}
],
"owner_id": "00000000-0000-0000-0000-000000000af0",
"status": "COMPLETED"
}
]
}
GET /public/v1/assemblies returns proper data for biotrack assembly
GET /public/v1/assemblies?completion_datetime=2025-06-12+14%3A32%3A38.717731Z%2C2025-06-12+16%3A32%3A38.717731Z&creation_source=MANUALLY_CREATED&license_number=CDPH-00000475&page[number]=1
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5NTgsImlhdCI6MTc0OTc0MjM1OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMmQ5MzI3YzMtNWIwZS00MWFlLTk0ODAtMWM1MWY2ODE0MDA4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzU3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MjQzNiIsInR5cCI6ImFjY2VzcyJ9.xfQ8aJVkgklKDX9OJXC6hQhhvh9Z1W43ykvpnEdLwRY
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 45cc56518fd2a0000000000000000001-fa4d3d517994bcc6-0
{
"data": [
{
"completion_datetime": "2025-06-12T15:32:38.717731Z",
"compliance_type": "BIOTRACK",
"creation_source": "MANUALLY_CREATED",
"custom_data": [],
"description": null,
"estimated_work_hours": null,
"estimated_work_minutes": null,
"fulfilled": true,
"id": "f07c28c1-90d8-4042-acc4-7ef33d045561",
"is_metrc_processing_job": false,
"license": {
"id": "00000000-0000-0000-0000-0000000001bf",
"license_number": "CDPH-00000475"
},
"outputs": [
{
"additional_costs": [],
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000292",
"name": "B2103"
},
"compliance_label": null,
"compliance_quantity": "1",
"expiration_datetime": null,
"ingredients": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000292",
"name": "B2103"
},
"compliance_quantity": "1",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000087e",
"id": "00000000-0000-0000-0000-0000000002a0",
"license_id": "00000000-0000-0000-0000-0000000001bf",
"name": "Place 665"
},
"package": {
"batch_number": null,
"compliance_label": "101",
"id": "00000000-0000-0000-0000-0000000000a1",
"metrc_label": "101",
"status": "active"
},
"product": {
"id": "209b3cd2-da4e-493a-8ef7-b5c95977f8cc",
"name": "Product 2097",
"sku": "sku 2098",
"updated_datetime": "2025-06-12T15:32:38.481699Z"
},
"quantity": "1",
"total_cost_actual": null,
"total_cost_default": null
}
],
"is_production_batch": false,
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000087e",
"id": "00000000-0000-0000-0000-0000000002a0",
"license_id": "00000000-0000-0000-0000-0000000001bf",
"name": "Place 665"
},
"package": {
"batch_number": null,
"compliance_label": null,
"id": "00000000-0000-0000-0000-0000000000a7",
"metrc_label": null,
"status": "active"
},
"package_datetime": null,
"package_unit_type": {
"id": "00000000-0000-0000-0000-000000007268",
"name": "Gram"
},
"product": {
"id": "209b3cd2-da4e-493a-8ef7-b5c95977f8cc",
"name": "Product 2097",
"sku": "sku 2098",
"updated_datetime": "2025-06-12T15:32:38.481699Z"
},
"quantity": "1"
}
],
"owner_id": "00000000-0000-0000-0000-000000000984",
"status": "COMPLETED"
}
]
}
Get assemblies ordered from oldest to newest by their last modified date.
Note: The page size for this endpoint is 500 assemblies per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/assemblies
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
completion_datetime | Filter assemblies by their completion datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
creation_source | Filter assemblies by their creation source. Options include MANUALLY_CREATED, SPLIT_PACKAGE, SALES_ORDER and LAB_TESTING | query | string | false | ||
license_number | Filter assemblies by their license number | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of assemblies | Assemblies |
Batch
Get batches
GET /public/v1/batches returns batches related to the company
GET /public/v1/batches
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzEsImlhdCI6MTc0OTc0MjUzMSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMDAwNjMyYzktZGU5YS00MWE2LTgyMjItYzUyMGVkY2Y0YjhhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTMwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzAxMTAiLCJ0eXAiOiJhY2Nlc3MifQ.sL5o-o3rm15k6Bpx0ceyIt4x4XHmoyg9NBl7b-1dQdY
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 51fd4111977330000000000000000001-7796f830bf34d947-0
{
"data": [
{
"batch_number": null,
"custom_data": [
{
"id": 89,
"name": "Custom Field 119",
"value": "Custom Data 1"
}
],
"description": null,
"expiration_date": "2024-01-01T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-0000000021af",
"name": "B26394",
"owner_id": "00000000-0000-0000-0000-0000000075a5",
"primary_test_result": null,
"product_id": "6629e5f6-b1de-4085-a08f-eeae543bc818"
},
{
"batch_number": null,
"custom_data": [
{
"id": 89,
"name": "Custom Field 119",
"value": null
}
],
"description": null,
"expiration_date": null,
"id": "00000000-0000-0000-0000-0000000021b0",
"name": "B26397",
"owner_id": "00000000-0000-0000-0000-0000000075ad",
"primary_test_result": {
"cbd_mg_per_unit": "1",
"cbd_mg_per_unit_total": "2",
"cbd_percentage": "3",
"cbd_percentage_total": "4",
"mg_per_unit_type": "mg/mL",
"name": "File.pdf",
"thc_mg_per_unit": "5",
"thc_mg_per_unit_total": "6",
"thc_percentage": "7",
"thc_percentage_total": "8"
},
"product_id": "a090b16b-ccdf-4065-b339-54d7b01abea8"
}
]
}
Get batches sorted by their creation date and filtered by various attributes.
Note: The page size for this endpoint is 5000 batches per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/batches
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter batches by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter batches by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of batches | Batches |
Create a batch
POST /public/v1/batches Errors from service messages are properly reflected in the response
POST /public/v1/batches
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMjYsImlhdCI6MTc0OTc0MjUyNiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNDZmNTBjMzUtNmJkMC00MDViLTkyNWUtMzQ0ZTRmMjA4NWNmIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTI1LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6Mjk2NTQiLCJ0eXAiOiJhY2Nlc3MifQ._dqPCMbuzkWI3JvFRPO9WxNRr-4Ib2FVTg0MvSwY4E0
{
"owner_id": "a86c43f8-2652-48f4-9ac2-84222ef48a57",
"product_id": "fcfa73a3-dbea-460f-8f93-d10942eb34ea"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 8561b99da4b710000000000000000001-d022030b2fcd2fa3-0
{
"errors": [
{
"context": {},
"message": "Owner not found",
"pointer": [
"owner_id"
],
"section": "body"
},
{
"context": {},
"message": "Product not found",
"pointer": [
"product_id"
],
"section": "body"
},
{
"context": {},
"message": "Unable to verify inventory tracking method",
"pointer": [
"product_id"
],
"section": "body"
}
]
}
POST /public/v1/batches Can create batch with all optional fields missing
POST /public/v1/batches
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzAsImlhdCI6MTc0OTc0MjUzMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMzcyN2M2ZDctMzIxMC00NGU0LWJjZGYtOTM4ZTdlNDNlNTgzIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTI5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6Mjk5NTIiLCJ0eXAiOiJhY2Nlc3MifQ.CVJruHKl-buPQ5IddNeZOhUszuX_1PpTU0Wx3YMDNps
{
"product_id": "8da641f6-b5f8-4bd5-b74f-2453ffac3bec"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: a086881b30ceb0000000000000000001-639f4a45d96198e0-0
{
"data": {
"batch_number": null,
"custom_data": [],
"description": null,
"expiration_date": null,
"id": "00000000-0000-0000-0000-00000000218f",
"name": "B1",
"owner_id": null,
"product_id": "8da641f6-b5f8-4bd5-b74f-2453ffac3bec"
}
}
POST /public/v1/batches Can create batch with all optional fields provided
POST /public/v1/batches
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzAsImlhdCI6MTc0OTc0MjUzMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzBiMTdmOGQtMGY0YS00YzIyLWI5MTYtMTBiOTFmYzI5ZTU2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTI5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzAwMTEiLCJ0eXAiOiJhY2Nlc3MifQ.Im9ox5ONREGOFpH2e6oQemndCabS5DUZudh0LdRe7Mw
{
"batch_number": "B1",
"description": "Test batch",
"expiration_date": "2025-01-01T00:00:00.000000Z",
"owner_id": "00000000-0000-0000-0000-000000007547",
"product_id": "c8c8ec4a-5584-4f4f-a654-6b3442dc3d32"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 7d73800118d0f8000000000000000001-7e1480d19358dc75-0
{
"data": {
"batch_number": "B1",
"custom_data": [],
"description": "Test batch",
"expiration_date": "2025-01-01T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-00000000219c",
"name": "B1",
"owner_id": "00000000-0000-0000-0000-000000007547",
"product_id": "c8c8ec4a-5584-4f4f-a654-6b3442dc3d32"
}
}
Create a single batch.
Request
POST /public/v1/batches
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
product_id | The ID of the product that this batch belongs to. | query | string | false | ||
batch_number | The batch number of the batch. | query | string | false | ||
expiration_date | The expiration date of the batch. | query | string | false | ||
owner_id | The ID of the user that is the designated owner of this batch. | query | string | false | ||
description | The description of the batch. | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A single batch | Batch |
Company
Get companies
GET /public/companies returns companies related to the company
GET /public/v1/companies
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIyMzksImlhdCI6MTc0OTc0MjYzOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMzVmODU3YjUtZDMzYS00NTBkLTgwYWEtNDFiZjcwMDJmOTI4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNjM4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NDgwNTAiLCJ0eXAiOiJhY2Nlc3MifQ.GyO1iqdtrd5iEnNndFUF_ZVXHr4BdwqNd7MZ7wBgb7o
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: dab7ee784e61c8000000000000000001-617303c442cbf9e9-0
{
"data": [
{
"category": "Retailer",
"custom_data": [
{
"id": 174,
"name": "Custom Field 195",
"value": "Custom Data 1"
}
],
"default_email": "company-1@example.com",
"default_purchase_order_notes": "Default Purchase Order Notes 1",
"default_sales_order_notes": "Default Order External Notes 1",
"id": "00000000-0000-0000-0000-0000000050d6",
"invoice_email": "invoice email",
"legal_business_name": "Company Legal Name 1",
"licenses": [],
"locations": [
{
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000008bbf",
"id": "00000000-0000-0000-0000-000000003ba1",
"license_id": null,
"name": "Place 15068"
}
],
"name": "Company 35626",
"order_shipment_email": "order shipment email",
"outstanding_balance_threshold": 1000,
"owner_id": "00000000-0000-0000-0000-00000000bbbf",
"phone_number": "1234567890",
"purchase_order_email": "purchase email",
"relationship_type": {
"id": "00000000-0000-0000-0000-0000000002a5",
"name": "Supplier"
},
"sales_order_email": "order email",
"updated_datetime": "2023-11-03T00:00:00.000000Z",
"website": "https://www.example.com"
},
{
"category": "Other",
"custom_data": [
{
"id": 174,
"name": "Custom Field 195",
"value": null
}
],
"default_email": "company-83645@example.com",
"default_purchase_order_notes": null,
"default_sales_order_notes": null,
"id": "00000000-0000-0000-0000-0000000050da",
"invoice_email": null,
"legal_business_name": "Company Legal Name 35630",
"licenses": [
{
"id": "00000000-0000-0000-0000-0000000022c6",
"license_number": "CDPH-00009966"
}
],
"locations": [],
"name": "Company 35630",
"order_shipment_email": null,
"outstanding_balance_threshold": null,
"owner_id": null,
"phone_number": null,
"purchase_order_email": null,
"relationship_type": null,
"sales_order_email": null,
"updated_datetime": "2023-12-02T00:00:00.000000Z",
"website": null
}
]
}
Get companies sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 5000 companies per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/companies
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter companies by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter companies by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of companies | Companies |
Contact
Get contacts
GET /public/v1/contacts returns contacts related to the company
GET /public/v1/contacts
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIyMzUsImlhdCI6MTc0OTc0MjYzNSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNWRlNGE5MTMtMGQ0Yy00OWUyLWI2YTgtNDcxYWI0NDRiYzk0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNjM0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NDczMDgiLCJ0eXAiOiJhY2Nlc3MifQ.Ey1QSP6Ene_bXqV98SxZDT1YfbVofiHNEoVs7b04QSc
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: fc54a8693814b0000000000000000001-7a13353d2a4746c1-0
{
"data": [
{
"company": {
"id": "00000000-0000-0000-0000-000000004f8c"
},
"custom_data": [
{
"id": 173,
"name": "Custom Field 194",
"value": "Custom Data 1"
}
],
"email": "email1",
"full_name": "FirstName93937 LastName93938",
"id": "00000000-0000-0000-0000-0000000000f2",
"owner": {
"id": "00000000-0000-0000-0000-00000000b8cf"
},
"phone_number": "1234567890",
"title": null
},
{
"company": {
"id": "00000000-0000-0000-0000-000000004f8f"
},
"custom_data": [
{
"id": 173,
"name": "Custom Field 194",
"value": null
}
],
"email": "email2",
"full_name": "FirstName93939 LastName93940",
"id": "00000000-0000-0000-0000-0000000000f3",
"owner": {
"id": "00000000-0000-0000-0000-00000000b8d5"
},
"phone_number": "1234567890",
"title": null
}
]
}
Get contacts sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 1000 contacts per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/contacts
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter contacts by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter contacts by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of contacts | Contacts |
FileAttachment
Insert a file attachment
POST /public/v1/file-attachments uploads and creates a file attachment successfully with simplified reference
POST /public/v1/file-attachments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjksImlhdCI6MTc0OTc0MjQyOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMGYwNWQ4ZGItM2M4NS00YzgxLWIzZTktMDllZWJmMWViYWU1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDI4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTIwNjkiLCJ0eXAiOiJhY2Nlc3MifQ.ecSQ0_QD56eJNzW0mocgEWJazlVv_jvQ08ekal8e_-g
{
"file": {
"content_type": "image/png",
"filename": "test-image.png"
},
"name": "My Test Image",
"product_id": "1b101267-b70a-4338-85f7-d311229ad460"
}
Response
201
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 8c473be7617070000000000000000001-2b04c2b346416ca2-0
{
"data": {
"assembly_id": null,
"batch_id": null,
"company_relationship_id": null,
"contact_id": null,
"id": "00000000-0000-0000-0000-000000000032",
"invoice_id": null,
"license_id": null,
"mime_type": "image/png",
"name": "My Test Image",
"order_id": null,
"order_shipment_id": null,
"product_id": "1b101267-b70a-4338-85f7-d311229ad460",
"purchase_id": null,
"request_id": null,
"return_id": null,
"size_in_bytes": 355974,
"stock_transfer_id": null,
"task_id": null,
"upload_datetime": "2025-06-12T15:33:49.754979Z",
"uploader": {
"id": "00000000-0000-0000-0000-000000002f25",
"name": "FirstName24000 LastName24001"
},
"url": "/var/folders/j1/6rk0jm4s1l3bts_p6m88jd4r0000gn/T/382b4dad-bb54-4d1f-a3d1-a9d6af9367e0/test-image.png"
}
}
Insert a new file attachment. The file will be uploaded to S3 and associated with the specified entity. Exactly one reference ID must be provided (product_id, order_id, purchase_id, etc.).
Request
POST /public/v1/file-attachments
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
file | The file to upload | formData | file | true | ||
name | Display name for the attachment (defaults to filename if not provided) | formData | string | false | ||
product_id | Product ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
order_id | Order ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
purchase_id | Purchase ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
invoice_id | Invoice ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
batch_id | Batch ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
contact_id | Contact ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
company_relationship_id | Company relationship ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
request_id | Request ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
task_id | Task ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
stock_transfer_id | Stock transfer ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
assembly_id | Assembly ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
return_id | Return ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
order_shipment_id | Order shipment ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 | |
license_id | License ID to attach file to | formData | string | false | 550e8400-e29b-41d4-a716-446655440000 |
Responses
Status | Description | Schema |
---|---|---|
201 | File attachment inserted successfully | FileAttachment |
400 | Invalid parameters | |
422 | Storage quota exceeded or other validation error |
Inventory
Get inventory levels
GET /public/inventory returns stock quantities filtered by product IDs
GET /public/v1/inventory?grouping[]=PRODUCT&product_ids[]=161a4ff9-9170-4e3b-a9e1-e437acdb2c92
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDcsImlhdCI6MTc0OTc0MjQwNywiaXNzIjoiRGlzdHJ1IiwianRpIjoiODE1ZmVhNTItYjY0Yy00MjlkLThkZmMtMmI1ZmU3YzU3ZTQ1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDA2LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6OTI1MSIsInR5cCI6ImFjY2VzcyJ9.2C0VqjnfogUusIwbDU7kuf4KTF9X8mlJB-bp6QaYWTM
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: b5daa42dc0d540000000000000000001-fb7bbe1d3c325104-0
{
"data": [
{
"active": "10.000000000",
"available": "10.000000000",
"product_id": "161a4ff9-9170-4e3b-a9e1-e437acdb2c92",
"updated_datetime": "2025-06-12T15:33:27.221594Z"
}
]
}
GET /public/inventory returns stock quantities grouped by product
GET /public/v1/inventory?grouping[]=PRODUCT
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDAsImlhdCI6MTc0OTc0MjQwMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzBhZDNiZmQtZjNmMy00OWQyLWEyYzYtNWI4OGIyOTE2YmU1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzk5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODQ4MCIsInR5cCI6ImFjY2VzcyJ9.PtJSIRqLGg8Mu4kIwHa9tOiONPJbVltm9yspkumCbFc
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 2cf2095b99dad8000000000000000001-2f96e0ad88a1a41a-0
{
"data": [
{
"active": "95.000000000",
"available": "80.000000000",
"product_id": "7425c719-8f50-4115-b81b-342a81640738",
"updated_datetime": "2023-11-06T00:00:00.000000Z"
},
{
"active": "50.000000000",
"available": "50.000000000",
"product_id": "b49cfe51-cdee-4897-986d-726f42cb900f",
"updated_datetime": "2023-11-05T00:00:00.000000Z"
},
{
"active": "100.000000000",
"available": "90.000000000",
"product_id": "ed8507db-a274-48a9-9a0c-3ea7939057f8",
"updated_datetime": "2023-12-03T00:00:00.000000Z"
}
]
}
GET /public/inventory returns stock quantities grouped by product & location
GET /public/v1/inventory?grouping[]=PRODUCT&grouping[]=LOCATION
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDQsImlhdCI6MTc0OTc0MjQwNCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTMxOGU0MmMtMTg4YS00OTk1LTllOGItZDgzMTU1ZTg4ODQ3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDAzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODkxOCIsInR5cCI6ImFjY2VzcyJ9.5k76N-GzaqvQJOjkPa6VMQ0qSTgrAwr6rzZdXNekC2o
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 7ffd081ab206b0000000000000000001-0ba8f22a9eeaaec8-0
{
"data": [
{
"active": "100.000000000",
"available": "100.000000000",
"location_id": "00000000-0000-0000-0000-000000000ae0",
"product_id": "359b50b7-9570-4c31-9dcc-8e3ef076800b",
"updated_datetime": "2030-09-01T00:00:00.000000Z"
},
{
"active": "30.000000000",
"available": "26.000000000",
"location_id": null,
"product_id": "359b50b7-9570-4c31-9dcc-8e3ef076800b",
"updated_datetime": "2030-10-07T00:00:00.000000Z"
},
{
"active": "100.000000000",
"available": "85.000000000",
"location_id": "00000000-0000-0000-0000-000000000ade",
"product_id": "3cf1a9e1-801d-4cda-a85e-ae4f4af8cb60",
"updated_datetime": "2030-10-03T00:00:00.000000Z"
},
{
"active": "90.000000000",
"available": "82.000000000",
"location_id": "00000000-0000-0000-0000-000000000ae0",
"product_id": "3cf1a9e1-801d-4cda-a85e-ae4f4af8cb60",
"updated_datetime": "2030-10-04T00:00:00.000000Z"
},
{
"active": "150.000000000",
"available": "129.000000000",
"location_id": "00000000-0000-0000-0000-000000000ae2",
"product_id": "3cf1a9e1-801d-4cda-a85e-ae4f4af8cb60",
"updated_datetime": "2030-10-05T00:00:00.000000Z"
},
{
"active": "0.000000000",
"available": "-1.000000000",
"location_id": null,
"product_id": "3cf1a9e1-801d-4cda-a85e-ae4f4af8cb60",
"updated_datetime": "2030-10-08T00:00:00.000000Z"
},
{
"active": "100.000000000",
"available": "90.000000000",
"location_id": "00000000-0000-0000-0000-000000000ade",
"product_id": "95b9f765-c411-4cfa-a410-0b9abfd3fba2",
"updated_datetime": "2030-10-01T00:00:00.000000Z"
},
{
"active": "0.000000000",
"available": "-1.000000000",
"location_id": "00000000-0000-0000-0000-000000000ae0",
"product_id": "95b9f765-c411-4cfa-a410-0b9abfd3fba2",
"updated_datetime": "2030-10-02T00:00:00.000000Z"
}
]
}
GET /public/inventory returns stock quantities grouped by product & batch number
GET /public/v1/inventory?grouping[]=PRODUCT&grouping[]=BATCH_NUMBER
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5OTUsImlhdCI6MTc0OTc0MjM5NSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTI0YWZlYTItNWU3Yi00NTdkLWE5YmQtMGY4NjJhMjE5Mjk1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzk0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6Nzg3NCIsInR5cCI6ImFjY2VzcyJ9.lwWcyVbm-kSFmrgj6YTtktXm0w0mtn2ucxfXIFTx7HA
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: c1f6253969e598000000000000000001-0ff8767e1829eb51-0
{
"data": [
{
"active": "43.000000000",
"available": "43.000000000",
"batch_number": null,
"product_id": "11d4dfaa-60b4-40c3-a497-787a20ee6acf",
"updated_datetime": "2030-11-02T00:00:00.000000Z"
},
{
"active": "47.000000000",
"available": "47.000000000",
"batch_number": "1",
"product_id": "11d4dfaa-60b4-40c3-a497-787a20ee6acf",
"updated_datetime": "2030-11-04T00:00:00.000000Z"
},
{
"active": "25.000000000",
"available": "25.000000000",
"batch_number": "2",
"product_id": "11d4dfaa-60b4-40c3-a497-787a20ee6acf",
"updated_datetime": "2030-11-05T00:00:00.000000Z"
},
{
"active": "8.000000000",
"available": "8.000000000",
"batch_number": "TEST-1",
"product_id": "6b5e2f63-ec83-4b99-a4f5-2921af29e843",
"updated_datetime": "2030-09-01T00:00:00.000000Z"
},
{
"active": "19.000000000",
"available": "19.000000000",
"batch_number": null,
"product_id": "b4cbc3cd-b1ac-471a-882f-6b8674c54c27",
"updated_datetime": "2030-10-02T00:00:00.000000Z"
},
{
"active": "13.000000000",
"available": "13.000000000",
"batch_number": "TEST-1",
"product_id": "b4cbc3cd-b1ac-471a-882f-6b8674c54c27",
"updated_datetime": "2030-10-04T00:00:00.000000Z"
},
{
"active": "26.000000000",
"available": "26.000000000",
"batch_number": null,
"product_id": "d2acff7c-31b6-4ccb-9706-29435ed97d06",
"updated_datetime": "2030-12-01T00:00:00.000000Z"
},
{
"active": "27.000000000",
"available": "27.000000000",
"batch_number": "1",
"product_id": "d2acff7c-31b6-4ccb-9706-29435ed97d06",
"updated_datetime": "2030-12-02T00:00:00.000000Z"
}
]
}
GET /public/inventory returns stock quantities grouped by product & location & batch number
GET /public/v1/inventory?grouping[]=PRODUCT&grouping[]=LOCATION&grouping[]=BATCH_NUMBER
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDIsImlhdCI6MTc0OTc0MjQwMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZWRjMDQ1NzgtOGUxMS00ODE1LWI0MjctNjc4ODE2MDI3OTI5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDAxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODY4OCIsInR5cCI6ImFjY2VzcyJ9.4aJLovMMISg5clQWjHqxeIStHa-ctR-5cmjvE_TpxrU
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 2e3219bb33b81e000000000000000001-a0a6686550a06a5b-0
{
"data": [
{
"active": "41.000000000",
"available": "41.000000000",
"batch_number": null,
"location_id": "00000000-0000-0000-0000-000000000a93",
"product_id": "a79283c9-a12f-40a9-9880-ffb9a4a42e8e",
"updated_datetime": "2031-01-02T00:00:00.000000Z"
},
{
"active": "49.000000000",
"available": "49.000000000",
"batch_number": "TEST-1",
"location_id": "00000000-0000-0000-0000-000000000a93",
"product_id": "a79283c9-a12f-40a9-9880-ffb9a4a42e8e",
"updated_datetime": "2031-02-02T00:00:00.000000Z"
},
{
"active": "45.000000000",
"available": "45.000000000",
"batch_number": null,
"location_id": "00000000-0000-0000-0000-000000000a94",
"product_id": "a79283c9-a12f-40a9-9880-ffb9a4a42e8e",
"updated_datetime": "2031-01-04T00:00:00.000000Z"
},
{
"active": "53.000000000",
"available": "53.000000000",
"batch_number": "TEST-1",
"location_id": "00000000-0000-0000-0000-000000000a94",
"product_id": "a79283c9-a12f-40a9-9880-ffb9a4a42e8e",
"updated_datetime": "2031-02-04T00:00:00.000000Z"
},
{
"active": "21.000000000",
"available": "21.000000000",
"batch_number": null,
"location_id": "00000000-0000-0000-0000-000000000a93",
"product_id": "a80db09c-5b80-4e7d-951a-bb8533ffee1b",
"updated_datetime": "2030-11-02T00:00:00.000000Z"
},
{
"active": "29.000000000",
"available": "29.000000000",
"batch_number": "TEST-1",
"location_id": "00000000-0000-0000-0000-000000000a93",
"product_id": "a80db09c-5b80-4e7d-951a-bb8533ffee1b",
"updated_datetime": "2030-12-02T00:00:00.000000Z"
},
{
"active": "25.000000000",
"available": "25.000000000",
"batch_number": null,
"location_id": "00000000-0000-0000-0000-000000000a94",
"product_id": "a80db09c-5b80-4e7d-951a-bb8533ffee1b",
"updated_datetime": "2030-11-04T00:00:00.000000Z"
},
{
"active": "33.000000000",
"available": "33.000000000",
"batch_number": "TEST-1",
"location_id": "00000000-0000-0000-0000-000000000a94",
"product_id": "a80db09c-5b80-4e7d-951a-bb8533ffee1b",
"updated_datetime": "2030-12-04T00:00:00.000000Z"
}
]
}
Get active and available quantities grouped by a specified list of attributes. Groups with 0 active and 0 available quantity won't be returned. Groups are sorted by the IDs of the attributes they are grouped by. Note: The page size for this endpoint is 5000 groups per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/inventory
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
grouping | Attributes to group inventory by. PRODUCT is required to be in the list. Accepted values are "BATCH_NUMBER", "LOCATION" and "PRODUCT". | query | array | false | ["PRODUCT","LOCATION"] | |
page | Pagination information | body | Page | false | ||
product_ids | Filter inventory levels by product IDs | query | array | false | ["67ae9080-8dc2-4ab7-9704-19673f4d9f21","213c7080-8dc2-4ab7-9704-19673f4d9f22"] |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of active and available quantity for each group | Inventories |
Invoice
Get invoices
GET /invoices/ returns invoices related to the access token's company
GET /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNjQsImlhdCI6MTc0OTc0MjU2NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYWRmY2EzM2YtNmNjMS00NWI0LTgzNDMtNDQ3ZjQ5NDdlODU2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTYzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzUyODciLCJ0eXAiOiJhY2Nlc3MifQ.5jyM9E0K8veJCNQwS9Dm5jBNrsOR1TxSUeHCoC__xwE
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 3a474d8117d77a000000000000000001-b5def3bfe7518a07-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000003b1e",
"name": "Company 26415",
"updated_datetime": "2025-06-12T15:36:05.332782Z"
},
"creator": {
"banned": false,
"email": "owner-35621@example.com",
"full_name": "FirstName70253 LastName70254",
"id": "00000000-0000-0000-0000-000000008a36",
"role": {
"id": "00000000-0000-0000-0000-000000008a63",
"name": "Admin 35355"
}
},
"custom_data": [
{
"id": 104,
"name": "Custom Field 133",
"value": null
}
],
"due_datetime": "2025-06-12T15:36:05.639182Z",
"id": "00000000-0000-0000-0000-000000000266",
"inserted_datetime": "2025-06-12T15:36:05.641595Z",
"invoice_datetime": "2025-06-12T15:36:05.639180Z",
"invoice_number": "Invoice #528",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002746",
"name": "B30625"
},
"id": "00000000-0000-0000-0000-0000000002ef",
"order_item_id": "ae0b9aa5-812a-4ba0-b09d-310191b8357b",
"package": null,
"price": "10.000000000",
"product": {
"id": "fc0c4bdf-2eb9-49ed-9823-0df7e20ce951",
"name": "Product 30621",
"sku": "sku 30622",
"updated_datetime": "2025-06-12T15:36:05.379332Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000274c",
"name": "B30639"
},
"id": "00000000-0000-0000-0000-0000000002f0",
"order_item_id": "144d7fe8-35cc-4d44-be89-633258811536",
"package": null,
"price": "10.000000000",
"product": {
"id": "88a6aeb8-6b82-45b7-a78c-ae252710851f",
"name": "Product 30635",
"sku": "sku 30636",
"updated_datetime": "2025-06-12T15:36:05.418546Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "d08dce34-61a0-4165-8866-1dd71cfc4ed6",
"order_number": "SO-1929",
"status": "Pending",
"total": "320.00"
},
"owner": {
"banned": false,
"email": "owner-35621@example.com",
"full_name": "FirstName70253 LastName70254",
"id": "00000000-0000-0000-0000-000000008a36",
"role": {
"id": "00000000-0000-0000-0000-000000008a63",
"name": "Admin 35355"
}
},
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:36:05.641595Z"
},
{
"charges": [
{
"id": "c7fc4a08-39c6-4b6f-8e06-3bfe6778fc3f",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000003b07",
"name": "Company 26371",
"updated_datetime": "2025-06-12T15:36:04.870490Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-0000000089cf",
"role": {
"id": "00000000-0000-0000-0000-0000000089fc",
"name": "Admin 35253"
}
},
"custom_data": [
{
"id": 104,
"name": "Custom Field 133",
"value": "Custom Field Value 1"
}
],
"due_datetime": "2020-01-01T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-000000000262",
"inserted_datetime": "2025-06-12T15:36:04.946855Z",
"invoice_datetime": "2020-01-01T00:00:02.000000Z",
"invoice_number": "INV-123",
"items": [
{
"batch": {
"batch_number": "UID1",
"id": "00000000-0000-0000-0000-00000000272d",
"name": "B1"
},
"id": "00000000-0000-0000-0000-0000000002e9",
"order_item_id": "6d6f15ec-311a-424d-87ea-aa293ed31ac7",
"package": {
"batch_number": "B1",
"compliance_label": "ABCDEF012345670000008822",
"id": "00000000-0000-0000-0000-000000000b6f",
"metrc_label": "ABCDEF012345670000008822",
"status": "active"
},
"price": "10.000000000",
"product": {
"id": "bec1e0eb-1b12-4411-950d-0abaecc019ce",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:36:04.785771Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "e2072dd0-a139-441d-964d-fcfffa6eca47",
"order_number": "SO-123",
"status": "Completed",
"total": "10.00"
},
"owner": {
"banned": false,
"email": "user2@a.com",
"full_name": "John Bar",
"id": "00000000-0000-0000-0000-0000000089d4",
"role": {
"id": "00000000-0000-0000-0000-000000008a01",
"name": "Admin 35258"
}
},
"paid_amount": "5.00",
"status": "PARTIALLY_PAID",
"total": "8.00",
"updated_datetime": "2025-06-12T15:36:05.051210Z"
}
]
}
GET /invoices/ returns cost/returned_quantity data for invoice items
GET /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDIsImlhdCI6MTc0OTc0MjU0MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzFmYjI4OWQtMDc3Yi00Njg0LTlkOTYtYjU2MTliMGUzNGQwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE5NjciLCJ0eXAiOiJhY2Nlc3MifQ.bROYAbd7lvbFZ5h_uauy5Qz3IYezPBINgvmxjNhAYAQ
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 081d605547e2b9800000000000000001-8a03d5dd5f4b3d4c-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000003551",
"name": "Company 24068",
"updated_datetime": "2025-06-12T15:35:42.636362Z"
},
"creator": {
"banned": false,
"email": "owner-32358@example.com",
"full_name": "FirstName63793 LastName63794",
"id": "00000000-0000-0000-0000-000000007d6a",
"role": {
"id": "00000000-0000-0000-0000-000000007dd7",
"name": "Admin 32144"
}
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:42.973229Z",
"id": "00000000-0000-0000-0000-0000000001d8",
"inserted_datetime": "2025-06-12T15:35:42.974254Z",
"invoice_datetime": "2025-06-12T15:35:42.973226Z",
"invoice_number": "Invoice #401",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000239a",
"name": "B27847"
},
"id": "00000000-0000-0000-0000-00000000025a",
"order_item_id": "d06ba405-5dd8-422f-8c9f-0dd5a24b882c",
"package": null,
"price": "908270.000000000",
"product": {
"id": "b5db6ebc-eda5-42de-b15d-1fe5a2132aeb",
"name": "Product 27845",
"sku": "sku 27846",
"updated_datetime": "2025-06-12T15:35:42.475745Z"
},
"quantity": "2.000000000",
"returned_quantity": "2",
"total_cost_actual": "20.052",
"total_cost_default": "10"
}
],
"order": {
"id": "ff43c449-587b-4b3c-bd34-b29bfb0aa69c",
"order_number": "SO-0000001",
"status": "Processing",
"total": "1816540.00"
},
"owner": {
"banned": false,
"email": "owner-32358@example.com",
"full_name": "FirstName63793 LastName63794",
"id": "00000000-0000-0000-0000-000000007d6a",
"role": {
"id": "00000000-0000-0000-0000-000000007dd7",
"name": "Admin 32144"
}
},
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:42.974254Z"
}
]
}
GET /invoices/ allows filtering by several statuses
GET /public/v1/invoices?status[]=Fully+Paid&status[]=Not+Paid
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzcsImlhdCI6MTc0OTc0MjUzNywiaXNzIjoiRGlzdHJ1IiwianRpIjoiODYxM2JiMzgtNzQ1NC00NDBjLWIwOTAtZTQ3YzQ5ZGQxNmM0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTM2LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzEyMzQiLCJ0eXAiOiJhY2Nlc3MifQ.ZlN2C2xzl4KlbZFvkx3CbcJjEPQrYwdOq9XYXZx0-qg
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: cb015aeef97808000000000000000001-ddebd5f1f0e16d8c-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000003444",
"name": "Company 23595",
"updated_datetime": "2025-06-12T15:35:39.042585Z"
},
"creator": {
"banned": false,
"email": "owner-31728@example.com",
"full_name": "FirstName62545 LastName62546",
"id": "00000000-0000-0000-0000-000000007af3",
"role": {
"id": "00000000-0000-0000-0000-000000007b73",
"name": "Admin 31532"
}
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:39.611976Z",
"id": "00000000-0000-0000-0000-0000000001cb",
"inserted_datetime": "2025-06-12T15:35:39.614222Z",
"invoice_datetime": "2020-01-01T12:30:00.000000Z",
"invoice_number": "Invoice #390",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022f8",
"name": "B27383"
},
"id": "00000000-0000-0000-0000-00000000024c",
"order_item_id": "d8dc58c3-1bd6-4d60-93cb-6c1667342011",
"package": null,
"price": "10.000000000",
"product": {
"id": "3c113dd3-9916-408d-8c14-1fb06e1ff52e",
"name": "Product 27381",
"sku": "sku 27382",
"updated_datetime": "2025-06-12T15:35:39.092288Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022fd",
"name": "B27396"
},
"id": "00000000-0000-0000-0000-00000000024d",
"order_item_id": "3ea00d36-2b48-49b3-9180-9ee6146a0a29",
"package": null,
"price": "10.000000000",
"product": {
"id": "679f4ee8-6002-4b01-9a03-54ecf6ec8068",
"name": "Product 27394",
"sku": "sku 27395",
"updated_datetime": "2025-06-12T15:35:39.345997Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "c4d4c850-6e51-4898-99ff-9fdc537eef7e",
"order_number": "SO-1616",
"status": "Pending",
"total": "320.00"
},
"owner": {
"banned": false,
"email": "owner-31728@example.com",
"full_name": "FirstName62545 LastName62546",
"id": "00000000-0000-0000-0000-000000007af3",
"role": {
"id": "00000000-0000-0000-0000-000000007b73",
"name": "Admin 31532"
}
},
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:39.614222Z"
},
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000341b",
"name": "Company 23527",
"updated_datetime": "2025-06-12T15:35:38.512973Z"
},
"creator": {
"banned": false,
"email": "owner-31659@example.com",
"full_name": "FirstName62411 LastName62412",
"id": "00000000-0000-0000-0000-000000007aaf",
"role": {
"id": "00000000-0000-0000-0000-000000007b2d",
"name": "Admin 31462"
}
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:38.897266Z",
"id": "00000000-0000-0000-0000-0000000001c9",
"inserted_datetime": "2025-06-12T15:35:38.899626Z",
"invoice_datetime": "2020-01-01T12:20:00.000000Z",
"invoice_number": "Invoice #389",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022e2",
"name": "B27315"
},
"id": "00000000-0000-0000-0000-000000000247",
"order_item_id": "85547f42-ea96-47d6-9fc8-66e8061cfc5e",
"package": null,
"price": "10.000000000",
"product": {
"id": "648c87b7-f7e1-4a0a-a2f6-cde286a7283f",
"name": "Product 27313",
"sku": "sku 27314",
"updated_datetime": "2025-06-12T15:35:38.543588Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022e4",
"name": "B27325"
},
"id": "00000000-0000-0000-0000-000000000248",
"order_item_id": "9d6a8073-279b-4548-9f9a-6eef4eae505a",
"package": null,
"price": "10.000000000",
"product": {
"id": "6020b653-1add-43f3-b8fb-6831360e8e95",
"name": "Product 27323",
"sku": "sku 27324",
"updated_datetime": "2025-06-12T15:35:38.605204Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "5733eadb-c00f-4288-81d6-775f47cc6dc6",
"order_number": "SO-1609",
"status": "Pending",
"total": "320.00"
},
"owner": {
"banned": false,
"email": "owner-31659@example.com",
"full_name": "FirstName62411 LastName62412",
"id": "00000000-0000-0000-0000-000000007aaf",
"role": {
"id": "00000000-0000-0000-0000-000000007b2d",
"name": "Admin 31462"
}
},
"paid_amount": "0.0",
"status": "FULLY_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:38.899626Z"
},
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-0000000033c8",
"name": "Company 23382",
"updated_datetime": "2025-06-12T15:35:37.703415Z"
},
"creator": {
"banned": false,
"email": "owner-31489@example.com",
"full_name": "FirstName62067 LastName62068",
"id": "00000000-0000-0000-0000-000000007a04",
"role": {
"id": "00000000-0000-0000-0000-000000007a8f",
"name": "Admin 31304"
}
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:37.975309Z",
"id": "00000000-0000-0000-0000-0000000001c7",
"inserted_datetime": "2025-06-12T15:35:37.977386Z",
"invoice_datetime": "2020-01-01T12:00:00.000000Z",
"invoice_number": "Invoice #387",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022b9",
"name": "B27186"
},
"id": "00000000-0000-0000-0000-000000000243",
"order_item_id": "d2a43be3-9bb0-4963-8e4c-4773cac19b68",
"package": null,
"price": "10.000000000",
"product": {
"id": "b2431dd3-6f77-49fc-9fc1-fd0c9f494e2f",
"name": "Product 27183",
"sku": "sku 27184",
"updated_datetime": "2025-06-12T15:35:37.747001Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022bd",
"name": "B27200"
},
"id": "00000000-0000-0000-0000-000000000244",
"order_item_id": "ecc81e14-a80c-48bd-b605-3c0604cc4d3a",
"package": null,
"price": "10.000000000",
"product": {
"id": "20e00f82-0598-4134-8844-a8faaf050f66",
"name": "Product 27198",
"sku": "sku 27199",
"updated_datetime": "2025-06-12T15:35:37.788207Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "c983c485-099e-4e64-84d2-382d5bfc2eda",
"order_number": "SO-1603",
"status": "Pending",
"total": "320.00"
},
"owner": {
"banned": false,
"email": "owner-31489@example.com",
"full_name": "FirstName62067 LastName62068",
"id": "00000000-0000-0000-0000-000000007a04",
"role": {
"id": "00000000-0000-0000-0000-000000007a8f",
"name": "Admin 31304"
}
},
"paid_amount": "0.0",
"status": "FULLY_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:37.977386Z"
}
]
}
GET /invoices/:id returns cost/returned_quantity data for invoice items
GET /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDMsImlhdCI6MTc0OTc0MjU0MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiNGUwZmQ1YjUtMjZiMC00NjU2LTliYTktZWVkOTNmNDEwM2Q5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzIxNDEiLCJ0eXAiOiJhY2Nlc3MifQ.zpfvpxa_YK0LbWcAdCGRINCkZI3t2yid87W5ogcZuu8
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 40adf4ee581f1c000000000000000001-6de989e917bcdd45-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000003586",
"name": "Company 24160",
"updated_datetime": "2025-06-12T15:35:43.260514Z"
},
"creator": {
"banned": false,
"email": "owner-32507@example.com",
"full_name": "FirstName64091 LastName64092",
"id": "00000000-0000-0000-0000-000000007dff",
"role": {
"id": "00000000-0000-0000-0000-000000007e64",
"name": "Admin 32285"
}
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:43.603064Z",
"id": "00000000-0000-0000-0000-0000000001dd",
"inserted_datetime": "2025-06-12T15:35:43.604580Z",
"invoice_datetime": "2025-06-12T15:35:43.603062Z",
"invoice_number": "Invoice #405",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023ba",
"name": "B27937"
},
"id": "00000000-0000-0000-0000-00000000025b",
"order_item_id": "00468be6-a57a-40bb-97c0-8d8de4e5d64d",
"package": null,
"price": "337873.000000000",
"product": {
"id": "18a7b343-d0b9-4613-889d-ef28399ec0d2",
"name": "Product 27932",
"sku": "sku 27933",
"updated_datetime": "2025-06-12T15:35:43.135683Z"
},
"quantity": "1.000000000",
"returned_quantity": "1",
"total_cost_actual": "10.026",
"total_cost_default": "5"
}
],
"order": {
"id": "3ad0617a-7b4d-4c1b-8d88-46daf76e3815",
"order_number": "SO-0000001",
"status": "Processing",
"total": "675746.00"
},
"owner": {
"banned": false,
"email": "owner-32507@example.com",
"full_name": "FirstName64091 LastName64092",
"id": "00000000-0000-0000-0000-000000007dff",
"role": {
"id": "00000000-0000-0000-0000-000000007e64",
"name": "Admin 32285"
}
},
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:43.604580Z"
}
]
}
Get invoices sorted by Invoice Date descendingly date and filtered by various attributes
Note: The page size for this endpoint is 500 invoices per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/invoices
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
due_datetime | Filter invoices by the due datetime | query | string | false | ,2022-07-10T00:00:00Z | |
inserted_datetime | Filter invoices by their creation datetime | query | string | false | 2022-07-10T00:00:00Z,2022-07-11T00:00:00Z | |
invoice_datetime | Filter invoices by the invoice datetime | query | string | false | 2022-07-10T00:00:00Z, | |
invoice_number | Filter invoices by whether their invoice number contains the given string | query | string | false | 001 | |
order_id | Filter invoices by order IDs | query | array | false | ["67ae9080-8dc2-4ab7-9704-19673f4d9f21","213c7080-8dc2-4ab7-9704-19673f4d9f22"] | |
page | Pagination information | body | Page | false | ||
status | Filter invoices by their status. Accepted values are "Not Paid", "Over Paid", "Fully Paid" and "Partially Paid". | query | array | false | ["Not Paid","Over Paid"] | |
updated_datetime | Filter invoices by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of invoices | Invoices |
Insert a payment for an invoice
POST /invoices/:id/payments can create a payment for an invoice with both quickbooks id and name
POST /public/v1/invoices/00000000-0000-0000-0000-00000000026e/payments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNjYsImlhdCI6MTc0OTc0MjU2NiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNjdlMDg5ODMtZjI5Zi00NDFjLThhNTMtZDI2ODhiMGVkM2ZlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTY1LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzU2MjUiLCJ0eXAiOiJhY2Nlc3MifQ.o2h1IQ4-4N0zLDI6JM-0I1v-T0Hh6D6Yee55GMjDS3U
{
"amount": 100.01,
"description": "Payment for invoice",
"payment_datetime": "2020-01-01T00:00:00.000000Z",
"payment_method_id": "00000000-0000-0000-0000-0000000000ab",
"quickbooks_deposit_account_id": "QBD-123"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6e7b8b50cfe584000000000000000001-2c6a85076fee885f-0
{
"data": {
"amount": "100.01",
"description": "Payment for invoice",
"id": "00000000-0000-0000-0000-000000000083",
"inserted_datetime": "2025-06-12T15:36:06.698248Z",
"invoice_id": "00000000-0000-0000-0000-00000000026e",
"payment_date": "2020-01-01T00:00:00.000000Z",
"payment_method": {
"id": "00000000-0000-0000-0000-0000000000ab",
"name": "Payment Method 0"
},
"payment_number": "PYT-0000001",
"quickbooks_deposit_account_id": "QBD-123"
}
}
POST /invoices/:id/payments can create a payment for an invoice with both quickbooks id and name
POST /public/v1/invoices/00000000-0000-0000-0000-00000000026e/payments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNjYsImlhdCI6MTc0OTc0MjU2NiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNjdlMDg5ODMtZjI5Zi00NDFjLThhNTMtZDI2ODhiMGVkM2ZlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTY1LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzU2MjUiLCJ0eXAiOiJhY2Nlc3MifQ.o2h1IQ4-4N0zLDI6JM-0I1v-T0Hh6D6Yee55GMjDS3U
{
"amount": 100.01,
"description": "Payment for invoice",
"payment_datetime": "2020-01-01T00:00:00.000000Z",
"payment_method_id": "00000000-0000-0000-0000-0000000000ab",
"quickbooks_deposit_account_name": "QBD-NAME"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6e7b8b50cfe584000000000000000001-8dbde1b2d2f221ca-0
{
"data": {
"amount": "100.01",
"description": "Payment for invoice",
"id": "00000000-0000-0000-0000-000000000084",
"inserted_datetime": "2025-06-12T15:36:06.860987Z",
"invoice_id": "00000000-0000-0000-0000-00000000026e",
"payment_date": "2020-01-01T00:00:00.000000Z",
"payment_method": {
"id": "00000000-0000-0000-0000-0000000000ab",
"name": "Payment Method 0"
},
"payment_number": "PYT-0000002",
"quickbooks_deposit_account_id": "QBD-123"
}
}
Request
POST /public/v1/invoices/{id}/payments
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
payment_method_id | Payment method ID | query | string | true | ||
amount | Amount of the payment. Will round to 2 decimal places | query | decimal | true | ||
payment_datetime | Payment date | query | string | true | ||
description | Description of the payment | query | string | true | ||
quickbooks_deposit_account_id | Quickbooks deposit account ID. Cannot include both this and quickbooks_deposit_account_name. If user's company is integrated with Quickbooks, either this or quickbooks_deposit_account_name must be provided. Account type must be "Bank" or "Other Current Asset" | query | string | false | ||
quickbooks_deposit_account_name | Quickbooks deposit account name. Cannot include both this and quickbooks_deposit_account_id. If user's company is integrated with Quickbooks, either this or quickbooks_deposit_account_id must be provided. Account type must be "Bank" or "Other Current Asset" | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A single payment | InvoicePayment |
Get an invoice
GET /invoices/:id returns the expected invoice
GET /public/v1/invoices/00000000-0000-0000-0000-000000000241
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTYsImlhdCI6MTc0OTc0MjU1NiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTkyNzZlYTMtOTdkYi00M2I5LWE0YTYtNzRlM2NkYjNmNWE2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTU1LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzQ1NDgiLCJ0eXAiOiJhY2Nlc3MifQ.DjuLLN7uyGA_JP0CIh6OK-_5jOmYiHxEvov01BsVQ_c
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 522b02f819d690000000000000000001-24f60dd08f1f9a0b-0
{
"data": {
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-0000000039c1",
"name": "Company 25840",
"updated_datetime": "2025-06-12T15:35:56.902476Z"
},
"creator": {
"banned": false,
"email": "owner-34799@example.com",
"full_name": "FirstName68637 LastName68638",
"id": "00000000-0000-0000-0000-0000000086fc",
"role": {
"id": "00000000-0000-0000-0000-000000008735",
"name": "Admin 34542"
}
},
"custom_data": [
{
"id": 97,
"name": "Custom Field 126",
"value": "Custom Field Value 1"
}
],
"due_datetime": "2025-06-12T15:35:57.196077Z",
"id": "00000000-0000-0000-0000-000000000241",
"inserted_datetime": "2025-06-12T15:35:57.198114Z",
"invoice_datetime": "2025-06-12T15:35:57.196075Z",
"invoice_number": "Invoice #494",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002662",
"name": "B29943"
},
"id": "00000000-0000-0000-0000-0000000002cf",
"order_item_id": "56e8dce2-176d-4340-a816-cb7f88f3e5f5",
"package": null,
"price": "10.000000000",
"product": {
"id": "c1cf88a1-240f-4d43-bf5d-1c0a3bd0ee82",
"name": "Product 29941",
"sku": "sku 29942",
"updated_datetime": "2025-06-12T15:35:56.950885Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002667",
"name": "B29956"
},
"id": "00000000-0000-0000-0000-0000000002d0",
"order_item_id": "cf85afa7-fd59-4b0c-a260-30fa83002b85",
"package": null,
"price": "10.000000000",
"product": {
"id": "1b8e8989-4fd2-4dc8-aba3-2d7c2b84807b",
"name": "Product 29954",
"sku": "sku 29955",
"updated_datetime": "2025-06-12T15:35:57.000714Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "40d8f47a-1c9f-46cd-a80e-1a53dc3d6afd",
"order_number": "SO-1859",
"status": "Pending",
"total": "320.00"
},
"owner": {
"banned": false,
"email": "owner-34799@example.com",
"full_name": "FirstName68637 LastName68638",
"id": "00000000-0000-0000-0000-0000000086fc",
"role": {
"id": "00000000-0000-0000-0000-000000008735",
"name": "Admin 34542"
}
},
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:57.198114Z"
}
}
Get a single invoice given the ID
Request
GET /public/v1/invoices/{id}
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
id | Unique ID for an invoice | path | string | true |
Responses
Status | Description | Schema |
---|---|---|
200 | An invoice | Invoice |
Upsert an invoice
POST /invoices creates an invoice
POST /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTAsImlhdCI6MTc0OTc0MjU1MCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTFiMDEwMzUtOGQzYy00MzU5LWFlNDYtZWUxYzJiMWNmYjY0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzM0MDIiLCJ0eXAiOiJhY2Nlc3MifQ.U7To3FcjJx69u8oMcdVyS6ekj0uzp0vhmCIyZseqzV0
{
"billing_location_id": "00000000-0000-0000-0000-000000002934",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"due_datetime": "2020-01-30T00:00:01.000000Z",
"invoice_datetime": "2020-01-01T00:00:00.000000Z",
"items": [
{
"order_item_id": "b1f3066f-7755-4ad5-87a6-8b0f216b4986",
"quantity": "1.000000000"
},
{
"order_item_id": "34d5c37c-154a-4548-8128-464e13961299",
"quantity": "10.000000000"
}
],
"order_id": "dc9585e3-f517-4834-aba2-dc5ffc568c7c"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 0626a23f5fbd4a800000000000000001-516fe4e7406385c8-0
{
"data": {
"charges": [
{
"id": "5e6c5ae4-90f5-4243-9b78-4f1cb5ea2ad5",
"name": "C1",
"percent": "10.0000",
"price": "5.30",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "81001848-c2bf-464a-b01e-462edccde224",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000037aa",
"name": "Company 25028",
"updated_datetime": "2025-06-12T15:35:50.268950Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-00000000827a",
"role": {
"id": "00000000-0000-0000-0000-0000000082c2",
"name": "Admin 33403"
}
},
"custom_data": [],
"due_datetime": "2020-01-30T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-0000000001ff",
"inserted_datetime": "2025-06-12T15:35:50.533373Z",
"invoice_datetime": "2020-01-01T00:00:00.000000Z",
"invoice_number": "INV-0000001",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002520",
"name": "B1"
},
"id": "00000000-0000-0000-0000-000000000289",
"order_item_id": "b1f3066f-7755-4ad5-87a6-8b0f216b4986",
"package": null,
"price": "3.000000000",
"product": {
"id": "81618406-a207-4a8c-a74b-b32c0e5e1887",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:50.331024Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002523",
"name": "B2"
},
"id": "00000000-0000-0000-0000-00000000028a",
"order_item_id": "34d5c37c-154a-4548-8128-464e13961299",
"package": null,
"price": "5.000000000",
"product": {
"id": "112ba048-5504-4669-811c-a99e3b2e79f9",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:35:50.371872Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "dc9585e3-f517-4834-aba2-dc5ffc568c7c",
"order_number": "SO-1751",
"status": "Processing",
"total": "0.00"
},
"owner": null,
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "53.30",
"updated_datetime": "2025-06-12T15:35:50.558593Z"
}
}
POST /invoices updates an invoice
POST /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDQsImlhdCI6MTc0OTc0MjU0NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMWVmNjg3NTItYjk3OS00MDdjLWI4NjMtY2E0NjI4MmVkNDdlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzIzNjEiLCJ0eXAiOiJhY2Nlc3MifQ.WiRROZVnMODgRxasEAAg0fTGfsvSocEu1XKCnRFot1o
{
"billing_location_id": "00000000-0000-0000-0000-00000000278e",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"due_datetime": "2020-01-30T00:00:01.000000Z",
"invoice_datetime": "2020-01-01T00:00:00.000000Z",
"items": [
{
"order_item_id": "fa1a6a45-edab-4a08-a65f-93314fc64edc",
"quantity": "1.000000000"
},
{
"order_item_id": "743a76a2-627b-4951-9349-898a173adc2c",
"quantity": "10.000000000"
}
],
"order_id": "3c7dc9fa-f475-451c-98aa-7d51cf80d542"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6b5bb85806ede4000000000000000001-83fcf58b4abe1aaf-0
{
"data": {
"charges": [
{
"id": "4899a706-46f9-4b66-896c-e16c2aa55374",
"name": "C1",
"percent": "10.0000",
"price": "5.30",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "188436bb-446d-4304-b923-8fd8b752da27",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000035c8",
"name": "Company 24276",
"updated_datetime": "2025-06-12T15:35:44.008003Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000007e69",
"role": {
"id": "00000000-0000-0000-0000-000000007ece",
"name": "Admin 32391"
}
},
"custom_data": [],
"due_datetime": "2020-01-30T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-0000000001df",
"inserted_datetime": "2025-06-12T15:35:44.214404Z",
"invoice_datetime": "2020-01-01T00:00:00.000000Z",
"invoice_number": "INV-0000001",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023ec",
"name": "B1"
},
"id": "00000000-0000-0000-0000-00000000025c",
"order_item_id": "fa1a6a45-edab-4a08-a65f-93314fc64edc",
"package": null,
"price": "3.000000000",
"product": {
"id": "09074179-f0a0-4d59-b014-1363090f696d",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:44.069142Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023ee",
"name": "B2"
},
"id": "00000000-0000-0000-0000-00000000025d",
"order_item_id": "743a76a2-627b-4951-9349-898a173adc2c",
"package": null,
"price": "5.000000000",
"product": {
"id": "996297a1-df43-4ab2-83f2-2d55460e115a",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:35:44.107618Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "3c7dc9fa-f475-451c-98aa-7d51cf80d542",
"order_number": "SO-1682",
"status": "Processing",
"total": "0.00"
},
"owner": null,
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "53.30",
"updated_datetime": "2025-06-12T15:35:44.234018Z"
}
}
POST /invoices updates an invoice
POST /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDQsImlhdCI6MTc0OTc0MjU0NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMWVmNjg3NTItYjk3OS00MDdjLWI4NjMtY2E0NjI4MmVkNDdlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzIzNjEiLCJ0eXAiOiJhY2Nlc3MifQ.WiRROZVnMODgRxasEAAg0fTGfsvSocEu1XKCnRFot1o
{
"billing_location_id": "00000000-0000-0000-0000-00000000278f",
"charges": [
{
"id": "4899a706-46f9-4b66-896c-e16c2aa55374",
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C3",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"due_datetime": "2020-01-28T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-0000000001df",
"invoice_datetime": "2020-01-02T00:00:00.000000Z",
"items": [
{
"id": "00000000-0000-0000-0000-00000000025c",
"order_item_id": "fa1a6a45-edab-4a08-a65f-93314fc64edc",
"quantity": "1.000000000"
},
{
"order_item_id": "743a76a2-627b-4951-9349-898a173adc2c",
"quantity": "8.000000000"
}
],
"order_id": "3c7dc9fa-f475-451c-98aa-7d51cf80d542"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6b5bb85806ede4000000000000000001-a0efea8c8aa53402-0
{
"data": {
"charges": [
{
"id": "4899a706-46f9-4b66-896c-e16c2aa55374",
"name": "C1",
"percent": "10.0000",
"price": "4.30",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "743d9ed4-e3dd-4e57-9b79-e1ecc66239d4",
"name": "C3",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000035c8",
"name": "Company 24276",
"updated_datetime": "2025-06-12T15:35:44.008003Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000007e69",
"role": {
"id": "00000000-0000-0000-0000-000000007ece",
"name": "Admin 32391"
}
},
"custom_data": [],
"due_datetime": "2020-01-28T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-0000000001df",
"inserted_datetime": "2025-06-12T15:35:44.214404Z",
"invoice_datetime": "2020-01-02T00:00:00.000000Z",
"invoice_number": "INV-0000001",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023ec",
"name": "B1"
},
"id": "00000000-0000-0000-0000-00000000025c",
"order_item_id": "fa1a6a45-edab-4a08-a65f-93314fc64edc",
"package": null,
"price": "3.000000000",
"product": {
"id": "09074179-f0a0-4d59-b014-1363090f696d",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:44.069142Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023ee",
"name": "B2"
},
"id": "00000000-0000-0000-0000-00000000025e",
"order_item_id": "743a76a2-627b-4951-9349-898a173adc2c",
"package": null,
"price": "5.000000000",
"product": {
"id": "996297a1-df43-4ab2-83f2-2d55460e115a",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:35:44.107618Z"
},
"quantity": "8.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"order": {
"id": "3c7dc9fa-f475-451c-98aa-7d51cf80d542",
"order_number": "SO-1682",
"status": "Processing",
"total": "0.00"
},
"owner": null,
"paid_amount": "0.0",
"status": "NOT_PAID",
"total": "42.30",
"updated_datetime": "2025-06-12T15:35:44.454982Z"
}
}
POST /invoices reports various errors correctly on update
POST /public/v1/invoices
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNjUsImlhdCI6MTc0OTc0MjU2NSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMDhjODU4ZjItNDllZS00MzIwLWJmN2MtMThjNjUxZjQ3NDI5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTY0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzU1MDgiLCJ0eXAiOiJhY2Nlc3MifQ.IS9c3il1mumNXh5a2u_7fP8Jq8UTuBFb5KiESeFxRHs
{
"billing_location_id": "00000000-0000-0000-0000-000000002c85",
"charges": [
{
"name": "C1",
"percent": "-1000.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"due_datetime": "2020-01-30T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-00000000026a",
"invoice_datetime": "2020-01-01T00:00:00.000000Z",
"items": [
{
"order_item_id": "00000000-0000-0000-0000-000000000000",
"quantity": "15.000"
},
{
"order_item_id": "f6ef7b91-81ba-4bbf-9c54-c893efca7bbb",
"quantity": "19.000"
}
],
"order_id": "95515c75-1e8a-4bd6-88bf-e0af40f134e2"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 205359a17632be000000000000000001-45a55265aeacf58d-0
{
"errors": [
{
"context": {
"id": "10e35fda-7cc6-4b21-ae0b-f31ee257ee43"
},
"message": "Must be less than or equal to 100",
"pointer": [
"charges",
0,
"percent"
],
"section": "body"
},
{
"context": {},
"message": "Order item not found",
"pointer": [
"items",
2,
"order_item_id"
],
"section": "body"
},
{
"context": {},
"message": "Only 10 left uninvoiced",
"pointer": [
"items",
3,
"quantity"
],
"section": "body"
}
]
}
Upsert a single invoice. To update an existing invoice, pass in an existing invoice ID in the id field. When updating an invoice, you must pass in all fields (no sparse update currently supported). Any existing invoice item or charge you do not pass in to items and charges respectively will be deleted
Request
POST /public/v1/invoices
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
due_datetime | The datetime at which the invoice is due | query | string | false | ||
id | Unique ID for this invoice. If it exists, an update will be performed; otherwise, it will be used as the ID of a new invoice record | query | string | false | ||
invoice_datetime | The datetime on which the invoice was placed | query | string | false | ||
charges | The additional lines of Charge, Discount, or Tax added to this invoice | body | InvoiceChargesRequest | false | ||
items | The invoice items present on this order | body | InvoiceItemsRequest | false | ||
billing_location_id | The billing location's ID | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A single invoice | Invoice |
Location
Get locations
GET /public/v1/locations returns locations related to the company
GET /public/v1/locations
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIyMTQsImlhdCI6MTc0OTc0MjYxNCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYmQyMGFmNDItNTdhOS00YzQxLWE2ZTgtNWEwMmMxMDM4NTk4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNjEzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NDQ1MzQiLCJ0eXAiOiJhY2Nlc3MifQ.lz5V-jxGzo9-NiPwYFmsar6LZ5q4F0KoE51YTPq5RFc
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: bebdc2805e14b8000000000000000001-e1a0e80439c4feba-0
{
"data": [
{
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000008127",
"id": "00000000-0000-0000-0000-0000000036ca",
"license": null,
"license_id": null,
"name": "Place 13831"
},
{
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000008127",
"id": "00000000-0000-0000-0000-0000000036cb",
"license": {
"id": "00000000-0000-0000-0000-000000002029",
"license_number": "CDPH-00009261"
},
"license_id": "00000000-0000-0000-0000-000000002029",
"name": "Place 13832"
}
]
}
Get locations sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 1000 locations per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/locations
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter locations by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter locations by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of locations | Locations |
Order
Get orders
GET /public/v1/orders returns orders related to the company
GET /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjAsImlhdCI6MTc0OTc0MjQyMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTRkYTQ3ZjItYmZmOS00Mjc1LWIyNzktZjczN2QyYjBkYTY1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA5NTIiLCJ0eXAiOiJhY2Nlc3MifQ.K5IMKVYZiwQNPitkrlYnfgIFImjga8_YquKojHxrE20
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 3b1ea6d009f7e0000000000000000001-3f634a2ecb439ff0-0
{
"data": [
{
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000002145",
"id": "00000000-0000-0000-0000-000000000d5d",
"license_id": null,
"name": "Place 3415"
},
"biotrack_id": null,
"charges": [
{
"id": "c8134f89-aba7-4baf-9979-2e7f378fc925",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000012c8",
"name": "Company 8558",
"updated_datetime": "2030-11-01T00:00:00.000000Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000002ac1",
"role": {
"id": "00000000-0000-0000-0000-000000002af6",
"name": "Admin 10985"
}
},
"custom_data": [
{
"id": 15,
"name": "Custom Field 45",
"value": "Custom Field Value 1"
}
],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "6c88db80-6203-49fa-9a77-ad39582d3a69",
"inserted_datetime": "2020-01-01T00:00:03.000000Z",
"internal_notes": "Internal notes for this order",
"items": [
{
"batch": {
"batch_number": "UID1",
"id": "00000000-0000-0000-0000-000000000e16",
"name": "B1"
},
"compliance_quantity": "10.0000",
"id": "603d76da-b1c4-48f6-9159-33db17eceb25",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000002145",
"id": "00000000-0000-0000-0000-000000000d5d",
"license_id": null,
"name": "Place 3415"
},
"package": {
"batch_number": "B1",
"compliance_label": "ABCDEF012345670000002208",
"id": "00000000-0000-0000-0000-0000000002e8",
"metrc_label": "ABCDEF012345670000002208",
"status": "active"
},
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "520be713-7c6b-49b8-a9e3-28dbb89b2c7a",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2023-11-02T00:00:00.000000Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": "fdc5a9be-c98c-4eab-b4ac-dc2b54746bd0",
"metrc_transfer_id": 1,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-123",
"owner": {
"banned": false,
"email": "user2@a.com",
"full_name": "John Bar",
"id": "00000000-0000-0000-0000-000000002ac2",
"role": {
"id": "00000000-0000-0000-0000-000000002af7",
"name": "Admin 10987"
}
},
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000002145",
"id": "00000000-0000-0000-0000-000000000d5d",
"license_id": null,
"name": "Place 3415"
},
"status": "COMPLETED",
"total": "11.00",
"updated_datetime": "2020-01-01T00:00:04.000000Z"
}
]
}
GET /public/v1/orders returns cost/returned_quantity data for order items
GET /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5ODgsImlhdCI6MTc0OTc0MjM4OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzA3MGFiMTgtNjk2Zi00Y2ExLWE3ZjktZTY3N2YwMWM5MTRlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzg3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6Njg5NiIsInR5cCI6ImFjY2VzcyJ9.FpHhtytx4RZR39Es3gGhrrHLsfz_cxabDLJr92zcznI
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 39d972a61c9a56000000000000000001-b9098bd43275bc2c-0
{
"data": [
{
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000b7b",
"name": "Company 5568",
"updated_datetime": "2025-06-12T15:33:08.891068Z"
},
"creator": {
"banned": false,
"email": "owner-7161@example.com",
"full_name": "FirstName13836 LastName13837",
"id": "00000000-0000-0000-0000-000000001b2c",
"role": {
"id": "00000000-0000-0000-0000-000000001b52",
"name": "Admin 6990"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:08.896433Z",
"external_notes": null,
"id": "33825c72-8704-4be1-a4d4-0b5160efd77b",
"inserted_datetime": "2025-06-12T15:33:09.034542Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000083f",
"name": "B6245"
},
"compliance_quantity": null,
"id": "9844a142-03d9-4f02-b3af-3a6733ac33f9",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000157f",
"id": "00000000-0000-0000-0000-000000000839",
"license_id": null,
"name": "Place 2109"
},
"package": null,
"price": "313767.000000000",
"price_base": "313767",
"product": {
"id": "72b348f0-7bc8-44f2-aa10-2b4b8fd4fad5",
"name": "Product 6234",
"sku": "sku 6235",
"updated_datetime": "2025-06-12T15:33:08.533988Z"
},
"quantity": "2.000000000",
"returned_quantity": "2",
"total_cost_actual": "20.052",
"total_cost_default": "10"
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2025-06-12T15:33:08.896436Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "627534.00",
"updated_datetime": "2025-06-12T15:33:09.034542Z"
}
]
}
GET /public/v1/orders allows filtering by several statuses
GET /public/v1/orders?status[]=COMPLETED&status[]=CANCELED
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5OTgsImlhdCI6MTc0OTc0MjM5OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZWY5MjI2YzAtM2RmNi00ZDRlLTlkYzQtNzc4MDg4N2E0OTQwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzk3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODE4NyIsInR5cCI6ImFjY2VzcyJ9.9sJ3u01V2f3TdO6WJWkJAkI-jjQnWFGVtsGh6OaReTY
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 25a2bd5828ff9c000000000000000001-2eaece693d191f86-0
{
"data": [
{
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000e36",
"name": "Company 6645",
"updated_datetime": "2025-06-12T15:33:20.203765Z"
},
"creator": {
"banned": false,
"email": "owner-8610@example.com",
"full_name": "FirstName16716 LastName16717",
"id": "00000000-0000-0000-0000-0000000020d2",
"role": {
"id": "00000000-0000-0000-0000-000000002117",
"name": "Admin 8467"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:20.293818Z",
"external_notes": null,
"id": "f879265e-aa55-4a81-95d5-14ebffc23e49",
"inserted_datetime": "2025-06-12T15:33:20.296727Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000ab6",
"name": "B7992"
},
"compliance_quantity": null,
"id": "baf4275d-ae65-4bd7-ba4d-0cd7bc488dfa",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "584e276e-a649-4a95-a44a-19b8c2e9f74a",
"name": "Product 7990",
"sku": "sku 7991",
"updated_datetime": "2025-06-12T15:33:20.452843Z"
},
"quantity": "15.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000abc",
"name": "B8006"
},
"compliance_quantity": null,
"id": "efd30f4d-42dd-4643-9c0b-18734a31e24a",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "22d500ba-c41e-452d-8e18-2636272f806d",
"name": "Product 8004",
"sku": "sku 8005",
"updated_datetime": "2025-06-12T15:33:20.521678Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000ac0",
"name": "B8014"
},
"compliance_quantity": null,
"id": "a2ad61e4-8950-47a8-873f-1299dce23579",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "55ae302c-9e54-413a-b38f-0b4431e9cf07",
"name": "Product 8012",
"sku": "sku 8013",
"updated_datetime": "2025-06-12T15:33:20.573295Z"
},
"quantity": "5.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000ac3",
"name": "B8027"
},
"compliance_quantity": null,
"id": "fd934c2e-4699-4362-8db5-d1fc581c44b0",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "b452a39d-9d07-4af3-b4bc-7ebfc5f55ed0",
"name": "Product 8025",
"sku": "sku 8026",
"updated_datetime": "2025-06-12T15:33:20.630658Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T12:30:00.000000Z",
"order_number": "SO-476",
"owner": {
"banned": false,
"email": "owner-8610@example.com",
"full_name": "FirstName16716 LastName16717",
"id": "00000000-0000-0000-0000-0000000020d2",
"role": {
"id": "00000000-0000-0000-0000-000000002117",
"name": "Admin 8467"
}
},
"shipping_location": null,
"status": "CANCELED",
"total": "320.00",
"updated_datetime": "2025-06-12T15:33:20.795227Z"
},
{
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000e0e",
"name": "Company 6585",
"updated_datetime": "2025-06-12T15:33:19.651446Z"
},
"creator": {
"banned": false,
"email": "owner-8528@example.com",
"full_name": "FirstName16548 LastName16549",
"id": "00000000-0000-0000-0000-00000000207f",
"role": {
"id": "00000000-0000-0000-0000-0000000020c2",
"name": "Admin 8383"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:19.761902Z",
"external_notes": null,
"id": "590e787b-8c48-4f08-83f1-3f860a5c16f6",
"inserted_datetime": "2025-06-12T15:33:19.787377Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a89",
"name": "B7891"
},
"compliance_quantity": null,
"id": "6d8e59bb-bd45-489d-99d4-f41d2d072288",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "7716dc3a-137e-477d-919f-e4d4460d1530",
"name": "Product 7884",
"sku": "sku 7887",
"updated_datetime": "2025-06-12T15:33:19.828622Z"
},
"quantity": "15.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a97",
"name": "B7918"
},
"compliance_quantity": null,
"id": "947e6f09-cb29-4852-b9ba-83f62c2761d1",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "48ce71df-8cb1-43e3-8952-f39fe4dc9a6d",
"name": "Product 7912",
"sku": "sku 7913",
"updated_datetime": "2025-06-12T15:33:19.893055Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000aa3",
"name": "B7937"
},
"compliance_quantity": null,
"id": "5dd120ca-e06b-4514-b002-c95a0e064f62",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "25d7a8df-1fd8-42bb-8e47-3e6e8451e67d",
"name": "Product 7933",
"sku": "sku 7934",
"updated_datetime": "2025-06-12T15:33:19.963943Z"
},
"quantity": "5.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000aa5",
"name": "B7945"
},
"compliance_quantity": null,
"id": "86c43bff-e224-429f-ada0-bf65b11fedda",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "8ab6eff8-50df-43bd-a479-88cdf40c42f9",
"name": "Product 7943",
"sku": "sku 7944",
"updated_datetime": "2025-06-12T15:33:20.024328Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T12:20:00.000000Z",
"order_number": "SO-470",
"owner": {
"banned": false,
"email": "owner-8528@example.com",
"full_name": "FirstName16548 LastName16549",
"id": "00000000-0000-0000-0000-00000000207f",
"role": {
"id": "00000000-0000-0000-0000-0000000020c2",
"name": "Admin 8383"
}
},
"shipping_location": null,
"status": "COMPLETED",
"total": "320.00",
"updated_datetime": "2025-06-12T15:33:20.163109Z"
},
{
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000dc2",
"name": "Company 6481",
"updated_datetime": "2025-06-12T15:33:18.681984Z"
},
"creator": {
"banned": false,
"email": "owner-8400@example.com",
"full_name": "FirstName16292 LastName16293",
"id": "00000000-0000-0000-0000-000000001ffe",
"role": {
"id": "00000000-0000-0000-0000-000000002042",
"name": "Admin 8254"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:18.773817Z",
"external_notes": null,
"id": "f2a022dc-0013-4bdb-82cc-734d7f0c823a",
"inserted_datetime": "2025-06-12T15:33:18.775598Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a16",
"name": "B7646"
},
"compliance_quantity": null,
"id": "4e2d33b2-6944-44b6-b7f3-18206944336b",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "d76a936e-3556-4959-a8d2-a3dbddfb8ba5",
"name": "Product 7642",
"sku": "sku 7643",
"updated_datetime": "2025-06-12T15:33:18.823846Z"
},
"quantity": "15.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a1a",
"name": "B7656"
},
"compliance_quantity": null,
"id": "d163e49d-9b56-459c-9614-3567fe7e4ee3",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "8c30fbc7-36be-4149-a6aa-7126fcf7c6ac",
"name": "Product 7653",
"sku": "sku 7654",
"updated_datetime": "2025-06-12T15:33:18.875701Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a1c",
"name": "B7662"
},
"compliance_quantity": null,
"id": "c1054568-3ee3-4b6d-9f23-e56f3b248537",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "1c584ad3-2dce-412f-928b-aec9cf245866",
"name": "Product 7659",
"sku": "sku 7660",
"updated_datetime": "2025-06-12T15:33:18.923662Z"
},
"quantity": "5.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000a20",
"name": "B7676"
},
"compliance_quantity": null,
"id": "475c8870-bd6f-4ae4-84cd-3fdfb689db70",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "f30ea263-d713-4db6-b0ea-a046ecb00993",
"name": "Product 7674",
"sku": "sku 7675",
"updated_datetime": "2025-06-12T15:33:18.960778Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T12:00:00.000000Z",
"order_number": "SO-459",
"owner": {
"banned": false,
"email": "owner-8400@example.com",
"full_name": "FirstName16292 LastName16293",
"id": "00000000-0000-0000-0000-000000001ffe",
"role": {
"id": "00000000-0000-0000-0000-000000002042",
"name": "Admin 8254"
}
},
"shipping_location": null,
"status": "COMPLETED",
"total": "320.00",
"updated_datetime": "2025-06-12T15:33:19.109662Z"
}
]
}
Get orders sorted by Order Date descendingly date and filtered by various attributes
Note: The page size for this endpoint is 500 orders per page.
Request
GET /public/v1/orders
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
delivery_datetime | Filter orders by the delivery datetime | query | string | false | 2022-07-10T00:00:00Z, | |
due_datetime | Filter orders by the due datetime | query | string | false | ,2022-07-10T00:00:00Z | |
inserted_datetime | Filter orders by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
order_datetime | Filter orders by the order datetime | query | string | false | 2022-07-10T00:00:00Z,2022-07-11T00:00:00Z | |
page | Pagination information | body | Page | false | ||
status | Filter orders by their status. Accepted values are "PENDING", "PROCESSING", "READY_TO_SHIP", "DELIVERING", "DELIVERED", "COMPLETED" and "CANCELED". | query | array | false | ["PENDING","PROCESSING"] | |
updated_datetime | Filter orders by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of orders | Orders |
Get an order
GET /orders/:id returns the expected order
GET /public/v1/orders/398477e3-b2b7-494b-9b46-0f0df57eb4c7
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjEsImlhdCI6MTc0OTc0MjQyMSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMWE0MTM4MmMtZTdhZC00ZDNlLTgxMzAtY2I3YzRmOGNjNDk5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDIwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTEwMzMiLCJ0eXAiOiJhY2Nlc3MifQ.L5lvZFIrcnOsInhEjbcs8kS-HZ1xlAgiuhHSwh5d0i8
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 86074eece5ddc0000000000000000001-3a9ec2f6720b7ba7-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-0000000012e2",
"name": "Company 8597",
"updated_datetime": "2025-06-12T15:33:41.383522Z"
},
"creator": {
"banned": false,
"email": "owner-11218@example.com",
"full_name": "FirstName21942 LastName21943",
"id": "00000000-0000-0000-0000-000000002b1e",
"role": {
"id": "00000000-0000-0000-0000-000000002b53",
"name": "Admin 11078"
}
},
"custom_data": [
{
"id": 16,
"name": "Custom Field 46",
"value": "Custom Field Value 1"
}
],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:41.457773Z",
"external_notes": null,
"id": "398477e3-b2b7-494b-9b46-0f0df57eb4c7",
"inserted_datetime": "2025-06-12T15:33:41.459123Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000e31",
"name": "B10556"
},
"compliance_quantity": null,
"id": "24637e9f-ecbb-43bb-9137-577bfdd58bd2",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "10ef663f-6eee-469f-8ecb-14510ec6a776",
"name": "Product 10554",
"sku": "sku 10555",
"updated_datetime": "2025-06-12T15:33:41.502744Z"
},
"quantity": "15.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000e35",
"name": "B10567"
},
"compliance_quantity": null,
"id": "35c02193-c9bf-4074-9116-deac3b90ba47",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "9b6fa895-9dfe-4e61-8951-9b5c38a5d011",
"name": "Product 10561",
"sku": "sku 10562",
"updated_datetime": "2025-06-12T15:33:41.619511Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000e39",
"name": "B10574"
},
"compliance_quantity": null,
"id": "4e406026-5253-4a55-bb15-661798d6b9ef",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "7021a3b9-96c6-4f47-a253-7a7af66681d8",
"name": "Product 10570",
"sku": "sku 10571",
"updated_datetime": "2025-06-12T15:33:41.688701Z"
},
"quantity": "5.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000e3c",
"name": "B10585"
},
"compliance_quantity": null,
"id": "7a0fbe5b-5660-42bc-9bca-9473505f02d7",
"location": null,
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "690160ab-f362-457b-9121-a56106faef32",
"name": "Product 10581",
"sku": "sku 10582",
"updated_datetime": "2025-06-12T15:33:41.739163Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2025-06-12T15:33:41.457771Z",
"order_number": "SO-598",
"owner": {
"banned": false,
"email": "owner-11218@example.com",
"full_name": "FirstName21942 LastName21943",
"id": "00000000-0000-0000-0000-000000002b1e",
"role": {
"id": "00000000-0000-0000-0000-000000002b53",
"name": "Admin 11078"
}
},
"shipping_location": null,
"status": "COMPLETED",
"total": "320.00",
"updated_datetime": "2025-06-12T15:33:41.854284Z"
}
}
GET /orders/:id returns cost data for order items
GET /public/v1/orders/7e22591c-e868-4db7-b99d-fc498a418dda
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTMsImlhdCI6MTc0OTc0MjQxMywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzM1YzZkNmUtMWU0NC00OWZhLWJlNjItYWYwYjI3ZmIxODE4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDEyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6OTk2OSIsInR5cCI6ImFjY2VzcyJ9.rSaV47TvYxHVvW5nBuf2Hl-IZfWRB45XRxyGkJbN-R4
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 0c59d9b5a35972000000000000000001-3b59aafa3af12169-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000112a",
"name": "Company 7842",
"updated_datetime": "2025-06-12T15:33:33.819558Z"
},
"creator": {
"banned": false,
"email": "owner-10180@example.com",
"full_name": "FirstName19855 LastName19857",
"id": "00000000-0000-0000-0000-000000002706",
"role": {
"id": "00000000-0000-0000-0000-00000000273f",
"name": "Admin 10034"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2025-06-12T15:33:33.823144Z",
"external_notes": null,
"id": "7e22591c-e868-4db7-b99d-fc498a418dda",
"inserted_datetime": "2025-06-12T15:33:33.945906Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000d0f",
"name": "B9698"
},
"compliance_quantity": null,
"id": "5640b767-5147-4b06-904c-ab382f1727f2",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001e88",
"id": "00000000-0000-0000-0000-000000000c1e",
"license_id": null,
"name": "Place 3096"
},
"package": null,
"price": "527211.000000000",
"price_base": "527211",
"product": {
"id": "2d826465-355e-4e9a-8c44-a01b5960ad09",
"name": "Product 9691",
"sku": "sku 9692",
"updated_datetime": "2025-06-12T15:33:33.592812Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": "20.052",
"total_cost_default": "10"
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2025-06-12T15:33:33.823147Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "1054422.00",
"updated_datetime": "2025-06-12T15:33:33.945906Z"
}
}
Get a single order given the ID. Note: This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/orders/{id}
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
id | Order ID | path | string | true |
Responses
Status | Description | Schema |
---|---|---|
200 | A single order | Order |
Upsert an order
POST /public/v1/orders creates an order (with product-tracked item)
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5ODQsImlhdCI6MTc0OTc0MjM4NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNzg1NTNhNjMtN2EwMS00Y2Y2LTg5MjItNjJlOGFjZDgyMjFhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzgzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NjM2MyIsInR5cCI6ImFjY2VzcyJ9.dsJDm0cvQrzDuJJJWxd0msXhjxJDzULon2ndL9pPS3E
{
"billing_location_id": "00000000-0000-0000-0000-000000000786",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-000000000a7d",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": "Thank you for ordering!",
"internal_notes": "Internal notes for this order",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000786",
"price_base": "10.000000000",
"product_id": "df840f0b-6ebb-4fdf-a587-943aaa5eac6e",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"owner_id": "00000000-0000-0000-0000-0000000018db",
"shipping_location_id": "00000000-0000-0000-0000-000000000786",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 1e1142d85d7091000000000000000001-8fc85487096e8b16-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001409",
"id": "00000000-0000-0000-0000-000000000786",
"license_id": "00000000-0000-0000-0000-00000000054b",
"name": "Place 1931"
},
"biotrack_id": null,
"charges": [
{
"id": "20887300-fa0c-4e52-9076-709163a38324",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "29a2c506-41d9-472f-9813-8fdc72640ce4",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000000a7d",
"name": "Company 5158",
"updated_datetime": "2025-06-12T15:33:04.667460Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-0000000018db",
"role": {
"id": "00000000-0000-0000-0000-0000000018f5",
"name": "Admin 6385"
}
},
"custom_data": [
{
"id": 6,
"name": "Custom Field 36",
"value": null
}
],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": "Thank you for ordering!",
"id": "22a4bab3-6ed6-46c7-b32c-7352606e25af",
"inserted_datetime": "2025-06-12T15:33:04.901278Z",
"internal_notes": "Internal notes for this order",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000076f",
"name": "B1"
},
"compliance_quantity": null,
"id": "d88246a3-10df-4e8a-9ad8-ce1be50458f9",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001409",
"id": "00000000-0000-0000-0000-000000000786",
"license_id": "00000000-0000-0000-0000-00000000054b",
"name": "Place 1931"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "df840f0b-6ebb-4fdf-a587-943aaa5eac6e",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:04.765821Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-0000000018db",
"role": {
"id": "00000000-0000-0000-0000-0000000018f5",
"name": "Admin 6385"
}
},
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001409",
"id": "00000000-0000-0000-0000-000000000786",
"license_id": "00000000-0000-0000-0000-00000000054b",
"name": "Place 1931"
},
"status": "PROCESSING",
"total": "6.00",
"updated_datetime": "2025-06-12T15:33:05.007845Z"
}
}
POST /public/v1/orders creates an order (with product-tracked item) for a Blaze retailer, fails if payment type not specified
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDIsImlhdCI6MTc0OTc0MjQwMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNjUyY2UxNWMtOTFkYS00NjY5LWI3OTItMzY2NWM5YWJmM2YzIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDAxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODczMyIsInR5cCI6ImFjY2VzcyJ9.wcF919QIc8__F84nmbVzpV6h5WJn4_KMNZ6bOnFZJRI
{
"billing_location_id": "00000000-0000-0000-0000-000000000a9e",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000000ec8",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000a9e",
"price_base": "10.000000000",
"product_id": "a39edc0a-e7e8-4f8e-95bc-e7e389797574",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"shipping_location_id": "00000000-0000-0000-0000-000000000a9e",
"status": "PROCESSING"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 2b05fbe017a642000000000000000001-4dafdf76f88aa265-0
{
"errors": [
{
"context": {
"id": "2fa01eff-9ee9-4e68-a013-69a1f82d9245"
},
"message": "can't be blank",
"pointer": [
"blaze_payment_type"
],
"section": "body"
}
]
}
POST /public/v1/orders creates an order (with product-tracked item) for a Blaze retailer, fails if payment type not specified
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMDIsImlhdCI6MTc0OTc0MjQwMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNjUyY2UxNWMtOTFkYS00NjY5LWI3OTItMzY2NWM5YWJmM2YzIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDAxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6ODczMyIsInR5cCI6ImFjY2VzcyJ9.wcF919QIc8__F84nmbVzpV6h5WJn4_KMNZ6bOnFZJRI
{
"billing_location_id": "00000000-0000-0000-0000-000000000a9e",
"blaze_payment_type": "CASH",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000000ec8",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000a9e",
"price_base": "10.000000000",
"product_id": "a39edc0a-e7e8-4f8e-95bc-e7e389797574",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"shipping_location_id": "00000000-0000-0000-0000-000000000a9e",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 2b05fbe017a642000000000000000001-e53ebe52943fc221-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ac1",
"id": "00000000-0000-0000-0000-000000000a9e",
"license_id": "00000000-0000-0000-0000-0000000006e6",
"name": "Place 2712"
},
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000ec8",
"name": "Company 6879",
"updated_datetime": "2025-06-12T15:33:22.786242Z"
},
"creator": {
"banned": false,
"email": "owner-8941@example.com",
"full_name": "FirstName17376 LastName17379",
"id": "00000000-0000-0000-0000-00000000221d",
"role": {
"id": "00000000-0000-0000-0000-000000002264",
"name": "Admin 8799"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "055a0b3e-f735-4ede-8bcc-c070086bf629",
"inserted_datetime": "2025-06-12T15:33:23.079772Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000b31",
"name": "B1"
},
"compliance_quantity": null,
"id": "68259c75-07ca-4a35-a5e7-e89f70633a12",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ac1",
"id": "00000000-0000-0000-0000-000000000a9e",
"license_id": "00000000-0000-0000-0000-0000000006e6",
"name": "Place 2712"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "a39edc0a-e7e8-4f8e-95bc-e7e389797574",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:22.900770Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ac1",
"id": "00000000-0000-0000-0000-000000000a9e",
"license_id": "00000000-0000-0000-0000-0000000006e6",
"name": "Place 2712"
},
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:23.079772Z"
}
}
POST /public/v1/orders applies the best fit price tier items to order items
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5OTMsImlhdCI6MTc0OTc0MjM5MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTAxMDIxNmYtOWU5MS00ZGRmLTkzOGYtOTkwODkxNjQ0YTRiIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzkyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NzU4MSIsInR5cCI6ImFjY2VzcyJ9.35q9pN3kMfu0LOrcXnGAtl-VtQT_bGSZvy-L1nw2bb0
{
"billing_location_id": "00000000-0000-0000-0000-000000000916",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000000c85",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000916",
"position": 1,
"price_base": "100.000000000",
"product_id": "9be2698b-a64f-48b2-bf03-d777285f75ea",
"quantity": "80.000000000"
},
{
"location_id": "00000000-0000-0000-0000-000000000916",
"position": 2,
"price_base": "200.000000000",
"product_id": "9be2698b-a64f-48b2-bf03-d777285f75ea",
"quantity": "10.000000000"
},
{
"location_id": "00000000-0000-0000-0000-000000000916",
"position": 3,
"price_base": "300.000000000",
"product_id": "2b65a805-c92a-4aa7-95e4-0529bdca381c",
"quantity": "20.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"shipping_location_id": "00000000-0000-0000-0000-000000000916",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 42df8bca957260000000000000000001-8d4e8c6976d25ebb-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000174e",
"id": "00000000-0000-0000-0000-000000000916",
"license_id": "00000000-0000-0000-0000-00000000062e",
"name": "Place 2330"
},
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000c85",
"name": "Company 5994",
"updated_datetime": "2025-06-12T15:33:13.076347Z"
},
"creator": {
"banned": false,
"email": "owner-7784@example.com",
"full_name": "FirstName15080 LastName15081",
"id": "00000000-0000-0000-0000-000000001d9d",
"role": {
"id": "00000000-0000-0000-0000-000000001dda",
"name": "Admin 7638"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "608c7314-1e85-4747-b5e9-48f7a0a76cc0",
"inserted_datetime": "2025-06-12T15:33:13.639323Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000090a",
"name": "B1"
},
"compliance_quantity": null,
"id": "29b6ab92-7c72-4805-896f-d74fd3d9af56",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000174e",
"id": "00000000-0000-0000-0000-000000000916",
"license_id": "00000000-0000-0000-0000-00000000062e",
"name": "Place 2330"
},
"package": null,
"price": "80.000000000",
"price_base": "100.000000000",
"product": {
"id": "9be2698b-a64f-48b2-bf03-d777285f75ea",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:13.250608Z"
},
"quantity": "80.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000090a",
"name": "B1"
},
"compliance_quantity": null,
"id": "632b5c1a-9406-4204-a9cd-9cd2880d80ca",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000174e",
"id": "00000000-0000-0000-0000-000000000916",
"license_id": "00000000-0000-0000-0000-00000000062e",
"name": "Place 2330"
},
"package": null,
"price": "180.000000000",
"price_base": "200.000000000",
"product": {
"id": "9be2698b-a64f-48b2-bf03-d777285f75ea",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:13.250608Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000913",
"name": "B2"
},
"compliance_quantity": null,
"id": "95010605-867b-4072-9d41-d94f1a789975",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000174e",
"id": "00000000-0000-0000-0000-000000000916",
"license_id": "00000000-0000-0000-0000-00000000062e",
"name": "Place 2330"
},
"package": null,
"price": "270.000000000",
"price_base": "300.000000000",
"product": {
"id": "2b65a805-c92a-4aa7-95e4-0529bdca381c",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:33:13.359781Z"
},
"quantity": "20.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000174e",
"id": "00000000-0000-0000-0000-000000000916",
"license_id": "00000000-0000-0000-0000-00000000062e",
"name": "Place 2330"
},
"status": "PROCESSING",
"total": "13600.00",
"updated_datetime": "2025-06-12T15:33:13.806836Z"
}
}
POST /public/v1/orders creates an order (with batch-tracked item)
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5ODEsImlhdCI6MTc0OTc0MjM4MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMTM5MzMzN2ItMmRiYy00OGJiLWE5YzItMWRhZjM2MjJlYjA4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzgwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NTg4MCIsInR5cCI6ImFjY2VzcyJ9.SCdVrKibFvggpPF1uGlIzQUc4YPNb7aPn5DMpZy-6HQ
{
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"batch_id": "00000000-0000-0000-0000-0000000006b6",
"location_id": "00000000-0000-0000-0000-0000000006e2",
"price_base": "10.000000000",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 012d0a7ea65ddb700000000000000001-835fd94870f67a27-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": null,
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-0000000016f8",
"role": {
"id": "00000000-0000-0000-0000-000000001710",
"name": "Admin 5900"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "685b94a9-fd51-412d-b2e5-c39f18d49455",
"inserted_datetime": "2025-06-12T15:33:01.130345Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000006b6",
"name": "B1"
},
"compliance_quantity": null,
"id": "019f899a-8050-4ef1-a18b-8636ead13241",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000129e",
"id": "00000000-0000-0000-0000-0000000006e2",
"license_id": "00000000-0000-0000-0000-0000000004d9",
"name": "Place 1768"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "4a63742a-913a-4522-b58c-c08c4c94acb8",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:01.061743Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:01.130345Z"
}
}
POST /public/v1/orders creates an order (with batch-tracked item without batch set)
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTIsImlhdCI6MTc0OTc0MjQxMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZTdmMjkyZDUtZTE0NC00YmEzLWI2ZDktNWI3Y2E2M2EwNWFlIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDExLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6OTc3MyIsInR5cCI6ImFjY2VzcyJ9.kzXo9ZFxWRzUFOSZeMn2JdprJFD7V_LZPtZM8QcSbAs
{
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000be1",
"price_base": "10.000000000",
"product_id": "b3029287-c0e0-46a6-a75f-a1cd673a34ab",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6a7674193fe6ec000000000000000001-3e3d0af5a13d1b79-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": null,
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-00000000262d",
"role": {
"id": "00000000-0000-0000-0000-000000002665",
"name": "Admin 9818"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "8352610f-99f5-4d33-9cc1-36ae702144d6",
"inserted_datetime": "2025-06-12T15:33:32.186765Z",
"internal_notes": null,
"items": [
{
"batch": null,
"compliance_quantity": null,
"id": "bdc0cf41-7bed-4832-8e94-266e1d6e4c5d",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001dea",
"id": "00000000-0000-0000-0000-000000000be1",
"license_id": "00000000-0000-0000-0000-0000000007ac",
"name": "Place 3035"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "b3029287-c0e0-46a6-a75f-a1cd673a34ab",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:32.125641Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:32.186765Z"
}
}
POST /public/v1/orders creates an order (with package-tracked item)
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjIsImlhdCI6MTc0OTc0MjQyMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYjY4OTM0ZDMtNDlkMS00ZDcxLWFkZGEtNzc0NGE5Y2IyOGYyIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDIxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTExODkiLCJ0eXAiOiJhY2Nlc3MifQ.anwB446EZ5MCmd6iMVOh4fbQWGKv3hL4Q9X69HXogcI
{
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"compliance_quantity": "1.0000",
"location_id": "00000000-0000-0000-0000-000000000db8",
"package_id": "00000000-0000-0000-0000-0000000002fd",
"price_base": "10.000000000",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: f3d90beaa62068000000000000000001-911eaabd64154591-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": null,
"creator": {
"banned": false,
"email": "owner-11367@example.com",
"full_name": "FirstName22240 LastName22243",
"id": "00000000-0000-0000-0000-000000002bb5",
"role": {
"id": "00000000-0000-0000-0000-000000002be7",
"name": "Admin 11226"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "da411620-2a5c-479e-9eb8-dc1b3ebf0ec4",
"inserted_datetime": "2025-06-12T15:33:43.245825Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000e63",
"name": "B1"
},
"compliance_quantity": "1.0000",
"id": "a7066d5f-b483-4e77-b834-9469c46d9302",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000002201",
"id": "00000000-0000-0000-0000-000000000db8",
"license_id": "00000000-0000-0000-0000-000000000890",
"name": "Place 3506"
},
"package": {
"batch_number": "B1",
"compliance_label": "ABCDEF012345670000002259",
"id": "00000000-0000-0000-0000-0000000002fd",
"metrc_label": "ABCDEF012345670000002259",
"status": "selling"
},
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "f0bf2ab0-54a9-4655-8539-35c40ceff69b",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:42.818215Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:43.245825Z"
}
}
POST /public/v1/orders creates an order (with package-tracked item without package set)
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTIsImlhdCI6MTc0OTc0MjQxMiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOWJmYzYxZjktYTNkYS00ZDllLThlOGQtZDQ2NzhjNDE1YjljIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDExLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6OTg1MCIsInR5cCI6ImFjY2VzcyJ9.cAlWkmobnNGkVElfIsKlNa_2I7a8BJI6I4p22O18wDQ
{
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000bfc",
"price_base": "10.000000000",
"product_id": "70e040b3-ce1a-46de-ade6-1d3278aea07d",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6ef8bbacbb2200000000000000000001-37ed9ab96136463c-0
{
"data": {
"billing_location": null,
"biotrack_id": null,
"charges": [],
"company": null,
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-00000000267a",
"role": {
"id": "00000000-0000-0000-0000-0000000026b5",
"name": "Admin 9897"
}
},
"custom_data": [],
"delivery_datetime": null,
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "9aa0fce7-7c5c-44c2-ade3-9c78a54274ee",
"inserted_datetime": "2025-06-12T15:33:32.715174Z",
"internal_notes": null,
"items": [
{
"batch": null,
"compliance_quantity": null,
"id": "9369aa72-9fbf-4cef-8be5-75477c2c6e61",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001e2c",
"id": "00000000-0000-0000-0000-000000000bfc",
"license_id": "00000000-0000-0000-0000-0000000007b9",
"name": "Place 3062"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "70e040b3-ce1a-46de-ade6-1d3278aea07d",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:32.598140Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": null,
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:32.715174Z"
}
}
POST /public/v1/orders creates an order with metrc transfer template
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTksImlhdCI6MTc0OTc0MjQxOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMTNmZDY0N2UtOGMyZS00MzJkLWE3YTktMTQ5MTY3N2QxZjgwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA3NjEiLCJ0eXAiOiJhY2Nlc3MifQ.AmR22wTWRwhmhc7Nldtraj99Uyx1vZO9TEChpX-wHBc
{
"billing_location_id": "00000000-0000-0000-0000-000000000d2a",
"charges": [],
"company_id": "00000000-0000-0000-0000-00000000126f",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"items": [
{
"compliance_quantity": "1.0000",
"id": "23017064-8e08-4d38-a273-a280002709a2",
"location_id": "00000000-0000-0000-0000-000000000d2a",
"package_id": "00000000-0000-0000-0000-0000000002dc",
"price_base": "10.000000000",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000000d2a",
"metrc_transfer_template_directions": "Go to the store around the corner",
"metrc_transfer_template_recipient_license_number": "C12-0123458-LIC",
"metrc_transfer_template_status": "PENDING",
"metrc_transfer_template_transporter_info": [
{
"driver_license_number": "1234567890",
"driver_name": "John Doe",
"driver_occupational_license_number": "1234567890",
"driver_phone_number": "1234567890",
"transporter_license_number": "C12-0123456-LIC",
"vehicle_license_plate_number": "1234567890",
"vehicle_make": "Toyota",
"vehicle_model": "Prius"
},
{
"driver_license_number": "1234567891",
"driver_name": "Jane Doe",
"driver_occupational_license_number": "1234567891",
"driver_phone_number": "1234567891",
"transporter_license_number": "C12-0123457-LIC",
"vehicle_license_plate_number": "1234567891",
"vehicle_make": "Toyota",
"vehicle_model": "Corolla"
}
],
"metrc_transfer_template_type": "Transfer",
"order_datetime": "2020-01-01T00:00:02.000000Z",
"owner_id": "00000000-0000-0000-0000-000000002a09",
"shipping_location_id": "00000000-0000-0000-0000-000000000d2a",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 1ddcb032a241cf000000000000000001-c8c6d67e386c928a-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000020cd",
"id": "00000000-0000-0000-0000-000000000d2a",
"license_id": "00000000-0000-0000-0000-000000000858",
"name": "Place 3364"
},
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000126f",
"name": "Company 8414",
"updated_datetime": "2025-06-12T15:33:39.626738Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000002a09",
"role": {
"id": "00000000-0000-0000-0000-000000002a3f",
"name": "Admin 10802"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "36d818e3-bdc1-4ae9-8475-c1b721dc3a93",
"inserted_datetime": "2025-06-12T15:33:40.099883Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000de7",
"name": "B2"
},
"compliance_quantity": "1.0000",
"id": "23017064-8e08-4d38-a273-a280002709a2",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000020cd",
"id": "00000000-0000-0000-0000-000000000d2a",
"license_id": "00000000-0000-0000-0000-000000000858",
"name": "Place 3364"
},
"package": {
"batch_number": "B1",
"compliance_label": "ABCDEF012345670000002180",
"id": "00000000-0000-0000-0000-0000000002dc",
"metrc_label": "ABCDEF012345670000002180",
"status": "selling"
},
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "0b270b9a-0b1a-4862-beac-ebfd2987d040",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:39.757944Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000002a09",
"role": {
"id": "00000000-0000-0000-0000-000000002a3f",
"name": "Admin 10802"
}
},
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000020cd",
"id": "00000000-0000-0000-0000-000000000d2a",
"license_id": "00000000-0000-0000-0000-000000000858",
"name": "Place 3364"
},
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:40.451038Z"
}
}
POST /public/v1/orders updates an order
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5NzUsImlhdCI6MTc0OTc0MjM3NSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTExYWM4OGItMDk2OS00NWY2LThjNjctMjQxMDdiZTQzMDVjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzc0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NDc2MiIsInR5cCI6ImFjY2VzcyJ9.3w95epUXHpRf3S5W6YkUN-dKhym_X8EyqObdjZSBOR0
{
"billing_location_id": "00000000-0000-0000-0000-000000000579",
"charges": [
{
"id": "8d7ddcce-0c48-4ad8-a209-6b1b60c5f8ec",
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "243d3b5c-e4bc-43a2-92c3-02c1fe6a2955",
"name": "C2",
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-0000000007d6",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": "gonna make you sweat",
"id": "2860f7fe-c2a2-4230-9332-126275cbbf08",
"items": [
{
"id": "4c6bebf5-a2ed-4209-a233-2aad5e738b80",
"location_id": "00000000-0000-0000-0000-000000000579",
"price_base": "10.000000000",
"product_id": "494eddac-452f-4c6a-a23e-2d503b613eb7",
"quantity": "2.000000000"
},
{
"id": "5bb6a4ef-038a-468d-8f87-9845c70e2377",
"location_id": "00000000-0000-0000-0000-000000000579",
"price_base": "100.000000000",
"product_id": "494eddac-452f-4c6a-a23e-2d503b613eb7",
"quantity": "3.000000000"
},
{
"compliance_quantity": "1.0000",
"id": "e6e92bb7-8162-452f-a87c-258488584130",
"location_id": "00000000-0000-0000-0000-000000000579",
"package_id": "00000000-0000-0000-0000-000000000145",
"price_base": "10.000000000",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000000579",
"metrc_transfer_template_directions": "Go to the store around the corner",
"metrc_transfer_template_recipient_license_number": "C12-0123458-LIC",
"metrc_transfer_template_status": "PENDING",
"metrc_transfer_template_transporter_info": [
{
"driver_license_number": "1234567890",
"driver_name": "John Doe",
"driver_occupational_license_number": "1234567890",
"driver_phone_number": "1234567890",
"transporter_license_number": "C12-0123456-LIC",
"vehicle_license_plate_number": "1234567890",
"vehicle_make": "Toyota",
"vehicle_model": "Prius"
},
{
"driver_license_number": "1234567891",
"driver_name": "Jane Doe",
"driver_occupational_license_number": "1234567891",
"driver_phone_number": "1234567891",
"transporter_license_number": "C12-0123457-LIC",
"vehicle_license_plate_number": "1234567891",
"vehicle_make": "Toyota",
"vehicle_model": "Corolla"
}
],
"metrc_transfer_template_type": "Transfer",
"order_datetime": "2020-01-01T00:00:02.000000Z",
"owner_id": "00000000-0000-0000-0000-0000000012e6",
"shipping_location_id": "00000000-0000-0000-0000-000000000579",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 8fd9a0ba3d75d0000000000000000001-9f0e29df3ead8431-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000000f7e",
"id": "00000000-0000-0000-0000-000000000579",
"license_id": "00000000-0000-0000-0000-0000000003fa",
"name": "Place 1414"
},
"biotrack_id": null,
"charges": [
{
"id": "8d7ddcce-0c48-4ad8-a209-6b1b60c5f8ec",
"name": "C1",
"percent": "10.0000",
"price": "33.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "243d3b5c-e4bc-43a2-92c3-02c1fe6a2955",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000007d6",
"name": "Company 4007",
"updated_datetime": "2025-06-12T15:32:55.441427Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000001296",
"role": {
"id": "00000000-0000-0000-0000-0000000012bd",
"name": "Admin 4793"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": "gonna make you sweat",
"id": "2860f7fe-c2a2-4230-9332-126275cbbf08",
"inserted_datetime": "2025-06-12T15:32:55.594434Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000574",
"name": "B1"
},
"compliance_quantity": null,
"id": "4c6bebf5-a2ed-4209-a233-2aad5e738b80",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000000f7e",
"id": "00000000-0000-0000-0000-000000000579",
"license_id": "00000000-0000-0000-0000-0000000003fa",
"name": "Place 1414"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "494eddac-452f-4c6a-a23e-2d503b613eb7",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:32:55.540194Z"
},
"quantity": "2.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000574",
"name": "B1"
},
"compliance_quantity": null,
"id": "5bb6a4ef-038a-468d-8f87-9845c70e2377",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000000f7e",
"id": "00000000-0000-0000-0000-000000000579",
"license_id": "00000000-0000-0000-0000-0000000003fa",
"name": "Place 1414"
},
"package": null,
"price": "100.000000000",
"price_base": "100.000000000",
"product": {
"id": "494eddac-452f-4c6a-a23e-2d503b613eb7",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:32:55.540194Z"
},
"quantity": "3.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000057d",
"name": "B2"
},
"compliance_quantity": "1.0000",
"id": "e6e92bb7-8162-452f-a87c-258488584130",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000000f7e",
"id": "00000000-0000-0000-0000-000000000579",
"license_id": "00000000-0000-0000-0000-0000000003fa",
"name": "Place 1414"
},
"package": {
"batch_number": "B2",
"compliance_label": "ABCDEF012345670000000927",
"id": "00000000-0000-0000-0000-000000000145",
"metrc_label": "ABCDEF012345670000000927",
"status": "selling"
},
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "7f7f7123-13fb-4576-ae75-37535e58a847",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:32:55.638236Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-260",
"owner": {
"banned": false,
"email": "owner-5097@example.com",
"full_name": "FirstName9604 LastName9605",
"id": "00000000-0000-0000-0000-0000000012e6",
"role": {
"id": "00000000-0000-0000-0000-00000000130c",
"name": "Admin 4872"
}
},
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000000f7e",
"id": "00000000-0000-0000-0000-000000000579",
"license_id": "00000000-0000-0000-0000-0000000003fa",
"name": "Place 1414"
},
"status": "PROCESSING",
"total": "358.00",
"updated_datetime": "2025-06-12T15:32:56.553543Z"
}
}
POST /public/v1/orders does not alter locked price tier items on update
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTQsImlhdCI6MTc0OTc0MjQxNCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNzVlOTczODUtNGY0OC00MmZmLTgxYTMtNGFlNTg4Y2NjMzQxIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDEzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTAwOTQiLCJ0eXAiOiJhY2Nlc3MifQ.YwEgUJ2z3C1ngYfwdqsn_Whm1wEGkhmHuqf6FWJBxaE
{
"billing_location_id": "00000000-0000-0000-0000-000000000c48",
"charges": [],
"company_id": "00000000-0000-0000-0000-00000000115a",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000000c48",
"position": 1,
"price_base": "100.000000000",
"product_id": "7b970e06-ed77-4fe9-a4d0-7a9595380c2e",
"quantity": "10.000000000"
},
{
"location_id": "00000000-0000-0000-0000-000000000c48",
"position": 2,
"price_base": "200.000000000",
"product_id": "11c55117-8f5e-4976-a22b-bafa11b74e1e",
"quantity": "10.000000000"
},
{
"location_id": "00000000-0000-0000-0000-000000000c48",
"position": 3,
"price_base": "300.000000000",
"product_id": "3b471854-8979-4ef4-80bc-322e8af7a1e4",
"quantity": "10.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"shipping_location_id": "00000000-0000-0000-0000-000000000c48",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: db38b4a38e08a8000000000000000001-6dcf1dc0ee4b7179-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ee0",
"id": "00000000-0000-0000-0000-000000000c48",
"license_id": "00000000-0000-0000-0000-0000000007d8",
"name": "Place 3138"
},
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000115a",
"name": "Company 7918",
"updated_datetime": "2025-06-12T15:33:34.571231Z"
},
"creator": {
"banned": false,
"email": "owner-10281@example.com",
"full_name": "FirstName20060 LastName20061",
"id": "00000000-0000-0000-0000-00000000276e",
"role": {
"id": "00000000-0000-0000-0000-0000000027a2",
"name": "Admin 10133"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "b5a3b8ed-c830-4a50-a180-485506b5e3d5",
"inserted_datetime": "2025-06-12T15:33:35.083462Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000d2a",
"name": "B1"
},
"compliance_quantity": null,
"id": "c91f75c4-966b-451a-b10f-74c32db84fb4",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ee0",
"id": "00000000-0000-0000-0000-000000000c48",
"license_id": "00000000-0000-0000-0000-0000000007d8",
"name": "Place 3138"
},
"package": null,
"price": "90.000000000",
"price_base": "100.000000000",
"product": {
"id": "7b970e06-ed77-4fe9-a4d0-7a9595380c2e",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:34.646817Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000d2c",
"name": "B2"
},
"compliance_quantity": null,
"id": "dfc34ae8-dd96-4b2e-9424-99d20da0c5ca",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ee0",
"id": "00000000-0000-0000-0000-000000000c48",
"license_id": "00000000-0000-0000-0000-0000000007d8",
"name": "Place 3138"
},
"package": null,
"price": "200.000000000",
"price_base": "200.000000000",
"product": {
"id": "11c55117-8f5e-4976-a22b-bafa11b74e1e",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:33:34.704757Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000000d30",
"name": "B3"
},
"compliance_quantity": null,
"id": "62c13155-e74a-4a80-a60d-f6413c4d0880",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ee0",
"id": "00000000-0000-0000-0000-000000000c48",
"license_id": "00000000-0000-0000-0000-0000000007d8",
"name": "Place 3138"
},
"package": null,
"price": "290.000000000",
"price_base": "300.000000000",
"product": {
"id": "3b471854-8979-4ef4-80bc-322e8af7a1e4",
"name": "P3",
"sku": "SKU3",
"updated_datetime": "2025-06-12T15:33:34.759245Z"
},
"quantity": "10.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-0000001",
"owner": null,
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000001ee0",
"id": "00000000-0000-0000-0000-000000000c48",
"license_id": "00000000-0000-0000-0000-0000000007d8",
"name": "Place 3138"
},
"status": "PROCESSING",
"total": "5800.00",
"updated_datetime": "2025-06-12T15:33:35.268265Z"
}
}
POST /public/v1/orders deleting order items & charges
POST /public/v1/orders
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5OTIsImlhdCI6MTc0OTc0MjM5MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMDczM2EzNzctYjg2MS00ZDcxLTk4YmEtNThlMTJhMWM4YjA3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzkxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NzQzNSIsInR5cCI6ImFjY2VzcyJ9.4wy3VTryOTt5OltFTPo6wvOG-msA9RoneUhuQLDqfe0
{
"billing_location_id": "00000000-0000-0000-0000-0000000008e6",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000000c4a",
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"id": "0e8ff76c-3eea-4bc6-bfc6-284e1bc63a27",
"items": [
{
"id": "47b4f143-f75c-4b84-aa32-e2d50011caab",
"location_id": "00000000-0000-0000-0000-0000000008e6",
"price_base": "10.000000000",
"product_id": "bcda8319-b3c5-4fff-94e9-d921c273c474",
"quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"shipping_location_id": "00000000-0000-0000-0000-0000000008e6",
"status": "PROCESSING"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 5128cee41e55f8000000000000000001-1946de1d2aba0641-0
{
"data": {
"billing_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000016f0",
"id": "00000000-0000-0000-0000-0000000008e6",
"license_id": "00000000-0000-0000-0000-000000000611",
"name": "Place 2282"
},
"biotrack_id": null,
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000000c4a",
"name": "Company 5902",
"updated_datetime": "2025-06-12T15:33:12.264394Z"
},
"creator": {
"banned": false,
"email": "user1@a.com",
"full_name": "John Foo",
"id": "00000000-0000-0000-0000-000000001d0b",
"role": {
"id": "00000000-0000-0000-0000-000000001d46",
"name": "Admin 7490"
}
},
"custom_data": [],
"delivery_datetime": "2020-01-01T00:00:00.000000Z",
"due_datetime": "2020-01-01T00:00:01.000000Z",
"external_notes": null,
"id": "0e8ff76c-3eea-4bc6-bfc6-284e1bc63a27",
"inserted_datetime": "2025-06-12T15:33:12.492886Z",
"internal_notes": null,
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000008e5",
"name": "B1"
},
"compliance_quantity": null,
"id": "47b4f143-f75c-4b84-aa32-e2d50011caab",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000016f0",
"id": "00000000-0000-0000-0000-0000000008e6",
"license_id": "00000000-0000-0000-0000-000000000611",
"name": "Place 2282"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "bcda8319-b3c5-4fff-94e9-d921c273c474",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:33:12.356158Z"
},
"quantity": "1.000000000",
"returned_quantity": "0",
"total_cost_actual": null,
"total_cost_default": null
}
],
"leaflink_order_number": null,
"metrc_transfer_id": null,
"order_datetime": "2020-01-01T00:00:02.000000Z",
"order_number": "SO-408",
"owner": null,
"shipping_location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000016f0",
"id": "00000000-0000-0000-0000-0000000008e6",
"license_id": "00000000-0000-0000-0000-000000000611",
"name": "Place 2282"
},
"status": "PROCESSING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:33:12.846881Z"
}
}
Upsert a single order. To update an existing order, pass in an existing order ID in the id field. When updating an order, you must pass in all fields (no sparse update currently supported). Any existing order item or charge you do not pass in to items and charges respectively will be deleted
Request
POST /public/v1/orders
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
biotrack_id | The Biotrack ID for this order | query | string | false | ||
blaze_payment_type | The payment type for an order shipping to a Blaze-associated company. Required when the company being used is mapped to a Blaze retailer via the Distru integration. | query | string | false | CASH | |
company_id | Company ID | query | string | false | ||
delivery_datetime | The datetime on which the order was / will be delivered | query | string | false | ||
due_datetime | The datetime by which the order should be completed for the customer | query | string | false | ||
external_notes | This is a message that will be shown to the customer on order slips. This is the "Message to Customer" field in the Distru order form. | query | string | false | ||
id | Unique ID for this order. If it exists, an update will be performed; otherwise, it will be used as the ID of a new order record | query | string | false | ||
order_datetime | The datetime on which the order was placed | query | string | false | ||
charges | The additional lines of Charge, Discount, or Tax added to this order | body | OrderChargesRequest | false | ||
items | The order items present on this order | body | OrderItemsRequest | false | ||
internal_notes | Internal notes for this order | query | string | false | ||
metrc_transfer_template_transporter_info | The Metrc transfer template transporter(s) information about this order | body | OrderTransferTemplateTransporterInfosRequest | false | ||
metrc_transfer_template_directions | The Metrc transfer template directions | query | string | false | ||
metrc_transfer_id | The Metrc transfer ID for this order | query | integer | false | ||
metrc_transfer_template_recipient_license_number | The Metrc transfer template recipient license number | query | string | false | ||
metrc_transfer_template_status | The Metrc transfer template status | query | string | false | ||
metrc_transfer_template_type | The Metrc transfer template type | query | string | false | ||
billing_location_id | The billing location's ID | query | string | false | ||
shipping_location_id | The shipping location's ID | query | string | false | ||
owner_id | The ID of the Distru user that owns this order | query | string | false | ||
status | Filter orders by their status. Accepted values are "PENDING", "PROCESSING", "READY_TO_SHIP", "DELIVERING", "DELIVERED", "COMPLETED" and "CANCELED". | query | string | false | PENDING |
Responses
Status | Description | Schema |
---|---|---|
200 | A single order | Order |
Package
Get packages
GET /public/v1/packages returns packages related to the company
GET /public/v1/packages
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNzAsImlhdCI6MTc0OTc0MjU3MCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNmRjNDgyMzMtYmU4ZC00OGUzLThlN2ItOWFlZTI2MGM2NWVmIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTY5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzYxNDMiLCJ0eXAiOiJhY2Nlc3MifQ.LXC0Cak5oSL4oznLNBbm5x35W_6exE1zA5qoLy9TQlE
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6258963413e60c000000000000000001-022d0a586969bff5-0
{
"data": [
{
"batch_number": null,
"compliance_label": "ABCDEF012345670000009046",
"custom_data": [
{
"id": 107,
"name": "Custom Field 136",
"value": "Custom Field Value 1"
}
],
"expiration_date": "2024-01-01T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000bd3",
"is_trade_sample": true,
"license": {
"id": "00000000-0000-0000-0000-000000001a52",
"license_number": "CDPH-00007683"
},
"location": {
"id": "00000000-0000-0000-0000-000000002d2f",
"name": "Place 11402"
},
"metrc_label": "ABCDEF012345670000009046",
"primary_test_result": null,
"product_id": "69f824d1-46c1-413f-b570-f53bbac50b96",
"product_unit_quantity": "7.500000000",
"product_unit_type": {
"id": "00000000-0000-0000-0000-00000005b6e0",
"name": "3"
},
"quantity": "5.000000000",
"quantity_assembling": "0.000000000",
"quantity_available": "5.000000000",
"status": "active",
"unit_type": {
"id": "00000000-0000-0000-0000-00000005b6e1",
"name": "2"
}
},
{
"batch_number": null,
"compliance_label": "ABCDEF012345670000009059",
"custom_data": [
{
"id": 107,
"name": "Custom Field 136",
"value": null
}
],
"expiration_date": null,
"id": "00000000-0000-0000-0000-000000000bd6",
"is_trade_sample": false,
"license": {
"id": "00000000-0000-0000-0000-000000001a52",
"license_number": "CDPH-00007683"
},
"location": {
"id": "00000000-0000-0000-0000-000000002d32",
"name": "Place 11405"
},
"metrc_label": "ABCDEF012345670000009059",
"primary_test_result": {
"cbd_mg_per_unit": "1",
"cbd_mg_per_unit_total": "2",
"cbd_percentage": "3",
"cbd_percentage_total": "4",
"mg_per_unit_type": "mg/mL",
"name": "File.pdf",
"thc_mg_per_unit": "5",
"thc_mg_per_unit_total": "6",
"thc_percentage": "7",
"thc_percentage_total": "8"
},
"product_id": "69f824d1-46c1-413f-b570-f53bbac50b96",
"product_unit_quantity": "15.000000000",
"product_unit_type": {
"id": "00000000-0000-0000-0000-00000005b6e0",
"name": "3"
},
"quantity": "20.000000000",
"quantity_assembling": "0.000000000",
"quantity_available": "20.000000000",
"status": "active",
"unit_type": {
"id": "00000000-0000-0000-0000-00000005b6e2",
"name": "4"
}
}
]
}
Get packages sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 5000 packages per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/packages
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter packages by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
location_ids | A list of location UUIDs to filter packages by. | |||||
query | array | false | ["123e4567-e89b-12d3-a456-426655440000","456e89b1-2d3a-4564-2665-544000000000"] | |||
license_number | Filter packages by license number | query | string | false | 1234567890 | |
statuses | Filter packages by their status | query | array | false | ["active","selling","sold"] | |
updated_datetime | Filter packages by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of packages | Packages |
PaymentMethod
Get payment methods
GET /public/v1/payments/methods returns payment methods related to the user's company only
GET /public/v1/payment-methods
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxODQsImlhdCI6MTc0OTc0MjU4NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMmZjMmY1NzgtZjE2Zi00MDg3LWEyM2ItODY2MzJjNTA2YTllIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTgzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6Mzg4NzAiLCJ0eXAiOiJhY2Nlc3MifQ.790SZEiAtiMMPTVO74BvO6QNVj9wEHA3ez9-9soPYzQ
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 72b42b9a648668000000000000000001-28eb917b4c272ffb-0
{
"data": [
{
"id": "00000000-0000-0000-0000-0000000000c6",
"name": "Payment Method 196"
}
]
}
Get payment methods. Note: This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/payment-methods
Responses
Status | Description | Schema |
---|---|---|
200 | A list of payment methods | PaymentMethods |
Product
Get products
GET /public/products returns products related to the company
GET /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjQsImlhdCI6MTc0OTc0MjQ2NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZjg4NDhmOTgtOTZkYi00NGNmLTkzNGItMTU0NzdlMTY3NjI3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTcxNDciLCJ0eXAiOiJhY2Nlc3MifQ.uBL50Kvw4HvTDOZ8oFJBBio8YN2EsIYGLRnMXygHYWc
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: d2d5f92d3cb9a8000000000000000001-980d62cbb254a97d-0
{
"data": [
{
"brand": {
"id": "00000000-0000-0000-0000-000000001d5f",
"name": "Company 12937",
"updated_datetime": "2030-11-01T00:00:00.000000Z"
},
"category": {
"id": "00000000-0000-0000-0000-000000001868",
"name": "Some category 5588",
"type": "OTHER"
},
"custom_data": [
{
"id": 31,
"name": "Custom Field 61",
"value": "Custom Field Value 1"
}
],
"description": "test",
"external_name": "External Name",
"id": "80370038-3cf9-491b-8795-9fd7bb0d971d",
"images": [
{
"id": "00000000-0000-0000-0000-00000000002d",
"name": "Image Name 367",
"rank": 0,
"url": "https://google.com/original-37.jpg"
},
{
"id": "00000000-0000-0000-0000-00000000002e",
"name": "Image Name 368",
"rank": 1,
"url": "https://google.com/original-38.jpg"
}
],
"is_active": true,
"msrp": null,
"name": "Product 15970",
"sku": "sku 15971",
"strain": {
"id": "00000000-0000-0000-0000-0000000000aa",
"name": "Strain 167"
},
"subcategory": {
"id": "00000000-0000-0000-0000-00000000180e",
"name": "Some subcategory 5237"
},
"unit_price": "1",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b84e",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2023-11-01T00:00:00.000000Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d64",
"name": "Company 12948",
"updated_datetime": "2030-11-03T00:00:00.000000Z"
}
},
{
"brand": {
"id": "00000000-0000-0000-0000-000000001d61",
"name": "Company 12942",
"updated_datetime": "2030-11-02T00:00:00.000000Z"
},
"category": {
"id": "00000000-0000-0000-0000-00000000186c",
"name": "Some category 5592",
"type": "OTHER"
},
"custom_data": [
{
"id": 31,
"name": "Custom Field 61",
"value": null
}
],
"description": null,
"external_name": null,
"id": "3f5efb97-fd17-4235-875e-2f3905090036",
"images": [],
"is_active": false,
"msrp": "100",
"name": "Product 15976",
"sku": "sku 15977",
"strain": null,
"subcategory": {
"id": "00000000-0000-0000-0000-000000001812",
"name": "Some subcategory 5241"
},
"unit_price": "1",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b84c",
"name": "Pound"
},
"units_per_case": null,
"updated_datetime": "2023-11-02T00:00:00.000000Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d6b",
"name": "Company 12952",
"updated_datetime": "2030-11-04T00:00:00.000000Z"
}
}
]
}
Get products sorted by their creation date and filtered by various attributes.
Note: The page size for this endpoint is 5000 products per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/products
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter products by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter products by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of products | Products |
Upsert a product
POST /public/v1/orders Creates a product with all optional fields set
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNTksImlhdCI6MTc0OTc0MjQ1OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOWU0MWE0Y2YtZTNjZS00NzY2LWFlMmEtMzliZWVkYzU5NTQ0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDU4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY0MTgiLCJ0eXAiOiJhY2Nlc3MifQ.RzhTNA-aDzS6MseoZ6zeHa-guPgP5Kp6jNmFHvoOU8A
{
"brand_id": "00000000-0000-0000-0000-000000001c08",
"category_id": "00000000-0000-0000-0000-00000000173c",
"description": "My Product Description",
"group_id": "00000000-0000-0000-0000-0000000013a7",
"id": "dd29e900-cbd9-47e8-a3e0-831fafb5fa43",
"inventory_tracking_method": "PACKAGE",
"is_featured": true,
"is_inactive": true,
"menu_visibility": "INCLUDE_IN_ALL",
"menus": [
"00000000-0000-0000-0000-0000000001d1"
],
"msrp": "100.5",
"name": "My Product",
"owner_id": "00000000-0000-0000-0000-00000000401d",
"quantity_available_threshold_max": "10.5",
"quantity_available_threshold_min": "5.5",
"sku": "12345",
"strain_id": "00000000-0000-0000-0000-00000000009a",
"subcategory_id": "00000000-0000-0000-0000-0000000016fe",
"tags": [
"00000000-0000-0000-0000-0000000000b1"
],
"total_cannabinoid_unit": "PERCENT",
"total_cbd": "5.2",
"total_thc": "10.4",
"unit_cost": "50.4",
"unit_net_weight": "3.1",
"unit_net_weight_and_serving_size_unit_type_id": "00000000-0000-0000-0000-000000029c54",
"unit_price": "100",
"unit_serving_size": "2.2",
"unit_type_id": "00000000-0000-0000-0000-000000029c5c",
"units_per_case": "0.2",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001c02",
"wholesale_unit_price": "90.50"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 4a26ebf2265394000000000000000001-7d5585e1f5554eb7-0
{
"data": {
"brand": {
"id": "00000000-0000-0000-0000-000000001c08",
"name": "Company 12428",
"updated_datetime": "2025-06-12T15:34:19.726811Z"
},
"category": {
"id": "00000000-0000-0000-0000-00000000173c",
"name": "Some category 5288",
"type": "OTHER"
},
"custom_data": [
{
"id": 29,
"name": "Custom Field 59",
"value": null
}
],
"description": "My Product Description",
"external_name": null,
"id": "dd29e900-cbd9-47e8-a3e0-831fafb5fa43",
"images": [],
"is_active": false,
"msrp": "100.5",
"name": "My Product",
"sku": "12345",
"strain": {
"id": "00000000-0000-0000-0000-00000000009a",
"name": "Strain 151"
},
"subcategory": {
"id": "00000000-0000-0000-0000-0000000016fe",
"name": "Some subcategory 4965"
},
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-000000029c5c",
"name": "Unit"
},
"units_per_case": "0.2",
"updated_datetime": "2025-06-12T15:34:19.912413Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001c02",
"name": "Company 12416",
"updated_datetime": "2025-06-12T15:34:19.689656Z"
}
}
}
POST /public/v1/orders Updates a product with all optional fields set
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjIsImlhdCI6MTc0OTc0MjQ2MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTAwMjMwZTAtODcxYS00Yzk0LWJiYjgtZjgyNDNjNmM3NzM3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY4MzciLCJ0eXAiOiJhY2Nlc3MifQ.ufbMsduL4QONCklLZwqRCHyDHX66B0auXFGSuhdcit0
{
"category_id": "00000000-0000-0000-0000-0000000017e2",
"id": "2237e64d-7d32-41c5-8619-7415d7359a73",
"inventory_tracking_method": "PACKAGE",
"name": "My Product",
"sku": "12345",
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002ac70",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001cc9"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 2e34984deb881a000000000000000001-f27205e0322eeb3b-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-0000000017e2",
"name": "Some category 5454",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "2237e64d-7d32-41c5-8619-7415d7359a73",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002ac70",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:22.379507Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001cc9",
"name": "Company 12716",
"updated_datetime": "2025-06-12T15:34:22.221589Z"
}
}
}
POST /public/v1/orders Updates a product with all optional fields set
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjIsImlhdCI6MTc0OTc0MjQ2MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTAwMjMwZTAtODcxYS00Yzk0LWJiYjgtZjgyNDNjNmM3NzM3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY4MzciLCJ0eXAiOiJhY2Nlc3MifQ.ufbMsduL4QONCklLZwqRCHyDHX66B0auXFGSuhdcit0
{
"unit_net_weight_and_serving_size_unit_type_id": "00000000-0000-0000-0000-00000002ac72",
"id": "2237e64d-7d32-41c5-8619-7415d7359a73",
"is_featured": true,
"wholesale_unit_price": "90.50",
"msrp": "100.5",
"unit_type_id": "00000000-0000-0000-0000-00000002ac79",
"quantity_available_threshold_min": "5.5",
"total_thc": "10.4",
"brand_id": "00000000-0000-0000-0000-000000001ce8",
"sku": "45678",
"unit_price": "200",
"category_id": "00000000-0000-0000-0000-0000000017fa",
"unit_serving_size": "2.2",
"tags": [
"00000000-0000-0000-0000-0000000000ba"
],
"total_cbd": "5.2",
"unit_cost": "50.4",
"group_id": "00000000-0000-0000-0000-000000001455",
"is_inactive": true,
"units_per_case": "0.2",
"menus": [
"00000000-0000-0000-0000-0000000001e8"
],
"vendor_id": "00000000-0000-0000-0000-000000001ce3",
"total_cannabinoid_unit": "PERCENT",
"menu_visibility": "INCLUDE_IN_ALL",
"inventory_tracking_method": "PACKAGE",
"description": "My Product Description",
"owner_id": "00000000-0000-0000-0000-000000004205",
"subcategory_id": "00000000-0000-0000-0000-0000000017a8",
"external_name": "External Name",
"quantity_available_threshold_max": "10.5",
"upc": "036000291453",
"unit_net_weight": "3.1",
"strain_id": "00000000-0000-0000-0000-0000000000a3",
"name": "Updated Name"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 2e34984deb881a000000000000000001-29cdf092242abbf9-0
{
"data": {
"brand": {
"id": "00000000-0000-0000-0000-000000001ce8",
"name": "Company 12757",
"updated_datetime": "2025-06-12T15:34:22.604351Z"
},
"category": {
"id": "00000000-0000-0000-0000-0000000017fa",
"name": "Some category 5478",
"type": "OTHER"
},
"custom_data": [],
"description": "My Product Description",
"external_name": "External Name",
"id": "2237e64d-7d32-41c5-8619-7415d7359a73",
"images": [],
"is_active": false,
"msrp": "100.5",
"name": "Updated Name",
"sku": "45678",
"strain": {
"id": "00000000-0000-0000-0000-0000000000a3",
"name": "Strain 160"
},
"subcategory": {
"id": "00000000-0000-0000-0000-0000000017a8",
"name": "Some subcategory 5136"
},
"unit_price": "200",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002ac79",
"name": "Unit"
},
"units_per_case": "0.2",
"updated_datetime": "2025-06-12T15:34:22.684604Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001ce3",
"name": "Company 12748",
"updated_datetime": "2025-06-12T15:34:22.568655Z"
}
}
}
POST /public/v1/orders Menus act as expected
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjMsImlhdCI6MTc0OTc0MjQ2MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTRiYmIzYTQtOWQ5NS00Nzc0LTg0YmEtMGVhMWQ4OTJjYjRhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY5NjMiLCJ0eXAiOiJhY2Nlc3MifQ.Hshm7_SQKqtJ1p0yKNykU94-aBFQe9BbE6UqU5yCW3Q
{
"category_id": "00000000-0000-0000-0000-00000000181a",
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"inventory_tracking_method": "PACKAGE",
"menu_visibility": "INCLUDE_IN_ALL",
"menus": [
"00000000-0000-0000-0000-0000000001ec"
],
"name": "My Product",
"sku": "12345",
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002b15d",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001d0d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ba6456856900a0000000000000000001-f72597cbce2a669d-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-00000000181a",
"name": "Some category 5510",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b15d",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:23.274529Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d0d",
"name": "Company 12809",
"updated_datetime": "2025-06-12T15:34:23.097796Z"
}
}
}
POST /public/v1/orders Menus act as expected
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjMsImlhdCI6MTc0OTc0MjQ2MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTRiYmIzYTQtOWQ5NS00Nzc0LTg0YmEtMGVhMWQ4OTJjYjRhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY5NjMiLCJ0eXAiOiJhY2Nlc3MifQ.Hshm7_SQKqtJ1p0yKNykU94-aBFQe9BbE6UqU5yCW3Q
{
"category_id": "00000000-0000-0000-0000-00000000181a",
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"inventory_tracking_method": "PACKAGE",
"menu_visibility": "DO_NOT_INCLUDE",
"menus": [
"00000000-0000-0000-0000-0000000001ec",
"00000000-0000-0000-0000-0000000001ed"
],
"name": "My Product",
"sku": "12345",
"tags": [],
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002b15d",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001d0d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ba6456856900a0000000000000000001-cff9d3a83fe5837e-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-00000000181a",
"name": "Some category 5510",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b15d",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:23.446390Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d0d",
"name": "Company 12809",
"updated_datetime": "2025-06-12T15:34:23.097796Z"
}
}
}
POST /public/v1/orders Menus act as expected
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjMsImlhdCI6MTc0OTc0MjQ2MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTRiYmIzYTQtOWQ5NS00Nzc0LTg0YmEtMGVhMWQ4OTJjYjRhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY5NjMiLCJ0eXAiOiJhY2Nlc3MifQ.Hshm7_SQKqtJ1p0yKNykU94-aBFQe9BbE6UqU5yCW3Q
{
"category_id": "00000000-0000-0000-0000-00000000181a",
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"inventory_tracking_method": "PACKAGE",
"menu_visibility": "INCLUDE_IN_SELECT",
"menus": [
"00000000-0000-0000-0000-0000000001ec",
"00000000-0000-0000-0000-0000000001ed"
],
"name": "My Product",
"sku": "12345",
"tags": [],
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002b15d",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001d0d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ba6456856900a0000000000000000001-c898c616744556d6-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-00000000181a",
"name": "Some category 5510",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b15d",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:23.569553Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d0d",
"name": "Company 12809",
"updated_datetime": "2025-06-12T15:34:23.097796Z"
}
}
}
POST /public/v1/orders Menus act as expected
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjMsImlhdCI6MTc0OTc0MjQ2MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTRiYmIzYTQtOWQ5NS00Nzc0LTg0YmEtMGVhMWQ4OTJjYjRhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY5NjMiLCJ0eXAiOiJhY2Nlc3MifQ.Hshm7_SQKqtJ1p0yKNykU94-aBFQe9BbE6UqU5yCW3Q
{
"category_id": "00000000-0000-0000-0000-00000000181a",
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"inventory_tracking_method": "PACKAGE",
"menu_visibility": "INCLUDE_IN_SELECT",
"menus": [
"00000000-0000-0000-0000-0000000001ed"
],
"name": "My Product",
"sku": "12345",
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002b15d",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001d0d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ba6456856900a0000000000000000001-b97a9b16b00ffa74-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-00000000181a",
"name": "Some category 5510",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b15d",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:23.691811Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d0d",
"name": "Company 12809",
"updated_datetime": "2025-06-12T15:34:23.097796Z"
}
}
}
POST /public/v1/orders Menus act as expected
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjMsImlhdCI6MTc0OTc0MjQ2MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiYTRiYmIzYTQtOWQ5NS00Nzc0LTg0YmEtMGVhMWQ4OTJjYjRhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY5NjMiLCJ0eXAiOiJhY2Nlc3MifQ.Hshm7_SQKqtJ1p0yKNykU94-aBFQe9BbE6UqU5yCW3Q
{
"category_id": "00000000-0000-0000-0000-00000000181a",
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"inventory_tracking_method": "PACKAGE",
"menu_visibility": "INCLUDE_IN_SELECT",
"menus": [],
"name": "My Product",
"sku": "12345",
"unit_price": "100",
"unit_type_id": "00000000-0000-0000-0000-00000002b15d",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001d0d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ba6456856900a0000000000000000001-a3e5d6a2341abd2d-0
{
"data": {
"brand": null,
"category": {
"id": "00000000-0000-0000-0000-00000000181a",
"name": "Some category 5510",
"type": "OTHER"
},
"custom_data": [],
"description": null,
"external_name": null,
"id": "9bbb3a59-c443-48c9-9602-6611070ad497",
"images": [],
"is_active": true,
"msrp": null,
"name": "My Product",
"sku": "12345",
"strain": null,
"subcategory": null,
"unit_price": "100",
"unit_type": {
"id": "00000000-0000-0000-0000-00000002b15d",
"name": "Gram"
},
"units_per_case": null,
"updated_datetime": "2025-06-12T15:34:23.787071Z",
"vendor": {
"id": "00000000-0000-0000-0000-000000001d0d",
"name": "Company 12809",
"updated_datetime": "2025-06-12T15:34:23.097796Z"
}
}
}
POST /public/v1/orders Error pointers are properly transformed to reflect the field name that our api users expect
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjAsImlhdCI6MTc0OTc0MjQ2MCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzk4NTAwYWEtOTczYi00ZGZkLTgxYzMtNTk3YWU1MjA4OWJkIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDU5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY1MDgiLCJ0eXAiOiJhY2Nlc3MifQ.W6dgPwm9ZIYmub9XbUmrURegTXXEmtsp5mdPXXJdgSI
{
"id": "3b5b5d0d-6284-48d7-b4e6-dc0a58314a31",
"menu_visibility": "INCLUDE_IN_ALL",
"quantity_available_threshold_max": "-4.5",
"quantity_available_threshold_min": "-5.5",
"unit_net_weight": "3.1",
"unit_serving_size": "5.2"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 5f8ddb23f2e1dc000000000000000001-cfcac0b17ac18ccd-0
{
"errors": [
{
"context": {
"id": "3b5b5d0d-6284-48d7-b4e6-dc0a58314a31"
},
"message": "A unit type needs to be selected when setting Unit Net Weight/Volume or Unit Serving Size",
"pointer": [
"unit_net_weight_and_serving_size_unit_type_id"
],
"section": "body"
},
{
"context": {
"id": "3b5b5d0d-6284-48d7-b4e6-dc0a58314a31"
},
"message": "Unit Serving Size can't be greater than Unit Net Weight/Volume",
"pointer": [
"unit_serving_size"
],
"section": "body"
},
{
"context": {
"id": "3b5b5d0d-6284-48d7-b4e6-dc0a58314a31"
},
"message": "Cannot be negative",
"pointer": [
"quantity_available_threshold_max"
],
"section": "body"
},
{
"context": {
"id": "3b5b5d0d-6284-48d7-b4e6-dc0a58314a31"
},
"message": "Cannot be negative",
"pointer": [
"quantity_available_threshold_min"
],
"section": "body"
}
]
}
POST /public/v1/orders Errors when threshold max is less than threshold min
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNTksImlhdCI6MTc0OTc0MjQ1OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiODQyMWNlOWYtMDBlYi00ZDU3LThmOTMtNzI4MzViY2EyYzhiIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDU4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTYzODQiLCJ0eXAiOiJhY2Nlc3MifQ.5tHCSCEK4-kdplBmsAuPwLL8i2lFM5nHMGp3XPIjA2c
{
"id": "3ab1fae4-d038-4bf5-8767-cc1bcc52ab5c",
"quantity_available_threshold_max": "4.5",
"quantity_available_threshold_min": "5.5"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: c9f4533743d7b8000000000000000001-e9e354ed24dd2149-0
{
"errors": [
{
"context": {
"id": "3ab1fae4-d038-4bf5-8767-cc1bcc52ab5c"
},
"message": "Must be greater than threshold min",
"pointer": [
"quantity_available_threshold_max"
],
"section": "body"
},
{
"context": {
"id": "3ab1fae4-d038-4bf5-8767-cc1bcc52ab5c"
},
"message": "Must be less than threshold max",
"pointer": [
"quantity_available_threshold_min"
],
"section": "body"
}
]
}
POST /public/v1/orders Cannot use associations from another company
POST /public/v1/products
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjEsImlhdCI6MTc0OTc0MjQ2MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiODkwMGRiZDYtMjU3Yi00ZjliLThiODEtOTA2M2M2YmU0MzdmIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDYwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTY3NzUiLCJ0eXAiOiJhY2Nlc3MifQ.BYGFqSAci2vEao1i85quYC2fWpvjIY7Scww5EOjqjRc
{
"brand_id": "00000000-0000-0000-0000-000000001cb4",
"category_id": "00000000-0000-0000-0000-0000000017c7",
"cbd": "5.2",
"description": "My Product Description",
"group_id": "00000000-0000-0000-0000-00000000142a",
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e",
"inventory_tracking_method": "PACKAGE",
"is_featured": true,
"is_inactive": true,
"menu_visibility": "INCLUDE_IN_ALL",
"menus": [
"00000000-0000-0000-0000-0000000001e3",
"00000000-0000-0000-0000-0000000001e4",
"00000000-0000-0000-0000-0000000001e5"
],
"msrp": "100.5",
"name": "My Product",
"owner_id": "00000000-0000-0000-0000-000000004191",
"quantity_available_threshold_max": "10.5",
"quantity_available_threshold_min": "5.5555",
"sku": "12345",
"strain_id": "00000000-0000-0000-0000-0000000000a1",
"subcategory_id": "00000000-0000-0000-0000-00000000177e",
"tags": [
"00000000-0000-0000-0000-0000000000b7",
"00000000-0000-0000-0000-0000000000b8",
"00000000-0000-0000-0000-0000000000b9"
],
"thc": "10.4",
"unit_cost": "50.4",
"unit_net_weight": "3.1",
"unit_net_weight_and_serving_size_unit_type_id": "00000000-0000-0000-0000-00000002aa62",
"unit_price": "100",
"unit_serving_size": "2.2",
"unit_type_id": "00000000-0000-0000-0000-00000002aa69",
"units_per_case": "0.2",
"upc": "036000291452",
"vendor_id": "00000000-0000-0000-0000-000000001cae",
"wholesale_unit_price": "90.50"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: d21013d8a80e50000000000000000001-118fe944fc89bca0-0
{
"errors": [
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Brand does not exist",
"pointer": [
"brand_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Category does not exist",
"pointer": [
"category_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Vendor does not exist",
"pointer": [
"vendor_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Group does not exist",
"pointer": [
"group_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Serving unit type does not exist",
"pointer": [
"unit_net_weight_and_serving_size_unit_type_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Owner does not exist",
"pointer": [
"owner_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Strain does not exist",
"pointer": [
"strain_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Subcategory does not belong to the product category",
"pointer": [
"subcategory_id"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "One or more of the provided tags do not exist",
"pointer": [
"tags"
],
"section": "body"
},
{
"context": {
"id": "380b3aaf-76c2-4183-b695-e21e8e5b466e"
},
"message": "Unit type does not exist",
"pointer": [
"unit_type_id"
],
"section": "body"
},
{
"context": {},
"message": "Menu does not exist",
"pointer": [
"menus",
0,
"00000000-0000-0000-0000-0000000001e3"
],
"section": "body"
},
{
"context": {},
"message": "Menu does not exist",
"pointer": [
"menus",
1,
"00000000-0000-0000-0000-0000000001e4"
],
"section": "body"
}
]
}
Upsert a single product. To update an existing product, pass in an existing product ID in the id field. When updating a product, you must pass in all fields (no sparse update currently supported).Any existing tag you do not pass in to tags will be deleted. If the menu_visibility field isset to INCLUDE_IN_SELECT, any existing menu that you do not pass into menus will be deleted.
Request
POST /public/v1/products
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
id | Unique ID for this product. If it exists, an update will be performed; otherwise, it will be used as the ID of a new product record | query | string | false | ||
inventory_tracking_method | Once the tracking method is set for a product, it cannot be changed. The tracking method can be one of the following: PACKAGE: The inventory will be defined by packages. PRODUCT: Not grouped in any manner. The inventory simply exists on your product that you can add or remove as you transact. BATCH: Grouped by batches. Batches share common traits such as expiration dates and test results. | query | string | false | PACKAGE | |
sku | Stock Keeping Unit (SKU) for this product | query | string | false | SKU123 | |
name | Name of the product | query | string | false | King Size Pre-rolls | |
vendor_id | The ID of the company_relationship association with the vendor (company) that supplies this product. | query | string | false | ||
category_id | The ID of the product category of the product. | query | string | false | ||
external_name | Customer-facing name for DistruCommerce menus and Order Tracker. Defaults to Product Name if left blank | query | string | false | ||
unit_type_id | The ID of the unit type the product. | query | string | false | ||
unit_price | The sale price of the product per unit. | query | number | false | ||
description | Description of the product | query | string | false | A pack of 5 pre-rolls | |
upc | Universal Product Code (UPC) for this product | query | string | false | 123456789012 | |
subcategory_id | The ID of the product subcategory of the product. The provided subcategory must be a child of the provided category. | query | string | false | ||
group_id | The ID of the product's group. | query | string | false | ||
brand_id | The ID of the company_relationship association with the brand (company) that is associated with this product. | query | query | false | ||
quantity_available_threshold_min | The minimum quantity of the product you'd like to maintain. When the product inventory count dips below this number, it will automatically be included in scheduled Low Inventory Reports. | query | number | false | ||
quantity_available_threshold_max | The maximum quantity of the product you'd like to maintain. When the product inventory count exceeds this number, it will automatically be included in scheduled Inventory Reports. | query | number | false | ||
units_per_case | The number of units in a case of the product. | query | number | false | ||
unit_cost | The cost of the product per unit. | query | number | false | ||
msrp | The Manufacturer's Suggested Retail Price (MSRP) of the product per unit. If you have POS integrations enabled in Distru, this may be synced to your POS | query | number | false | ||
wholesale_unit_price | The wholesale price of the product per unit. | query | number | false | ||
is_featured | Whether the product is featured. Featured products will be displayed at the top of menus. | query | boolean | false | ||
strain_id | The ID of the strain associated with the product. | query | string | false | ||
owner_id | The ID of the user that is deemed to be the owner of the product. | query | string | false | ||
is_inactive | Whether the product is inactive from use. Inactive products can be set to active at any time. | query | boolean | false | ||
total_cannabinoid_unit | The unit of the THC/CBD content of the product (MG or PERCENT). | query | string | false | ||
total_thc | The THC content of the product in the unit specified by total_cannabinoid_unit. Must also include total_cannabinoid_unit. | query | string | false | ||
total_cbd | The CBD content of the product in the unit specified by total_cannabinoid_unit. Must also include total_cannabinoid_unit. | query | string | false | ||
menu_visibility | This key is responsible for which menus (if any) the product will be displayed in. DO_NOT_INCLUDE: The product will not be displayed in any menus. INCLUDE_IN_ALL: The product will be displayed in all menus. INCLUDE_IN_SELECT: The product will be displayed in menus that have been explicitly selected (passed into the menus list). | query | string | false | ||
unit_net_weight | The net weight of the product per unit. | query | number | false | ||
unit_serving_size | The serving size of the product per unit. | query | number | false | ||
unit_net_weight_and_serving_size_unit_type_id | The ID of the unit type that the net quantity per unit and serving size are measured in. This field should be null unless the product's unit type is count-based. If this field is set, the act of changing the category from 'Unit' will throw an error. | query | string | false | ||
tags | A list of tags associated with the product. | query | array | false | ["0ef8347c-b714-4cd9-ba0e-872488bc9244", "daa0294c-833c-42bd-a133-b4c9e7f64017"] | |
menus | A list of menus you would like this product to be included in. This field will only be used if the menu_visibility key is set to INCLUDE_IN_SELECT. | query | array | false | ["0ef8347c-b714-4cd9-ba0e-872488bc9244", "daa0294c-833c-42bd-a133-b4c9e7f64017"] |
Responses
Status | Description | Schema |
---|---|---|
200 | A single product | Product |
Purchase
Get purchases
GET /public/v1/purchases returns purchases related to the company
GET /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTEsImlhdCI6MTc0OTc0MjU1MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMmM5MjQ2Y2ItMDJhMC00YTBhLTk3YzItYzM5NWI5MTJiODBhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTUwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzM2MDEiLCJ0eXAiOiJhY2Nlc3MifQ.Lbst1pThJh2mRRq3dHV9PsQTSlVXhfYc-PAY-DOtqTs
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: fda92e3ad924d8000000000000000001-50a83782a6c5a5c1-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-000000003833",
"name": "Company 25221",
"updated_datetime": "2025-06-12T15:35:51.717917Z"
},
"custom_data": [
{
"id": 96,
"name": "Custom Field 125",
"value": null
}
],
"due_datetime": "2025-06-12T15:35:51.791559Z",
"id": "00000000-0000-0000-0000-00000000019e",
"inserted_datetime": "2025-06-12T15:35:51.794552Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002586",
"name": "B29291"
},
"compliance_quantity": null,
"id": "29e7bb3b-7886-4553-8080-f537275e26f5",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000062ca",
"id": "00000000-0000-0000-0000-0000000029b4",
"license_id": null,
"name": "Place 10517"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "9c0f70f7-4367-4f15-9ff5-da8985eb682b",
"name": "Product 29259",
"sku": "sku 29260",
"updated_datetime": "2025-06-12T15:35:51.818376Z"
},
"quantity": "15.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002587",
"name": "B29292"
},
"compliance_quantity": null,
"id": "311ee8d3-438a-4b8a-b66e-16e43d1f5deb",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000062ca",
"id": "00000000-0000-0000-0000-0000000029b4",
"license_id": null,
"name": "Place 10517"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "db646a7b-f137-45d3-be7f-c05703752d30",
"name": "Product 29273",
"sku": "sku 29274",
"updated_datetime": "2025-06-12T15:35:51.848717Z"
},
"quantity": "10.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002588",
"name": "B29293"
},
"compliance_quantity": null,
"id": "5f52ec6d-0500-4c7b-85b4-dd5a6b616cfe",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000062ca",
"id": "00000000-0000-0000-0000-0000000029b4",
"license_id": null,
"name": "Place 10517"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "01d1f344-0dc8-4c61-8baa-a22c8ea99aec",
"name": "Product 29284",
"sku": "sku 29285",
"updated_datetime": "2025-06-12T15:35:51.877671Z"
},
"quantity": "5.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002589",
"name": "B29294"
},
"compliance_quantity": null,
"id": "bfef2b82-8417-4d20-b332-4fa6bac2ce12",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000062ca",
"id": "00000000-0000-0000-0000-0000000029b4",
"license_id": null,
"name": "Place 10517"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "0d65e374-e68e-42af-aeed-0321f0a43423",
"name": "Product 29289",
"sku": "sku 29290",
"updated_datetime": "2025-06-12T15:35:51.902520Z"
},
"quantity": "2.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2025-06-12T15:35:51.791554Z",
"purchase_number": "Purchase #320",
"status": "PENDING",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:51.794552Z"
},
{
"charges": [
{
"id": "9538a329-e248-4a5d-bb53-669f3dbcea7f",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000003826",
"name": "Company 25208",
"updated_datetime": "2030-11-01T00:00:00.000000Z"
},
"custom_data": [
{
"id": 96,
"name": "Custom Field 125",
"value": "Custom Field Value 1"
}
],
"due_datetime": "2020-01-01T00:00:01.000000Z",
"id": "00000000-0000-0000-0000-00000000019d",
"inserted_datetime": "2020-01-01T00:00:03.000000Z",
"items": [
{
"batch": {
"batch_number": "UID1",
"id": "00000000-0000-0000-0000-00000000256c",
"name": "B1"
},
"compliance_quantity": "1.0000",
"id": "2f3e32e0-082d-4017-abf6-ee6dcb17db27",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-0000000062ca",
"id": "00000000-0000-0000-0000-00000000299b",
"license_id": "00000000-0000-0000-0000-0000000017a2",
"name": "Place 10492"
},
"package": {
"batch_number": "B1",
"compliance_label": "ABCDEF012345670000008193",
"id": "00000000-0000-0000-0000-000000000ab3",
"metrc_label": "ABCDEF012345670000008193",
"status": "active"
},
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "49e19a5a-27c5-484d-b309-0de18fc51a82",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2023-11-02T00:00:00.000000Z"
},
"quantity": "1.000000000",
"received_quantity": "1.000000000"
}
],
"order_datetime": "2020-01-01T00:00:02.000000Z",
"purchase_number": "SO-123",
"status": "COMPLETED",
"total": "10.00",
"updated_datetime": "2020-01-01T00:00:04.000000Z"
}
]
}
GET /public/v1/purchases allows filtering by several statuses
GET /public/v1/purchases?status[]=Completed&status[]=Pending
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDEsImlhdCI6MTc0OTc0MjU0MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOGYyZWY2MWUtY2Y0OC00NzcyLTk2NDctMmJiMzVmOTYyY2EwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE3NTUiLCJ0eXAiOiJhY2Nlc3MifQ.xvgKchq-tk7Qgq_1lxJsLQuwnUEb_Pmql7C3-kR5f04
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 11dfe4cd70d2af000000000000000001-a6be5a6f6bf8236a-0
{
"data": [
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000352b",
"name": "Company 23996",
"updated_datetime": "2025-06-12T15:35:42.169042Z"
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:42.238945Z",
"id": "00000000-0000-0000-0000-000000000157",
"inserted_datetime": "2025-06-12T15:35:42.240690Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002392",
"name": "B27829"
},
"compliance_quantity": null,
"id": "488e19af-1c91-4860-aabe-bc7e60aa85ab",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026dd",
"license_id": null,
"name": "Place 9830"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "355f9a5f-3dfe-45c5-a242-2ecfaeea0c14",
"name": "Product 27819",
"sku": "sku 27820",
"updated_datetime": "2025-06-12T15:35:42.261030Z"
},
"quantity": "15.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002393",
"name": "B27832"
},
"compliance_quantity": null,
"id": "6b11de0f-f852-4274-8528-c158f2e996c6",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026dd",
"license_id": null,
"name": "Place 9830"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "ace3bef7-d69f-47eb-a9b5-c829f0b543d8",
"name": "Product 27823",
"sku": "sku 27824",
"updated_datetime": "2025-06-12T15:35:42.285974Z"
},
"quantity": "10.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002395",
"name": "B27834"
},
"compliance_quantity": null,
"id": "8d171db0-6cdb-4304-a6ae-375ec9d9bd69",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026dd",
"license_id": null,
"name": "Place 9830"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "31a10f42-893b-4299-9802-9777a12233b8",
"name": "Product 27825",
"sku": "sku 27826",
"updated_datetime": "2025-06-12T15:35:42.311607Z"
},
"quantity": "5.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002396",
"name": "B27835"
},
"compliance_quantity": null,
"id": "474ed671-1b3f-4ff6-a15a-19c518c13360",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026dd",
"license_id": null,
"name": "Place 9830"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "778c70af-b01b-4d32-9ad1-24c407638dff",
"name": "Product 27827",
"sku": "sku 27828",
"updated_datetime": "2025-06-12T15:35:42.338741Z"
},
"quantity": "2.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-01T12:30:00.000000Z",
"purchase_number": "Purchase #259",
"status": "PENDING",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:42.240690Z"
},
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000350c",
"name": "Company 23948",
"updated_datetime": "2025-06-12T15:35:41.927454Z"
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:41.996853Z",
"id": "00000000-0000-0000-0000-000000000154",
"inserted_datetime": "2025-06-12T15:35:41.998475Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002386",
"name": "B27793"
},
"compliance_quantity": null,
"id": "a8df304c-c149-483d-9fc6-75413d9340fa",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026c5",
"license_id": null,
"name": "Place 9807"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "2eb35439-d99a-4c0e-a7cf-89461a8fffa0",
"name": "Product 27765",
"sku": "sku 27766",
"updated_datetime": "2025-06-12T15:35:42.015768Z"
},
"quantity": "15.000000000",
"received_quantity": "15.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002388",
"name": "B27795"
},
"compliance_quantity": null,
"id": "5766e583-d13f-4382-97a1-d5913f06abb7",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026c5",
"license_id": null,
"name": "Place 9807"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "586f8c1f-2fc6-4cff-b076-3d94a5be62d8",
"name": "Product 27774",
"sku": "sku 27775",
"updated_datetime": "2025-06-12T15:35:42.052321Z"
},
"quantity": "10.000000000",
"received_quantity": "10.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000238b",
"name": "B27798"
},
"compliance_quantity": null,
"id": "f32e4e88-b976-4f63-b6f6-4770b6ce39ab",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026c5",
"license_id": null,
"name": "Place 9807"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "617685d7-3cef-4647-8be3-4054ed924463",
"name": "Product 27781",
"sku": "sku 27782",
"updated_datetime": "2025-06-12T15:35:42.077960Z"
},
"quantity": "5.000000000",
"received_quantity": "5.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000238c",
"name": "B27801"
},
"compliance_quantity": null,
"id": "01bffa55-fa4b-418a-a4b9-8a82f0bc813c",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026c5",
"license_id": null,
"name": "Place 9807"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "69cbe7f8-4c38-4b15-9c6b-ced5ead0b03a",
"name": "Product 27790",
"sku": "sku 27791",
"updated_datetime": "2025-06-12T15:35:42.108347Z"
},
"quantity": "2.000000000",
"received_quantity": "2.000000000"
}
],
"order_datetime": "2020-01-01T12:20:00.000000Z",
"purchase_number": "Purchase #258",
"status": "COMPLETED",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:41.998475Z"
},
{
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-0000000034d9",
"name": "Company 23863",
"updated_datetime": "2025-06-12T15:35:41.460717Z"
},
"custom_data": [],
"due_datetime": "2025-06-12T15:35:41.539119Z",
"id": "00000000-0000-0000-0000-000000000150",
"inserted_datetime": "2025-06-12T15:35:41.540892Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002366",
"name": "B27695"
},
"compliance_quantity": null,
"id": "979fe09f-0fbb-4240-a256-6426c93f513b",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026a1",
"license_id": null,
"name": "Place 9773"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "03e1db7b-5b51-4561-977d-04646309b351",
"name": "Product 27689",
"sku": "sku 27690",
"updated_datetime": "2025-06-12T15:35:41.626353Z"
},
"quantity": "5.000000000",
"received_quantity": "5.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002367",
"name": "B27696"
},
"compliance_quantity": null,
"id": "a7fec39c-65b3-4526-8e50-85ffba6865dd",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026a1",
"license_id": null,
"name": "Place 9773"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "864d1e12-df55-4d11-bfee-78d6e2f3bac4",
"name": "Product 27691",
"sku": "sku 27692",
"updated_datetime": "2025-06-12T15:35:41.653890Z"
},
"quantity": "2.000000000",
"received_quantity": "2.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002364",
"name": "B27693"
},
"compliance_quantity": null,
"id": "8b889b21-8d36-450e-bc8c-43d745496d7d",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026a1",
"license_id": null,
"name": "Place 9773"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "93c18f61-65fc-436e-9023-87e54d1e911d",
"name": "Product 27670",
"sku": "sku 27671",
"updated_datetime": "2025-06-12T15:35:41.569672Z"
},
"quantity": "15.000000000",
"received_quantity": "15.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002365",
"name": "B27694"
},
"compliance_quantity": null,
"id": "5fca0be5-34dc-4a69-a99b-33d857f95d3c",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005d9c",
"id": "00000000-0000-0000-0000-0000000026a1",
"license_id": null,
"name": "Place 9773"
},
"package": null,
"price": "10.000000000",
"price_base": "10",
"product": {
"id": "59fa64e0-cb96-44f3-8a9a-5abac4b81a57",
"name": "Product 27678",
"sku": "sku 27679",
"updated_datetime": "2025-06-12T15:35:41.600277Z"
},
"quantity": "10.000000000",
"received_quantity": "10.000000000"
}
],
"order_datetime": "2020-01-01T12:00:00.000000Z",
"purchase_number": "Purchase #253",
"status": "COMPLETED",
"total": "32.00",
"updated_datetime": "2025-06-12T15:35:41.540892Z"
}
]
}
Get purchases sorted by Order Date descendingly date and filtered by various attributes.
Note: The page size for this endpoint is 500 purchase orders per page.
Request
GET /public/v1/purchases
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
due_datetime | Filter purchases by the due datetime | query | string | false | ,2022-07-10T00:00:00Z | |
inserted_datetime | Filter purchases by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
order_datetime | Filter purchases by the order datetime | query | string | false | 2022-07-10T00:00:00Z,2022-07-11T00:00:00Z | |
page | Pagination information | body | Page | false | ||
status | Filter purchases by their status. Accepted values are "Completed", "Delivering", "Partially Received", "Pending", "Processing". | query | array | false | ["Pending","Processing"] | |
updated_datetime | Filter purchases by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of purchases | Purchases |
Insert a payment for a purchase
POST /purchases/:id/payments can create a payment for an purchase with both quickbooks id and name
POST /public/v1/purchases/00000000-0000-0000-0000-000000000181/payments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDgsImlhdCI6MTc0OTc0MjU0OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNmEwZWM0NTItMjBhNS00NGIzLWI5ZDAtMDNkY2UyMTVhNTM2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzMxMDYiLCJ0eXAiOiJhY2Nlc3MifQ.AdSFx4KHFiHh1vgZl80p5bSfAK5B27083Rv-bQpSXdE
{
"amount": 100.01,
"description": "Payment for purchase",
"payment_datetime": "2020-01-01T00:00:00.000000Z",
"payment_method_id": "00000000-0000-0000-0000-000000000079",
"quickbooks_deposit_account_id": "QBD-123"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: eb1b499bcb74d8000000000000000001-ab03cc7120cb0461-0
{
"data": {
"amount": "100.01",
"description": "Payment for purchase",
"id": "00000000-0000-0000-0000-00000000001d",
"inserted_datetime": "2025-06-12T15:35:48.205769Z",
"payment_date": "2020-01-01T00:00:00.000000Z",
"payment_method": {
"id": "00000000-0000-0000-0000-000000000079",
"name": "Payment Method 0"
},
"payment_number": "PYT-0000001",
"purchase_id": "00000000-0000-0000-0000-000000000181",
"quickbooks_deposit_account_id": "QBD-123"
}
}
POST /purchases/:id/payments can create a payment for an purchase with both quickbooks id and name
POST /public/v1/purchases/00000000-0000-0000-0000-000000000181/payments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDgsImlhdCI6MTc0OTc0MjU0OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNmEwZWM0NTItMjBhNS00NGIzLWI5ZDAtMDNkY2UyMTVhNTM2IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzMxMDYiLCJ0eXAiOiJhY2Nlc3MifQ.AdSFx4KHFiHh1vgZl80p5bSfAK5B27083Rv-bQpSXdE
{
"amount": 100.01,
"description": "Payment for purchase",
"payment_datetime": "2020-01-01T00:00:00.000000Z",
"payment_method_id": "00000000-0000-0000-0000-000000000079",
"quickbooks_deposit_account_name": "QBD-NAME"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: eb1b499bcb74d8000000000000000001-6aba13287aadabd8-0
{
"data": {
"amount": "100.01",
"description": "Payment for purchase",
"id": "00000000-0000-0000-0000-00000000001e",
"inserted_datetime": "2025-06-12T15:35:48.498727Z",
"payment_date": "2020-01-01T00:00:00.000000Z",
"payment_method": {
"id": "00000000-0000-0000-0000-000000000079",
"name": "Payment Method 0"
},
"payment_number": "PYT-0000002",
"purchase_id": "00000000-0000-0000-0000-000000000181",
"quickbooks_deposit_account_id": "QBD-123"
}
}
Request
POST /public/v1/purchases/{id}/payments
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
payment_method_id | Payment method ID | query | string | true | ||
amount | Amount of the payment. Will round to 2 decimal places | query | decimal | true | ||
payment_datetime | Payment date | query | string | true | ||
description | Description of the payment | query | string | true | ||
quickbooks_deposit_account_id | Quickbooks deposit account ID. Cannot include both this and quickbooks_deposit_account_name. If user's company is integrated with Quickbooks, either this or quickbooks_deposit_account_name must be provided. Account type must be "Bank" or "Credit Card" | query | string | false | ||
quickbooks_deposit_account_name | Quickbooks deposit account name. Cannot include both this and quickbooks_deposit_account_id. If user's company is integrated with Quickbooks, either this or quickbooks_deposit_account_id must be provided. Account type must be "Bank" or "Credit Card" | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A single payment | PurchasePayment |
Upsert a purchase order
POST /public/v1/purchases creates a purchase (with product-tracked item)
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDQsImlhdCI6MTc0OTc0MjU0NCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMWQ0N2EzZTQtNGQ3Mi00NjQ5LWE4YzctODVlMzFhYTk2ZmIxIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzI0MDciLCJ0eXAiOiJhY2Nlc3MifQ.QtBsMNN179BHzJhbN1ecmSus16JHixpFR1iPE9cPMCI
{
"billing_location_id": "00000000-0000-0000-0000-00000000279b",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-0000000035d7",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-00000000279a",
"price": "10.000000000",
"product_id": "f42929c9-2066-4197-b298-e078cc22dd1e",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-00000000279a",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ea8ae748e87ba0000000000000000001-c7bf13517fd863e8-0
{
"data": {
"charges": [
{
"id": "65497deb-f436-4cc8-b9a7-5af0a10120f8",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "4ace5a78-17c8-4cae-be97-b83a1b298672",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-0000000035d7",
"name": "Company 24296",
"updated_datetime": "2025-06-12T15:35:44.150669Z"
},
"custom_data": [
{
"id": 92,
"name": "Custom Field 122",
"value": null
}
],
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000165",
"inserted_datetime": "2025-06-12T15:35:44.660682Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000023fe",
"name": "B1"
},
"compliance_quantity": null,
"id": "790dc90d-788c-4a38-9e8f-2cbcccf3462f",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005f4e",
"id": "00000000-0000-0000-0000-00000000279a",
"license_id": "00000000-0000-0000-0000-0000000016a9",
"name": "Place 10006"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "f42929c9-2066-4197-b298-e078cc22dd1e",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:44.601120Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-01T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "6.00",
"updated_datetime": "2025-06-12T15:35:44.701315Z"
}
}
POST /public/v1/purchases creates a purchase (with batch-tracked item)
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDIsImlhdCI6MTc0OTc0MjU0MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNWYxOGRhYzEtNjQ5YS00NmI1LTgxNTktNjUzYzgxOGRiOWY4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE5OTIiLCJ0eXAiOiJhY2Nlc3MifQ.qcETBoYfYrue14_JyGlYQ_vYnFfd87Iqx4w_rTOvBQA
{
"billing_location_id": "00000000-0000-0000-0000-0000000026f0",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-000000003543",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"batch_id": "00000000-0000-0000-0000-00000000239c",
"location_id": "00000000-0000-0000-0000-0000000026f0",
"price": "10.000000000",
"product_id": "ffcfc8c0-f6d8-4c46-8dd0-3240d4c4f9c1",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000026f0",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 801e8849248c78000000000000000001-36565a299e8e8681-0
{
"data": {
"charges": [
{
"id": "7542f020-7aa2-4cbe-a8b2-84c095a611a9",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "ad010203-e15e-4a2c-8baa-b22aed65a245",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000003543",
"name": "Company 24039",
"updated_datetime": "2025-06-12T15:35:42.488191Z"
},
"custom_data": [],
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000158",
"inserted_datetime": "2025-06-12T15:35:42.615133Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-00000000239c",
"name": "B1"
},
"compliance_quantity": null,
"id": "ae9dc8ee-d9ec-4220-820c-c5fb4063d027",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005e4d",
"id": "00000000-0000-0000-0000-0000000026f0",
"license_id": "00000000-0000-0000-0000-00000000164a",
"name": "Place 9848"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "ffcfc8c0-f6d8-4c46-8dd0-3240d4c4f9c1",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:42.552343Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-01T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "6.00",
"updated_datetime": "2025-06-12T15:35:42.636416Z"
}
}
POST /public/v1/purchases creates a purchase (with package-tracked item)
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTIsImlhdCI6MTc0OTc0MjU1MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYjllMTBhMmUtNTlmYy00ODIyLWFmMTItZjZkZDJhZGIyNzkwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTUxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzM3NDUiLCJ0eXAiOiJhY2Nlc3MifQ.E_gA8E2Kv_E7NIFEGO2LVig7emiENsVHFaoGkeHqYwQ
{
"billing_location_id": "00000000-0000-0000-0000-0000000029d1",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"price": "-5.0000",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-00000000385b",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-0000000029d1",
"price": "10.000000000",
"product_id": "d0772efc-258b-45eb-a913-15f0c6688efb",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000029d1",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: cbaa37d31604d8000000000000000001-a05f583eeb41c05c-0
{
"data": {
"charges": [
{
"id": "c8d49eb7-65b9-4a3f-9192-6635db0914a1",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "45b13629-dab0-4dcc-8793-a9b6ed9eae7b",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-00000000385b",
"name": "Company 25279",
"updated_datetime": "2025-06-12T15:35:52.117410Z"
},
"custom_data": [],
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-0000000001a0",
"inserted_datetime": "2025-06-12T15:35:52.281242Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-000000002598",
"name": "B1"
},
"compliance_quantity": null,
"id": "02d03878-4361-4284-8e6d-11349a180ab6",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000632d",
"id": "00000000-0000-0000-0000-0000000029d1",
"license_id": "00000000-0000-0000-0000-0000000017be",
"name": "Place 10546"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "d0772efc-258b-45eb-a913-15f0c6688efb",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:52.210360Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-01T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "6.00",
"updated_datetime": "2025-06-12T15:35:52.301448Z"
}
}
POST /public/v1/purchases updates a purchase
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDgsImlhdCI6MTc0OTc0MjU0OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiODRlODkzMjktYjUxNi00ZThlLWJmODgtZWEyYjc0ZjgyNTZkIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzMxOTIiLCJ0eXAiOiJhY2Nlc3MifQ.g0HmNGnw0i_awhBYZV4R_Y-TC538h6pk3eczaIzMGUA
{
"billing_location_id": "00000000-0000-0000-0000-0000000028d1",
"charges": [
{
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"company_id": "00000000-0000-0000-0000-000000003738",
"due_datetime": "2020-01-20T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-0000000028d1",
"price": "10.000000000",
"product_id": "29b1748b-8996-490c-a999-9bec65992688",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000028d1",
"order_datetime": "2020-01-02T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 4ec034bddc82c8000000000000000001-8c7c6effe4dcaf28-0
{
"data": {
"charges": [
{
"id": "d1816496-281e-40e9-bfba-0ea3ae68760a",
"name": "C1",
"percent": "10.0000",
"price": "1.00",
"type": "CHARGE",
"unit_type": "PERCENT"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000003738",
"name": "Company 24869",
"updated_datetime": "2025-06-12T15:35:48.839229Z"
},
"custom_data": [],
"due_datetime": "2020-01-20T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000185",
"inserted_datetime": "2025-06-12T15:35:49.089379Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000024cf",
"name": "B1"
},
"compliance_quantity": null,
"id": "f00c14a9-ce5a-4116-8ad4-c819c2830db4",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000618a",
"id": "00000000-0000-0000-0000-0000000028d1",
"license_id": "00000000-0000-0000-0000-000000001743",
"name": "Place 10295"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "29b1748b-8996-490c-a999-9bec65992688",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:48.933196Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-02T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "11.00",
"updated_datetime": "2025-06-12T15:35:49.138072Z"
}
}
POST /public/v1/purchases updates a purchase
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDgsImlhdCI6MTc0OTc0MjU0OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiODRlODkzMjktYjUxNi00ZThlLWJmODgtZWEyYjc0ZjgyNTZkIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzMxOTIiLCJ0eXAiOiJhY2Nlc3MifQ.g0HmNGnw0i_awhBYZV4R_Y-TC538h6pk3eczaIzMGUA
{
"billing_location_id": "00000000-0000-0000-0000-0000000028d1",
"charges": [
{
"id": "d1816496-281e-40e9-bfba-0ea3ae68760a",
"name": "C1",
"percent": "10.0000",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company_id": "00000000-0000-0000-0000-000000003738",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000185",
"items": [
{
"id": "f00c14a9-ce5a-4116-8ad4-c819c2830db4",
"location_id": "00000000-0000-0000-0000-0000000028d1",
"price": "10.000000000",
"product_id": "29b1748b-8996-490c-a999-9bec65992688",
"quantity": "1.000000000"
},
{
"batch_id": "00000000-0000-0000-0000-0000000024da",
"location_id": "00000000-0000-0000-0000-0000000028d1",
"price": "5.000000000",
"product_id": "cd4a6a4c-b4a6-4ae6-b16a-efe1caf0937b",
"quantity": "2.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000028d1",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 4ec034bddc82c8000000000000000001-55c18b5af1eac511-0
{
"data": {
"charges": [
{
"id": "d1816496-281e-40e9-bfba-0ea3ae68760a",
"name": "C1",
"percent": "10.0000",
"price": "2.00",
"type": "CHARGE",
"unit_type": "PERCENT"
},
{
"id": "9629f0ac-9e0b-4b60-ad4b-ecc0a98f28c0",
"name": "C2",
"percent": null,
"price": "-5.00",
"type": "DISCOUNT",
"unit_type": "PRICE"
}
],
"company": {
"id": "00000000-0000-0000-0000-000000003738",
"name": "Company 24869",
"updated_datetime": "2025-06-12T15:35:48.839229Z"
},
"custom_data": [],
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000185",
"inserted_datetime": "2025-06-12T15:35:49.089379Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000024cf",
"name": "B1"
},
"compliance_quantity": null,
"id": "f00c14a9-ce5a-4116-8ad4-c819c2830db4",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000618a",
"id": "00000000-0000-0000-0000-0000000028d1",
"license_id": "00000000-0000-0000-0000-000000001743",
"name": "Place 10295"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "29b1748b-8996-490c-a999-9bec65992688",
"name": "P1",
"sku": "SKU1",
"updated_datetime": "2025-06-12T15:35:48.933196Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
},
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000024da",
"name": "B2"
},
"compliance_quantity": null,
"id": "102908d8-5931-4f7c-8f42-c9e0dafa4454",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-00000000618a",
"id": "00000000-0000-0000-0000-0000000028d1",
"license_id": "00000000-0000-0000-0000-000000001743",
"name": "Place 10295"
},
"package": null,
"price": "5.000000000",
"price_base": "5.000000000",
"product": {
"id": "cd4a6a4c-b4a6-4ae6-b16a-efe1caf0937b",
"name": "P2",
"sku": "SKU2",
"updated_datetime": "2025-06-12T15:35:49.009666Z"
},
"quantity": "2.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-01T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "17.00",
"updated_datetime": "2025-06-12T15:35:49.416310Z"
}
}
POST /public/v1/purchases updating a purchase removes line items that aren't included in the payload
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzgsImlhdCI6MTc0OTc0MjUzOCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiY2M0OTU3YzctMGU2NS00YTBiLWFjZmMtNWViNTNhMDhiYTU0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTM3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE0MTciLCJ0eXAiOiJhY2Nlc3MifQ.AuseGMhshuz8PPv5LIP7AUfIRqdBZUITcKDx7NbsYYk
{
"billing_location_id": "00000000-0000-0000-0000-00000000260c",
"company_id": "00000000-0000-0000-0000-00000000341e",
"due_datetime": "2020-01-20T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-00000000260c",
"price": "10",
"product_id": "817bf443-a59e-412a-90dd-dd32313e908d",
"quantity": "1"
}
],
"location_id": "00000000-0000-0000-0000-00000000260c",
"order_datetime": "2020-01-02T00:00:00.000000Z"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 109bf544085b16000000000000000001-2907fe95f2a3eab8-0
{
"data": {
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000341e",
"name": "Company 23528",
"updated_datetime": "2025-06-12T15:35:38.529523Z"
},
"custom_data": [],
"due_datetime": "2020-01-20T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000139",
"inserted_datetime": "2025-06-12T15:35:38.671111Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022e5",
"name": "B27326"
},
"compliance_quantity": null,
"id": "4f379d0e-7ef2-4bd8-b8af-bec1d5419cbb",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005c4d",
"id": "00000000-0000-0000-0000-00000000260c",
"license_id": "00000000-0000-0000-0000-0000000015d2",
"name": "Place 9626"
},
"package": null,
"price": "10.000000000",
"price_base": "10.000000000",
"product": {
"id": "817bf443-a59e-412a-90dd-dd32313e908d",
"name": "Product 27319",
"sku": "sku 27320",
"updated_datetime": "2025-06-12T15:35:38.598622Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-02T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "10.00",
"updated_datetime": "2025-06-12T15:35:38.671111Z"
}
}
POST /public/v1/purchases updating a purchase removes line items that aren't included in the payload
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzgsImlhdCI6MTc0OTc0MjUzOCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiY2M0OTU3YzctMGU2NS00YTBiLWFjZmMtNWViNTNhMDhiYTU0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTM3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE0MTciLCJ0eXAiOiJhY2Nlc3MifQ.AuseGMhshuz8PPv5LIP7AUfIRqdBZUITcKDx7NbsYYk
{
"company_id": "00000000-0000-0000-0000-00000000341e",
"id": "00000000-0000-0000-0000-000000000139",
"items": [
{
"location_id": "00000000-0000-0000-0000-00000000260c",
"price": "2",
"product_id": "817bf443-a59e-412a-90dd-dd32313e908d",
"quantity": "1"
}
]
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 109bf544085b16000000000000000001-0ccea9c447d1a68c-0
{
"data": {
"charges": [],
"company": {
"id": "00000000-0000-0000-0000-00000000341e",
"name": "Company 23528",
"updated_datetime": "2025-06-12T15:35:38.529523Z"
},
"custom_data": [],
"due_datetime": "2020-01-20T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-000000000139",
"inserted_datetime": "2025-06-12T15:35:38.671111Z",
"items": [
{
"batch": {
"batch_number": null,
"id": "00000000-0000-0000-0000-0000000022e5",
"name": "B27326"
},
"compliance_quantity": null,
"id": "5012db41-bd0e-4abf-bcc4-34a0f9159726",
"location": {
"address": "123 Fake Street, Beverly Hills, CA 88888, USA",
"company_id": "00000000-0000-0000-0000-000000005c4d",
"id": "00000000-0000-0000-0000-00000000260c",
"license_id": "00000000-0000-0000-0000-0000000015d2",
"name": "Place 9626"
},
"package": null,
"price": "2.000000000",
"price_base": "2.000000000",
"product": {
"id": "817bf443-a59e-412a-90dd-dd32313e908d",
"name": "Product 27319",
"sku": "sku 27320",
"updated_datetime": "2025-06-12T15:35:38.598622Z"
},
"quantity": "1.000000000",
"received_quantity": "0.000000000"
}
],
"order_datetime": "2020-01-02T00:00:00.000000Z",
"purchase_number": "PO-0000001",
"status": "PENDING",
"total": "2.00",
"updated_datetime": "2025-06-12T15:35:39.035663Z"
}
}
POST /public/v1/purchases does not update a purchase that has moved beyond Pending status
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTIsImlhdCI6MTc0OTc0MjU1MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNzVkZDBmMTgtNWZjNi00NjcwLWE5NzItNTNhZTgzMzc3M2E4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTUxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzM4MzUiLCJ0eXAiOiJhY2Nlc3MifQ.gw_F65K2Mkrasebeau90nY42n3G3KK2rC0hY6aSgxKQ
{
"billing_location_id": "00000000-0000-0000-0000-0000000029ff",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000003880",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"id": "00000000-0000-0000-0000-0000000001a3",
"items": [
{
"batch_id": "00000000-0000-0000-0000-0000000025b3",
"id": "cf00e7d6-8e45-4d6f-9135-684a263459a0",
"location_id": "00000000-0000-0000-0000-0000000029ff",
"price": "10.000000000",
"product_id": "32b2decd-f4ad-4215-9adc-f16cd64423ed",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000029ff",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 7501d0dcaa7534000000000000000001-d8d98868a53c0351-0
{
"errors": [
{
"context": {},
"message": "Cannot change this PO through the Distru API because it's beyond Pending status",
"pointer": [
"status"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a company relationship that belongs to another company
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzYsImlhdCI6MTc0OTc0MjUzNiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMjU2Y2I4N2ItNmE2NS00YWRmLWI0MjgtOWM1OWMyYjVkNzJjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTM1LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzEwOTciLCJ0eXAiOiJhY2Nlc3MifQ.eDK2rHORfR_6c2vW1IVmKbeatlYntoeTfNBzAtsAlj0
{
"billing_location_id": "00000000-0000-0000-0000-000000002592",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000003367",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000002592",
"price": "10.000000000",
"product_id": "a1242f9a-1048-4d31-b84b-1cb08ce4aa72",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000002592",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 847cd917e2c690000000000000000001-cc4f81dd6fc08c5d-0
{
"errors": [
{
"context": {},
"message": "The provided supplier does not exist",
"pointer": [
"company_id"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a product that belongs to another company
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDMsImlhdCI6MTc0OTc0MjU0MywiaXNzIjoiRGlzdHJ1IiwianRpIjoiY2Y3OTM5NTQtYmIxNi00M2Y4LTk4YmQtYzExZjE4MmQzYTc3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQyLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzIzNDgiLCJ0eXAiOiJhY2Nlc3MifQ.w8h5u8HcoLsxk4q8Jzdfq1VDS9jqkZvGfmzSOFkEEfY
{
"billing_location_id": "00000000-0000-0000-0000-000000002787",
"charges": [],
"company_id": "00000000-0000-0000-0000-0000000035c3",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-000000002787",
"price": "10.000000000",
"product_id": "860ccd52-365a-4038-826b-8bb79543b581",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000002787",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 2862e814348672000000000000000001-7bbde137305754d0-0
{
"errors": [
{
"context": {
"id": "a555172c-dedc-4cab-bbec-135c5e214413"
},
"message": "This record does not belong to your company.",
"pointer": [
"items",
0,
"product_id"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a batch that belongs to another company
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDEsImlhdCI6MTc0OTc0MjU0MSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYzk0OTI5ODUtN2YyZS00MTA0LTkzMDEtODY5YWQwYjI1ZjYxIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzE3MTMiLCJ0eXAiOiJhY2Nlc3MifQ.cAjI5olrV3YT_9ziP36jB--pLci99QlxPTXyHkCpsBA
{
"billing_location_id": "00000000-0000-0000-0000-000000002686",
"charges": [],
"company_id": "00000000-0000-0000-0000-0000000034bb",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"batch_id": "00000000-0000-0000-0000-00000000234f",
"location_id": "00000000-0000-0000-0000-000000002686",
"price": "10.000000000",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000002686",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: df08159a726078000000000000000001-615f045807ec6399-0
{
"errors": [
{
"context": {
"id": "502e6f3e-2777-4783-9975-6a3e21eef67d"
},
"message": "This record does not belong to your company.",
"pointer": [
"items",
0,
"product_id"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a location that belongs to another company
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxMzQsImlhdCI6MTc0OTc0MjUzNCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYWQ0YzZkNTItNDZkNi00Y2E5LWI3ODEtZDc1MWZmN2EzNmM1IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTMzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzA3ODIiLCJ0eXAiOiJhY2Nlc3MifQ.l6WEZs07BfEYQqxFbvm6P1YJmC89EaE7v1cJ-r4849o
{
"billing_location_id": "00000000-0000-0000-0000-000000002515",
"charges": [],
"company_id": "00000000-0000-0000-0000-0000000032d7",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-00000000251a",
"price": "10.000000000",
"product_id": "b18b3cee-c7d1-423e-8081-ae3c6b659e83",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-00000000251a",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 3c8cbcc8bf3240000000000000000001-72ccafe8ea433353-0
{
"errors": [
{
"context": {
"id": "4b9d3357-a711-49ee-bb7c-c046f6d8d02a"
},
"message": "This record does not belong to your company.",
"pointer": [
"items",
0,
"location_id"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a location different from the order items
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNDcsImlhdCI6MTc0OTc0MjU0NywiaXNzIjoiRGlzdHJ1IiwianRpIjoiZjBjZWIzYTUtNWMwYy00NTJkLTk2OWQtMjM3OGVhNzQzMjdjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTQ2LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzMwNzEiLCJ0eXAiOiJhY2Nlc3MifQ.gAGYQMAlLSS2voASogv1gIjsWqg6O8wt9kZ294ccBm8
{
"billing_location_id": "00000000-0000-0000-0000-00000000288e",
"charges": [],
"company_id": "00000000-0000-0000-0000-0000000036fb",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-00000000288e",
"price": "10.000000000",
"product_id": "2312aa23-319b-4d29-913f-d62f72667a30",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-000000002893",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: bb15f1462043d0000000000000000001-190fbe1306899322-0
{
"errors": [
{
"context": {
"id": "832e3957-2830-4fcf-9af4-1fb84f6d6cb0"
},
"message": "Purchase item delivery location must be the same as purchase delivery location.",
"pointer": [
"items",
0,
"location_id"
],
"section": "body"
}
]
}
POST /public/v1/purchases does not create a purchase with a billing location that belongs to another company
POST /public/v1/purchases
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIxNTIsImlhdCI6MTc0OTc0MjU1MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTdjMzNjZDMtOGFkOC00NjUyLWE1NGItYjY4MDJiNDI4ODljIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNTUxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MzM4MDYiLCJ0eXAiOiJhY2Nlc3MifQ.fjPUcU8IJi4RuMAzLz6WEcRUF2O4lMG85dd2zSTRXO8
{
"billing_location_id": "00000000-0000-0000-0000-0000000029f3",
"charges": [],
"company_id": "00000000-0000-0000-0000-000000003870",
"due_datetime": "2020-01-30T00:00:00.000000Z",
"items": [
{
"location_id": "00000000-0000-0000-0000-0000000029ee",
"price": "10.000000000",
"product_id": "6fbe0587-e8f7-436e-a7df-f564fa2052af",
"quantity": "1.000000000"
}
],
"location_id": "00000000-0000-0000-0000-0000000029ee",
"order_datetime": "2020-01-01T00:00:00.000000Z"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 88a266ca8e1478000000000000000001-67157b4e8b773859-0
{
"errors": [
{
"context": {},
"message": "The provided billing address does not exist",
"pointer": [
"billing_location_id"
],
"section": "body"
}
]
}
Upsert a single purchase order. To update an existing purchase order, pass in an existing purchase order ID in the id field. When updating a purchase order, you must pass in all fields (no sparse update currently supported). Any existing order item or charge you do not pass in to items and charges respectively will be deleted
Request
POST /public/v1/purchases
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
id | Unique ID for this purchase order. If it exists, an update will be performed; otherwise, it will be used as the ID of a new purchase order record | query | string | false | ||
description | A description of the purchase order | query | string | false | ||
location_id | The location into which the inventory in this purchase will be received | query | string | false | ||
billing_location_id | The billing address for this purchase order | query | string | false | ||
company_id | The company that is the supplier for this purchase order | query | string | false | ||
order_datetime | The datetime on which the purchase order was placed | query | string | false | ||
due_datetime | The datetime by which the purchase order should be paid | query | string | false | ||
charges | The additional lines of Charge, Discount, or Tax added to this purchase order | body | PurchaseChargesRequest | false | ||
items | The items present on this purchase order | body | PurchaseItemsRequest | false | ||
billing_location_id | The billing location's ID | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A single purchase orders | Purchase |
StockAdjustment
Get adjustments
GET /public/v1/adjustments returns proper data for stock adjustments of product/batch/package tracked
GET /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjAsImlhdCI6MTc0OTc0MjQyMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMmZlYzM5NWItZWRlZi00MmMwLThhMWUtNDk4MDE0ZTljYjUxIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA4NzQiLCJ0eXAiOiJhY2Nlc3MifQ.c0CzhoLtxC7HOHZVWs5eoqcTj3ax2rjVpEONhqG_pIs
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: ad31b57df7a228000000000000000001-4d4c05a57d09f8e4-0
{
"data": [
{
"batch_id": null,
"completion_datetime": "2025-06-12T15:33:40.443873Z",
"compliance_quantity": null,
"description": null,
"id": "00000000-0000-0000-0000-000000000032",
"license_id": null,
"location_id": null,
"owner_id": "00000000-0000-0000-0000-000000002a7a",
"package_id": null,
"product_id": "bda98682-44ff-4f0d-9d83-21d8401739d3",
"quantity": "10",
"reason": "revaluation",
"total_cost": "10000"
},
{
"batch_id": null,
"completion_datetime": "2025-06-12T15:33:40.811693Z",
"compliance_quantity": "1",
"description": "A default note describing this transaction",
"id": "00000000-0000-0000-0000-000000000033",
"license_id": "00000000-0000-0000-0000-000000000868",
"location_id": "00000000-0000-0000-0000-000000000d55",
"owner_id": null,
"package_id": "00000000-0000-0000-0000-0000000002e5",
"product_id": "350b58c8-68c5-4706-8c1e-b028272dec55",
"quantity": "1",
"reason": "Voluntary Surrender",
"total_cost": "900"
},
{
"batch_id": "00000000-0000-0000-0000-000000000e1f",
"completion_datetime": "2025-06-12T15:33:41.138342Z",
"compliance_quantity": null,
"description": null,
"id": "00000000-0000-0000-0000-000000000034",
"license_id": null,
"location_id": "00000000-0000-0000-0000-000000000d4d",
"owner_id": null,
"package_id": null,
"product_id": "74ffec30-014a-4979-84b0-bce04b312e64",
"quantity": "1",
"reason": "revaluation",
"total_cost": "-800"
}
]
}
Get stock adjustments sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 5000 stock adjustments per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/adjustments
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter stock adjustments by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of stock adjustments | StockAdjustments |
Insert a stock adjustment
POST /public/v1/adjustments creates an adjustment for a product tracked product
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTgsImlhdCI6MTc0OTc0MjQxOCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTk5ZWM0N2QtNmY5Ni00Nzk5LTg1NDQtMWFlYjkzY2UyMTIwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA1NjEiLCJ0eXAiOiJhY2Nlc3MifQ.5kJxS0lK7NSFdayYEliUnWK53Z1h-7xxNAdQeiADv3M
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "00000000-0000-0000-0000-000000000ce5",
"product_id": "8fb5d4ac-13a8-4f2a-859f-d188766b2004",
"quantity": 10,
"reason": "expired"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 01016c31724132100000000000000001-b2c215034bd050bc-0
{
"data": {
"batch_id": null,
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": null,
"description": "test",
"id": "00000000-0000-0000-0000-00000000002a",
"license_id": null,
"location_id": "00000000-0000-0000-0000-000000000ce5",
"owner_id": null,
"package_id": null,
"product_id": "8fb5d4ac-13a8-4f2a-859f-d188766b2004",
"quantity": "10",
"reason": "expired",
"total_cost": null
}
}
POST /public/v1/adjustments creates an adjustment for a batch tracked product
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTgsImlhdCI6MTc0OTc0MjQxOCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiYmI3NjlhYjMtYjcwZi00OTVmLTg0ZWEtNWRiZDA4Y2ZmMWVjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA2MjEiLCJ0eXAiOiJhY2Nlc3MifQ.DOw_R3kLB31jtbC41jO49pltTsVdLqI7s6c_qq6p6YQ
{
"batch_id": "00000000-0000-0000-0000-000000000dbc",
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "00000000-0000-0000-0000-000000000cf6",
"quantity": 10,
"reason": "expired",
"unit_cost": 1000
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 94f4fe69957618000000000000000001-54898ab7a6b4fff1-0
{
"data": {
"batch_id": "00000000-0000-0000-0000-000000000dbc",
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": null,
"description": "test",
"id": "00000000-0000-0000-0000-00000000002d",
"license_id": null,
"location_id": "00000000-0000-0000-0000-000000000cf6",
"owner_id": null,
"package_id": null,
"product_id": "e61e0358-0525-4a5c-a3d0-a4074f1966a9",
"quantity": "10",
"reason": "expired",
"total_cost": "10000"
}
}
POST /public/v1/adjustments creates an adjustment for a package tracked product
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTksImlhdCI6MTc0OTc0MjQxOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMzJmOWJkNzktZGJmZS00N2FhLTlmMjYtMTk1NjIyYWM0Y2U0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA3MjYiLCJ0eXAiOiJhY2Nlc3MifQ.UKp5Z02rJw1CiVU5zZCTxliEyxeEaMKjqdJFEGtdhJo
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": 10,
"description": "test",
"package_id": "00000000-0000-0000-0000-0000000002d7",
"reason": "Damage (BCC)",
"unit_cost": 1000
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 6da85be13b4fbc000000000000000001-354f37eba0dca72d-0
{
"data": {
"batch_id": null,
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": "10",
"description": "test",
"id": "00000000-0000-0000-0000-000000000031",
"license_id": "00000000-0000-0000-0000-000000000852",
"location_id": "00000000-0000-0000-0000-000000000d19",
"owner_id": null,
"package_id": "00000000-0000-0000-0000-0000000002d7",
"product_id": "49694e74-3de8-4d75-b092-f39901208710",
"quantity": "0.35274",
"reason": "Damage (BCC)",
"total_cost": "10000.000000005834"
}
}
POST /public/v1/adjustments pointer translation works as intended
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTUsImlhdCI6MTc0OTc0MjQxNSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMzIzZTViZDItY2MxMS00ZWM4LWJkMmUtZDUwNjM2YTQwYmEwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTAxNzMiLCJ0eXAiOiJhY2Nlc3MifQ.MmV5AZLS7dAXhQMLSZeAy4jjYsfF9-frAxR83rIKUcI
{
"description": "test",
"package_id": "00000000-0000-0000-0000-0000000002ba",
"quantity": 10,
"reason": "Damage (BCC)"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 07372dca74cf36800000000000000001-99dcf82293f197ce-0
{
"errors": [
{
"context": {},
"message": "can't be blank",
"pointer": [
"completion_datetime"
],
"section": "body"
},
{
"context": {},
"message": "Required for adjustments of package tracked products",
"pointer": [
"compliance_quantity"
],
"section": "body"
},
{
"context": {},
"message": "Cannot be set for adjustments of package tracked products",
"pointer": [
"quantity"
],
"section": "body"
}
]
}
POST /public/v1/adjustments pointer translation works for cost accounting as well
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTksImlhdCI6MTc0OTc0MjQxOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNDg1NGY2ZGUtYjdjMy00OTRmLTlhODMtYjA3ODZlZjc0MGQ4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA2ODAiLCJ0eXAiOiJhY2Nlc3MifQ.pCLPpAy69v-zyFUllHp4N7LgOj2T3MtE0kMP8VZaMWg
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "00000000-0000-0000-0000-000000000d14",
"product_id": "24a9eed0-b924-4845-a0cf-f08372174384",
"quantity": 10,
"reason": "expired"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 0ac2221b892110000000000000000001-52489c2b68f800e4-0
{
"errors": [
{
"context": {},
"message": "Your company cost settings require a cost to be set when adding quantity",
"pointer": [
"unit_cost"
],
"section": "body"
}
]
}
POST /public/v1/adjustments validates quantity for non-compliance adjustments
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjAsImlhdCI6MTc0OTc0MjQyMCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNmE0NDQ3MzgtNTNiZC00ZmIxLTk2MTktMDI5Y2I3Yjc2NmEwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA4MzkiLCJ0eXAiOiJhY2Nlc3MifQ.MEmAe0sdLdQNk7Zp9WzXayXbV9sndU2yZzv6Gj7ZRII
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": 10,
"description": "test",
"location_id": "00000000-0000-0000-0000-000000000d40",
"product_id": "95b9bbba-5f13-4eec-b9fd-82ee6e6a6991",
"reason": "expired"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: a6f67d7e233090000000000000000001-695cd1f80e4abced-0
{
"errors": [
{
"context": {},
"message": "Cannot be set for adjustments of non-package tracked products",
"pointer": [
"compliance_quantity"
],
"section": "body"
},
{
"context": {},
"message": "Required for adjustments of non-package tracked products",
"pointer": [
"quantity"
],
"section": "body"
}
]
}
validates only one id can be passed
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTUsImlhdCI6MTc0OTc0MjQxNSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMjgxODIzMDItYmVhOC00YTM3LWEyODEtMTMwOTFhOGRhNGNmIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTAyNzMiLCJ0eXAiOiJhY2Nlc3MifQ.PXQT0EMfgwDpkBXZqQ0DXvrLUT6RRMx9k8mwA8ro4zE
{
"batch_id": "d38a438b-e138-469a-b914-5ba355ffe20e",
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "aa2c9d3f-4c45-4c2c-a382-21f773bb28b9",
"package_id": "5b096362-fb7a-4970-8a4b-10c5bdf348ce",
"product_id": "ab867411-b980-417a-aa3a-89d29efe6030",
"reason": "expired"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 44570c7d0041a4000000000000000001-8e30c6a489dbc071-0
{
"errors": [
{
"context": {},
"message": "Only one of batch_id, package_id, or product_id can be set",
"pointer": [
"batch_id"
],
"section": "body"
},
{
"context": {},
"message": "Required for adjustments of package tracked products",
"pointer": [
"compliance_quantity"
],
"section": "body"
},
{
"context": {},
"message": "Cannot be set for adjustments of package tracked products because the source will automatically be set to the location of the package",
"pointer": [
"location_id"
],
"section": "body"
},
{
"context": {},
"message": "Only one of batch_id, package_id, or product_id can be set",
"pointer": [
"package_id"
],
"section": "body"
},
{
"context": {},
"message": "Only one of batch_id, package_id, or product_id can be set",
"pointer": [
"product_id"
],
"section": "body"
}
]
}
validates at least one id is passed
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTQsImlhdCI6MTc0OTc0MjQxNCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOGIwZTIzMTktODNjNy00MDJiLWJkMzktYTBhZmU3NDhjODFjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDEzLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTAwODUiLCJ0eXAiOiJhY2Nlc3MifQ.-Y9nf0A5_s175LXQNkzg1TgZe933eei0igksxV_1nCc
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "2d59b582-61e9-462c-89db-6c56ad81eec7",
"reason": "expired"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 4d36911841c83c000000000000000001-fb74356dcd107815-0
{
"errors": [
{
"context": {},
"message": "At least one of batch_id, package_id, or product_id must be set",
"pointer": [
"batch_id"
],
"section": "body"
},
{
"context": {},
"message": "At least one of batch_id, package_id, or product_id must be set",
"pointer": [
"package_id"
],
"section": "body"
},
{
"context": {},
"message": "At least one of batch_id, package_id, or product_id must be set",
"pointer": [
"product_id"
],
"section": "body"
},
{
"context": {},
"message": "Required for adjustments of non-package tracked products",
"pointer": [
"quantity"
],
"section": "body"
}
]
}
validate waste must be negative
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTksImlhdCI6MTc0OTc0MjQxOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZGY0M2ExMmMtOTUzOS00ZGViLTg2MjUtMWQ4YTNjYzAwMDM0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA2NjQiLCJ0eXAiOiJhY2Nlc3MifQ.3WBorrN21SHCivRgLEmfxfv7avQy4GT5g_F_4mt2SKY
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "c88b550d-7f06-4d55-81bb-cd8b150a8e39",
"product_id": "bf8b356a-ccb3-4f17-a497-9d80e2b11107",
"quantity": 10,
"reason": "waste"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 3d2bf3ca7abcf6000000000000000001-efcfd3a910be8943-0
{
"errors": [
{
"context": {},
"message": "Quantity must be negative for waste adjustments",
"pointer": [
"quantity"
],
"section": "body"
}
]
}
validate compliance adjustments must not include location_id
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTgsImlhdCI6MTc0OTc0MjQxOCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZDg4NWRhZmUtOGFlOS00ZGFjLTk4ZGMtZWM1NWFlNzM0Nzg3IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA2MDciLCJ0eXAiOiJhY2Nlc3MifQ.7Xr9do7TvbMTlhNNVnLrZ07K2K6MF7jhc-703DK6Is4
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": 10,
"description": "test",
"location_id": "848b4043-f107-48f4-8422-b97b19017ec4",
"package_id": "79bcc389-86c4-4e20-ae66-14f442b6ff39",
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 5f86d4925ed0a0000000000000000001-3285f123c2df91e7-0
{
"errors": [
{
"context": {},
"message": "Cannot be set for adjustments of package tracked products because the source will automatically be set to the location of the package",
"pointer": [
"location_id"
],
"section": "body"
}
]
}
validate compliance adjustments must include location_id
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjEsImlhdCI6MTc0OTc0MjQyMSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMTZkMWRmNGItZTYyZS00MDRkLWJhYTEtNDczZWJiM2VlMjJiIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDIwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTEwNTYiLCJ0eXAiOiJhY2Nlc3MifQ.QgMpZvYqclLrXiPBxaTPaUb8WmSCuHaxnUprpNn2CkY
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"product_id": "fba2ac4c-dc8e-49dc-8300-b3da264d8796",
"quantity": 10,
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: f384e9bf0ba960000000000000000001-21818f74063d0912-0
{
"errors": [
{
"context": {},
"message": "Source location is required for non-compliance adjustments",
"pointer": [
"location_id"
],
"section": "body"
}
]
}
validates product exists
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTksImlhdCI6MTc0OTc0MjQxOSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOTU4MjMzNzYtZTFiZi00M2FmLTlmYTAtNjU3YzNkNmU2NDc5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA4MTMiLCJ0eXAiOiJhY2Nlc3MifQ.DEm3sYb3jaXvG9duZTknrP-1A3PQ3cQ8G_zYCeLXNFs
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "e47bb103-83c1-4796-8989-b1551517b7b8",
"product_id": "dd100b10-e26c-4d07-b4a6-ceca1a6baca5",
"quantity": 10,
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 24eaaba74888a2000000000000000001-1f71e3aa0f4ef339-0
{
"errors": [
{
"context": {},
"message": "Product not found",
"pointer": [
"product_id"
],
"section": "body"
}
]
}
validates batch exists
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTcsImlhdCI6MTc0OTc0MjQxNywiaXNzIjoiRGlzdHJ1IiwianRpIjoiMzg2NDI0ZGEtN2JmNC00MDkwLTk0YTUtMThlZDFjNWEyNGVjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE2LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTA0MzgiLCJ0eXAiOiJhY2Nlc3MifQ.Lz-fH_GcwmB96Juv7JAvq0Us2hI0DOkoji4S3e1J8Ek
{
"batch_id": "00000000-0000-0000-0000-000000000d7c",
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "ff5e2249-4054-4e1f-8ee5-058489d354b4",
"quantity": 10,
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 802f7419e191e0000000000000000001-aeca61b36b2aaa9d-0
{
"errors": [
{
"context": {},
"message": "Batch not found",
"pointer": [
"batch_id"
],
"section": "body"
}
]
}
validates package exists
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMjEsImlhdCI6MTc0OTc0MjQyMSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOWY5ZmVkNzgtZDhkMC00ODc5LWI1MDUtODcxY2VhN2U4NTA4IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDIwLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTEwNjIiLCJ0eXAiOiJhY2Nlc3MifQ.ln_Xi3B4sjSC5BHAVQtkh6pI8X0SbKzGFlIheTpxGdQ
{
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"compliance_quantity": 10,
"description": "test",
"package_id": "00000000-0000-0000-0000-0000000002f2",
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 7a27e336129dac000000000000000001-ecf6f89241bd9f0e-0
{
"errors": [
{
"context": {},
"message": "Package not found",
"pointer": [
"package_id"
],
"section": "body"
}
]
}
validates location exists
POST /public/v1/adjustments
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwMTUsImlhdCI6MTc0OTc0MjQxNSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiMDQwNGM2MjQtYWFmZi00ODQ2LTk2OGEtYjQyNjM1YzRhN2NjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDE0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTAyNDEiLCJ0eXAiOiJhY2Nlc3MifQ.LvAAPbNsIXPHIvCgeqjRkqLO3jHQcqKZOWiWuttU9hk
{
"batch_id": "00000000-0000-0000-0000-000000000d48",
"completion_datetime": "2020-01-03T12:20:00.000000Z",
"description": "test",
"location_id": "00000000-0000-0000-0000-000000000c7a",
"quantity": 10,
"reason": "compliance"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: efd68c107cf808000000000000000001-4e667aca52c618b3-0
{
"errors": [
{
"context": {},
"message": "Location not found",
"pointer": [
"location_id"
],
"section": "body"
}
]
}
Request
POST /public/v1/adjustments
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
product_id | The ID of the product to adjust. Must only be provided if the product is product-tracked. | query | string | false | ||
batch_id | The ID of the batch to adjust. Must only be provided if the batch's associated product is batch-tracked. | query | string | false | ||
package_id | The ID of the package to adjust. Must only be provided if the package's associated product is package-tracked. | query | string | false | ||
quantity | The quantity to adjust the stock by. Must only be provided for non-compliance adjustments. Must be negative if the adjustment reason is 'waste'. | query | number | false | ||
compliance_quantity | The quantity to adjust the stock by. Must only be provided for compliance adjustments. | query | number | false | ||
description | The description of the stock adjustment. Required for compliance adjustmenst. Has a max length of 800 characters for non-compliance adjustments, and 250 characters for compliance adjustments. | query | string | false | ||
unit_cost | The cost per unit of the stock adjustment. Can only be provided for companies with cost accounting enabled. Must be empty when the quantity is negative. Must be provided if the company setting 'Require Cost on Intake and Quantity Adjustments' is true. | query | number | false | ||
completion_datetime | The datetime of the stock adjustment. Must only be provided for compliance adjustments. | query | string | false | ||
reason | The reason for the stock adjustment. For non-compliance adjustments, must be one of the following: 'waste', 'stolen', 'damaged', 'fire', 'write-off', 'expired', 'lab-testing', 'revaluation', 'other.' For compliance adjustments, must be a reason that is accepted by the the compliance API | query | string | false | ||
location_id | The ID of the source location of the stock adjustment. Must only be provided for non-compliance adjustments. | query | string | false |
Responses
Status | Description | Schema |
---|---|---|
200 | The stock adjustment was inserted successfully | StockAdjustment |
Strain
Get strains
GET /public/v1/strains returns strains related to the company
GET /public/v1/strains
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTE5ODIsImlhdCI6MTc0OTc0MjM4MiwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNTg0ODE5NTgtMWMzMS00NTFiLWFlNDEtNjBiZGM0OGU2NzkwIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyMzgxLCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6NjEyOCIsInR5cCI6ImFjY2VzcyJ9.Gu8786tsYM3BEj5j4aOHpRWhTW5XJjSwVdyt-9o5Axk
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 12516f229c49ca000000000000000001-be60cff1ebd8d950-0
{
"data": [
{
"id": "00000000-0000-0000-0000-00000000005a",
"name": "Strain 87"
},
{
"id": "00000000-0000-0000-0000-00000000005b",
"name": "Strain 88"
}
]
}
Get strains filtered by various attributes
Note: The page size for this endpoint is 50k strains per page.
Request
GET /public/v1/strains
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter strains by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter strains by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of strains | Strains |
TestResult
Get test results
GET /public/v1/test-results returns test results
GET /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNzAsImlhdCI6MTc0OTc0MjQ3MCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiN2Y4ODZjYmItNDI2ZC00YmVkLTk5N2UtNmE1YTg0ZGMxZThjIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY5LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTg0MzMiLCJ0eXAiOiJhY2Nlc3MifQ.xRn5FEkjlWfWAgmWuV7a6ZkJ23jp0x8hm2v_37ix4h0
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 4e384d2d3adc44000000000000000001-9b1c9c2769c90471-0
{
"data": [
{
"additional_test_results": {
"thca_percentage": "12"
},
"batch_id": null,
"cbd_mg_per_unit": "1.12345",
"cbd_percentage": "60.1234",
"id": "00000000-0000-0000-0000-000000000098",
"is_primary": false,
"lab_license_number": "1234567890",
"lab_name": "Test Lab",
"mg_per_unit_type": "mg/g",
"name": "Test result 1",
"package_id": "00000000-0000-0000-0000-000000000576",
"release_date": "2025-06-12",
"thc_mg_per_unit": "2.12345",
"thc_percentage": "20.1234",
"total_cbd_mg_per_unit": "3.12345",
"total_cbd_percentage": "80.1234",
"total_thc_mg_per_unit": "4.12345",
"total_thc_percentage": "40.1234",
"updated_datetime": "2025-06-12T15:34:30.619040Z"
},
{
"additional_test_results": {
"thca_percentage": "12"
},
"batch_id": "00000000-0000-0000-0000-000000001677",
"cbd_mg_per_unit": null,
"cbd_percentage": null,
"id": "00000000-0000-0000-0000-000000000099",
"is_primary": false,
"lab_license_number": null,
"lab_name": null,
"mg_per_unit_type": "mg/g",
"name": "File.pdf",
"package_id": null,
"release_date": null,
"thc_mg_per_unit": null,
"thc_percentage": null,
"total_cbd_mg_per_unit": null,
"total_cbd_percentage": null,
"total_thc_mg_per_unit": null,
"total_thc_percentage": null,
"updated_datetime": "2025-06-12T15:34:30.654062Z"
},
{
"additional_test_results": {},
"batch_id": null,
"cbd_mg_per_unit": null,
"cbd_percentage": null,
"id": "00000000-0000-0000-0000-00000000009a",
"is_primary": false,
"lab_license_number": null,
"lab_name": null,
"mg_per_unit_type": "mg/g",
"name": "File.pdf",
"package_id": "00000000-0000-0000-0000-000000000577",
"release_date": null,
"thc_mg_per_unit": null,
"thc_percentage": null,
"total_cbd_mg_per_unit": null,
"total_cbd_percentage": null,
"total_thc_mg_per_unit": null,
"total_thc_percentage": null,
"updated_datetime": "2025-06-12T15:34:30.847663Z"
}
]
}
GET /public/v1/test-results returns only the additional test results that are present in the test result settings
GET /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjgsImlhdCI6MTc0OTc0MjQ2OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiNzNhYmIyYmEtZDU0Yy00YTU3LWIyOTAtOGJjMDMxNGJiNjJhIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTgwMzEiLCJ0eXAiOiJhY2Nlc3MifQ.4yiKnCfioa47Q_E_T57ezGNDIZ5BltJwiL9nf86zZKI
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 3ba95b00f4775c000000000000000001-73cad16049b0c7fb-0
{
"data": [
{
"additional_test_results": {
"spiroxamine_a_ug_per_g": "13",
"thiacloprid_ug_per_g": "14"
},
"batch_id": "00000000-0000-0000-0000-000000001607",
"cbd_mg_per_unit": null,
"cbd_percentage": null,
"id": "00000000-0000-0000-0000-000000000086",
"is_primary": false,
"lab_license_number": null,
"lab_name": null,
"mg_per_unit_type": "mg/g",
"name": "File.pdf",
"package_id": null,
"release_date": null,
"thc_mg_per_unit": null,
"thc_percentage": null,
"total_cbd_mg_per_unit": null,
"total_cbd_percentage": null,
"total_thc_mg_per_unit": null,
"total_thc_percentage": null,
"updated_datetime": "2025-06-12T15:34:28.677083Z"
}
]
}
Get test results filtered by various attributes.
Note: The page size for this endpoint is 5000 test results per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/test-results
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
updated_datetime | Filter test results by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z | |
page | Pagination information | body | Page | false |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of test results | TestResults |
Upsert a test result
POST /public/v1/test-results creates a test result for a batch tracked product
POST /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjksImlhdCI6MTc0OTc0MjQ2OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiY2QxOTNkZDEtOWEwNS00MzM2LWEwZTAtYjIxMDdiNWM3MTY5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTgzMDUiLCJ0eXAiOiJhY2Nlc3MifQ.SkNQ0EJTQ41RcEqYpEWEsKyEIV708mxnyifMjDKmAo0
{
"additional_test_results": {
"delta_8_thc_mg_per_unit": "17.3333",
"delta_8_thc_percentage": "12.55",
"thcva_percentage": "100"
},
"batch_id": "00000000-0000-0000-0000-00000000164b",
"cbd_mg_per_unit": "1.1",
"cbd_percentage": "2.2",
"is_primary": true,
"lab_license_number": "1234567890",
"lab_name": "Test Lab",
"mg_per_unit_type": "mg/g",
"name": "Name",
"release_date": "2025-05-22",
"thc_mg_per_unit": "3.3",
"thc_percentage": "4.4",
"total_cbd_mg_per_unit": "5.5",
"total_cbd_percentage": "6.6",
"total_thc_mg_per_unit": "7.7",
"total_thc_percentage": "8.8"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 0c041775c401fd000000000000000001-0c0e5f992b9936d5-0
{
"data": {
"additional_test_results": {
"delta_8_thc_mg_per_unit": "17.3333",
"delta_8_thc_percentage": "12.55",
"thcva_percentage": "100"
},
"batch_id": "00000000-0000-0000-0000-00000000164b",
"cbd_mg_per_unit": "1.1",
"cbd_percentage": "2.2",
"id": "00000000-0000-0000-0000-000000000091",
"is_primary": true,
"lab_license_number": "1234567890",
"lab_name": "Test Lab",
"mg_per_unit_type": "mg/g",
"name": "Name",
"package_id": null,
"release_date": "2025-05-22",
"thc_mg_per_unit": "3.3",
"thc_percentage": "4.4",
"total_cbd_mg_per_unit": "5.5",
"total_cbd_percentage": "6.6",
"total_thc_mg_per_unit": "7.7",
"total_thc_percentage": "8.8",
"updated_datetime": "2025-06-12T15:34:29.902897Z"
}
}
POST /public/v1/test-results creates a test result for a package tracked product
POST /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjgsImlhdCI6MTc0OTc0MjQ2OCwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZGE3ZmZiYWMtOGZmOS00YmVhLWEzZDEtMTRlYzMzZjJlZDU5IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY3LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTc5NDgiLCJ0eXAiOiJhY2Nlc3MifQ.4x4bn2OI-L2j3HLZ8SdR25wMVTTfLf699oqenXeOYtQ
{
"additional_test_results": {},
"is_primary": false,
"lab_license_number": "1234567890",
"lab_name": "Test Lab",
"mg_per_unit_type": "mg/mL",
"name": "Name",
"package_id": "00000000-0000-0000-0000-00000000054d"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 3058f73d03406c000000000000000001-5cffabb9c7e3eadc-0
{
"data": {
"additional_test_results": {},
"batch_id": null,
"cbd_mg_per_unit": null,
"cbd_percentage": null,
"id": "00000000-0000-0000-0000-000000000085",
"is_primary": true,
"lab_license_number": "1234567890",
"lab_name": "Test Lab",
"mg_per_unit_type": "mg/mL",
"name": "Name",
"package_id": "00000000-0000-0000-0000-00000000054d",
"release_date": null,
"thc_mg_per_unit": null,
"thc_percentage": null,
"total_cbd_mg_per_unit": null,
"total_cbd_percentage": null,
"total_thc_mg_per_unit": null,
"total_thc_percentage": null,
"updated_datetime": "2025-06-12T15:34:28.381023Z"
}
}
POST /public/v1/test-results properly transforms pointer on error
POST /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjksImlhdCI6MTc0OTc0MjQ2OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiZjA4NWU0YjgtYzdkOC00Mzc3LWIyMjctODJjYmRiZDg4NGM0IiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTgyODUiLCJ0eXAiOiJhY2Nlc3MifQ.kUzpare5i0CRExpeDs2_NZGhwuYkSEfuxUycF-HM3Ik
{
"batch_id": "00000000-0000-0000-0000-000000001645",
"mg_per_unit_type": "mg/g",
"name": "Name"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 2a4e49e80ca1a2000000000000000001-58e98efc0c11426c-0
{
"errors": [
{
"context": {},
"message": "can't be blank",
"pointer": [
"additional_test_results"
],
"section": "body"
},
{
"context": {},
"message": "can't be blank",
"pointer": [
"is_primary"
],
"section": "body"
}
]
}
POST /public/v1/test-results properly transforms pointer on service function error
POST /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjksImlhdCI6MTc0OTc0MjQ2OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiN2M0ODU1ODktOGMyYy00NDBhLWJjMTktOTkwMTQ1YzhlZGZmIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTgzNDMiLCJ0eXAiOiJhY2Nlc3MifQ.dcGCNLEG4ulBzpjKD9smNkz27kB_6NmGm8QgzESM5EQ
{
"additional_test_results": {},
"batch_id": "00000000-0000-0000-0000-000000001652",
"is_primary": false,
"mg_per_unit_type": "mg/g",
"name": "Name",
"total_cbd_mg_per_unit": "-3.3456",
"total_cbd_percentage": "2.234567",
"total_thc_mg_per_unit": "-4.4567",
"total_thc_percentage": "1.123456"
}
Response
400
cache-control: max-age=0, private, must-revalidate
content-type: application/json; charset=utf-8
b3: 8dd212fb30b678000000000000000001-46e6861a639bb848-0
{
"errors": [
{
"context": {},
"message": "must be greater than or equal to 0",
"pointer": [
"total_cbd_mg_per_unit"
],
"section": "body"
},
{
"context": {},
"message": "Must have at most 4 decimal digits",
"pointer": [
"total_cbd_percentage"
],
"section": "body"
},
{
"context": {},
"message": "must be greater than or equal to 0",
"pointer": [
"total_thc_mg_per_unit"
],
"section": "body"
},
{
"context": {},
"message": "Must have at most 4 decimal digits",
"pointer": [
"total_thc_percentage"
],
"section": "body"
}
]
}
POST /public/v1/test-results properly updates a test result
POST /public/v1/test-results
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwNjksImlhdCI6MTc0OTc0MjQ2OSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiN2IwZDYzNTgtNzY2My00ZTQ5LTgwMTUtNmJjY2E1ZWVkZGRiIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDY4LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MTgyNDAiLCJ0eXAiOiJhY2Nlc3MifQ.WRYWOEW0gbDUBoDHBjR7YWe-F0QjtuMEzcHPDDBMbe0
{
"additional_test_results": {
"thca_percentage": "15"
},
"id": "00000000-0000-0000-0000-00000000008f",
"is_primary": true,
"lab_name": "after lab name",
"mg_per_unit_type": "mg/mL",
"name": "after name",
"release_date": "2025-05-23",
"total_thc_percentage": "14"
}
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: e4a6c31da590c0000000000000000001-b3934c9283e92f75-0
{
"data": {
"additional_test_results": {
"thca_percentage": "15"
},
"batch_id": "00000000-0000-0000-0000-000000001639",
"cbd_mg_per_unit": null,
"cbd_percentage": null,
"id": "00000000-0000-0000-0000-00000000008f",
"is_primary": true,
"lab_license_number": null,
"lab_name": "after lab name",
"mg_per_unit_type": "mg/mL",
"name": "after name",
"package_id": null,
"release_date": "2025-05-23",
"thc_mg_per_unit": null,
"thc_percentage": null,
"total_cbd_mg_per_unit": null,
"total_cbd_percentage": null,
"total_thc_mg_per_unit": null,
"total_thc_percentage": "14",
"updated_datetime": "2025-06-12T15:34:29.664044Z"
}
}
Upsert a single test result. To update an existing test result, pass in an existing test result ID in the id field. When updating a test result, you must pass in all fields including all additional test results (no sparse update currently supported). Result percentage values can have no more than 4 decimal places.
Request
POST /public/v1/test-results
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
id | Unique ID for this test result. If it exists, an update will be performed, and will otherwise throw an error. Only non-compliance tracked test results can be updated. | query | string | false | ||
package_id | The ID of the package this test result belongs to. Cannot be provided if either id or batch_id is provided. | query | string | false | 123e4567-e89b-12d3-a456-426614174000 | |
batch_id | The ID of the batch this test result belongs to. Cannot be provided if either id or package_id is provided. | query | string | false | 123e4567-e89b-12d3-a456-426614174000 | |
additional_test_results | The additional tests results for this test result. Check here for the valid options. | query | object | false | ||
mg_per_unit_type | The unit type for the mg per unit fields | query | string | false | mg/g | |
is_primary | Setting a test result to is_primary: true will propagate the test result to child packages if applicable. Cannot update a test_result from is_primary: true to is_primary: false. If you want to do this, you must set a different test result on the same package/batch to is_primary: true. Once done, this test_result will be set to is_primary: false automatically. | query | boolean | false | true | |
release_date | The release date for this test result | query | string | false | 2022-07-10 | |
lab_license_number | The license number of this test result's lab | query | string | false | 1234567890 | |
lab_name | The name of this test result's lab | query | string | false | Lab Name | |
name | The name of this test result | query | string | false | Test Result Name | |
thc_percentage | The THC percentage for this test result. Max precision is 4 decimal places. | query | decimal | false | 1.5 | |
total_thc_percentage | The total THC percentage for this test result. Max precision is 4 decimal places. | query | decimal | false | 1.5 | |
thc_mg_per_unit | The THC mg per unit for this test result. | query | decimal | false | 1.5 | |
total_thc_mg_per_unit | The total THC mg per unit for this test result. | query | decimal | false | 1.5 | |
cbd_percentage | The CBD percentage for this test result. Max precision is 4 decimal places. | query | decimal | false | 1.5 | |
total_cbd_percentage | The total CBD percentage for this test result. Max precision is 4 decimal places. | query | decimal | false | 1.5 | |
cbd_mg_per_unit | The CBD mg per unit for this test result. | query | decimal | false | 1.5 | |
total_cbd_mg_per_unit | The total CBD mg per unit for this test result. | query | decimal | false | 1.5 |
Responses
Status | Description | Schema |
---|---|---|
200 | A single test result | TestResult |
User
Get users
GET /public/v1/users returns users related to the company
GET /public/v1/users
content-type: application/json
accept: application/json
authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJEaXN0cnUiLCJleHAiOjE3ODExOTIwOTUsImlhdCI6MTc0OTc0MjQ5NSwiaXNzIjoiRGlzdHJ1IiwianRpIjoiOWI2OGY1NDMtYjkzOS00ZTA1LTk0ZDAtZGUxYzE0MWUwYmExIiwibW9iaWxlIjpmYWxzZSwibmJmIjoxNzQ5NzQyNDk0LCJwbGF0Zm9ybSI6IkFQSSIsInN1YiI6IlVzZXI6MjM2MzgiLCJ0eXAiOiJhY2Nlc3MifQ.TPWCeOdqU3QYBAkRV5n6pNFy2INqRnK7SIuuBrEW-KE
Response
200
content-type: application/json; charset=utf-8
cache-control: max-age=0, private, must-revalidate
b3: 8c952ae68afa98000000000000000001-379e8ee7dc300430-0
{
"data": [
{
"banned": false,
"email": "owner-23779@example.com",
"full_name": "FirstName47018 LastName47019",
"id": "00000000-0000-0000-0000-000000005c56",
"role": {
"id": "00000000-0000-0000-0000-000000005cd1",
"name": "Admin 23705"
}
},
{
"banned": false,
"email": "owner-23781@example.com",
"full_name": "FirstName47022 LastName47023",
"id": "00000000-0000-0000-0000-000000005c58",
"role": {
"id": "00000000-0000-0000-0000-000000005cd3",
"name": "Admin 23707"
}
}
]
}
Get users sorted by their creation date and filtered by various attributes
Note: The page size for this endpoint is 1000 users per page. This endpoint returns eventually consistent data, with changes taking up to 1 second to propagate in responses.
Request
GET /public/v1/users
Parameters
Parameter | Description | In | Type | Required | Default | Example |
---|---|---|---|---|---|---|
inserted_datetime | Filter users by their creation datetime | query | string | false | 2022-07-10T00:00:00Z, | |
page | Pagination information | body | Page | false | ||
updated_datetime | Filter users by the datetime they were most recently modified | query | string | false | ,2022-07-10T00:00:00Z |
Responses
Status | Description | Schema |
---|---|---|
200 | A list of users | Users |
Changelog
2024-10-2
- Added GET
/public/v1/strains
endpoint. - In endpoint GET /public/v1/companies, added fields category and relationship to the response.
2024-11-6
- Field thc of type string in the Product object was replaced with total_thc field of type number.
- Field cbd of type string in the Product object was replaced with total_cbd field of type number.
- Added total_cannabinoid_unit field to Product object. Allowed values are either "MG" or "PERCENT".
2024-12-24
- Added billing_location_id to POST
/public/v1/purchases
endpoint.
2024-12-26
- Added msrp, is_active, category.type and images.rank to GET
/public/v1/products
.
2025-01-08
- Added GET
/public/v1/payment-methods
endpoint.
2025-01-15
- Added POST
/public/v1/purchases/:id/payments
endpoint. - Added POST
/public/v1/invoices/:id/payments
endpoint.
2025-01-17
- Added
product_unit_quantity
to GET/public/v1/packages
endpoint. - Added
product_unit_type
to GET/public/v1/packages
endpoint.
2025-01-31
- Added POST
/public/v1/batches
endpoint. - Added batch_number, product_id, owner_id and description to GET
/public/v1/batches
endpoint. - Added title and phone_number to GET
/public/v1/contacts
endpoint.
2025-02-26
Page size change from 50,000 to 5000 for the following endpoints:
- GET
/public/v1/batches
- GET
/public/v1/companies
- GET
/public/v1/contacts
- GET
/public/v1/inventory
- GET
/public/v1/packages
- GET
/public/v1/products
- GET
/public/v1/purchases
- GET
All GET endpoints now return eventually consistent data, with changes taking up to 1 second to propagate in responses
2025-03-05
- Added GET
/public/v1/assemblies
endpoint.
2025-03-11
- Added
total_cost_actual
,total_cost_default
andreturned_quantity
to "items" in GET/public/v1/invoices
endpoint. - Added
total_cost_actual
,total_cost_default
andreturned_quantity
to "items" in GET/public/v1/invoices/:id
endpoint. - Added
total_cost_actual
,total_cost_default
andreturned_quantity
to "items" in GET/public/v1/orders
endpoint. - Added
total_cost_actual
,total_cost_default
andreturned_quantity
to "items" in GET/public/v1/orders/:id
endpoint.
2025-03-18
- Modified
unit_net_weight
andunit_serving_size
in GET/public/v1/products
endpoint: These fields can now be populated regardless of the product's unit type.
2025-04-09
- Added the following fields to GET
/public/v1/companies
endpoint:legal_business_name
default_email
phone_number
invoice_email
sales_order_email
purchase_order_email
order_shipment_email
website
default_sales_order_notes
default_purchase_order_notes
outstanding_balance_threshold
owner_id
2025-05-06
- Added
is_trade_sample
to GET/public/v1/packages
endpoint.
2025-05-13
- Added GET
/public/v1/adjustments
endpoint.
2025-05-14
Added
custom_data
to the response of the following endpoints:- GET
/public/v1/assemblies
- GET
/public/v1/batches
- POST
/public/v1/batches
- GET
/public/v1/companies
- GET
/public/v1/contacts
- GET
/public/v1/invoices
- GET
/public/v1/invoices/:id
- POST
/public/v1/invoices
- GET
/public/v1/orders
- GET
/public/v1/orders/:id
- POST
/public/v1/orders
- GET
/public/v1/packages
- GET
/public/v1/products
- POST
/public/v1/products
- GET
/public/v1/purchases
- POST
/public/v1/purchases
- GET
2025-05-15
- Added POST
/public/v1/stock_adjustments
endpoint.
2025-05-16
- Added GET
/public/v1/test-results
- Added POST
/public/v1/test-results
2025-05-18
- Added
leaflink_order_number
to GET/public/v1/orders
2025-05-22
- Added
external_name
to GET/POST/public/v1/products
2025-05-27
- Added
biotrack_id
andmetrc_transfer_id
to POST/public/v1/orders
2025-06-09
- Added POST
/public/v1/file-attachments
endpoint for uploading files and attaching them to business entities (products, orders, purchases, etc.).
2025-06-12
- Added
metrc_transfer_id
andbiotrack_id
to GET/public/v1/orders
2025-06-12
- Changed
cost
on GET/public/v1/assemblies
tototal_cost_actual
iningredients
- Added
total_cost_default
to GET/public/v1/assemblies
iningredients
- Added
total_cost_actual
to GET/public/v1/assemblies
inadditional_costs
- Added
total_cost_default
to GET/public/v1/assemblies
inadditional_costs