LeafLink API (2022-10-31)

Download OpenAPI specification:Download

This reference specification outlines all the available HTTP operations of the LeafLink API.

See the LeafLink Developer Hub for guides, how-to, and general information of the API.

Company

Provide potential cashback earnings for the given marketplace company slug.

Returns cashback statistics for a company.

Authorizations:
bearerAuth
path Parameters
marketplace_slug
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "buyer_cashback_invoice_count": -2147483648,
  • "buyer_cashback_potential_earnings": -9999999999
}

Invoice Recorded Payment

Create an Invoice Recorded Payment

Create an invoice's recorded payment.

Authorizations:
bearerAuth
Request Body schema: application/json
required
amount
required
string non-empty

Quantity in USD

payment_date
required
string <date>

Date payment was made in YYYY-MM-DD

payment_reason
required
string non-empty

Reason payment was made. choices: ['invoice_purchase', 'reversal', 'adjustment', 'principal', 'extension_fee', 'factor_fee', 'direct_pay_fee', 'direct_pay_fee_reversal', 'direct_pay_fee_batch', 'cashback_reward', 'standard', 'ach_error', 'marketplace_payment', 'other', 'sell_through']

payment_method
required
string non-empty

The way the payment was made. choices:['ach', 'wire', 'money_order', 'cash_pickup', 'check', 'other']

check_number
string non-empty

Check number if the method is check

source_id
required
string non-empty

The ID of this payment in your system

Responses

Request samples

Content type
application/json
{
  • "amount": "string",
  • "payment_date": "2019-08-24",
  • "payment_reason": "string",
  • "payment_method": "string",
  • "check_number": "string",
  • "source_id": "string"
}

Response samples

Content type
application/json
{
  • "amount": "string",
  • "payment_date": "2019-08-24",
  • "payment_reason": "string",
  • "payment_method": "string",
  • "check_number": "string",
  • "source_id": "string"
}

managed_companies

managed_companies_list

Managed Companies collection view. Companies you are the admin of

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

managed_companies_retrieve

Managed Companies collection view. Companies you are the admin of

Authorizations:
bearerAuth
path Parameters
id
required
string <uuid>
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "dba": "string",
  • "legal_entity": {
    },
  • "has_linked_bank_account": true
}

managed_companies_licenses_list

Licenses for a company

Authorizations:
bearerAuth
path Parameters
id
required
string
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

managed_companies_retrieve_2

Managed Companies collection view. Companies you are the admin of

Authorizations:
bearerAuth
path Parameters
marketplace_slug
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "dba": "string",
  • "legal_entity": {
    },
  • "has_linked_bank_account": true
}

Payment Contract

List Payment Contracts

List multiple payment contracts.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

Create a Payment Contract

Create a payment contract.

Authorizations:
bearerAuth
Request Body schema: application/json
required
docusign_id
string or null <= 200 characters
status
string
Default: "active"
buyer_id
required
string <uuid>
seller_id
required
string <uuid>
default_payment_program
string
Default: "do_not_process"
Enum: "do_not_process" "flexible" "direct" "factoring" "b2b"
default_flexible_payment_strategy
string (DefaultFlexiblePaymentStrategyEnum)
Enum: "factored" "reverse_factored"
custom_direct_payment_term_type
string non-empty
custom_reverse_factor_auto_assignment
boolean or null

Responses

Request samples

Content type
application/json
{
  • "docusign_id": "string",
  • "status": "active",
  • "buyer_id": "2a8aae71-324e-470e-b3d1-589903cf2f45",
  • "seller_id": "28f4dc41-8499-4ead-9976-f2fa20a45fd1",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "docusign_id": "string",
  • "status": "active",
  • "buyer": {
    },
  • "seller": {
    },
  • "contract_stats": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "modified": "2019-08-24T14:15:22Z",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Get a Payment Contract

Get a single payment contracts.

Authorizations:
bearerAuth
path Parameters
contract_id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "docusign_id": "string",
  • "status": "active",
  • "buyer": {
    },
  • "seller": {
    },
  • "contract_stats": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "modified": "2019-08-24T14:15:22Z",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Replace a Payment Contract

Replace a single payment contracts.

Authorizations:
bearerAuth
path Parameters
contract_id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
docusign_id
string or null <= 200 characters
status
string
Default: "active"
buyer_id
required
string <uuid>
seller_id
required
string <uuid>
default_payment_program
string
Default: "do_not_process"
Enum: "do_not_process" "flexible" "direct" "factoring" "b2b"
default_flexible_payment_strategy
string (DefaultFlexiblePaymentStrategyEnum)
Enum: "factored" "reverse_factored"
custom_direct_payment_term_type
string non-empty
custom_reverse_factor_auto_assignment
boolean or null

Responses

Request samples

Content type
application/json
{
  • "docusign_id": "string",
  • "status": "active",
  • "buyer_id": "2a8aae71-324e-470e-b3d1-589903cf2f45",
  • "seller_id": "28f4dc41-8499-4ead-9976-f2fa20a45fd1",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "docusign_id": "string",
  • "status": "active",
  • "buyer": {
    },
  • "seller": {
    },
  • "contract_stats": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "modified": "2019-08-24T14:15:22Z",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Update a Payment Contract

Update a single payment contract.

Authorizations:
bearerAuth
path Parameters
contract_id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
docusign_id
string or null <= 200 characters
status
string
Default: "active"
buyer_id
string <uuid>
seller_id
string <uuid>
default_payment_program
string
Default: "do_not_process"
Enum: "do_not_process" "flexible" "direct" "factoring" "b2b"
default_flexible_payment_strategy
string (DefaultFlexiblePaymentStrategyEnum)
Enum: "factored" "reverse_factored"
custom_direct_payment_term_type
string non-empty
custom_reverse_factor_auto_assignment
boolean or null

Responses

Request samples

Content type
application/json
{
  • "docusign_id": "string",
  • "status": "active",
  • "buyer_id": "2a8aae71-324e-470e-b3d1-589903cf2f45",
  • "seller_id": "28f4dc41-8499-4ead-9976-f2fa20a45fd1",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Response samples

Content type
application/json
{
  • "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
  • "docusign_id": "string",
  • "status": "active",
  • "buyer": {
    },
  • "seller": {
    },
  • "contract_stats": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "modified": "2019-08-24T14:15:22Z",
  • "default_payment_program": "do_not_process",
  • "default_flexible_payment_strategy": "factored",
  • "custom_direct_payment_term_type": "string",
  • "custom_reverse_factor_auto_assignment": true
}

Delete a Payment Contract

Delete a single payment contract.

Authorizations:
bearerAuth
path Parameters
contract_id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

billing

billing_m2m_order_usages_retrieve

Handle GET request for OrderUsage.

Authorizations:
bearerAuth

Responses

Brand

List Brands

List multiple Brands.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Get Brand

Get a single Brand.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this brand.

header Parameters
LeafLink-Version
string <date>

Responses

Shop Brands

List brands and sponsorships for the Shop Brands page.

Authorizations:
bearerAuth
query Parameters
ancillary_type
string
Enum: "all" "preferred"
badge
Array of strings

Filter by badge code

category
Array of strings

Filter by category slug

company_id
required
integer

The ID of the viewing company

has_ordered_from
boolean

Filter by brands that were ordered from previously

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

payment_method
Array of strings
Items Enum: "direct_pay" "flex_pay" "payment_on_sell_through"
search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 420,
  • "previous": "http://example.com",
  • "content": {
    }
}

brands

Buyer Product Image

List Product Images

List multiple Product Images.

Authorizations:
bearerAuth
query Parameters
company
integer
company_slug
string
id
Array of integers

Multiple values may be separated by commas.

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

product
integer
product__id
Array of integers

Multiple values may be separated by commas.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get Product Image

Get a single Product Image.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product image.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "image": "http://example.com",
  • "product": 0,
  • "position": 1
}

chats

chats_list

List all discussions

Authorizations:
bearerAuth
query Parameters
from_date
string

Filter discussions from this date (YYYY-MM-DD)

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term for filtering messages content

status
string

Filter by discussion status ('in_progress' or 'completed')

to_date
string

Filter discussions until this date (YYYY-MM-DD)

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 420,
  • "previous": "http://example.com",
  • "current_page": 0,
  • "results": [
    ]
}

chats_create

Create a new discussion with the first message.

Authorizations:
bearerAuth
Request Body schema: application/json
required
topic
required
string non-empty
required
object (CompanyRequest)

Company serializer

required
object (CompanyRequest)

Company serializer

creator
integer or null

Discussion Creator

required
object

Discussion Message serializer

Responses

Request samples

Content type
application/json
{
  • "topic": "string",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "first_message": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "topic": "string",
  • "status": "in_progress",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "latest_message": {
    }
}

chats_retrieve

LeafLink API for Marketplace discussions.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "topic": "string",
  • "status": "in_progress",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "latest_message": {
    }
}

chats_update

LeafLink API for Marketplace discussions.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
topic
required
string non-empty
required
object (CompanyRequest)

Company serializer

required
object (CompanyRequest)

Company serializer

creator
integer or null

Discussion Creator

required
object

Discussion Message serializer

Responses

Request samples

Content type
application/json
{
  • "topic": "string",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "first_message": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "topic": "string",
  • "status": "in_progress",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "latest_message": {
    }
}

chats_partial_update

LeafLink API for Marketplace discussions.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
topic
string non-empty
object (CompanyRequest)

Company serializer

object (CompanyRequest)

Company serializer

creator
integer or null

Discussion Creator

object

Discussion Message serializer

Responses

Request samples

Content type
application/json
{
  • "topic": "string",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "first_message": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "topic": "string",
  • "status": "in_progress",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "latest_message": {
    }
}

chats_destroy

LeafLink API for Marketplace discussions.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

header Parameters
LeafLink-Version
string <date>

Responses

chats_messages_read_partial_update

Mark a specific message as read

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

message_id
required
integer

A unique integer value identifying this message.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
read_by_sender_company
boolean
read_by_recipient_company
boolean

Responses

Request samples

Content type
application/json
{
  • "read_by_sender_company": true,
  • "read_by_recipient_company": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "topic": "string",
  • "status": "in_progress",
  • "sender_company": {
    },
  • "recipient_company": {
    },
  • "creator": 0,
  • "latest_message": {
    }
}

Bulk update chat status

Takes a list of chat IDs and updates their status to the given status. Status must be one of: in_progress, completed

Authorizations:
bearerAuth
Request Body schema: application/json
status
string
Enum: "in_progress" "completed"
chats
Array of integers

Responses

Request samples

Content type
application/json
{
  • "status": "in_progress",
  • "chats": [
    ]
}

Messages

chats_messages_list

Get or post messages for a discussion

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 420,
  • "previous": "http://example.com",
  • "current_page": 0,
  • "results": [
    ]
}

chats_messages_create

Get or post messages for a discussion

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this chat.

query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
message
required
string non-empty

Responses

Request samples

Content type
application/json
{
  • "message": "string"
}

Response samples

Content type
application/json
{
  • "count": 420,
  • "previous": "http://example.com",
  • "current_page": 0,
  • "results": [
    ]
}

company_messages

company_messages_find_seller_list

Unified API Buyer Notification Settings.

Authorizations:
bearerAuth
query Parameters
page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term for filtering companies by name

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

company_messages_find_seller_retrieve

Unified API Buyer Notification Settings.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "address": "string",
  • "city": "string",
  • "state": "string",
  • "zipcode": "string",
  • "business_identifier": "string",
  • "business_license_name": "string",
  • "image": "http://example.com",
  • "name": "string",
  • "seller": true,
  • "slug": "string"
}

compliance

compliance_license_types_list

Unified API to list company license types

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

is_buyer_license
boolean

Return buyer license types

is_seller_license
boolean

Return seller license types

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

used_by_company
boolean

Only return license types that are used by the provide company, otherwise return all for the company's state

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

compliance_license_types_retrieve

Unified API to list company license types

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "active_for_registration": true,
  • "classification": "string",
  • "created_on": "2019-08-24T14:15:22Z",
  • "description": "string",
  • "display_type": "string",
  • "has_medical_line_items": true,
  • "id": 0,
  • "modified": "2019-08-24T14:15:22Z",
  • "post_2018_CA": true,
  • "pre_2018_CA": true,
  • "require_ein": true,
  • "state_id": 0,
  • "type": "string"
}

compliance_licenses_list

Unified API to list company licenses

Authorizations:
bearerAuth
query Parameters
company_id
Array of integers

Multiple values may be separated by commas.

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

compliance_licenses_create

Create new licenses from a list of licenses directly from a seed-to-sale vendor.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
Array
number
required
string non-empty
start_date
required
string or null <date>
end_date
required
string <date>
type_id
required
integer

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "license_ids": [
    ]
}

compliance_licenses_retrieve

Unified API to list company licenses

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this license.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "number": "string",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "type_id": 0
}

Contact

List Contacts

List multiple Contacts.

Authorizations:
bearerAuth
query Parameters
company_slug
string
created_date
string <date-time>
delete
string <date-time>
email
string <email>
first_name
string
id
integer
last_name
string
modified_date
string <date-time>
ordering
string

Which field to use when ordering the results.

owner
integer
page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Get Contact

Get a single Contact.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

contacts

contacts_create

LeafLink API for Marketplace contacts.

Authorizations:
bearerAuth
Request Body schema: application/json
required
owner
required
integer
first_name
required
string [ 1 .. 30 ] characters
last_name
string <= 30 characters
email
string or null <email> (Email address) <= 255 characters
secondary_email
string or null <email> (Secondary email address) <= 255 characters
role
string or null (Position) <= 400 characters

Position or role at company

description
string or null <= 1500 characters

An overview of the contact

phone
string or null <= 400 characters ^(\d{10})?$

Phone Number of Brand

phone_extension
string or null <= 20 characters
secondary_phone
string or null <= 400 characters ^(\d{10})?$

Secondary Phone Number of Brand

secondary_phone_extension
string or null <= 20 characters
delete
boolean (Contact deleted)

Is this Contact marked as deleted?

Responses

Request samples

Content type
application/json
{
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

contacts_update

LeafLink API for Marketplace contacts.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
owner
required
integer
first_name
required
string [ 1 .. 30 ] characters
last_name
string <= 30 characters
email
string or null <email> (Email address) <= 255 characters
secondary_email
string or null <email> (Secondary email address) <= 255 characters
role
string or null (Position) <= 400 characters

Position or role at company

description
string or null <= 1500 characters

An overview of the contact

phone
string or null <= 400 characters ^(\d{10})?$

Phone Number of Brand

phone_extension
string or null <= 20 characters
secondary_phone
string or null <= 400 characters ^(\d{10})?$

Secondary Phone Number of Brand

secondary_phone_extension
string or null <= 20 characters
delete
boolean (Contact deleted)

Is this Contact marked as deleted?

Responses

Request samples

Content type
application/json
{
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

contacts_partial_update

LeafLink API for Marketplace contacts.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
owner
integer
first_name
string [ 1 .. 30 ] characters
last_name
string <= 30 characters
email
string or null <email> (Email address) <= 255 characters
secondary_email
string or null <email> (Secondary email address) <= 255 characters
role
string or null (Position) <= 400 characters

Position or role at company

description
string or null <= 1500 characters

An overview of the contact

phone
string or null <= 400 characters ^(\d{10})?$

Phone Number of Brand

phone_extension
string or null <= 20 characters
secondary_phone
string or null <= 400 characters ^(\d{10})?$

Secondary Phone Number of Brand

secondary_phone_extension
string or null <= 20 characters
delete
boolean (Contact deleted)

Is this Contact marked as deleted?

Responses

Request samples

Content type
application/json
{
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "owner": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "email": "user@example.com",
  • "secondary_email": "user@example.com",
  • "role": "string",
  • "description": "string",
  • "phone": "string",
  • "phone_extension": "string",
  • "secondary_phone": "string",
  • "secondary_phone_extension": "string",
  • "delete": true
}

contacts_destroy

Perform a 'DELETE' on a contact. It will mark the specified contact as Deleted.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Dashboard

Sponsorships

General purpose Sponsorship Content

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

placement
required
Array of strings
Items Enum: "buyer-dash-hero-1" "buyer-dash-hero-2" "buyer-dash-hero-3" "buyer-dash-hero-4" "buyer-dash-hero-5" "buyer-dash-hero-6" "deals-page-1" "deals-page-2" "deals-page-3" "deals-page-4" "discovery-left" "discovery-right" "order-submit-1" "order-submit-2" "order-submit-3" "order-submit-4" "product-spotlight-carousel" "recommended-brands-recently-purchased" "recommended-products-cart" "recommended-products-order" "recommended-products-pdm-alternative" "recommended-products-pdp-alternative" "recommended-products-shop-brands" "recommended-products-shop-discover-products" "recommended-products-shop-products" "recommended-products-top-purchased" "seller-dash-hero-1" "seller-dash-hero-2" "seller-dash-hero-3" "seller-dash-hero-4" "seller-dash-hero-5" "seller-dash-hero-6" "shop-brands-featured-brand" "shop-brands-featured-brand-2" "shop-brands-featured-brand-3" "shop-brands-featured-brand-4" "shop-brands-featured-brand-5" "shop-brands-sidebar-3" "shop-brands-sidebar-4" "shop-brands-sidebar-bottom" "shop-brands-sidebar-top" "shop-brands-skyscraper-1" "shop-brands-skyscraper-2" "shop-brands-skyscraper-3" "shop-brands-skyscraper-4" "shop-products-1" "shop-products-2" "shop-products-3" "shop-products-4" "shop-products-5"

The ID of an ad location (can be repeated)

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "content": {
    }
}

Customer

List Company Customer Status

List multiple Company Customer Status.

Authorizations:
bearerAuth
query Parameters
company_slug
string
description
string
hex_color
string
id
integer
is_stock
boolean
order
integer
ordering
string

Which field to use when ordering the results.

owner
integer
page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

state
string
header Parameters
LeafLink-Version
string <date>

Responses

Get Company Customer Status

Get a single Company Customer Status.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer status.

header Parameters
LeafLink-Version
string <date>

Responses

List Customers

List multiple Customers.

Authorizations:
bearerAuth
query Parameters
address
string
address__in
string
address__startswith
string
archived
boolean
brand
string
brand__in
Array of strings

Multiple values may be separated by commas.

brand__startswith
string
business_identifier
string
business_identifier__in
Array of strings

Multiple values may be separated by commas.

business_identifier__startswith
string
business_license_name
string
business_license_name__in
string
business_license_name__startswith
string
company_slug
string
created_on__gt
string <date-time>
created_on__gte
string <date-time>
created_on__lt
string <date-time>
created_on__lte
string <date-time>
dba
string
dba__in
string
dba__startswith
string
delinquent
boolean
discount_percent__gt
number
discount_percent__gte
number
discount_percent__lt
number
discount_percent__lte
number
ein
string
ein__in
string
ein__startswith
string
email
string
email__in
Array of strings

Multiple values may be separated by commas.

email__startswith
string
ext_acct_id
string
ext_acct_id__in
Array of strings

Multiple values may be separated by commas.

ext_acct_id__isnull
boolean
ext_acct_id__startswith
string
external_id
string
external_id__in
Array of strings

Multiple values may be separated by commas.

external_id__startswith
string
external_id_key
string
external_id_unmapped
boolean
external_id_values
string
id
Array of integers

Multiple values may be separated by commas.

id__in
Array of integers

Multiple values may be separated by commas.

is_archived
boolean
leaflink_source
boolean
license_inactive
boolean
license_number
string
license_type
string
modified__gt
string <date-time>
modified__gte
string <date-time>
modified__lt
string <date-time>
modified__lte
string <date-time>
name
string
name__in
string
name__startswith
string
next_contact_date__gt
string <date>
next_contact_date__gte
string <date>
next_contact_date__lt
string <date>
next_contact_date__lte
string <date>
nickname
string
nickname__in
Array of strings

Multiple values may be separated by commas.

nickname__startswith
string
old_license_number
string
old_license_number__in
Array of strings

Multiple values may be separated by commas.

old_license_number__startswith
string
ordering
string

Which field to use when ordering the results.

owner
integer
owner__slug
string
page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

partner
integer
payment_term
Array of integers

Multiple values may be separated by commas.

phone
string
phone__in
string
phone__startswith
string
price_schedule
Array of integers

Multiple values may be separated by commas.

search
string

A search term.

service_zone
Array of integers

Multiple values may be separated by commas.

state
Array of integers

Multiple values may be separated by commas.

status
Array of integers

Multiple values may be separated by commas.

tier
Array of integers

Multiple values may be separated by commas.

website
string
website__in
string
website__startswith
string
header Parameters
LeafLink-Version
string <date>

Responses

Get Customer

Get a single Customer.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>

Responses

customer_statuses

customer_statuses_create

LeafLink API for Marketplace company customer status.

Authorizations:
bearerAuth
Request Body schema: application/json
required
state
required
string (Customer Status) [ 1 .. 40 ] characters

Customer Status State

order
integer (Sort Order) [ 1 .. 2147483647 ]

Sort order, lower is first.

description
string or null <= 1500 characters

Description of status

owner
required
integer or null (Company)

The Company that created the custom status.

is_stock
boolean (Is a LeafLink Stock Status)

Is this a stock LeafLink status?

hex_color
string or null <= 40 characters ^#[0-9a-fA-F]{6}$

Hex color for customer status

Responses

Request samples

Content type
application/json
{
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

customer_statuses_update

LeafLink API for Marketplace company customer status.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer status.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
state
required
string (Customer Status) [ 1 .. 40 ] characters

Customer Status State

order
integer (Sort Order) [ 1 .. 2147483647 ]

Sort order, lower is first.

description
string or null <= 1500 characters

Description of status

owner
required
integer or null (Company)

The Company that created the custom status.

is_stock
boolean (Is a LeafLink Stock Status)

Is this a stock LeafLink status?

hex_color
string or null <= 40 characters ^#[0-9a-fA-F]{6}$

Hex color for customer status

Responses

Request samples

Content type
application/json
{
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

customer_statuses_partial_update

LeafLink API for Marketplace company customer status.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer status.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
state
string (Customer Status) [ 1 .. 40 ] characters

Customer Status State

order
integer (Sort Order) [ 1 .. 2147483647 ]

Sort order, lower is first.

description
string or null <= 1500 characters

Description of status

owner
integer or null (Company)

The Company that created the custom status.

is_stock
boolean (Is a LeafLink Stock Status)

Is this a stock LeafLink status?

hex_color
string or null <= 40 characters ^#[0-9a-fA-F]{6}$

Hex color for customer status

Responses

Request samples

Content type
application/json
{
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "state": "string",
  • "order": 1,
  • "description": "string",
  • "owner": 0,
  • "is_stock": true,
  • "hex_color": "string"
}

customer_statuses_destroy

LeafLink API for Marketplace company customer status.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer status.

header Parameters
LeafLink-Version
string <date>

Responses

customers

customers_create

LeafLink API for Marketplace customers.

Authorizations:
bearerAuth
Request Body schema: application/json
required
managers
Array of integers
phone
string or null non-empty
phone_extension
string or null non-empty
email
string or null <email> (Email address) <= 255 characters
website
string or null non-empty
next_contact_date
string or null <date>
(TierEnum (integer or null)) or (NullEnum-unified-upstream-marketplace (number or null)) (Company customer tier) [ -2147483648 .. 2147483647 ]

Company customer tier

name
required
string non-empty
license_number
string non-empty
old_license_number
string or null (Old License Number (stored after a transfer)) <= 100 characters

Old License Number (stored after a transfer)

is_license_inactive
boolean
Default: false

License inactive or transferred for this customer

business_identifier
string or null (Business Identifier / UBI) <= 100 characters

Company identifier distinct from license numbers

directions
string or null <= 6000 characters

(Driving) Directions to the Customer location for deliveries

delivery_preferences
string or null non-empty
shipping_charge
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Additional Shipping Charge

brand
string or null (Brand Name) <= 400 characters

Known Brand name of Company or Parent Company

business_license_name
string or null non-empty
description
string or null non-empty
notes
string or null <= 3000 characters

Other information on customer

is_archived
boolean
Default: false

Is the customer a relevent part of your CRM

is_delinquent
boolean
Default: false

Is this account delinquent on billing

discount_percent
string <decimal> ^-?\d{0,8}(?:\.\d{0,4})?$

Discount percent for orders of company customer

external_ids
string
owner_id
required
integer

Owner ID for customer

partner_id
integer

Partner ID for customer

price_schedule_id
integer

Price schedule ID for the customer

service_zone_id
integer

Service zone ID for the customer

status_id
integer

Status ID for the customer

Responses

Request samples

Content type
application/json
{
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "notes": "string",
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone_id": 0,
  • "status_id": 0
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "dba": "string",
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "nickname": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "ein": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "currency": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "corporate_address": {
    },
  • "delivery_address": {
    },
  • "notes": "string",
  • "leaflink_last_viewed": "2019-08-24T14:15:22Z",
  • "leaflink_source": true,
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone": {
    },
  • "license_type": 0,
  • "status": {
    },
  • "available_payment_options": [
    ]
}

customers_update

LeafLink API for Marketplace customers.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
managers
Array of integers
phone
string or null non-empty
phone_extension
string or null non-empty
email
string or null <email> (Email address) <= 255 characters
website
string or null non-empty
next_contact_date
string or null <date>
(TierEnum (integer or null)) or (NullEnum-unified-upstream-marketplace (number or null)) (Company customer tier) [ -2147483648 .. 2147483647 ]

Company customer tier

name
required
string non-empty
license_number
string non-empty
old_license_number
string or null (Old License Number (stored after a transfer)) <= 100 characters

Old License Number (stored after a transfer)

is_license_inactive
boolean
Default: false

License inactive or transferred for this customer

business_identifier
string or null (Business Identifier / UBI) <= 100 characters

Company identifier distinct from license numbers

directions
string or null <= 6000 characters

(Driving) Directions to the Customer location for deliveries

delivery_preferences
string or null non-empty
shipping_charge
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Additional Shipping Charge

brand
string or null (Brand Name) <= 400 characters

Known Brand name of Company or Parent Company

business_license_name
string or null non-empty
description
string or null non-empty
notes
string or null <= 3000 characters

Other information on customer

is_archived
boolean
Default: false

Is the customer a relevent part of your CRM

is_delinquent
boolean
Default: false

Is this account delinquent on billing

discount_percent
string <decimal> ^-?\d{0,8}(?:\.\d{0,4})?$

Discount percent for orders of company customer

external_ids
string
owner_id
required
integer

Owner ID for customer

partner_id
integer

Partner ID for customer

price_schedule_id
integer

Price schedule ID for the customer

service_zone_id
integer

Service zone ID for the customer

status_id
integer

Status ID for the customer

Responses

Request samples

Content type
application/json
{
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "notes": "string",
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone_id": 0,
  • "status_id": 0
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "dba": "string",
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "nickname": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "ein": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "currency": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "corporate_address": {
    },
  • "delivery_address": {
    },
  • "notes": "string",
  • "leaflink_last_viewed": "2019-08-24T14:15:22Z",
  • "leaflink_source": true,
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone": {
    },
  • "license_type": 0,
  • "status": {
    },
  • "available_payment_options": [
    ]
}

customers_partial_update

LeafLink API for Marketplace customers.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
managers
Array of integers
phone
string or null non-empty
phone_extension
string or null non-empty
email
string or null <email> (Email address) <= 255 characters
website
string or null non-empty
next_contact_date
string or null <date>
(TierEnum (integer or null)) or (NullEnum-unified-upstream-marketplace (number or null)) (Company customer tier) [ -2147483648 .. 2147483647 ]

Company customer tier

name
string non-empty
license_number
string non-empty
old_license_number
string or null (Old License Number (stored after a transfer)) <= 100 characters

Old License Number (stored after a transfer)

is_license_inactive
boolean
Default: false

License inactive or transferred for this customer

business_identifier
string or null (Business Identifier / UBI) <= 100 characters

Company identifier distinct from license numbers

directions
string or null <= 6000 characters

(Driving) Directions to the Customer location for deliveries

delivery_preferences
string or null non-empty
shipping_charge
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Additional Shipping Charge

brand
string or null (Brand Name) <= 400 characters

Known Brand name of Company or Parent Company

business_license_name
string or null non-empty
description
string or null non-empty
notes
string or null <= 3000 characters

Other information on customer

is_archived
boolean
Default: false

Is the customer a relevent part of your CRM

is_delinquent
boolean
Default: false

Is this account delinquent on billing

discount_percent
string <decimal> ^-?\d{0,8}(?:\.\d{0,4})?$

Discount percent for orders of company customer

external_ids
string
owner_id
integer

Owner ID for customer

partner_id
integer

Partner ID for customer

price_schedule_id
integer

Price schedule ID for the customer

service_zone_id
integer

Service zone ID for the customer

status_id
integer

Status ID for the customer

Responses

Request samples

Content type
application/json
{
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "notes": "string",
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone_id": 0,
  • "status_id": 0
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "dba": "string",
  • "managers": [
    ],
  • "phone": "string",
  • "phone_extension": "string",
  • "email": "user@example.com",
  • "website": "string",
  • "next_contact_date": "2019-08-24",
  • "tier": 1,
  • "name": "string",
  • "nickname": "string",
  • "license_number": "string",
  • "old_license_number": "string",
  • "is_license_inactive": false,
  • "business_identifier": "string",
  • "ein": "string",
  • "directions": "string",
  • "delivery_preferences": "string",
  • "currency": "string",
  • "shipping_charge": "string",
  • "brand": "string",
  • "business_license_name": "string",
  • "description": "string",
  • "corporate_address": {
    },
  • "delivery_address": {
    },
  • "notes": "string",
  • "leaflink_last_viewed": "2019-08-24T14:15:22Z",
  • "leaflink_source": true,
  • "is_archived": false,
  • "is_delinquent": false,
  • "discount_percent": "string",
  • "external_ids": "string",
  • "owner_id": 0,
  • "partner_id": 0,
  • "price_schedule_id": 0,
  • "service_zone": {
    },
  • "license_type": 0,
  • "status": {
    },
  • "available_payment_options": [
    ]
}

customers_destroy

For delete request

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>

Responses

customers_corporate_address_create

Action route for interfacing with the corporate address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
address
required
string [ 1 .. 400 ] characters

Address

unit_number
string (Unit #) <= 400 characters

Unit #

city
required
string [ 1 .. 400 ] characters

City

county
string <= 400 characters

County

state
string non-empty
zipcode
required
string [ 1 .. 7 ] characters

Zipcode

Responses

Request samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

Response samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

customers_corporate_address_partial_update

Action route for interfacing with the corporate address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
address
string [ 1 .. 400 ] characters

Address

unit_number
string (Unit #) <= 400 characters

Unit #

city
string [ 1 .. 400 ] characters

City

county
string <= 400 characters

County

state
string non-empty
zipcode
string [ 1 .. 7 ] characters

Zipcode

Responses

Request samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

Response samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

customers_corporate_address_destroy

Action route for interfacing with the corporate address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>

Responses

customers_delivery_address_create

Action route for interfacing with the delivery address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
address
required
string [ 1 .. 400 ] characters

Address

unit_number
string (Unit #) <= 400 characters

Unit #

city
required
string [ 1 .. 400 ] characters

City

county
string <= 400 characters

County

state
string non-empty
zipcode
required
string [ 1 .. 7 ] characters

Zipcode

Responses

Request samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

Response samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

customers_delivery_address_partial_update

Action route for interfacing with the delivery address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
address
string [ 1 .. 400 ] characters

Address

unit_number
string (Unit #) <= 400 characters

Unit #

city
string [ 1 .. 400 ] characters

City

county
string <= 400 characters

County

state
string non-empty
zipcode
string [ 1 .. 7 ] characters

Zipcode

Responses

Request samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

Response samples

Content type
application/json
{
  • "address": "string",
  • "unit_number": "string",
  • "city": "string",
  • "county": "string",
  • "state": "string",
  • "zipcode": "string"
}

customers_delivery_address_destroy

Action route for interfacing with the delivery address

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

header Parameters
LeafLink-Version
string <date>

Responses

customers_active_entries_destroy

Delete an Active Entry for a company

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company activity entry.

header Parameters
LeafLink-Version
string <date>

Responses

ActiveEntry

List Company Active Entries

List multiple Company Active Entries.

Authorizations:
bearerAuth
query Parameters
author
integer
author_id
Array of integers

Multiple values may be separated by commas.

brand
Array of integers

Multiple values may be separated by commas.

brand_id
Array of integers

Multiple values may be separated by commas.

company
integer
company_id
Array of integers

Multiple values may be separated by commas.

company_slug
string
contact
Array of integers

Multiple values may be separated by commas.

contact_id
Array of integers

Multiple values may be separated by commas.

created_on__gt
string <date-time>
created_on__gte
string <date-time>
created_on__lt
string <date-time>
created_on__lte
string <date-time>
customer
integer
customer_id
Array of integers

Multiple values may be separated by commas.

date__gt
string <date-time>
date__gte
string <date-time>
date__lt
string <date-time>
date__lte
string <date-time>
delete
boolean
entry
string
entry__in
Array of strings

Multiple values may be separated by commas.

entry__startswith
string
id
integer
is_deleted
boolean
modified__gt
string <date-time>
modified__gte
string <date-time>
modified__lt
string <date-time>
modified__lte
string <date-time>
ordering
string

Which field to use when ordering the results.

owner
integer
owner_id
Array of integers

Multiple values may be separated by commas.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

staff
integer
staff_id
Array of integers

Multiple values may be separated by commas.

type
Array of strings

Multiple values may be separated by commas.

header Parameters
LeafLink-Version
string <date>

Responses

Get Active Entry

Get a single Company Active Entry.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company activity entry.

header Parameters
LeafLink-Version
string <date>

Responses

Product

Featured Products

List new brands, products with deals, and sponsored products on the dashboard.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

List Express Product Menus

List multiple ExpressProductMenus.

Authorizations:
bearerAuth
query Parameters
brand
integer
ordering
string

Which field to use when ordering the results.

price_schedule
integer
products
string

Set to 'false' to avoid an unnecessary query for product IDs

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

List Products

List multiple Products.

Authorizations:
bearerAuth
query Parameters
archived
boolean
base_units_per_unit__isnull
boolean
batch_associated__isnull
boolean
brand
integer
buyer
number
category
integer
company
integer
company_slug
string
created_on__gt
string <date-time>
created_on__gte
string <date-time>
created_on__lt
string <date-time>
created_on__lte
string <date-time>
display_name
string
extern_sts_ids
Array of numbers

Multiple values may be separated by commas.

external_id_key
string
external_id_unmapped
boolean
external_id_values
string
external_ids
string
has_children
boolean
id
Array of integers

Multiple values may be separated by commas.

last_edit__gt
string <date-time>
last_edit__gte
string <date-time>
last_edit__lt
string <date-time>
last_edit__lte
string <date-time>
license
Array of integers

Multiple values may be separated by commas.

license__isnull
boolean
license__type
Array of integers

Multiple values may be separated by commas.

listing_state
string
modified__gt
string <date-time>
modified__gte
string <date-time>
modified__lt
string <date-time>
modified__lte
string <date-time>
name
string
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

parent
Array of integers

Multiple values may be separated by commas.

parent__isnull
boolean
product_line
Array of integers

Multiple values may be separated by commas.

reconcile_inventory
boolean
s2s_connected
boolean
search
string

A search term.

sku
Array of strings

Multiple values may be separated by commas.

strains
Array of integers

Multiple values may be separated by commas.

sub_category
Array of integers

Multiple values may be separated by commas.

sub_category__isnull
boolean
header Parameters
LeafLink-Version
string <date>

Responses

Get Product

Get a single Product.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>

Responses

Bulk Product Update

Update Multiple Products.

Authorizations:
bearerAuth
Request Body schema: application/json
required
Array
selector
required
string
Value: "product_line"

association or field to select products. Currently only supports 'product_line'.

selector_values
required
Array of integers
required
Array of objects (UnifiedProductBulkUpdateDataRequest)

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
{
  • "updated": 2,
  • "expected": 4,
  • "errors": {
    }
}

deliveries

deliveries_list

Unified API product categories.

Authorizations:
bearerAuth
query Parameters
buyer
string
delivery_date
string <date>
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

order_invoice_number
string
ordering
string

Which field to use when ordering the results.

pickup_date
string <date>
requested_date
string <date>
search
string

A search term.

sort_by
Array of strings
Items Enum: "-created_on" "-display_delivery_date" "-requested_pickup_date" "created_on" "display_delivery_date" "requested_pickup_date"

Ordering

status
Array of strings (Status of L3Order)
Items Enum: "assigned" "created" "delivered" "planned" "shipped" "uploaded"
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

deliveries_create

Unified API product categories.

Authorizations:
bearerAuth
Request Body schema: application/json
required
payment_expected
required
string
status
string (Status of L3Order)
Enum: "uploaded" "created" "assigned" "planned" "shipped" "delivered" "deleted"
requested_pickup_date
string or null <date> (Requested pick up date)

Requested pick up date

expected_pickup_datetime
string or null <date-time> (Expected pick up datetime)

Expected pick up date and time

actual_pickup_datetime
string or null <date-time> (Actual pick up datetime)

Actual date time the order was picked up

requested_delivery_date
string or null <date>

Requested delivery date for the order

expected_delivery_datetime
string or null <date-time>

Expected delivery date and time for the order

actual_delivery_datetime
string or null <date-time>

Actual delivery date and time for the order

required
object (DriverRequest)

serializer for Driver Model.

required
object (InternalVehicleRequest)

Internal serializer for Vehicle Model.

required
object (DriverRequest)

serializer for Driver Model.

required
object (InternalVehicleRequest)

Internal serializer for Vehicle Model.

required
object (PaymentMethodRequest)

Serialize payment method.

required
object (PaymentTermRequest)

Serialize payment term.

customer_notes
string or null

Customer notes for the L3 Order

notes
string or null (Additional Notes)

Additional notes for the L3 Order

eligible_payment_methods
Array of strings (Eligible payment methods for this order) [ items [ 1 .. 100 ] characters ]

A selection of eligible payment methods for this order

payment_method_collected
string (Collected Payment Method) <= 100 characters

Payment method used for this order

collected_payment_amount
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Payment collected at delivery

delivery_driver_comment
string <= 500 characters

Comment from delivery driver for this order

required
object (InternalLogisticsCompanyRequest)

Internal serializer for the Company model to be used by L3 endpoints.

Responses

Request samples

Content type
application/json
{
  • "payment_expected": "string",
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "brand": {
    }
}

Response samples

Content type
application/json
{
  • "number": "string",
  • "invoice_number": "string",
  • "mp_order_number": "string",
  • "transport_order_id": "string",
  • "payment_expected": "string",
  • "customer": {
    },
  • "pickup_address": {
    },
  • "destination": {
    },
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "display_delivery_date": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "additional_pickup_drivers": [
    ],
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "metrc_transfer": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "transport_company": {
    },
  • "brand": {
    }
}

Logistics Transport

Get Transport Order

Get a single Transport Order.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this l3 order.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "number": "string",
  • "invoice_number": "string",
  • "mp_order_number": "string",
  • "transport_order_id": "string",
  • "payment_expected": "string",
  • "customer": {
    },
  • "pickup_address": {
    },
  • "destination": {
    },
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "display_delivery_date": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "additional_pickup_drivers": [
    ],
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "metrc_transfer": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "transport_company": {
    },
  • "brand": {
    }
}

List Transport Companies

List all transport companies.

Authorizations:
bearerAuth
query Parameters
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

ordering
string

Which field to use when ordering the results.

search
string

A search term.

state_abbr
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

List Drivers

Get active drivers for given transport partner, by default returns only active drivers.

Authorizations:
tokenAuth
path Parameters
include_inactive
required
any

If set to 'true' endpoint will return all Drivers, both active and inactive.

query Parameters
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Create Driver

Create Driver

Authorizations:
tokenAuth
query Parameters
email
string
first_name
string
last_name
string
license_number
string
metrc_employee_id
string
phone
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
first_name
required
string (First Name of Driver) [ 1 .. 100 ] characters

First Name

last_name
required
string [ 1 .. 100 ] characters

Last Name of Driver

metrc_employee_id
required
string [ 1 .. 100 ] characters

METRC Employee ID for Driver

license_number
required
string [ 1 .. 15 ] characters

License Number of Driver

phone
required
string [ 1 .. 15 ] characters

Phone Number of Driver

is_active
boolean (Active)

Is an active driver?

Responses

Request samples

Content type
application/json
{
  • "first_name": "string",
  • "last_name": "string",
  • "metrc_employee_id": "string",
  • "license_number": "string",
  • "phone": "string",
  • "is_active": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "metrc_employee_id": "string",
  • "license_number": "string",
  • "phone": "string",
  • "is_active": true,
  • "transport_company": {
    }
}

List Transport Order

List multiple Transport Order.

Authorizations:
tokenAuth
query Parameters
buyer
string
delivery_date
string <date>
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

order_invoice_number
string
ordering
string

Which field to use when ordering the results.

pickup_date
string <date>
requested_date
string <date>
search
string

A search term.

sort_by
Array of strings
Items Enum: "-created_on" "-display_delivery_date" "-requested_pickup_date" "created_on" "display_delivery_date" "requested_pickup_date"

Ordering

status
Array of strings (Status of L3Order)
Items Enum: "assigned" "created" "delivered" "planned" "shipped" "uploaded"
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

Get Transport Order

Get a single Transport Order.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this l3 order.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "number": "string",
  • "invoice_number": "string",
  • "mp_order_number": "string",
  • "transport_order_id": "string",
  • "payment_expected": "string",
  • "customer": {
    },
  • "pickup_address": {
    },
  • "destination": {
    },
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "display_delivery_date": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "additional_pickup_drivers": [
    ],
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "metrc_transfer": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "transport_company": {
    },
  • "brand": {
    }
}

List Company Transport Partner

List all transport partners for all companies to which the requesting user has access.

Authorizations:
bearerAuth
query Parameters
company_slug
string
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Create Company Transport Partner

Company transport partner view set.

Authorizations:
bearerAuth
Request Body schema: application/json
required
transport_company_id
required
integer
company_id
integer

Responses

Request samples

Content type
application/json
{
  • "transport_company_id": 0,
  • "company_id": 0
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "company": {
    },
  • "transport_company": {
    }
}

Update Company Transport Partner

Company transport partner view set.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company transport partner.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
transport_company_id
integer
company_id
integer

Responses

Request samples

Content type
application/json
{
  • "transport_company_id": 0,
  • "company_id": 0
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "company": {
    },
  • "transport_company": {
    }
}

List Vehicles

Get vehicles for given transport partner.

Authorizations:
tokenAuth
query Parameters
limit
integer

Number of results to return per page.

offset
integer

The initial index from which to return the results.

ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Create Vehicle

Create Vehicle

Authorizations:
tokenAuth
query Parameters
has_air_conditioner
boolean
license_number
string
make
string
model_name
string
model_year
integer
state_id
integer
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
make
string or null (Vehicle Make) <= 255 characters

Vehicle Make

model_year
integer or null [ -2147483648 .. 2147483647 ]

Vehicle Model Year

model_name
string or null <= 255 characters

Vehicle Model Name

license_number
required
string or null <= 15 characters

License Number of Vehicle

capacity
integer or null [ -2147483648 .. 2147483647 ]

Vehicle Capacity

has_air_conditioner
boolean

Vehicle Has Air Conditioner

Responses

Request samples

Content type
application/json
{
  • "make": "string",
  • "model_year": -2147483648,
  • "model_name": "string",
  • "license_number": "string",
  • "capacity": -2147483648,
  • "has_air_conditioner": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "make": "string",
  • "model_year": -2147483648,
  • "model_name": "string",
  • "license_number": "string",
  • "capacity": -2147483648,
  • "has_air_conditioner": true,
  • "state": {
    }
}

express_menus

express_menus_create

LeafLink API for Marketplace Express Product Menus.

Authorizations:
bearerAuth
Request Body schema: application/json
required
brand
required
integer (Express Menu Brand)
price_schedule
required
integer (Public Menu Price Schedule)
products
required
Array of integers (Public Menu Products)

Responses

Request samples

Content type
application/json
{
  • "brand": 0,
  • "price_schedule": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "brand": 0,
  • "name": "string",
  • "price_schedule": 0,
  • "products": [
    ],
  • "products_count": 0,
  • "slug": "string"
}

express_menus_retrieve

LeafLink API for Marketplace Express Product Menus.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this express product menu.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "brand": 0,
  • "name": "string",
  • "price_schedule": 0,
  • "products": [
    ],
  • "products_count": 0,
  • "slug": "string"
}

express_menus_update

LeafLink API for Marketplace Express Product Menus.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this express product menu.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
brand
required
integer (Express Menu Brand)
price_schedule
required
integer (Public Menu Price Schedule)
products
required
Array of integers (Public Menu Products)

Responses

Request samples

Content type
application/json
{
  • "brand": 0,
  • "price_schedule": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "brand": 0,
  • "name": "string",
  • "price_schedule": 0,
  • "products": [
    ],
  • "products_count": 0,
  • "slug": "string"
}

express_menus_partial_update

LeafLink API for Marketplace Express Product Menus.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this express product menu.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
brand
integer (Express Menu Brand)
price_schedule
integer (Public Menu Price Schedule)
products
Array of integers (Public Menu Products)

Responses

Request samples

Content type
application/json
{
  • "brand": 0,
  • "price_schedule": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "brand": 0,
  • "name": "string",
  • "price_schedule": 0,
  • "products": [
    ],
  • "products_count": 0,
  • "slug": "string"
}

express_menus_destroy

LeafLink API for Marketplace Express Product Menus.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this express product menu.

header Parameters
LeafLink-Version
string <date>

Responses

Notification Preferences

List Notification Preferences Groups

List Notification Preferences Groups.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get a user's notification preferences.

Get a user's notification preferences.

Authorizations:
bearerAuth
path Parameters
user_id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Update a user's notification preferences.

Update a user's notification preferences.

Authorizations:
bearerAuth
path Parameters
user_id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
Array
topic
required
string
medium
required
string
enabled_timestamp
required
boolean

Responses

Request samples

Content type
application/json
[
  • {
    }
]

Response samples

Content type
application/json
[
  • {
    }
]

notification

notification_preferences_retrieve

Unified Notification Preferences view set.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this notification preference group.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "name": "string",
  • "display_description": "string",
  • "items": [
    ]
}

payments

payments_list

ViewSet for handling requests related to order payments.

Authorizations:
bearerAuth
query Parameters
created_date_from
string <date>
created_date_to
string <date>
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

payments_create

ViewSet for handling requests related to order payments.

Authorizations:
bearerAuth
Request Body schema: application/json
required
order
required
string <uuid>
payment_date
string or null <date-time>

Date that the was submitted.

total
required
string <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Total Paid

payment_type
string
Enum: "other" "cash" "check" "credit" "trade" "ach" "wire" "cashier" "leaflink_direct_payment" "leaflink_flexible_payment" "leaflink_financial"

How this payment was submitted.

Responses

Request samples

Content type
application/json
{
  • "order": "93b532b3-a125-4cd2-9b71-9996b1e164ce",
  • "payment_date": "2019-08-24T14:15:22Z",
  • "total": "string",
  • "payment_type": "other"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "order": "93b532b3-a125-4cd2-9b71-9996b1e164ce",
  • "payment_date": "2019-08-24T14:15:22Z",
  • "total": "string",
  • "currency": "string",
  • "payment_type": "other",
  • "customer": {
    }
}

payments_retrieve

ViewSet for handling requests related to order payments.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this order payment.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "order": "93b532b3-a125-4cd2-9b71-9996b1e164ce",
  • "payment_date": "2019-08-24T14:15:22Z",
  • "total": "string",
  • "currency": "string",
  • "payment_type": "other",
  • "customer": {
    }
}

poms

poms_orders_approval_create

Handle the 'APPROVAL' endpoint for a POMS Order. See the CartOrderApprovalAction choices for supported actions that can be performed.

Authorizations:
bearerAuth
Request Body schema: application/json
required
order_id
integer

Order ID from POMS system

purchase_order_number
required
string <uuid>

UUID of Order for approval

status
required
string
Enum: "approved" "rejected" "completed" "error"

Status of the POMS order that defines the action to be taken

message
string non-empty

Optional message

Responses

Request samples

Content type
application/json
{
  • "order_id": 0,
  • "purchase_order_number": "68164fc0-d678-4371-93ef-dd2a85d0ac7f",
  • "status": "approved",
  • "message": "string"
}

Response samples

Content type
application/json
{
  • "order_id": 0,
  • "purchase_order_number": "68164fc0-d678-4371-93ef-dd2a85d0ac7f",
  • "status": "approved",
  • "message": "string"
}

Product Category

List Product Categories

List multiple product categories.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get a Product Category

Get a single product category.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product category.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "name": "string",
  • "slug": "string",
  • "description": "string"
}

Product Grow Operation Type

List Grow Operation Types

List Grow Operation Types.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Product Image

List Product Images

List multiple Product Images.

Authorizations:
tokenAuth
query Parameters
company
integer
company_slug
string
id
Array of integers

Multiple values may be separated by commas.

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

product
integer
product__id
Array of integers

Multiple values may be separated by commas.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Create Product Image

LeafLink API for Marketplace product images.

Authorizations:
tokenAuth
Request Body schema:
required
image
required
string <binary>

The uploaded file, sent via multipart form data. Retrieved as a url link.

product
required
integer

The Product this image is attached to

position
required
integer

The position of the image in the product image gallery

crop_x
integer or null (Crop Box X Position) [ 0 .. 2147483647 ]

The X position of the image crop box

crop_y
integer or null (Crop Box Y Position) [ 0 .. 2147483647 ]

The Y position of the image crop box

crop_w
integer or null (Crop Box Width) [ 0 .. 2147483647 ]

The width of the image crop box

crop_h
integer or null (Crop Box Height) [ 0 .. 2147483647 ]

The height of the image crop box

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "image": "http://example.com",
  • "product": 0,
  • "position": 0,
  • "crop_x": 2147483647,
  • "crop_y": 2147483647,
  • "crop_w": 2147483647,
  • "crop_h": 2147483647
}

Get Product Image

Get a single Product Image.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product image.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "image": "http://example.com",
  • "product": 0,
  • "position": 0,
  • "crop_x": 2147483647,
  • "crop_y": 2147483647,
  • "crop_w": 2147483647,
  • "crop_h": 2147483647
}

Delete Product Image

LeafLink API for Marketplace product images.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product image.

header Parameters
LeafLink-Version
string <date>

Responses

Clone Product Image

Clone a Product Image via the CloneProductImageService service.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product image.

header Parameters
LeafLink-Version
string <date>
Request Body schema:
required
product
required
integer

The Product this image is attached to

position
required
integer

The position of the image in the product image gallery

crop_x
integer or null (Crop Box X Position) [ 0 .. 2147483647 ]

The X position of the image crop box

crop_y
integer or null (Crop Box Y Position) [ 0 .. 2147483647 ]

The Y position of the image crop box

crop_w
integer or null (Crop Box Width) [ 0 .. 2147483647 ]

The width of the image crop box

crop_h
integer or null (Crop Box Height) [ 0 .. 2147483647 ]

The height of the image crop box

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "image": "http://example.com",
  • "product": 0,
  • "position": 0,
  • "crop_x": 2147483647,
  • "crop_y": 2147483647,
  • "crop_w": 2147483647,
  • "crop_h": 2147483647
}

Bulk Create Product Images

LeafLink API for Marketplace product images.

Authorizations:
tokenAuth
Request Body schema:
required
product_id
required
integer

Product ID

images
required
Array of strings <binary> non-empty [ items <binary > ]
positions
required
Array of integers non-empty

Responses

Response samples

Content type
application/json
{}

Product Line

List Product Lines

List multiple Product Lines.

Authorizations:
tokenAuth
query Parameters
brand
integer
company
integer
company_slug
string
id
Array of integers

Multiple values may be separated by commas.

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Create Product Line

LeafLink API for Marketplace product lines.

Authorizations:
tokenAuth
Request Body schema: application/json
required
name
required
string (Product Line) [ 1 .. 100 ] characters

Name of Product Line

brand_id
required
integer

Brand ID for the product line

menu_position
integer or null (Product Line Menu Position) [ 0 .. 2147483647 ]

The position of ordering

product_ids
Array of integers

List of product IDs associated with this product line

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "brand_id": 0,
  • "menu_position": 2147483647,
  • "product_ids": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "brand": {
    },
  • "menu_position": 2147483647,
  • "products": [
    ]
}

Get Product Line

Get a single Product Line.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product line.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "brand": {
    },
  • "menu_position": 2147483647,
  • "products": [
    ]
}

Update Product Line

LeafLink API for Marketplace product lines.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product line.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
name
string (Product Line) [ 1 .. 100 ] characters

Name of Product Line

brand_id
integer

Brand ID for the product line

menu_position
integer or null (Product Line Menu Position) [ 0 .. 2147483647 ]

The position of ordering

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "brand_id": 0,
  • "menu_position": 2147483647
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "brand": {
    },
  • "menu_position": 2147483647,
  • "products": [
    ]
}

Delete Product Line

LeafLink API for Marketplace product lines.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product line.

header Parameters
LeafLink-Version
string <date>

Responses

Product Listing State

List Listing States

List Listing States.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
[
  • {
    }
]

Product Promotion

List Product Promotions

List multiple product promotions.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

Create a Product Promotion

Create a product promotion.

Authorizations:
bearerAuth
Request Body schema: application/json
required
moloco_id
string non-empty
status
required
string (ProductPromotionStatusEnum)
Enum: "Pending" "Approved" "Completed"
period
string
Default: "Weekly"
Enum: "Daily" "Weekly" "Monthly"
start_date
required
string <date>
end_date
string or null <date>
required
object
required
object
required
object
approver_email
string or null <email> non-empty
brand_id
required
integer
company_id
required
integer
billing_company_id
integer
products
required
Array of integers

Responses

Request samples

Content type
application/json
{
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand_id": 0,
  • "company_id": 0,
  • "billing_company_id": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand": {
    },
  • "company": {
    },
  • "billing_company": {
    },
  • "products": [
    ]
}

Get a Product Promotion

Get a single product promotion.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand": {
    },
  • "company": {
    },
  • "billing_company": {
    },
  • "products": [
    ]
}

Update a Product Promotion

Update a product promotion.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
moloco_id
string non-empty
status
string (ProductPromotionStatusEnum)
Enum: "Pending" "Approved" "Completed"
period
string
Default: "Weekly"
Enum: "Daily" "Weekly" "Monthly"
start_date
string <date>
end_date
string or null <date>
object
object
object
approver_email
string or null <email> non-empty
brand_id
integer
company_id
integer
billing_company_id
integer
products
Array of integers

Responses

Request samples

Content type
application/json
{
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand_id": 0,
  • "company_id": 0,
  • "billing_company_id": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand": {
    },
  • "company": {
    },
  • "billing_company": {
    },
  • "products": [
    ]
}

product_promotions

product_promotions_update

API endpoint to create, view, and edit ProductPromotions for a company.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
moloco_id
string non-empty
status
required
string (ProductPromotionStatusEnum)
Enum: "Pending" "Approved" "Completed"
period
string
Default: "Weekly"
Enum: "Daily" "Weekly" "Monthly"
start_date
required
string <date>
end_date
string or null <date>
required
object
required
object
required
object
approver_email
string or null <email> non-empty
brand_id
required
integer
company_id
required
integer
billing_company_id
integer
products
required
Array of integers

Responses

Request samples

Content type
application/json
{
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand_id": 0,
  • "company_id": 0,
  • "billing_company_id": 0,
  • "products": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "moloco_id": "string",
  • "status": "Pending",
  • "period": "Weekly",
  • "start_date": "2019-08-24",
  • "end_date": "2019-08-24",
  • "max_cpc": {
    },
  • "max_budget": {
    },
  • "budget_per_period": {
    },
  • "approver_email": "user@example.com",
  • "brand": {
    },
  • "company": {
    },
  • "billing_company": {
    },
  • "products": [
    ]
}

product_promotions_destroy

API endpoint to create, view, and edit ProductPromotions for a company.

Authorizations:
bearerAuth
path Parameters
id
required
string
header Parameters
LeafLink-Version
string <date>

Responses

Product Subcategory

List Product Subcategories

List multiple product subcategories.

Authorizations:
tokenAuth
query Parameters
category_id
integer
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

subcategory_id
integer
subcategory_name
string
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get a Product Subcategory

Get a single product subcategory.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this product sub category.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "name": "string",
  • "category": 0,
  • "base_unit_of_measure": 0
}

Product Template

List Product Templates

List multiple product templates.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer
name
string
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

Create Product Template

Create a new product template.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
template_name
required
string [ 1 .. 400 ] characters

Template Name

(ListingStateEnum (string or null)) or (BlankEnum-unified-upstream-marketplace (any or null)) or (NullEnum-unified-upstream-marketplace (any or null))
InventoryManagementEnum (string) or BlankEnum-unified-upstream-marketplace (any) (Product Inventory Management)

The state that determines how inventory is handled for the Product

unit_of_measure
integer or null

Unit of measure

sell_in_unit_of_measure
integer or null

Unit of measure that buyers see

sell_in_multiples
boolean
Default: false
unit_multiplier
integer or null [ 0 .. 2147483647 ]

How many individual units are sold when checking out by Unit of Measure

unit_denomination
integer or null

The denomination of unit for the Product.

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product template

retail_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Manufacturer's Suggested Retail Price (MSRP)

wholesale_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Max Wholesale Price

sale_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Sale Price

minimum_order
string or null <decimal> ^-?\d{0,32}(?:\.\d{0,6})?$

Minimum Units per Order

maximum_order
string or null <decimal> ^-?\d{0,32}(?:\.\d{0,6})?$

Maximum Units per Order

description
string or null <= 7000 characters

Brand Description

category
integer or null
sub_category
integer or null

The sub-category of the Product (e.g. Bulk Flower, Live Resin, etc)

seller
required
integer (Manufacturer)

Company who is selling the Product

brand
integer or null

Brand of product

product_line
integer or null

Product Line of product

(StrainClassificationEnum (string or null)) or (BlankEnum-unified-upstream-marketplace (any or null)) or (NullEnum-unified-upstream-marketplace (any or null))
license
integer or null
SHOW_QUANTITY
boolean or null (Show Product quantity)

Show Product Quantity

AVAILABLE_FOR_SAMPLES
boolean or null

This product is available for samples

threshold_value
integer or null (Product threshold value) [ 0 .. 2147483647 ]

When Product inventory reaches below this value, take various actions

threshold_action
string (Product threshold action)
Enum: "default" "backorder" "unavailable" "internal"

Action to take when Product inventory reaches below a specified value

is_medical_line_item
boolean

Is this a medical line item?

allow_fractional_quantities
boolean or null

This product quantity can contain decimal places

Responses

Request samples

Content type
application/json
{
  • "template_name": "string",
  • "listing_state": "Available",
  • "inventory_management": "inherited",
  • "unit_of_measure": 0,
  • "sell_in_unit_of_measure": 0,
  • "sell_in_multiples": false,
  • "unit_multiplier": 2147483647,
  • "unit_denomination": 0,
  • "base_units_per_unit": "string",
  • "retail_price": "string",
  • "wholesale_price": "string",
  • "sale_price": "string",
  • "minimum_order": "string",
  • "maximum_order": "string",
  • "description": "string",
  • "category": 0,
  • "sub_category": 0,
  • "seller": 0,
  • "brand": 0,
  • "product_line": 0,
  • "strain_classification": "sativa",
  • "license": 0,
  • "SHOW_QUANTITY": true,
  • "AVAILABLE_FOR_SAMPLES": true,
  • "threshold_value": 2147483647,
  • "threshold_action": "default",
  • "is_medical_line_item": true,
  • "allow_fractional_quantities": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "template_name": "string",
  • "listing_state": "Available",
  • "inventory_management": "inherited",
  • "unit_of_measure": 0,
  • "sell_in_unit_of_measure": 0,
  • "sell_in_multiples": false,
  • "unit_multiplier": 2147483647,
  • "unit_denomination": 0,
  • "base_units_per_unit": "string",
  • "retail_price": "string",
  • "wholesale_price": "string",
  • "sale_price": "string",
  • "minimum_order": "string",
  • "maximum_order": "string",
  • "description": "string",
  • "category": 0,
  • "sub_category": 0,
  • "seller": 0,
  • "brand": 0,
  • "product_line": 0,
  • "strain_classification": "sativa",
  • "license": 0,
  • "SHOW_QUANTITY": true,
  • "AVAILABLE_FOR_SAMPLES": true,
  • "threshold_value": 2147483647,
  • "threshold_action": "default",
  • "is_medical_line_item": true,
  • "allow_fractional_quantities": true,
  • "extern_income_acct_id": "string",
  • "cost": "string"
}

Retrieve Product Template

Retrieve a single product template.

Authorizations:
bearerAuth
path Parameters
id
required
string
query Parameters
company_id
required
integer
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "template_name": "string",
  • "listing_state": "Available",
  • "inventory_management": "inherited",
  • "unit_of_measure": 0,
  • "sell_in_unit_of_measure": 0,
  • "sell_in_multiples": false,
  • "unit_multiplier": 2147483647,
  • "unit_denomination": 0,
  • "base_units_per_unit": "string",
  • "retail_price": "string",
  • "wholesale_price": "string",
  • "sale_price": "string",
  • "minimum_order": "string",
  • "maximum_order": "string",
  • "description": "string",
  • "category": 0,
  • "sub_category": 0,
  • "seller": 0,
  • "brand": 0,
  • "product_line": 0,
  • "strain_classification": "sativa",
  • "license": 0,
  • "SHOW_QUANTITY": true,
  • "AVAILABLE_FOR_SAMPLES": true,
  • "threshold_value": 2147483647,
  • "threshold_action": "default",
  • "is_medical_line_item": true,
  • "allow_fractional_quantities": true,
  • "extern_income_acct_id": "string",
  • "cost": "string"
}

Update Product Template

Update an existing product template.

Authorizations:
bearerAuth
path Parameters
id
required
string
query Parameters
company_id
required
integer
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
template_name
string [ 1 .. 400 ] characters

Template Name

(ListingStateEnum (string or null)) or (BlankEnum-unified-upstream-marketplace (any or null)) or (NullEnum-unified-upstream-marketplace (any or null))
InventoryManagementEnum (string) or BlankEnum-unified-upstream-marketplace (any) (Product Inventory Management)

The state that determines how inventory is handled for the Product

unit_of_measure
integer or null

Unit of measure

sell_in_unit_of_measure
integer or null

Unit of measure that buyers see

sell_in_multiples
boolean
Default: false
unit_multiplier
integer or null [ 0 .. 2147483647 ]

How many individual units are sold when checking out by Unit of Measure

unit_denomination
integer or null

The denomination of unit for the Product.

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product template

retail_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Manufacturer's Suggested Retail Price (MSRP)

wholesale_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Max Wholesale Price

sale_price
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Sale Price

minimum_order
string or null <decimal> ^-?\d{0,32}(?:\.\d{0,6})?$

Minimum Units per Order

maximum_order
string or null <decimal> ^-?\d{0,32}(?:\.\d{0,6})?$

Maximum Units per Order

description
string or null <= 7000 characters

Brand Description

category
integer or null
sub_category
integer or null

The sub-category of the Product (e.g. Bulk Flower, Live Resin, etc)

seller
integer (Manufacturer)

Company who is selling the Product

brand
integer or null

Brand of product

product_line
integer or null

Product Line of product

(StrainClassificationEnum (string or null)) or (BlankEnum-unified-upstream-marketplace (any or null)) or (NullEnum-unified-upstream-marketplace (any or null))
license
integer or null
SHOW_QUANTITY
boolean or null (Show Product quantity)

Show Product Quantity

AVAILABLE_FOR_SAMPLES
boolean or null

This product is available for samples

threshold_value
integer or null (Product threshold value) [ 0 .. 2147483647 ]

When Product inventory reaches below this value, take various actions

threshold_action
string (Product threshold action)
Enum: "default" "backorder" "unavailable" "internal"

Action to take when Product inventory reaches below a specified value

is_medical_line_item
boolean

Is this a medical line item?

allow_fractional_quantities
boolean or null

This product quantity can contain decimal places

Responses

Request samples

Content type
application/json
{
  • "template_name": "string",
  • "listing_state": "Available",
  • "inventory_management": "inherited",
  • "unit_of_measure": 0,
  • "sell_in_unit_of_measure": 0,
  • "sell_in_multiples": false,
  • "unit_multiplier": 2147483647,
  • "unit_denomination": 0,
  • "base_units_per_unit": "string",
  • "retail_price": "string",
  • "wholesale_price": "string",
  • "sale_price": "string",
  • "minimum_order": "string",
  • "maximum_order": "string",
  • "description": "string",
  • "category": 0,
  • "sub_category": 0,
  • "seller": 0,
  • "brand": 0,
  • "product_line": 0,
  • "strain_classification": "sativa",
  • "license": 0,
  • "SHOW_QUANTITY": true,
  • "AVAILABLE_FOR_SAMPLES": true,
  • "threshold_value": 2147483647,
  • "threshold_action": "default",
  • "is_medical_line_item": true,
  • "allow_fractional_quantities": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "template_name": "string",
  • "listing_state": "Available",
  • "inventory_management": "inherited",
  • "unit_of_measure": 0,
  • "sell_in_unit_of_measure": 0,
  • "sell_in_multiples": false,
  • "unit_multiplier": 2147483647,
  • "unit_denomination": 0,
  • "base_units_per_unit": "string",
  • "retail_price": "string",
  • "wholesale_price": "string",
  • "sale_price": "string",
  • "minimum_order": "string",
  • "maximum_order": "string",
  • "description": "string",
  • "category": 0,
  • "sub_category": 0,
  • "seller": 0,
  • "brand": 0,
  • "product_line": 0,
  • "strain_classification": "sativa",
  • "license": 0,
  • "SHOW_QUANTITY": true,
  • "AVAILABLE_FOR_SAMPLES": true,
  • "threshold_value": 2147483647,
  • "threshold_action": "default",
  • "is_medical_line_item": true,
  • "allow_fractional_quantities": true,
  • "extern_income_acct_id": "string",
  • "cost": "string"
}

Delete Product Template

Delete an existing product template.

Authorizations:
bearerAuth
path Parameters
id
required
string
query Parameters
company_id
required
integer
header Parameters
LeafLink-Version
string <date>

Responses

products

products_create

LeafLink API for Marketplace products.

Authorizations:
bearerAuth
Request Body schema: application/json
required
name
required
string non-empty

Product name

description
required
string non-empty

Product details

category_id
required
integer

Product category ID for the product

listing_state
required
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

required
object

Wholesale price displayed in the LeafLink marketplace

unit_multiplier
integer

How many individual units are sold when compared to the assigned unit of measure

unit_denomination
required
string <decimal> (Unit Denomination Value) ^-?\d{0,5}(?:\.\d{0,5})?$

The amount of individual products in one sale unit

sku
string or null [ 1 .. 255 ] characters

Stock keeping unit for the product

brand_id
required
integer

Brand ID for the product

manufacturer_id
required
integer

ID of the Company that manufactured the product

seller_id
required
integer

Company who is selling the Product

unit_of_measure
required
string non-empty

Base unit of measure for this product

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "description": "string",
  • "category_id": 0,
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "sku": "string",
  • "brand_id": 0,
  • "manufacturer_id": 0,
  • "seller_id": 0,
  • "unit_of_measure": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "description": "string",
  • "category": {
    },
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "inventory": {
    },
  • "sku": "string",
  • "brand": {
    },
  • "seller_id": 0,
  • "external_ids": {
    },
  • "unit_of_measure": "string"
}

products_update

LeafLink API for Marketplace products.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
name
required
string non-empty

Product name

description
required
string non-empty

Product details

category_id
required
integer

Product category ID for the product

listing_state
required
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

required
object

Wholesale price displayed in the LeafLink marketplace

unit_multiplier
integer

How many individual units are sold when compared to the assigned unit of measure

unit_denomination
required
string <decimal> (Unit Denomination Value) ^-?\d{0,5}(?:\.\d{0,5})?$

The amount of individual products in one sale unit

sku
string or null [ 1 .. 255 ] characters

Stock keeping unit for the product

brand_id
required
integer

Brand ID for the product

manufacturer_id
required
integer

ID of the Company that manufactured the product

seller_id
required
integer

Company who is selling the Product

unit_of_measure
required
string non-empty

Base unit of measure for this product

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "description": "string",
  • "category_id": 0,
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "sku": "string",
  • "brand_id": 0,
  • "manufacturer_id": 0,
  • "seller_id": 0,
  • "unit_of_measure": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "description": "string",
  • "category": {
    },
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "inventory": {
    },
  • "sku": "string",
  • "brand": {
    },
  • "seller_id": 0,
  • "external_ids": {
    },
  • "unit_of_measure": "string"
}

products_partial_update

LeafLink API for Marketplace products.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
name
string non-empty

Product name

description
string non-empty

Product details

category_id
integer

Product category ID for the product

listing_state
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

object

Wholesale price displayed in the LeafLink marketplace

unit_multiplier
integer

How many individual units are sold when compared to the assigned unit of measure

unit_denomination
string <decimal> (Unit Denomination Value) ^-?\d{0,5}(?:\.\d{0,5})?$

The amount of individual products in one sale unit

sku
string or null [ 1 .. 255 ] characters

Stock keeping unit for the product

brand_id
integer

Brand ID for the product

manufacturer_id
integer

ID of the Company that manufactured the product

seller_id
integer

Company who is selling the Product

unit_of_measure
string non-empty

Base unit of measure for this product

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "description": "string",
  • "category_id": 0,
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "sku": "string",
  • "brand_id": 0,
  • "manufacturer_id": 0,
  • "seller_id": 0,
  • "unit_of_measure": "string"
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "display_name": "string",
  • "description": "string",
  • "category": {
    },
  • "listing_state": "Available",
  • "wholesale_price": {
    },
  • "unit_multiplier": 0,
  • "unit_denomination": "string",
  • "inventory": {
    },
  • "sku": "string",
  • "brand": {
    },
  • "seller_id": 0,
  • "external_ids": {
    },
  • "unit_of_measure": "string"
}

products_destroy

Perform a 'DELETE' on a product. It will mark the specified product as Archived.

Logic is put here as the ModelViewSet destroy function doesn't use the serializer.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>

Responses

Product MVP

List Products

List multiple Products.

Authorizations:
bearerAuth
query Parameters
archived
boolean
base_units_per_unit__isnull
boolean
batch_associated__isnull
boolean
brand
integer
buyer
number
category
integer
company
integer
company_slug
string
created_on__gt
string <date-time>
created_on__gte
string <date-time>
created_on__lt
string <date-time>
created_on__lte
string <date-time>
display_name
string
extern_sts_ids
Array of numbers

Multiple values may be separated by commas.

external_id_key
string
external_id_unmapped
boolean
external_id_values
string
has_children
boolean
id
Array of integers

Multiple values may be separated by commas.

last_edit__gt
string <date-time>
last_edit__gte
string <date-time>
last_edit__lt
string <date-time>
last_edit__lte
string <date-time>
license
Array of integers

Multiple values may be separated by commas.

license__isnull
boolean
license__type
Array of integers

Multiple values may be separated by commas.

listing_state
string
modified__gt
string <date-time>
modified__gte
string <date-time>
modified__lt
string <date-time>
modified__lte
string <date-time>
name
string
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

parent
Array of integers

Multiple values may be separated by commas.

parent__isnull
boolean
product_line
Array of integers

Multiple values may be separated by commas.

reconcile_inventory
boolean
s2s_connected
boolean
search
string

A search term.

sku
Array of strings

Multiple values may be separated by commas.

strains
Array of integers

Multiple values may be separated by commas.

sub_category
Array of integers

Multiple values may be separated by commas.

sub_category__isnull
boolean
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

Create Product

LeafLink API for Marketplace products.

Authorizations:
bearerAuth
Request Body schema: application/json
required
sku
string or null (Customer SKU) [ 1 .. 255 ] characters

Stock Keeping Unit. A unique identifier for a Product, alternative to id.

seller_id
required
integer

Company who is selling the Product

brand_id
required
integer

Brand ID for the product

product_line_id
integer

Product Line ID of product

name
required
string (Product) [ 1 .. 400 ] characters

Product Name

license_id
integer or null

License ID for the product

category_id
required
integer

Product category ID for the product

sub_category_id
integer

Product sub-category ID for the product

unit_of_measure_id
required
integer

Base unit of measure ID for this product

unit_denomination_id
required
integer

The ID of amount of individual products in one sale unit

listing_state
required
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

description
required
string [ 1 .. 7000 ] characters

Brand Description

required
object

Wholesale price displayed in the LeafLink marketplace

required
object

Retail price displayed in the LeafLink marketplace

strains
Array of integers (Strains of a product)

The cannabis strains associated with this product

StrainClassificationEnum (string) or BlankEnum-unified-upstream-marketplace (any)
is_medical_line_item
boolean

Is this a medical line item?

GrowTypeEnum (string) or BlankEnum-unified-upstream-marketplace (any)

The type of grow operation for the flower product

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product

object or null

Threshold configuration for inventory alerts

Responses

Request samples

Content type
application/json
{
  • "sku": "string",
  • "seller_id": 0,
  • "brand_id": 0,
  • "product_line_id": 0,
  • "name": "string",
  • "license_id": 0,
  • "category_id": 0,
  • "sub_category_id": 0,
  • "unit_of_measure_id": 0,
  • "unit_denomination_id": 0,
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Get Product

Get a single Product.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Update Product

LeafLink API for Marketplace products.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
sku
string or null (Customer SKU) [ 1 .. 255 ] characters

Stock Keeping Unit. A unique identifier for a Product, alternative to id.

seller_id
integer

Company who is selling the Product

brand_id
integer

Brand ID for the product

product_line_id
integer

Product Line ID of product

name
string (Product) [ 1 .. 400 ] characters

Product Name

license_id
integer or null

License ID for the product

category_id
integer

Product category ID for the product

sub_category_id
integer

Product sub-category ID for the product

unit_of_measure_id
integer

Base unit of measure ID for this product

unit_denomination_id
integer

The ID of amount of individual products in one sale unit

listing_state
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

description
string [ 1 .. 7000 ] characters

Brand Description

object

Wholesale price displayed in the LeafLink marketplace

object

Retail price displayed in the LeafLink marketplace

strains
Array of integers (Strains of a product)

The cannabis strains associated with this product

StrainClassificationEnum (string) or BlankEnum-unified-upstream-marketplace (any)
is_medical_line_item
boolean

Is this a medical line item?

GrowTypeEnum (string) or BlankEnum-unified-upstream-marketplace (any)

The type of grow operation for the flower product

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product

object or null

Threshold configuration for inventory alerts

Responses

Request samples

Content type
application/json
{
  • "sku": "string",
  • "seller_id": 0,
  • "brand_id": 0,
  • "product_line_id": 0,
  • "name": "string",
  • "license_id": 0,
  • "category_id": 0,
  • "sub_category_id": 0,
  • "unit_of_measure_id": 0,
  • "unit_denomination_id": 0,
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Clone Product

Clone a Product.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Clone Product

Clone a Product.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this product.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
sku
string or null (Customer SKU) [ 1 .. 255 ] characters

Stock Keeping Unit. A unique identifier for a Product, alternative to id.

seller_id
required
integer

Company who is selling the Product

brand_id
required
integer

Brand ID for the product

product_line_id
integer

Product Line ID of product

name
required
string (Product) [ 1 .. 400 ] characters

Product Name

license_id
integer or null

License ID for the product

category_id
required
integer

Product category ID for the product

sub_category_id
integer

Product sub-category ID for the product

unit_of_measure_id
required
integer

Base unit of measure ID for this product

unit_denomination_id
required
integer

The ID of amount of individual products in one sale unit

listing_state
required
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

description
required
string [ 1 .. 7000 ] characters

Brand Description

required
object

Wholesale price displayed in the LeafLink marketplace

required
object

Retail price displayed in the LeafLink marketplace

strains
Array of integers (Strains of a product)

The cannabis strains associated with this product

StrainClassificationEnum (string) or BlankEnum-unified-upstream-marketplace (any)
is_medical_line_item
boolean

Is this a medical line item?

GrowTypeEnum (string) or BlankEnum-unified-upstream-marketplace (any)

The type of grow operation for the flower product

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product

object or null

Threshold configuration for inventory alerts

Responses

Request samples

Content type
application/json
{
  • "sku": "string",
  • "seller_id": 0,
  • "brand_id": 0,
  • "product_line_id": 0,
  • "name": "string",
  • "license_id": 0,
  • "category_id": 0,
  • "sub_category_id": 0,
  • "unit_of_measure_id": 0,
  • "unit_denomination_id": 0,
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Add Product from Template

Add a Product from a Template.

Authorizations:
bearerAuth
path Parameters
template_id
required
string^[\d]+$
header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Add Product from Template

Add a Product from a Template.

Authorizations:
bearerAuth
path Parameters
template_id
required
string^[\d]+$
header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
sku
string or null (Customer SKU) [ 1 .. 255 ] characters

Stock Keeping Unit. A unique identifier for a Product, alternative to id.

seller_id
required
integer

Company who is selling the Product

brand_id
required
integer

Brand ID for the product

product_line_id
integer

Product Line ID of product

name
required
string (Product) [ 1 .. 400 ] characters

Product Name

license_id
integer or null

License ID for the product

category_id
required
integer

Product category ID for the product

sub_category_id
integer

Product sub-category ID for the product

unit_of_measure_id
required
integer

Base unit of measure ID for this product

unit_denomination_id
required
integer

The ID of amount of individual products in one sale unit

listing_state
required
string
Enum: "Available" "Archived" "Sample" "Backorder" "Internal" "Unavailable"

Product listing state. Values available at the /listing-states/ endpoint.

description
required
string [ 1 .. 7000 ] characters

Brand Description

required
object

Wholesale price displayed in the LeafLink marketplace

required
object

Retail price displayed in the LeafLink marketplace

strains
Array of integers (Strains of a product)

The cannabis strains associated with this product

StrainClassificationEnum (string) or BlankEnum-unified-upstream-marketplace (any)
is_medical_line_item
boolean

Is this a medical line item?

GrowTypeEnum (string) or BlankEnum-unified-upstream-marketplace (any)

The type of grow operation for the flower product

base_units_per_unit
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,15})?$

Number of base units in one unit of this product

object or null

Threshold configuration for inventory alerts

Responses

Request samples

Content type
application/json
{
  • "sku": "string",
  • "seller_id": 0,
  • "brand_id": 0,
  • "product_line_id": 0,
  • "name": "string",
  • "license_id": 0,
  • "category_id": 0,
  • "sub_category_id": 0,
  • "unit_of_measure_id": 0,
  • "unit_denomination_id": 0,
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "sku": "string",
  • "seller": {
    },
  • "brand": {
    },
  • "product_line": 0,
  • "name": "string",
  • "display_name": "string",
  • "license": {
    },
  • "category": {
    },
  • "sub_category": 0,
  • "unit_of_measure": {
    },
  • "unit_denomination": {
    },
  • "listing_state": "Available",
  • "description": "string",
  • "wholesale_price": {
    },
  • "retail_price": {
    },
  • "strains": [
    ],
  • "strain_classification": "sativa",
  • "is_medical_line_item": true,
  • "grow_type": "greenhouse",
  • "base_units_per_unit": "string",
  • "threshold": {
    }
}

sales_invoices

sales_invoices_list

Authorizations:
bearerAuth
query Parameters
created_date_from
string <date>
created_date_to
string <date>
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

sales_invoices_retrieve

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this order.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "paid_date": "2019-08-24",
  • "buyer": {
    },
  • "total": "string",
  • "order": "string",
  • "payment_due_date": "2019-08-24T14:15:22Z",
  • "ship_date": "2019-08-24T14:15:22Z",
  • "balance": "string",
  • "line_items": [
    ]
}

settings

settings_companies_buyer_notifications_list

Get buyer notification settings.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

settings_companies_buyer_notifications_create

Update buyer notification settings.

Authorizations:
bearerAuth
Request Body schema: application/json
object or null
object or null
object or null
object or null
object or null
object or null
object or null

Responses

Request samples

Content type
application/json
{
  • "order_accepted": {
    },
  • "order_rejected": {
    },
  • "order_fulfilled": {
    },
  • "order_shipped": {
    },
  • "order_complete": {
    },
  • "order_detail_changed": {
    },
  • "flower_available": {
    }
}

Response samples

Content type
application/json
{
  • "order_accepted": {
    },
  • "order_rejected": {
    },
  • "order_fulfilled": {
    },
  • "order_shipped": {
    },
  • "order_complete": {
    },
  • "order_detail_changed": {
    },
  • "flower_available": {
    }
}

settings_companies_buyer_notifications_retrieve

Unified API Buyer Notification Settings.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "order_accepted": {
    },
  • "order_rejected": {
    },
  • "order_fulfilled": {
    },
  • "order_shipped": {
    },
  • "order_complete": {
    },
  • "order_detail_changed": {
    },
  • "flower_available": {
    }
}

SplitIO

Get split treatments

Get split treatments for a company

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

split_name
Array of strings
Items Enum: "acct_man_pod__enrollment_nue_integration" "acct_man_pod__plans_and_billing" "acct_pod__seller_order_summary" "active_experiments" "ads_dashboard_recently_purchased_carousel" "ads_enable_recently_purchased_brands_carousel" "ads_enable_share_menu" "ads_enable_top_purchased_products_carousel" "ads_enable_vueified_share_leaflink" "ads_in_platform_product_promotion" "ads_kevel_buyer_seller_dash" "ads_moloco_shop_brands_featured_brands" "ads_moloco_shop_brands_sidebar_banners" "ads_platform_promotion_automation" "ads_pod_enable_moloco_ad_reporting" "ads_product_recommendation" "ads_product_recommendation_organic_recommendations" "ads_product_spotlight" "ads_serve_algolia_recommendations" "ads_shoppable_skyscraper" "ads_sponsorships_in_product_search" "buyer_settings_store_requests_vue" "can_access_company_group_features" "ce_pod__buyer_metrc_onboarding" "collab_pod__payments_in_crm" "collab_pod__promo_code_display" "collab_pod__sales_rep_email_actions" "com_pod__cart_payment_cta" "com_pod__cart_payment_option" "com_pod__reverse_factor" "com_pod__vendor_menu" "commerce__accept_payments_payment_events" "cop_pod__bank_linking" "cop_pod__payments_exploration_dashboard_widget" "cop_pod__terms_and_conditions" "cret_pod__vueified_company_profile" "custom_menus__edit_product_redirect" "eapps_sage_enabled" "enable_logistics_permission_to_all_users" "enterprise_pod__mult_payment_methods" "enterprise_pod__order_fees" "fire_pod__cashback_rewards" "fire_pod__delinquent_lockdown" "fire_pod__direct_pay_auto_authorization" "fire_pod__direct_pay_enabled_states" "fire_pod__enable_post_weekly_sum_view" "fire_pod__mp_auto_pausing" "fire_pod__mp_balance_checks" "fire_pod__order_adjustments_event_consumer" "fire_pod__post_package_services" "fire_pod__post_settings" "force_segment_reporting" "gro_pod__order_summary_invitations" "gro_pod__printed_menu" "gro_pod__vendor_menu_ui_enhancement" "inbound_shipments_create" "int_pod__order_pdf_report" "inventory_pod__inventory_batch_support" "inventory_pod__inventory_warehouse_support" "inventory_pod__listings_allocations" "inventory_pod__new_product_list_page" "knock_notifications_toaster" "live_inventory_indicator" "llm_sigma_gpo_report" "llm_vue_seller_reports" "logistics_pod__enable_auto_update_of_metrc_templates" "logistics_pod__enable_customers_to_select_transport_partner" "logistics_pod__submit_order_via_csv_upload" "manage_license__add_integration__buyer" "manage_licenses__new_metrc_flow" "messaging_notifications" "npr_pod__integrations_seller" "ogk_pod__knock_notifications" "order_latency" "order_summary_ancillary_enhancements" "order_summary_receipt_log" "orders_internal_approvals" "orders_received_dataview" "pause_inactive_license_companies" "payment_on_sell_through__enrollment" "plat_arch_pod__oso_cloud" "plat_arch_pod__unified_hijacking" "post__sign_terms_and_conditions_for_all_staff_users" "post_allow_remove_post_flag_from_order" "post_automated_payments__calculation" "post_order_preagreement_settings" "post_sts_unit_conversion" "replenishment_catalog_page" "ret_pod__order_minimum" "ret_pod__split_orders" "retail__leaflink_plus_enrollment" "retail_category_management_self_service" "retail_product_leaderboard_negotiate" "retention_pod__brand_menu_social_links" "retention_pod__buyer_reports" "seed_to_sale__buyer_nav" "seed_to_sale__transfer_template" "seed_to_sale_coa_download" "seller_settings_vue" "settings__buyer_account_details" "settings__tax_schedules" "shipping_request_delivery_modal" "shop_brands_performance_improvement" "show_sell_through_for_non_post" "sips_pod__mp_license_service_api" "spliff_pod__collab_notification" "ssr_iframe" "supply_chain_delivered_status" "switch_customer_for_cloned_orders" "trace_pod__s2s_transfers" "trace_pod__search_by_assigned_packages" "traceability__biotrack_buyer_onboarding" "traceability__biotrack_seller_attach_manifest" "traceability__biotrack_seller_transfers_page" "traceability_pod__automated_metrc_license_validation" "traceability_pod__credential_encryption" "traceability_pod__experiment__reconcile_inventory" "traceability_pod__integration_settings" "transport_pod__ma_next_day_delivery" "transport_pod__shipping_set_order_payments" "vue_buyer_notification_settings" "vue_inventory_bulk_price_update" "vue_inventory_product_add_edit_page" "vue_inventory_product_line_page" "vue_messages_page" "vue_settings_brands_page"

The names of the splits

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "commerce__accept_payments_payment_events": "string",
  • "active_experiments": "string",
  • "ads_dashboard_recently_purchased_carousel": "string",
  • "ads_pod_enable_moloco_ad_reporting": "string",
  • "ads_enable_recently_purchased_brands_carousel": "string",
  • "ads_enable_share_menu": "string",
  • "ads_enable_top_purchased_products_carousel": "string",
  • "ads_enable_vueified_share_leaflink": "string",
  • "ads_in_platform_product_promotion": "string",
  • "ads_product_recommendation": "string",
  • "ads_product_spotlight": "string",
  • "ads_shoppable_skyscraper": "string",
  • "ads_sponsorships_in_product_search": "string",
  • "fire_pod__mp_auto_pausing": "string",
  • "logistics_pod__enable_auto_update_of_metrc_templates": "string",
  • "traceability_pod__automated_metrc_license_validation": "string",
  • "fire_pod__mp_balance_checks": "string",
  • "cop_pod__bank_linking": "string",
  • "traceability__biotrack_buyer_onboarding": "string",
  • "ce_pod__buyer_metrc_onboarding": "string",
  • "buyer_settings_store_requests_vue": "string",
  • "retention_pod__buyer_reports": "string",
  • "can_access_company_group_features": "string",
  • "ret_pod__split_orders": "string",
  • "retention_pod__brand_menu_social_links": "string",
  • "com_pod__cart_payment_cta": "string",
  • "com_pod__cart_payment_option": "string",
  • "com_pod__reverse_factor": "string",
  • "fire_pod__cashback_rewards": "string",
  • "traceability_pod__credential_encryption": "string",
  • "custom_menus__edit_product_redirect": "string",
  • "spliff_pod__collab_notification": "string",
  • "fire_pod__delinquent_lockdown": "string",
  • "fire_pod__direct_pay_auto_authorization": "string",
  • "fire_pod__direct_pay_enabled_states": "string",
  • "fire_pod__post_settings": "string",
  • "logistics_pod__enable_customers_to_select_transport_partner": "string",
  • "enable_logistics_permission_to_all_users": "string",
  • "plat_arch_pod__oso_cloud": "string",
  • "acct_man_pod__enrollment_nue_integration": "string",
  • "enterprise_pod__mult_payment_methods": "string",
  • "enterprise_pod__order_fees": "string",
  • "force_segment_reporting": "string",
  • "ret_pod__order_minimum": "string",
  • "inbound_shipments_create": "string",
  • "traceability_pod__integration_settings": "string",
  • "npr_pod__integrations_seller": "string",
  • "orders_internal_approvals": "string",
  • "inventory_pod__inventory_batch_support": "string",
  • "inventory_pod__inventory_warehouse_support": "string",
  • "ogk_pod__knock_notifications": "string",
  • "knock_notifications_toaster": "string",
  • "inventory_pod__listings_allocations": "string",
  • "live_inventory_indicator": "string",
  • "manage_license__add_integration__buyer": "string",
  • "messaging_notifications": "string",
  • "fire_pod__order_adjustments_event_consumer": "string",
  • "order_latency": "string",
  • "int_pod__order_pdf_report": "string",
  • "order_summary_ancillary_enhancements": "string",
  • "gro_pod__order_summary_invitations": "string",
  • "order_summary_receipt_log": "string",
  • "orders_received_dataview": "string",
  • "ads_product_recommendation_organic_recommendations": "string",
  • "pause_inactive_license_companies": "string",
  • "payment_on_sell_through__enrollment": "string",
  • "cop_pod__payments_exploration_dashboard_widget": "string",
  • "collab_pod__payments_in_crm": "string",
  • "shop_brands_performance_improvement": "string",
  • "acct_man_pod__plans_and_billing": "string",
  • "ads_platform_promotion_automation": "string",
  • "post_allow_remove_post_flag_from_order": "string",
  • "post_automated_payments__calculation": "string",
  • "fire_pod__enable_post_weekly_sum_view": "string",
  • "post_order_preagreement_settings": "string",
  • "fire_pod__post_package_services": "string",
  • "post__sign_terms_and_conditions_for_all_staff_users": "string",
  • "post_sts_unit_conversion": "string",
  • "gro_pod__printed_menu": "string",
  • "inventory_pod__new_product_list_page": "string",
  • "collab_pod__promo_code_display": "string",
  • "replenishment_catalog_page": "string",
  • "retail_category_management_self_service": "string",
  • "retail__leaflink_plus_enrollment": "string",
  • "retail_product_leaderboard_negotiate": "string",
  • "seed_to_sale_coa_download": "string",
  • "traceability_pod__experiment__reconcile_inventory": "string",
  • "seed_to_sale__transfer_template": "string",
  • "trace_pod__s2s_transfers": "string",
  • "traceability__biotrack_seller_transfers_page": "string",
  • "eapps_sage_enabled": "string",
  • "collab_pod__sales_rep_email_actions": "string",
  • "trace_pod__search_by_assigned_packages": "string",
  • "seed_to_sale__buyer_nav": "string",
  • "traceability__biotrack_seller_attach_manifest": "string",
  • "llm_sigma_gpo_report": "string",
  • "manage_licenses__new_metrc_flow": "string",
  • "acct_pod__seller_order_summary": "string",
  • "seller_settings_vue": "string",
  • "ads_serve_algolia_recommendations": "string",
  • "settings__buyer_account_details": "string",
  • "settings__tax_schedules": "string",
  • "shipping_request_delivery_modal": "string",
  • "show_sell_through_for_non_post": "string",
  • "sips_pod__mp_license_service_api": "string",
  • "ssr_iframe": "string",
  • "logistics_pod__submit_order_via_csv_upload": "string",
  • "supply_chain_delivered_status": "string",
  • "switch_customer_for_cloned_orders": "string",
  • "cop_pod__terms_and_conditions": "string",
  • "transport_pod__shipping_set_order_payments": "string",
  • "transport_pod__ma_next_day_delivery": "string",
  • "plat_arch_pod__unified_hijacking": "string",
  • "ads_kevel_buyer_seller_dash": "string",
  • "ads_moloco_shop_brands_sidebar_banners": "string",
  • "ads_moloco_shop_brands_featured_brands": "string",
  • "com_pod__vendor_menu": "string",
  • "gro_pod__vendor_menu_ui_enhancement": "string",
  • "vue_buyer_notification_settings": "string",
  • "vue_inventory_bulk_price_update": "string",
  • "vue_inventory_product_add_edit_page": "string",
  • "vue_inventory_product_line_page": "string",
  • "vue_messages_page": "string",
  • "llm_vue_seller_reports": "string",
  • "vue_settings_brands_page": "string",
  • "cret_pod__vueified_company_profile": "string"
}

States

List States

List states.

Authorizations:
tokenAuth
path Parameters
logistics_enabled
required
boolean

If set to 'true' endpoint will return only States that have at least one seller with enabled logistics.

query Parameters
limit
integer

Number of results to return per page.

logistics_enabled
boolean
offset
integer

The initial index from which to return the results.

ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

states

states_retrieve

State view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this state.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "abbr": "st",
  • "name": "string",
  • "country": {
    }
}

Strain

List Strain Clasifications

List multiple Strain Classifications.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
[
  • {
    }
]

List Strains

List multiple Strains.

Authorizations:
tokenAuth
query Parameters
company
Array of integers

Multiple values may be separated by commas.

company__isnull
boolean
company_slug
string
id
Array of integers

Multiple values may be separated by commas.

name
string
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

strain_classification
Array of strings

Multiple values may be separated by commas.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get Strain

Get a single Strain.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this strain.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "name": "string",
  • "company": 0,
  • "strain_classification": "sativa"
}

taxes

taxes_tax_schedules_list

Get tax schedules for company.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

taxes_tax_schedules_create

Create a new TaxSchedule.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
name
required
string non-empty
tax_type
required
integer
tax_rate
required
string <decimal> ^-?\d{0,5}(?:\.\d{0,5})?$
unit_type
required
integer
product_category_ids
required
Array of integers

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "tax_type": 0,
  • "tax_rate": "string",
  • "unit_type": 0,
  • "product_category_ids": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0
}

taxes_tax_schedules_retrieve

Get tax schedule by ID for company.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this tax schedule.

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "name": "string",
  • "tax_type": "string",
  • "tax_rate": "string",
  • "unit_type": "string",
  • "product_categories": [
    ]
}

taxes_tax_schedules_partial_update

Update a TaxSchedule by marking it as archived and creating a new one.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this tax schedule.

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
name
string or null non-empty
tax_type
integer or null
tax_rate
string or null <decimal> ^-?\d{0,5}(?:\.\d{0,5})?$
unit_type
integer or null
product_category_ids
Array of integers or null

Responses

Request samples

Content type
application/json
{
  • "name": "string",
  • "tax_type": 0,
  • "tax_rate": "string",
  • "unit_type": 0,
  • "product_category_ids": [
    ]
}

Response samples

Content type
application/json
{
  • "id": 0
}

taxes_tax_schedules_destroy

Delete a TaxSchedule... well, mark it as archived.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this tax schedule.

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

traceability

traceability_actions_refresh_products_packages_partial_update

Reconcile inventory for products, utilizes marketplace celery tasks + traceability service data.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
product_ids
Array of integers

Responses

Request samples

Content type
application/json
{
  • "product_ids": [
    ]
}

traceability_actions_refresh_resources_retrieve

Perform refresh for specified resource types and optional datetime.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

end_date
string <date>

Resource refresh end date

start_date
string <date>

Resource refresh start date

types
required
string

Comma-separated list of resource types to refresh

header Parameters
LeafLink-Version
string <date>

Responses

traceability_companies_create

Create a new company in the traceability service.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
enable_seed_to_sale
required
boolean
enable_transfer_manifest
required
boolean
enable_sales_data
required
boolean
enable_hide_attached_packages
required
boolean
enable_license_verification
boolean or null
required
Array of objects (CompanyApiKeyRequest)
included_locations
Array of strings[ items non-empty ]
included_location_ids
Array of integers
excluded_lab_test_states
required
Array of strings[ items non-empty ]

Responses

Request samples

Content type
application/json
{
  • "enable_seed_to_sale": true,
  • "enable_transfer_manifest": true,
  • "enable_sales_data": true,
  • "enable_hide_attached_packages": true,
  • "enable_license_verification": true,
  • "api_configs": [
    ],
  • "included_locations": [
    ],
  • "included_location_ids": [
    ],
  • "excluded_lab_test_states": [
    ]
}

Response samples

Content type
application/json
{
  • "company_id": 0
}

traceability_companies_retrieve

Get company by ID.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of requested company

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "enable_seed_to_sale": true,
  • "enable_lab_test_result_sync": true,
  • "enable_transfer_manifest": true,
  • "enable_sales_data": true,
  • "enable_hide_attached_packages": true,
  • "enable_license_verification": true,
  • "integration_type": "string",
  • "excluded_lab_test_states": [
    ],
  • "included_locations": [
    ],
  • "integration_ids": [
    ],
  • "api_configs": [
    ]
}

traceability_companies_partial_update

Update a company in the traceability service.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of requested company

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
enable_seed_to_sale
boolean
enable_transfer_manifest
boolean
enable_sales_data
boolean
enable_hide_attached_packages
boolean
enable_license_verification
boolean or null
Array of objects (CompanyApiKeyRequest)
included_locations
Array of strings[ items non-empty ]
included_location_ids
Array of integers
excluded_lab_test_states
Array of strings[ items non-empty ]

Responses

Request samples

Content type
application/json
{
  • "enable_seed_to_sale": true,
  • "enable_transfer_manifest": true,
  • "enable_sales_data": true,
  • "enable_hide_attached_packages": true,
  • "enable_license_verification": true,
  • "api_configs": [
    ],
  • "included_locations": [
    ],
  • "included_location_ids": [
    ],
  • "excluded_lab_test_states": [
    ]
}

Response samples

Content type
application/json
{
  • "company_id": 0
}

traceability_company_customers_list

Get company customers.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

traceability_company_customers_retrieve

Get company customer by ID.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company customer.

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "display_name": "string",
  • "license_number": "string",
  • "partner_id": 0
}

traceability_company_licenses_create

Get company licenses

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
api_key
required
string non-empty

Responses

Request samples

Content type
application/json
{
  • "api_key": "string"
}

Response samples

Content type
application/json
{
  • "errors": [
    ],
  • "licenses": [
    ]
}

traceability_company_setting_destroy

Delete a company's integration.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of integration to modify

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "property1": null,
  • "property2": null
}

traceability_drivers_list

Get all drivers for company

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term to filter the list by

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

traceability_items_list

Get all items from the traceability service for a company.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

include_strain_data
boolean

Boolean to indicate whether strain data should be included

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term to filter the list by

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

traceability_onboarding_status_retrieve

Get onboarding status.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of requested company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "status": "string",
  • "vendor_type": "string",
  • "external_id": "string"
}

traceability_orders_by_package_labels_list

Unified API Orders by Package Labels.

Authorizations:
bearerAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

traceability_orders_by_package_labels_retrieve

Unified API Orders by Package Labels.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this attached package.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "short_id": "string",
  • "order_number": "string",
  • "is_post": true
}

traceability_packages_list

Get company packages

Authorizations:
bearerAuth
query Parameters
assigned
boolean

Filter by Traceability.common_packages that are assigned/unassigned products

cbd_max
number <double>

Filter by Traceability.common_packages with a CBD value less than or equal to the given value

cbd_min
number <double>

Filter by Traceability.common_packages with a CBD value greater than or equal to the given value

company_id
required
integer

The ID of the viewing company

hide_attached_packages
boolean

Filter out any Traceability.common_package that has already been assigned to an order line-item

include_source_packages
boolean

Indicate whether to include a list of source_package_labels in the response

item
string

Filter by Traceability.metrc_package.item_id (accepts comma-separated list)

lab_testing_status
string

Filter by Traceability.common_package.metrc_package.lab_testing_status (accepts comma-separated list)

label
string

Filter by Traceability.common_package.label (accepts comma-separated list)

license_number
string

Filter by Traceability.common_package.license_number (accepts comma-separated list)

limit
integer

Limit for results, hard-cap of 25 enforced, default 25

location
string

Filter by Traceability.common_package.location_id (accepts comma-separated list)

manifest_number
string

Filter Traceability.common_package by packages associated with manifest

offset
integer

Used for pagination

ordering
string

Which field to use when ordering the results.

packaged_date
string

Filter by Traceability.metrc_package.packaged_date (accepts comma-separated list)

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

product_ids
string

Filter Traceability.common_package by product_ids assigned to packages (accepts comma-separated list)

search
string

Search term to filter the list by

source_package
string

Filter Traceability.common_package by packages that are children of the given label

status
string

Filter by Traceability.common_package.status field

template_id
string

Filter Traceability.common_package by packages assigned to template

thc_max
number <double>

Filter by Traceability.common_packages with a THC value less than or equal to the given value

thc_min
number <double>

Filter by Traceability.common_packages with a THC value greater than or equal to the given value

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

traceability_refresh_requests_list

Get all refresh_requests from the traceability service for a company.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

refresh_date
string <date>

Filter results by refresh_request.created_at

search
string

A search term.

status
string

Filter results by comma-separated list of refresh statuses

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

traceability_templates_list

Get templates from the traceability service for company.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

limit
integer

Limit for results, hard-cap of 25 enforced, default 25

ll_order_id
integer

Filter results by associated LL order ID

offset
integer

Used for pagination

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term to filter the list by

ship_date
string <date-time>

Filter results by ship date

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

traceability_templates_create

Create a new Template in the traceability service.

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
required
estimated_departure_datetime
string or null non-empty
estimated_arrival_datetime
string or null non-empty
shipment_type_name
string or null non-empty
ll_order_id
integer or null
package_labels
Array of strings or null
object or null
driver_id
integer or null
vehicle_id
integer or null
turn_by_turn_directions
string or null non-empty
license_number
string or null non-empty
destination_company_id
required
integer or null
destination_license_number
string or null non-empty

Responses

Request samples

Content type
application/json
{
  • "estimated_departure_datetime": "string",
  • "estimated_arrival_datetime": "string",
  • "shipment_type_name": "string",
  • "ll_order_id": 0,
  • "package_labels": [
    ],
  • "packages": {
    },
  • "driver_id": 0,
  • "vehicle_id": 0,
  • "turn_by_turn_directions": "string",
  • "license_number": "string",
  • "destination_company_id": 0,
  • "destination_license_number": "string"
}

Response samples

Content type
application/json
{
  • "template_id": 0
}

traceability_templates_retrieve

Get template by ID for company.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of requested template

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "actual_arrival_datetime": "string",
  • "actual_departure_datetime": "string",
  • "company_id": 0,
  • "delivery_count": 0,
  • "estimated_arrival_datetime": "string",
  • "estimated_departure_datetime": "string",
  • "id": 0,
  • "last_modified_datetime": "string",
  • "license_number": "string",
  • "manifest_number": "string",
  • "metrc_delivery_id": 0,
  • "metrc_id": 0,
  • "name": "string",
  • "package_count": 0,
  • "received_datetime": "string",
  • "recipient_facility_license_number": "string",
  • "recipient_facility_name": "string",
  • "shipment_license_type": "string",
  • "shipment_transaction_type": "string",
  • "shipment_type_name": "string",
  • "shipper_facility_license_number": "string",
  • "shipper_facility_name": "string",
  • "driver": {
    },
  • "vehicle": {
    },
  • "turn_by_turn_directions": "string"
}

traceability_templates_partial_update

Update a template in the traceability service.

Authorizations:
bearerAuth
path Parameters
id
required
integer

ID of requested template

query Parameters
company_id
required
integer

The ID of the viewing company

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
estimated_departure_datetime
string or null non-empty
estimated_arrival_datetime
string or null non-empty
shipment_type_name
string or null non-empty
ll_order_id
integer or null
package_labels
Array of strings or null
object or null
driver_id
integer or null
vehicle_id
integer or null
turn_by_turn_directions
string or null non-empty

Responses

Request samples

Content type
application/json
{
  • "estimated_departure_datetime": "string",
  • "estimated_arrival_datetime": "string",
  • "shipment_type_name": "string",
  • "ll_order_id": 0,
  • "package_labels": [
    ],
  • "packages": {
    },
  • "driver_id": 0,
  • "vehicle_id": 0,
  • "turn_by_turn_directions": "string"
}

Response samples

Content type
application/json
{
  • "template_id": 0
}

traceability_transfer_companies_list

Get origin/destination companies of a transfer + their associated license

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

from_shipper
string

Filter by Traceability.transfer.shipper_facility_name|shipper_facility_license_number fields contain value

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

to_recipient
string

Filter by Traceability.transfer.recipient_facility_name|recipient_facility_license_number fields contain value

transfer_type
string

Filter by Traceability.transfer.type field

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

traceability_transfers_list

Get traceability transfer data. Note: resource_type fields will not be present in the payloads. They are just needed to help define polymorphic fields.

Authorizations:
bearerAuth
query Parameters
arrival_date
string <date>

Filter by Traceability.transfer.arrival_date field

company_id
required
integer

The ID of the viewing company

company_ids
string

Filter by Traceability.transfer.company.external_id (marketplace.company.id) field

exclude_received
boolean

Filter by Traceability.transfer.received_datetime field not None

external_ids
string

Filter by Traceability..external_id field

from_shipper
string

Filter by Traceability.transfer.shipper_facility_name|shipper_facility_license_number fields contain value

has_attached_orders
boolean

Filter by transfers that are associated with orders in LL

ids
string

Traceability..id field

include_package_data
boolean

Include delivery packages in response

limit
integer

Limit for results, hard-cap of 25 enforced, default 25

metrc_ids
string

Filter by Traceability..metrc_id field

offset
integer

Used for pagination

order_ids
string

Filter transfers by Traceability.order_transfer.order_id list field

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term to filter the list by

ship_date
string <date-time>

Filter results by ship date

sort_by
string

Sort results by given field

to_recipient
string

Filter by Traceability.transfer.recipient_facility_name|recipient_facility_license_number fields contain value

traceability_transfer_external_ids
string

Filter by Traceability.transfer.metrc_id field

transfer_status
string

Filter by Traceability.transfer.status field

transfer_type
string

Filter by Traceability.transfer.type field

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "count": 123,
  • "results": [
    ]
}

traceability_vehicles_list

Get all vehicles

Authorizations:
bearerAuth
query Parameters
company_id
required
integer

The ID of the viewing company

ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

Search term to filter the list by

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

transportation

transportation_companies_retrieve

Transport Company view set.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this transport company.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "transport_company_id": 0,
  • "name": "string",
  • "medical_license_number": "string",
  • "adult_use_license_number": "string",
  • "state": "string"
}

transportation_drivers_retrieve

Transport partner drivers view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this driver.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "metrc_employee_id": "string",
  • "license_number": "string",
  • "phone": "string",
  • "is_active": true,
  • "transport_company": {
    }
}

transportation_drivers_partial_update

Transport partner drivers view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this driver.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
first_name
string (First Name of Driver) [ 1 .. 100 ] characters

First Name

last_name
string [ 1 .. 100 ] characters

Last Name of Driver

metrc_employee_id
string [ 1 .. 100 ] characters

METRC Employee ID for Driver

license_number
string [ 1 .. 15 ] characters

License Number of Driver

phone
string [ 1 .. 15 ] characters

Phone Number of Driver

is_active
boolean (Active)

Is an active driver?

Responses

Request samples

Content type
application/json
{
  • "first_name": "string",
  • "last_name": "string",
  • "metrc_employee_id": "string",
  • "license_number": "string",
  • "phone": "string",
  • "is_active": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "first_name": "string",
  • "last_name": "string",
  • "metrc_employee_id": "string",
  • "license_number": "string",
  • "phone": "string",
  • "is_active": true,
  • "transport_company": {
    }
}

transportation_orders_create

Unified API product categories.

Authorizations:
tokenAuth
Request Body schema: application/json
required
payment_expected
required
string
status
string (Status of L3Order)
Enum: "uploaded" "created" "assigned" "planned" "shipped" "delivered" "deleted"
requested_pickup_date
string or null <date> (Requested pick up date)

Requested pick up date

expected_pickup_datetime
string or null <date-time> (Expected pick up datetime)

Expected pick up date and time

actual_pickup_datetime
string or null <date-time> (Actual pick up datetime)

Actual date time the order was picked up

requested_delivery_date
string or null <date>

Requested delivery date for the order

expected_delivery_datetime
string or null <date-time>

Expected delivery date and time for the order

actual_delivery_datetime
string or null <date-time>

Actual delivery date and time for the order

required
object (DriverRequest)

serializer for Driver Model.

required
object (InternalVehicleRequest)

Internal serializer for Vehicle Model.

required
object (DriverRequest)

serializer for Driver Model.

required
object (InternalVehicleRequest)

Internal serializer for Vehicle Model.

required
object (PaymentMethodRequest)

Serialize payment method.

required
object (PaymentTermRequest)

Serialize payment term.

customer_notes
string or null

Customer notes for the L3 Order

notes
string or null (Additional Notes)

Additional notes for the L3 Order

eligible_payment_methods
Array of strings (Eligible payment methods for this order) [ items [ 1 .. 100 ] characters ]

A selection of eligible payment methods for this order

payment_method_collected
string (Collected Payment Method) <= 100 characters

Payment method used for this order

collected_payment_amount
string or null <decimal> ^-?\d{0,8}(?:\.\d{0,2})?$

Payment collected at delivery

delivery_driver_comment
string <= 500 characters

Comment from delivery driver for this order

required
object (InternalLogisticsCompanyRequest)

Internal serializer for the Company model to be used by L3 endpoints.

Responses

Request samples

Content type
application/json
{
  • "payment_expected": "string",
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "brand": {
    }
}

Response samples

Content type
application/json
{
  • "number": "string",
  • "invoice_number": "string",
  • "mp_order_number": "string",
  • "transport_order_id": "string",
  • "payment_expected": "string",
  • "customer": {
    },
  • "pickup_address": {
    },
  • "destination": {
    },
  • "status": "uploaded",
  • "requested_pickup_date": "2019-08-24",
  • "expected_pickup_datetime": "2019-08-24T14:15:22Z",
  • "actual_pickup_datetime": "2019-08-24T14:15:22Z",
  • "requested_delivery_date": "2019-08-24",
  • "expected_delivery_datetime": "2019-08-24T14:15:22Z",
  • "actual_delivery_datetime": "2019-08-24T14:15:22Z",
  • "display_delivery_date": "2019-08-24T14:15:22Z",
  • "pickup_driver": {
    },
  • "additional_pickup_drivers": [
    ],
  • "pickup_vehicle": {
    },
  • "delivery_driver": {
    },
  • "delivery_vehicle": {
    },
  • "payment_method": {
    },
  • "payment_term": {
    },
  • "customer_notes": "string",
  • "notes": "string",
  • "eligible_payment_methods": [
    ],
  • "payment_method_collected": "string",
  • "collected_payment_amount": "string",
  • "delivery_driver_comment": "string",
  • "metrc_transfer": {
    },
  • "created_on": "2019-08-24T14:15:22Z",
  • "transport_company": {
    },
  • "brand": {
    }
}

transportation_partners_retrieve

Company transport partner view set.

Authorizations:
bearerAuth
path Parameters
id
required
integer

A unique integer value identifying this company transport partner.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "company": {
    },
  • "transport_company": {
    }
}

transportation_vehicles_retrieve

Transport partner vehicle view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this vehicle.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "make": "string",
  • "model_year": -2147483648,
  • "model_name": "string",
  • "license_number": "string",
  • "capacity": -2147483648,
  • "has_air_conditioner": true,
  • "state": {
    }
}

transportation_vehicles_partial_update

Transport partner vehicle view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this vehicle.

header Parameters
LeafLink-Version
string <date>
Request Body schema: application/json
make
string or null (Vehicle Make) <= 255 characters

Vehicle Make

model_year
integer or null [ -2147483648 .. 2147483647 ]

Vehicle Model Year

model_name
string or null <= 255 characters

Vehicle Model Name

license_number
string or null <= 15 characters

License Number of Vehicle

capacity
integer or null [ -2147483648 .. 2147483647 ]

Vehicle Capacity

has_air_conditioner
boolean

Vehicle Has Air Conditioner

Responses

Request samples

Content type
application/json
{
  • "make": "string",
  • "model_year": -2147483648,
  • "model_name": "string",
  • "license_number": "string",
  • "capacity": -2147483648,
  • "has_air_conditioner": true
}

Response samples

Content type
application/json
{
  • "id": 0,
  • "make": "string",
  • "model_year": -2147483648,
  • "model_name": "string",
  • "license_number": "string",
  • "capacity": -2147483648,
  • "has_air_conditioner": true,
  • "state": {
    }
}

transportation_vehicles_destroy

Transport partner vehicle view set.

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this vehicle.

header Parameters
LeafLink-Version
string <date>

Responses

Unit Denomination

List Unit Denominations

List all Unit Denominations

Authorizations:
tokenAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get a Unit Denomination

Get a Unit Denomination by ID

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this unit denomination.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "value": "string",
  • "name": "string",
  • "label": "string",
  • "description": "string"
}

Unit of Measure

List Unit of Measures

List all Unit of Measures

Authorizations:
tokenAuth
query Parameters
ordering
string

Which field to use when ordering the results.

page
integer

A page number within the paginated result set.

page_size
integer

Number of results to return per page.

search
string

A search term.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{}

Get a Unit of Measure

Get a Unit of Measure by ID

Authorizations:
tokenAuth
path Parameters
id
required
integer

A unique integer value identifying this unit of measure.

header Parameters
LeafLink-Version
string <date>

Responses

Response samples

Content type
application/json
{
  • "id": 0,
  • "created_date": "2019-08-24T14:15:22Z",
  • "modified_date": "2019-08-24T14:15:22Z",
  • "unit": "string",
  • "plural": "string",
  • "abbreviation": "string",
  • "multiple": true,
  • "ALLOW_FRACTIONAL": true,
  • "universal_name": "string",
  • "unconvertible": true,
  • "base_only": true
}

vendors