Retrieve location details.
OK
Bad Request
{- "results": {
- "type": "array",
- "records": {
- "count": "0 - 100",
- "total": 437,
- "previous": null,
}, - "data": [
- {
- "license": {
- "license_number": "KMPL20200818",
- "type": {
- "name": "Type 12"
}
}, - "id": "111",
- "name": "Pink Elephant Field",
- "parent_id": null,
- "type": {
- "id": "1",
- "name": "Default Location Type",
- "characteristics": {
- "plant_batches": true,
- "plants": true,
- "harvests": true,
- "lots": true,
- "quarantine": false
}
}, - "entity_state": [
- {
- "state": "active",
- "date": "2021-01-12T05:27:39Z",
- "reason": "location created",
- "actioned_by": "jdoe@kmp.com"
}
]
}
]
}, - "warnings": [ ]
}Create a location under the specific license_number.
OK
object | |||||||||||||||||||||||||
| |||||||||||||||||||||||||
Array of objects | |||||||||||||||||||||||||
Bad Request
{- "license": {
- "license_number": "KMP20200825"
}, - "name": "Hathaway cultivation 1",
- "parent_id": null,
- "type": {
- "id": "CALOC0001"
}
}{- "results": {
- "type": "object",
- "data": {
- "license": {
- "license_number": "KMPL20200818",
- "type": {
- "name": "Type 12"
}
}, - "id": "111",
- "name": "Pink Elephant Fields",
- "parent_id": null,
- "type": {
- "id": "1",
- "name": "Default Location Type",
- "characteristics": {
- "plant_batches": true,
- "plants": true,
- "harvests": true,
- "lots": true,
- "quarantine": false
}
}, - "entity_state": [
- {
- "state": "active",
- "date": "2021-01-12T05:27:39Z",
- "reason": "location created",
- "actioned_by": "jdoe@kmp.com"
}
]
}
}, - "warnings": [ ]
}Retrieve location details for id.
OK
object | |||||||||||||||||||||||||
| |||||||||||||||||||||||||
Array of objects | |||||||||||||||||||||||||
Bad Request
{- "results": {
- "type": "object",
- "data": {
- "license": {
- "license_number": "KMPL20200818",
- "type": {
- "name": "Type 12"
}
}, - "id": "111",
- "name": "Pink Elephant Field",
- "parent_id": null,
- "type": {
- "id": "1",
- "name": "Default Location Type",
- "characteristics": {
- "plant_batches": true,
- "plants": true,
- "harvests": true,
- "lots": true,
- "quarantine": false
}
}, - "entity_state": [
- {
- "state": "active",
- "date": "2021-01-12T05:27:39Z",
- "reason": "location created",
- "actioned_by": "jdoe@kmp.com"
}
]
}
}, - "warnings": [ ]
}Update a location under the specific license_number.
required | object |
| name | string location name. |
| parent_id | string or null reference (entity_ID) for the parent location entity which allows you to have segregation of the location in smaller sections. |
object location type as specified by the state and retrieved via location/types | |
Array of objects A list of state changes made to the entity. Entity states for location [active, inactive]. | |
OK
object | |||||||||||||||||||||||||
| |||||||||||||||||||||||||
Array of objects | |||||||||||||||||||||||||
Bad Request
{- "license": {
- "license_number": "KMP20200825"
}, - "type": {
- "id": "CALOC0002"
}
}{- "results": {
- "type": "object",
- "data": {
- "license": {
- "license_number": "KMPL20200818",
- "type": {
- "name": "Type 12"
}
}, - "id": "111",
- "name": "Pink Elephant Fields",
- "parent_id": null,
- "type": {
- "id": "2",
- "name": "Inventory Room",
- "characteristics": {
- "plant_batches": false,
- "plants": false,
- "harvests": false,
- "lots": false,
- "quarantine": true
}
}, - "entity_state": [
- {
- "state": "active",
- "date": "2021-01-12T05:27:39Z",
- "reason": "location updated",
- "actioned_by": "jdoe@kmp.com"
}
]
}
}, - "warnings": [ ]
}Delete location.
| id required | string Reference (entity_ID) for the location you are deleting. Example: 1234 |
| state required | string Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating. |
{- "license": {
- "license_number": "KMPL20200814"
}
}{- "results": {
- "type": "object",
- "data": {
- "id": "1234",
- "deleted": true
}
}, - "warnings": [ ]
}Retrieve a list of location types
{- "results": {
- "type": "array",
- "data": [
- {
- "id": "KMPLOC0001",
- "name": "lot inventories",
- "characteristics": {
- "plants": false,
- "plant_batches": false,
- "harvests": false,
- "lots": true,
- "quarantine": false
}
}
]
}, - "warnings": [ ]
}