Products
Search and view products for your account.
Properties
- Name
id
- Type
- string
- Description
Unique identifier for the product.
- Name
external_id
- Type
- string
- Description
The external id from the integration, e.g. Shopify, WooCommerce
- Name
external_variant_id
- Type
- string
- Description
The external variant id.
- Name
name
- Type
- string
- Description
The name for the product including variant name.
- Name
sku
- Type
- string
- Description
Product stock keeping unit.
- Name
vendor
- Type
- string
- Description
Vendor for the product.
- Name
price
- Type
- int
- Description
Price for the product in cents.
- Name
cost
- Type
- int
- Description
Cost for the product in cents.
- Name
tags
- Type
- array
- Description
Array of tags for the product.
- Name
inventory_quantity
- Type
- int
- Description
Current inventory quantity.
- Name
collaborators
- Type
- array
- Description
Array of connected collaborators.
Properties
- Name
percent
- Type
- decimal(5,2)
- Description
Percent split for the collaborator.
- Name
amount
- Type
- int
- Description
Fix amount for the collaborator split.
- Name
shipping_amount
- Type
- int
- Description
Shipping amount for the collaborator split.
- Name
shipping_percent
- Type
- decimal(5,2)
- Description
Shipping percent for the collaborator split.
- Name
created_at
- Type
- int
- Description
Unix timestamp when this was created.
- Name
collaborator
- Type
- collaborator
- Description
- Collaborator object
List all products
This endpoint allows you to retrieve a paginated list of all your products. See pagination for interacting with paginated lists.
Optional attributes
- Name
search
- Type
- string
- Description
Filter for products containing the matching string in the
name
orsku
field.
- Name
collaborator
- Type
- string
- Description
Filter to products for a given collaborator
id
.
- Name
include_collaborators
- Type
- boolean
- Description
Include the collaborator relation in the results, defaults to
false
.
- Name
include_stats
- Type
- boolean
- Description
Include the stats for the collaborator in the results, defaults to
false
.
Request
curl -G https://collabpay.app/api/v1/products \
-H 'Content-Type: application/json'
-H 'Accept: application/json'
-H "Authorization: Bearer {token}" \
-d per_page=15 \
-d search=hat \
-d include_collaborators=true
Response
{
"data": [
{
"id": "aeda9be5-c9e1-40ec-8c76-be098262b7f6",
"external_id": "12",
"external_variant_id": "13",
"name": "Hats (L)",
"sku": "HATLL",
"vendor": null,
"price": 0,
"cost": 200,
"tags": null,
"inventory_quantity": 55,
"collaborators": [
{
"percent": 2,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687578602,
"collaborator": {
"id": "83863eae-3d54-458a-8671-8494cec025c2",
"currency": "USD",
"payout_measurement": "monthly_date",
"payout_frequency": -1,
"payout_threshold": 410,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": 1687672448
}
},
{
"percent": 99,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687673092,
"collaborator": {
"id": "38f81dae-d025-42c7-bc48-e98b4e577f92",
"currency": "USD",
"payout_measurement": "month",
"payout_frequency": 1,
"payout_threshold": null,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": null
}
}
]
},
{
"id": "0dd0694a-3dd0-471b-81ec-286ef7ecb30c",
"external_id": "12",
"external_variant_id": "14",
"name": "Hats (M)",
"sku": "HATM",
"vendor": null,
"price": 0,
"cost": 6001,
"tags": null,
"inventory_quantity": null,
"collaborators": [
{
"percent": 2,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687578602,
"collaborator": {
"id": "83863eae-3d54-458a-8671-8494cec025c2",
"currency": "USD",
"payout_measurement": "monthly_date",
"payout_frequency": -1,
"payout_threshold": 410,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": 1687672448
}
},
{
"percent": 99,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687673092,
"collaborator": {
"id": "38f81dae-d025-42c7-bc48-e98b4e577f92",
"currency": "USD",
"payout_measurement": "month",
"payout_frequency": 1,
"payout_threshold": null,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": null
}
}
]
}
],
"meta": {
"current_page": 1,
"from": 1,
"last_page": 1,
"path": "https://collabpay.app/api/v1/products",
"per_page": 15,
"to": 2,
"total": 2
}
}
View a product
This endpoint allows you to view the product with attached collaborators.
Optional attributes
- Name
include_stats
- Type
- boolean
- Description
Include the stats for the collaborator in the results, defaults to
false
.
Request
curl https://collabpay.app/v1/products/aeda9be5-c9e1-40ec-8c76-be098262b7f6 \
-H 'Content-Type: application/json'
-H 'Accept: application/json'
-H "Authorization: Bearer {token}"
Response
{
"data": {
"id": "aeda9be5-c9e1-40ec-8c76-be098262b7f6",
"external_id": "12",
"external_variant_id": "13",
"name": "Hats (L)",
"sku": "HATLL",
"vendor": null,
"price": 0,
"cost": 200,
"tags": null,
"inventory_quantity": 55,
"collaborators": [
{
"percent": 2,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687578602,
"collaborator": {
"id": "83863eae-3d54-458a-8671-8494cec025c2",
"currency": "USD",
"payout_measurement": "monthly_date",
"payout_frequency": -1,
"payout_threshold": 410,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": 1687672448
},
"stats" => [
"sold_total" => "55",
]
},
{
"percent": 99,
"amount": null,
"shipping_percent": null,
"shipping_amount": null,
"created_at": 1687673092,
"collaborator": {
"id": "38f81dae-d025-42c7-bc48-e98b4e577f92",
"currency": "USD",
"payout_measurement": "month",
"payout_frequency": 1,
"payout_threshold": null,
"permissions": {
"see_product_price": false,
"see_product_quantity": false,
"see_product_discount": false,
"see_product_tax": false,
"see_customer_email": false,
"see_customer_name": false,
"see_order_status": false,
"see_order_payment_gateway": false,
"see_order_shipping_address": false,
"see_order_billing_address": false,
"see_product_cost": false,
"see_product_stock": false
},
"payouts_active_at": null
},
"stats" => [
"sold_total" => "0",
]
}
]
}
}