Search plant groups

distru-search-plant-groupsRead

Searches cultivation plant groups (plant batches) — a group of immature plants tracked as one unit until tagged.

Inputs

Every tool also takes the common inputs.

FieldTypeRequiredDescription
limitintegerNoDefault: 10
cursorstringNonextCursor of the previous call; keep the other arguments unchanged.
idsstring[]No
licenseIdsstring[]NoFilter to plant groups under these licenses. Resolve via distru-search-licenses.
locationIdsstring[]NoFilter to plant groups at these locations. Resolve via distru-search-locations.
metrcStrainNamesstring[]NoExact Metrc strain names. Matches any of them.
statusenum
ACTIVEANYINACTIVE
NoACTIVE: has immature plants. INACTIVE: none left. Default ACTIVE.
searchstringNoCase-insensitive substring match on the plant group name, Metrc strain name, or location name. Setting it also reorders results by how closely each field resembles the term; sortBy is ignored.
sortByobjectNoSort options. Defaults to most recently updated first when omitted. Ignored when search is set.
sortBy.directionenum
ASCDESC
Yes
sortBy.fieldenum
NAMEPLANTED_ATINSERTED_ATUPDATED_AT
YesField to sort by.

Output

Presence on a nested field assumes its parent exists.

FieldTypePresence
hasMorebooleanAlways
nextCursorstringCan be absent
totalCountintegerCan be absent
itemsobject[]Always
items[].idstringAlways
items[].namestringAlways
items[].metrcStrainNamestringCan be null
items[].plantedAtstringAlways
items[].complianceTypeenum
BIOTRACKMETRCNONE
Can be null
items[].isActivebooleanAlways
items[].totalPlantsCountnumberCan be null
items[].immaturePlantsCountnumberCan be null
items[].licenseobjectAlways
items[].license.idstringAlways
items[].license.licenseNumberstringAlways
items[].locationobjectAlways
items[].location.idstringAlways
items[].location.namestringAlways
What the AI reads

Searches cultivation plant groups (plant batches) — a group of immature plants tracked as one unit until tagged. Step 1 of the lifecycle: plant group → plants (tagged; distru-search-plants with plantGroupId) → teardown → harvests. One row per group.