API Documentation

Note 1: Please note that the Parent_UPC and Group_UPC fields have been phased out for product groupings and variants. Going forward, you must use the Variant_Group_ID field for matching product groupings and variants.

Note 2: Effective immediately new API call requirements: All SKUs have recently been discontinued. Going forward the TDID field will be the new product identifier used.

Reseller

Reseller API allows you to Retrieve Reseller data.


Subscription

Throttle: 600 calls every 60 seconds ( Leaky Bucket )

Query subscription type and status

Request Parameters


Response Parameters


subscription_list
Data Type : present|array

Array of Products

subscription
Data Type : required|string
Subscription name
active
Data Type : required|integer
Subscription status 1-active, 0-inactive
integration_id
Data Type : required|integer
Integration ID
platform
Data Type : required|string
Platform like shopify,ebay
store
Data Type : required|string
The store name
POST /api/TDApi/Reseller/subscription
curl --location --request POST 'https://topdawg.com/api/TDApi/Reseller/subscription' \
--header 'Authorization: Bearer INSERT_TOKEN_INSTEAD_IF_THIS_TAG \
--header 'Content-Type: application/json' \
--data-raw '[]'
Request Body (Raw Data)
[]
Response
{
    "subscription_list": [
        {
            "subscription": "Scale",
            "active": "1",
            "integration_id": 3334,
            "platform": "shopify",
            "store": "create-development-store.myshopify.com"
        }
    ]
}

Reseller Orders

Reseller Orders API allows you to List, Retrieve and Create Orders, Update order Contents, Process and Cancel orders, Manage and Track order fulfilment.


Reseller Order View

Throttle: 600 calls every 60 seconds ( Leaky Bucket )

View reseller order by Order ID

Request Parameters


order_id (Required)
Validation Rule : required|numeric

View order by ID.


Response Parameters


order_id
Data Type : numeric

Order ID.


created_at
Data Type : date

Order creation date


delivered_at
Data Type : date

Order delivery date (null before delivery)


gross
Data Type : numeric|min:1

Gross cost of products


shipping
Data Type : numeric|min:1

Shipping cost of products


total
Data Type : numeric|min:1

Total cost of products


status
Data Type : integer

General status { 1 : Saved Order, 2 : Pending Order, 3 : Pending Action, 4 : In Transit, 5 : Delivered, 6 : Returned, 7 : Failed , 8 : Canceled, 9 : Declined }


metadata
Data Type : string|max:256

A string of up to 256 characters that can be filled with any additional information you want to attach to the order. Recommended to use JSON format. JSON formatted field names: `id`, `order`, `source` : One both or all three fields will be depicted on orders UI for ease of cross identification.


checkout_messages
Data Type : string|max:256

JSON formatted checkout messages.


customer
Data Type : present|array

Array of Customer Properties

customer_id
Data Type : numeric
Customer ID
first_name
Data Type : string
First Name
last_name
Data Type : string
Last Name
phone
Data Type : string
Customer phone with international prefix

address_to
Data Type : present|array

Array of Address Properties

address_id
Data Type : numeric
Address ID
address_1
Data Type : string
Address 1
address_2
Data Type : nullable|string
Address 2
city
Data Type : string
City
state_code
Data Type : string
State Code
country_code
Data Type : string|max:2
Country Code
zip_code
Data Type : string
ZIP Code

transactions
Data Type : present|array

Array of Transactions - In case this field is not populated, order will have no transactions (results in empty order). Empty orders are used in case of full api integration for interactive order population and processing.

transaction_id
Data Type : integer
ID of transaction
tdid
Data Type : required|string
TopDawg Product ID, Preferred ID field
product_code
Data Type : string
TopDawg Product Code
price
Data Type : numeric
Price per Product
quantity
Data Type : numeric
Purchased product quantity
gross
Data Type : numeric|min:1
Gross cost of products
packing_fee
Data Type : numeric|min:1
Packing fee of the product charged by supplier
shipping
Data Type : numeric|min:1
Shipping cost of products
total
Data Type : numeric|min:1
Total cost of products
status
Data Type : integer
General status { 1 : Saved Order, 2 : Pending Order, 3 : Pending Action, 4 : In Transit, 5 : Delivered, 6 : Returned, 7 : Failed , 7 : Canceled, 8 : Declined }

parcels
Data Type : present|array

Array of Parcels

parcel
Data Type : present|array
Array of Parcel Data
id
Data Type : integer
ID of the Parcel
status
Data Type : string
Parcel transportation status { PRE_TRANSIT, TRANSIT, DELIVERED, RETURNED, FAILED }
carrier
Data Type : string
Carrier Name
tracking_number
Data Type : string
Tracking number for carrier
content
Data Type : present|array
Array of Parcels
tdid
Data Type : required|string
TopDawg Product ID, Preferred ID field
product_code
Data Type : string
TopDawg Product Code
quantity
Data Type : required|numeric
Quantity of the product
status
Data Type : integer
General status { 1 : Saved Order, 2 : Pending Order, 3 : Pending Action, 4 : In Transit, 5 : Delivered, 6 : Returned, 7 : Failed , 7 : Canceled, 8 : Declined }
POST /api/TDApi/ResellerOrder/view
curl --location --request POST 'https://topdawg.com/api/TDApi/ResellerOrder/view' \
--header 'Authorization: Bearer INSERT_TOKEN_INSTEAD_IF_THIS_TAG \
--header 'Content-Type: application/json' \
--data-raw '{
    "order_id": "18453"
}'
Request Body (Raw Data)
{
    "order_id": "18453"
}
Response
{
    "order_id": "18453",
    "created_at": "2021-06-10",
    "delivered_at": "2021-06-10",
    "gross": "15.05",
    "shipping": "3.02",
    "total": "18.07",
    "status": "1",
    "metadata": "{\"id\":4456, \"order\":13334562,\"source\":\"shopify\"}",
    "checkout_messages": "[{\"success\": true, \"msg\": \"Order was processed successfully.\", \"receipt_url\": \"https:\\\/\\\/pay.stripe.com\\\/receipts\\\/acct_1AAnM0BCuWWwhDtF\\\/ch_3KsNA2BCuWWwhDtF0VTa4LWQ\\\/rcpt_LZWClnxfFiTQPXrqqz3VW3iVW2wJKv6\", \"pm_data\": \"\", \"created_at\": \"2022-04-25 04:20:48\"}]",
    "customer": {
        "customer_id": "2884",
        "first_name": "Leroy",
        "last_name": "Jenkins",
        "phone": "1 234 567 89 01"
    },
    "address_to": {
        "address_id": "2442",
        "address_1": "123 Main Street",
        "address_2": "APT 111",
        "city": "Edison",
        "state_code": "NJ",
        "country_code": "US",
        "zip_code": "08818"
    },
    "transactions": [
        {
            "transaction_id": "24662",
            "tdid": "S000487B001525P000444V002",
            "product_code": "Macaron-no-window-1",
            "price": "pet-supplies",
            "quantity": "pet-supplies",
            "gross": "15.05",
            "packing_fee": "1.02",
            "shipping": "3.02",
            "total": "3.02",
            "status": "1"
        }
    ],
    "parcels": [
        {
            "parcel": {
                "id": "262",
                "status": "PRE_TRANSIT",
                "carrier": "USPS",
                "tracking_number": "92612901755477000000000010"
            },
            "content": [
                {
                    "tdid": "S000487B001525P000444V002",
                    "product_code": "Macaron-no-window-1",
                    "quantity": 3,
                    "status": "1"
                }
            ]
        }
    ]
}

Create

Throttle: 600 calls every 60 seconds ( Leaky Bucket )

Create Order. And optionally flag it not to be processed automatically.

Request Parameters


auto_process (Optional)
Validation Rule : boolean

Automatically process order (Generate Shipping Costs and Pay order), Field is optional and by default is enabled (set to true even if omitted). {auto_process : false} to Place un-processed orders for further manual processing.


bypass_address_validation (Optional)
Validation Rule : boolean

Automatically validate customer address (Proof customer address to avoid returned shipments), Field is optional and by default is disabled (set to false even if omitted). {bypass_address_validation : true} to process un-validated addresses. All costs and responsibility from failed deliveries fall upon reseller


api_aggregator (Optional)
Validation Rule : string|max:25

A string of up to 25 characters that identifies order/api aggregator company.


metadata (Optional)
Validation Rule : string|max:256

A string of up to 256 characters that can be filled with any additional information you want to attach to the order. Recommended to use JSON format. JSON formatted field names: `id`, `order`, `source` : One both or all three fields will be depicted on orders UI for ease of cross identification.


integration_id (Optional)
Validation Rule : numeric

Integration ID for particular store


customer (Required)
Validation Rule : required|present|array

Array of Customer Properties

customer_id (Optional)
Validation Rule : numeric
Product ID
first_name (Required)
Validation Rule : required|string
Customer first name
last_name (Required)
Validation Rule : required|string
Customer last name
phone (Optional)
Validation Rule : nullable|string
Customer phone with international prefix, In case phone number is not provided, reseller number will be inserted in the field

address_to (Required)
Validation Rule : required|present|array

Array of Delivery Address Properties

address_id (Optional)
Validation Rule : numeric
Address ID
address_1 (Required)
Validation Rule : required|string
Address 1
address_2 (Optional)
Validation Rule : nullable|string
Address 2
city (Required)
Validation Rule : required|string
City
state_code (Required)
Validation Rule : required|string
State Code
country_code (Required)
Validation Rule : required|string|max:2
Country Code
zip_code (Required)
Validation Rule : required|string
ZIP Code

transactions (Optional)
Validation Rule : present|array

Array of Transactions

tdid (Required)
Validation Rule : required_without_all:transactions.*.sku|string|existInAny:products,tdid,products,vendor_sku
TopDawg Product ID, Preferred ID field
sku (Required)
Validation Rule : required_without_all:transactions.*.tdid|string|existInAny:products,tdid,products,vendor_sku
TopDawg Product ID, Preferred ID field
quantity (Required)
Validation Rule : required|numeric|min:0
Quantity of the product

Response Parameters


order_id
Data Type : required|integer

Order ID


status
Data Type : required|integer

Processing status of the Order, Status 1 is default status on order creation.

POST /api/TDApi/ResellerOrder/create
curl --location --request POST 'https://topdawg.com/api/TDApi/ResellerOrder/create' \
--header 'Authorization: Bearer INSERT_TOKEN_INSTEAD_IF_THIS_TAG \
--header 'Content-Type: application/json' \
--data-raw '{
    "api_aggregator": "inventory_source",
    "metadata": "{\"id\":4456, \"order\":13334562,\"source\":\"shopify\"}",
    "integration_id": 3334,
    "customer": {
        "customer_id": "2884",
        "first_name": "Leroy",
        "last_name": "Jenkins",
        "phone": "1 234 567 89 01"
    },
    "address_to": {
        "address_id": "2442",
        "address_1": "123 Main Street",
        "address_2": "APT 111",
        "city": "Edison",
        "state_code": "NJ",
        "country_code": "US",
        "zip_code": "08818"
    },
    "transactions": [
        {
            "tdid": "S000487B001525P000444V002",
            "sku": "S000487B001525P000444V002",
            "quantity": 3
        }
    ]
}'
Request Body (Raw Data)
{
    "api_aggregator": "inventory_source",
    "metadata": "{\"id\":4456, \"order\":13334562,\"source\":\"shopify\"}",
    "integration_id": 3334,
    "customer": {
        "customer_id": "2884",
        "first_name": "Leroy",
        "last_name": "Jenkins",
        "phone": "1 234 567 89 01"
    },
    "address_to": {
        "address_id": "2442",
        "address_1": "123 Main Street",
        "address_2": "APT 111",
        "city": "Edison",
        "state_code": "NJ",
        "country_code": "US",
        "zip_code": "08818"
    },
    "transactions": [
        {
            "tdid": "S000487B001525P000444V002",
            "sku": "S000487B001525P000444V002",
            "quantity": 3
        }
    ]
}
Response
{
    "order_id": "15533",
    "status": "1"
}

Reseller Products

Reseller Products API allows you to List, Retrieve and Create Products, Update inventory Levels and Manage overall accessibility of your product on TopDawg portal.


List Products

Throttle: 10 calls every 10 seconds ( Leaky Bucket )

Retrieve list of the products. Optionally can be filtered by Brands, Sections, Categories and Departments.

Request Parameters


page (Optional)
Validation Rule : numeric

Paged retrieval of the data is enabled by providing index of the page to be retrieved.


per_page (Required)
Validation Rule : required|numeric|max:1000

Products to be displayed per each paged response.


integration_id (Optional)
Validation Rule : numeric

Integration ID for particular store


tdid_array (Optional)
Validation Rule : array|max:100

Array of the Product TDID-s


departments (Optional)
Validation Rule : array

Array of the Departments to list products from


sections (Optional)
Validation Rule : array

Array of the Sections to list products from


categories (Optional)
Validation Rule : array

Array of the Categories to list products from


brands (Optional)
Validation Rule : array

Array of the Brands to list products from


countries (Optional)
Validation Rule : array

Array of the Country Codes to list products from


no_channel_restrictions (Optional)
Validation Rule : array

Array of Channels - if provided, products without given channel restrictions will be listed


variant_group_id (Optional)
Validation Rule : array

Array of Variant Group ID - if provided, products without given Variant Group ID restrictions will be listed


min_pack_of (Optional)
Validation Rule : numeric

Minimal count of products per pack. For Bulk Packaging Filtering


min_quantity (Optional)
Validation Rule : numeric

Minimal count of products in stock. For secure stock management


international_shipping (Optional)
Validation Rule : in:yes,no,Yes,No

Filter products by international shipping availability.


product_updated_at (Optional)
Validation Rule : string

Filter products by updated date


Response Parameters


products
Data Type : present|array

Array of Products

tdid
Data Type : string
TopDawg Product ID, Preferred ID field
product_name
Data Type : string
Product title.
upc
Data Type : string
Product UPC.
description
Data Type : string
Product description.
product_country
Data Type : string|min:2|max:2
Product country code.
ship_country
Data Type : string|min:2|max:2
Product country code.
ship_state
Data Type : string|min:2|max:2
Product state code.
shipping_estimate
Data Type : string|max:256
JSON formatted shipping cost estimate. NULL if no shipping estimate is available.
color
Data Type : string
Product color.
ingredients
Data Type : string
Product ingredients.
size
Data Type : string
Product size.
width
Data Type : numeric
Product width.
length
Data Type : numeric
Product length.
height
Data Type : numeric
Product height.
product_weight
Data Type : numeric
Product weight.
ship_length
Data Type : numeric
Product shipping length.
ship_height
Data Type : numeric
Product shipping height.
ship_width
Data Type : numeric
Product shipping width.
msrp
Data Type : numeric
Product Manufacturer Suggested Retail Price.
price_map
Data Type : numeric
Minimum advertised pricing (MAP) is the lowest price a retailer can advertise the product for sale.
pack_of
Data Type : numeric
Product pack/case count.
qty_initial
Data Type : numeric
Initial quantity of the product.
qty_available
Data Type : numeric
Available quantity of the product.
cost
Data Type : numeric
Product cost.
channel_restriction
Data Type : required
Product channel restriction.
product_code
Data Type : nullable
Product code.
packing_fee
Data Type : nullable|numeric
Product packing fee.
return
Data Type : string
Product return policy
brand_name
Data Type : string
Department to list products from
department
Data Type : string
Department to list products from
section
Data Type : string
Section to list products from
age_group
Data Type : string
Age Group
gender
Data Type : string
Gender
variant_group_id
Data Type : string
Product Variant Group ID.
category
Data Type : string
Category to list products from
image_url
Data Type : string
Comma separated list of Product image URL-s
thumbnail_url
Data Type : string
Comma separated list of Product thumbnail URL-s
product_updated_at
Data Type : string
Date of product update.

pagination
Data Type : array

Array of Pagination variables, used to navigate through product list

total
Data Type : numeric
Total products found by call
count
Data Type : numeric
Products on current page
per_page
Data Type : numeric
Product pagination request
current_page
Data Type : numeric
Currentl page
total_pages
Data Type : numeric
Total pages generated by request
POST /api/TDApi/ResellerProduct/list
curl --location --request POST 'https://topdawg.com/api/TDApi/ResellerProduct/list' \
--header 'Authorization: Bearer INSERT_TOKEN_INSTEAD_IF_THIS_TAG \
--header 'Content-Type: application/json' \
--data-raw '{
    "page": "1",
    "per_page": "100",
    "integration_id": 3334,
    "tdid_array": [
        "S000487B001525P000444V002"
    ],
    "departments": [
        "pet-supplies"
    ],
    "sections": [
        "apparel"
    ],
    "categories": [
        "hand-tools"
    ],
    "brands": [
        "ali-industries"
    ],
    "countries": [
        "US"
    ],
    "no_channel_restrictions": [
        "amazon"
    ],
    "variant_group_id": [
        "6-851-1"
    ],
    "min_pack_of": "2",
    "min_quantity": "100",
    "international_shipping": "Yes",
    "product_updated_at": "2022-11-27 05:01:01"
}'
Request Body (Raw Data)
{
    "page": "1",
    "per_page": "100",
    "integration_id": 3334,
    "tdid_array": [
        "S000487B001525P000444V002"
    ],
    "departments": [
        "pet-supplies"
    ],
    "sections": [
        "apparel"
    ],
    "categories": [
        "hand-tools"
    ],
    "brands": [
        "ali-industries"
    ],
    "countries": [
        "US"
    ],
    "no_channel_restrictions": [
        "amazon"
    ],
    "variant_group_id": [
        "6-851-1"
    ],
    "min_pack_of": "2",
    "min_quantity": "100",
    "international_shipping": "Yes",
    "product_updated_at": "2022-11-27 05:01:01"
}
Response
{
    "products": [
        {
            "tdid": "S000487B001525P000444V002",
            "product_name": "Stainless Steel Spike",
            "upc": "9369998008780",
            "description": "AQUA LEASH is no ordinary leash and has revolutionized the dog walking industry.",
            "product_country": "US",
            "ship_country": "US",
            "ship_state": "FL",
            "shipping_estimate": "{\"ne\": {\"cost\": \"9.10\", \"city\": \"Portland\"}, \"se\": {\"cost\": \"8.75\", \"city\": \"Miami\"}, \"nw\": {\"cost\": \"9.54\", \"city\": \"Seattle\"}, \"sw\": {\"cost\": \"9.54\", \"city\": \"San Diego\"}, \"average\": \"9.23\", \"max\": \"9.54\", \"min\": \"8.75\", \"date\": \"05-15-2022\"}",
            "color": "Red",
            "ingredients": "Purified water, lauryl glucoside (coconut & sugar derived), glycerin.",
            "size": "Small\/medium .78",
            "width": "0.78",
            "length": "8.26",
            "height": "5.90",
            "product_weight": "1.64",
            "ship_length": "8.26",
            "ship_height": "5.90",
            "ship_width": "1.64",
            "msrp": "34.95",
            "price_map": "34.95",
            "pack_of": "1",
            "qty_initial": "4500",
            "qty_available": "500",
            "cost": "17.96",
            "channel_restriction": "No",
            "product_code": "No",
            "packing_fee": "No",
            "return": "30, 'Yes', 'No' ",
            "brand_name": "pets",
            "department": "pets",
            "section": "Collars and Harnesses",
            "age_group": "Adults",
            "gender": "Unisex",
            "variant_group_id": "9369998008780",
            "category": "Dog Collars",
            "image_url": "https:\/\/topdawg-production-images.s3.amazonaws.com\/9369998008780.0.jpg",
            "thumbnail_url": "https:\/\/topdawg-production-images.s3.amazonaws.com\/9369998008780.0.jpg",
            "product_updated_at": "2022-11-27 05:01:01"
        }
    ],
    "pagination": {
        "total": 2729,
        "count": 10,
        "per_page": 10,
        "current_page": 3,
        "total_pages": 273
    }
}

Webhook Documentation