Location

Retrieve locations

Retrieve location details.

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
state
required
string

Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
query Parameters
license_number
required
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

Example: license_number=ABC-1234
limit
number

Optional parameter that allows you to specify a number to limit the results in the response. Default limit is 100.

Example: limit=100
offset
number

Optional parameter that allows you to offset records if the max number for the filter exceeds the limit.

Example: offset=0
entity_state
string

Queryable entity states for location. Inactive will return deleted locations.

Enum: "active" "inactive" "deleted"
start_date
string

start date value for query operations.

Example: start_date=2021-08-12T00:00:00Z
end_date
string

end date value for query operations.

Example: end_date=2021-08-13T00:00:00Z
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Responses
200

OK

Response Schema: application/json
object
type
string
Value: "array"
object
count
string

A string representing what records you are receiving out of the total for the filter criteria.

total
number

The total number of records returned based upon filter criteria.

previous
string or null

URL that when executed will return you to the last page set.

next
string or null

URL that when executed will take you to the next set of paginated records.

Array of objects
Array
object
license_number
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

object

License type of the company/facility.

id
string

reference (entity_ID) for the location.

name
string

Location name.

parent_id
string or null

reference (entity_ID) for the parent location, which allows you to have segregation of the location in smaller sections.

object
id
string

reference (ID) for the type of the location.

name
string

name of the location type.

object
Array of objects

A list of state changes made to the entity. Entity states for location [active, inactive, deleted].

Array
state
string

state of the entity.

date
string

timestamp when the state was recorded ISO 8601 UTC format.

reason
string

additional information for the 'state' change.

actioned_by
string

username of the person who updated the state of the entity (if applicable).

Array of objects
Array
type
string
detail
string
400

Bad Request

get/{state}/v1/config/locations
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}

Create location

Create a location under the specific license_number.

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
state
required
string

Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Request Body schema: application/json
required
object
license_number
required
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

name
required
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.

required
object

location type as specified by the state and retrieved via location/types

id
required
string

reference (ID) for the type of the location.

Responses
200

OK

Response Schema: application/json
object
type
string
Value: "object"
object
object
license_number
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

object

License type of the company/facility.

name
string

The display name of the license type.

characteristics
object

Specific information related to the license type. The presence of the characteristics' object depends on the use of the expand query parameter .

id
string

reference (entity_ID) for the location.

name
string

Location name.

parent_id
string or null

reference (entity_ID) for the parent location, which allows you to have segregation of the location in smaller sections.

object
id
string

reference (ID) for the type of the location.

name
string

name of the location type.

object
plants
boolean

true if the location is for plants.

plant_batches
boolean

true if the location is for plant_batches.

harvests
boolean

true if the location is for harvests.

lots
boolean

true if the location is for lots.

quarantine
boolean

true if the location is for quarantined plants, lots, etc.

Array of objects

A list of state changes made to the entity. Entity states for location [active, inactive, deleted].

Array
state
string

state of the entity.

date
string

timestamp when the state was recorded ISO 8601 UTC format.

reason
string

additional information for the 'state' change.

actioned_by
string

username of the person who updated the state of the entity (if applicable).

Array of objects
Array
type
string
detail
string
400

Bad Request

post/{state}/v1/config/locations
Request samples
application/json
{
  • "license": {
    },
  • "name": "Hathaway cultivation 1",
  • "parent_id": null,
  • "type": {
    }
}
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}

Retrieve location

Retrieve location details for id.

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
id
required
string

id of the location

Example: a521f55de4394f4f99c282be687e63aa
state
required
string

Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
query Parameters
license_number
required
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

Example: license_number=ABC-1234
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Responses
200

OK

Response Schema: application/json
object
type
string
Value: "object"
object
object
license_number
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

object

License type of the company/facility.

name
string

The display name of the license type.

characteristics
object

Specific information related to the license type. The presence of the characteristics' object depends on the use of the expand query parameter .

id
string

reference (entity_ID) for the location.

name
string

Location name.

parent_id
string or null

reference (entity_ID) for the parent location, which allows you to have segregation of the location in smaller sections.

object
id
string

reference (ID) for the type of the location.

name
string

name of the location type.

object
plants
boolean

true if the location is for plants.

plant_batches
boolean

true if the location is for plant_batches.

harvests
boolean

true if the location is for harvests.

lots
boolean

true if the location is for lots.

quarantine
boolean

true if the location is for quarantined plants, lots, etc.

Array of objects

A list of state changes made to the entity. Entity states for location [active, inactive, deleted].

Array
state
string

state of the entity.

date
string

timestamp when the state was recorded ISO 8601 UTC format.

reason
string

additional information for the 'state' change.

actioned_by
string

username of the person who updated the state of the entity (if applicable).

Array of objects
Array
type
string
detail
string
400

Bad Request

get/{state}/v1/config/locations/{id}
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}

Update location

Update a location under the specific license_number.

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
id
required
string

id of the location

Example: a521f55de4394f4f99c282be687e63aa
state
required
string

Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Request Body schema: application/json
required
object
license_number
required
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

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

id
string

reference (ID) for the type of the location.

Array of objects

A list of state changes made to the entity. Entity states for location [active, inactive].

Array
state
required
string

The state of the entity.

date
required
string

Timestamp when the state was recorded ISO 8601 UTC format.

reason
required
string

Additional information for the 'state' change.

actioned_by
required
string

Username of the person who updated the state of the entity (if applicable).

Responses
200

OK

Response Schema: application/json
object
type
string
Value: "object"
object
object
license_number
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

object

License type of the company/facility.

name
string

The display name of the license type.

characteristics
object

Specific information related to the license type. The presence of the characteristics' object depends on the use of the expand query parameter .

id
string

reference (entity_ID) for the location.

name
string

Location name.

parent_id
string or null

reference (entity_ID) for the parent location, which allows you to have segregation of the location in smaller sections.

object
id
string

reference (ID) for the type of the location.

name
string

name of the location type.

object
plants
boolean

true if the location is for plants.

plant_batches
boolean

true if the location is for plant_batches.

harvests
boolean

true if the location is for harvests.

lots
boolean

true if the location is for lots.

quarantine
boolean

true if the location is for quarantined plants, lots, etc.

Array of objects

A list of state changes made to the entity. Entity states for location [active, inactive, deleted].

Array
state
string

state of the entity.

date
string

timestamp when the state was recorded ISO 8601 UTC format.

reason
string

additional information for the 'state' change.

actioned_by
string

username of the person who updated the state of the entity (if applicable).

Array of objects
Array
type
string
detail
string
400

Bad Request

put/{state}/v1/config/locations/{id}
Request samples
application/json
{
  • "license": {
    },
  • "type": {
    }
}
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}

Delete location

Delete location.

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
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.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Request Body schema: application/json
required
object
license_number
required
string

Reference (entity_ID) for the license. This is the business license number issued by the state.

Responses
200

OK

Response Schema: application/json
object
type
string
Value: "object"
object

Trace

id
string

reference (entity_ID) for the location.

deleted
boolean

true if location was deleted successfully, otherwise false.

Array of objects
Array
type
string
detail
string
400

Bad Request

delete/{state}/v1/config/locations/{id}
Request samples
application/json
{
  • "license": {
    }
}
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}

Retrieve location types

Retrieve a list of location types

SecurityApiKeyAuth and CustomAuth
Request
path Parameters
state
required
string

Lower case ANSI standard 38:2009 USPS codes of the US state where licensee is operating.

Enum: "ca" "or" "nv" "mt" "co" "mi" "il" "ma" "ri" "nj" "md" "de" "va" "oh" "ky" "al" "ms" "mn" "la" "ok" "sd" "me"
header Parameters
x-api-key
required
string

Trace API key header

Example: b123x21wbHlkYXBpa2V5
Authorization
required
string

Company and user credentials authentication

Example: KMP-JSON token=dmVuZG9yLWFwaS1rZXk6dX12312sdfs2V5
Responses
200

OK

Response Schema: application/json
object
type
string
Value: "array"
Array of objects
Array
id
string

reference (ID) for the type of the location.

name
string

name of the location type.

object
plants
boolean

true if the location is for plants.

plant_batches
boolean

true if the location is for plant_batches.

harvests
boolean

true if the location is for harvests.

lots
boolean

true if the location is for lots.

quarantine
boolean

true if the location is for quarantined plants, lots, etc.

Array of objects
Array
type
string
detail
string
400

Bad Request

get/{state}/v1/config/locations/types
Response samples
application/json
{
  • "results": {
    },
  • "warnings": [ ]
}