API Reference
Read and manage your store programmatically — inventory, orders, customers, campaigns, and pricing. 104 endpoints, grouped the same way your dashboard is.
SDKs & machine-readable spec
OpenAPI Spec
The full machine-readable spec behind this page — import it into any API client.
Download specAuthentication
Every request needs an API token. Create one from your store's dashboard under Settings → AI Assistant, then send it as a bearer token. Read-only tokens can call read endpoints only; read & write tokens can call all of them.
Authorization: Bearer YOUR_API_TOKEN
Official sandbox
SDKs, WordPress reviewers, and the laptop live-integration harness
share the synthetic sandbox tenant. Keep
DABDASH_SANDBOX_TOKEN in the approved secret store,
never in source control. The tenant is reconciled hourly without
rotating its stable token.
See the repository docs/official-sandbox.md guide for local setup.
Scopes
Every endpoint belongs to one area and one access level, written
area:access — for example
catalog:read or
marketing:write. The downloadable spec lists the scope every endpoint needs.
read
Grants :read on every area. Cannot change any data.
read_write
Grants :read and :write on every area.
Areas:
Base URL
Every endpoint is a POST request to
https://{your-store-slug}.dabdash.com/api/v1/tools/{tool}
— your own store's subdomain or mapped custom domain. This API is never served from
dabdash.com itself.
Your first request
Every endpoint follows this shape — swap the tool name and the body. Here's
inventory_status, which check inventorys across your store.
curl
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/inventory_status" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"alert_only": true
}'
JavaScript
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.inventory_status({
"alert_only": true
});
PHP
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->inventoryStatus([
'alert_only' => true,
]);
What your AI assistant can do
Everything on this page is also available to an AI assistant, using the same token and the same permissions — with no code at all. Connect one and you can just ask.

https://{your-store-slug}.dabdash.com/mcp
That's the shape. Your own address is ready to copy in your dashboard under Settings → AI Assistant.
Read the setup guideWant every endpoint, parameter, and response shape? Download the full spec and import it into your API client.
104 things it can do
Store
store:read- Check the connection
- Browse dashboard guidance
- Explain a dashboard control
Store
store:write- Configure delivery operations
- View or update store details and hours
Orders & Delivery
orders:read- Look up orders
Products & Inventory
catalog:read- Check inventory
- Inspect a product
- Search the product catalog
- Rank products by price per gram or ounce
- Search the strain library
- Find size-split products
- Review products and their variants
- Read the inventory audit log
- Find missing product photos
Products & Inventory
catalog:write- Merge size-split products
- Combine products into named variants
- List price menus
- Edit pricing tiers
- Assign pricing to products
- Delete a price menu
- Restore a deleted price menu
- Update a product by SKU
- Manage categories
- Create a product
- Sync product variations
- Control product storefront visibility
- Import many products at once
- Mark products as featured
- Set a product photo from the media library
- Apply strain library photos
- Add or update a supplier
- Start a purchase order
- Add items to a purchase order
Media Library
media:write- Browse the media library
- Upload an image
- Build a promo image
Customers
customers:read- Find a customer
- Check customer addresses
- Review recent customer messages
- Browse customers
- Check email inbox health
Customers
customers:write- Clean up a contact list
- Update customer details
- Prepare customer reply drafts
- Prepare delivery delay updates
Promotions
promotions:read- Review promotions
- List discount coupons
- List freebie rules
Promotions
promotions:write- List bundle deals
- Create or update a bundle
- Preview bundle rule matches
- Pin or exclude bundle members
- Audit bundle pricing conflicts
- Create or update a coupon
- Apply or remove a category shelf sale
- Create or update a freebie
- Set up the loyalty program
- Manage storefront widgets
Zones
zones:read- Check delivery coverage
Zones
zones:write- Add or change a delivery zone
- Clone delivery coverage between stores
- List or remove delivery zones
Analytics
analytics:read- Run revenue reports
- See website traffic
- See search performance
- Rank products by profit margin
Marketing
marketing:read- Split warm vs cold audience
- Check campaign product links
- Score campaign copy for inbox risk
- Preview a campaign as an image
- Read a campaign back, wording and all
- List campaigns
Marketing
marketing:write- Configure abandoned-cart emails
- Configure store notifications
- Collect and moderate product reviews
- Create or edit a campaign
- Apply a design template
- Design flyer artwork from your product photos
- Teach it the look of your past flyers
- Add an image to a campaign
- Send a test email
- Schedule or launch a campaign
- Retry failed recipients
- Start, pause, or cancel a send
- Manage contact lists
- Build a Smart List
- Manage marketing suppressions
- Manage product image SEO
- Configure storefront SEO
- Import blog posts and policy pages
- Write a storefront blog post
Integrations
integrations:read- Check customer blocks
- Check push notifications
- Check compliance sync
Integrations
integrations:write- Block or unblock customer identifiers
- Fill in Modern storefront sections
- Connect a custom domain
- View or update Advanced store SMTP
- Set up Send Email with Mailgun
- Configure Klaviyo
- Configure Twilio
- Manage webhooks
- Update the store logo, homepage hero, and email logo
Endpoints
Store
store 5 endpoints · 3 read · 2 writeIdentify the connected store and check its subscription state.
POSTstore_info store:read Identify the connected store — name, slug, timezone, currency, country, and subscription status.
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/store_info" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.store_info({});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->storeInfo();
Response
- storeobject
- idinteger
- namestring
- slugstring
- timezonestring
- currencystring
- countrystring
- on_trialboolean
- has_active_subscriptionboolean
POSTteaching_index store:read List DabDash UI teaching units (control-level tips shared with tours and Dabby tooltips).
Parameters
Optional page key, e.g. dab-ai.
Optional Driver.js tour key, e.g. dab-ai or dabmaster-dabby.
Optional unit id prefix, e.g. dab-ai.
| Name | Type | Required | Description |
|---|---|---|---|
| page | string | optional | Optional page key, e.g. dab-ai. |
| tour_key | string | optional | Optional Driver.js tour key, e.g. dab-ai or dabmaster-dabby. |
| prefix | string | optional | Optional unit id prefix, e.g. dab-ai. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/teaching_index" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"page": "example",
"tour_key": "example",
"prefix": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.teaching_index({
"page": "example",
"tour_key": "example",
"prefix": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->teachingIndex([
'page' => 'example',
'tour_key' => 'example',
'prefix' => 'example',
]);
POSTteaching_guide store:read Fetch one Teaching Continuity unit or all units for a page, including body text and selector so you can coach a human through the live DabDash UI with the same wording as Dabby tooltips and Help tours.
Parameters
Unit id from teaching_index, e.g. dab-ai.attach.
Page key to return every unit for that page, e.g. dab-ai. Ignored when id is set.
| Name | Type | Required | Description |
|---|---|---|---|
| id | string | optional | Unit id from teaching_index, e.g. dab-ai.attach. |
| page | string | optional | Page key to return every unit for that page, e.g. dab-ai. Ignored when id is set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/teaching_guide" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"id": "example",
"page": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.teaching_guide({
"id": "example",
"page": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->teachingGuide([
'id' => 'example',
'page' => 'example',
]);
POSTdelivery_settings_manage store:write Show or configure tenant delivery operations: logistics gate, driver self-serve,.
Parameters
"show" (default) or "set".
15–10080 minutes.
disabled, link_only, status_and_eta, or full_with_map.
none, photo, signature, either, or both.
7–365 days.
0–120 minutes.
Defaults to true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| delivery_logistics_enabled | boolean | optional | |
| driver_self_serve_claim_enabled | boolean | optional | |
| driver_self_serve_cancel_enabled | boolean | optional | |
| driver_self_serve_swap_enabled | boolean | optional | |
| driver_self_serve_cancel_lead_minutes | integer | optional | 15–10080 minutes. |
| customer_tracking_visibility | string | optional | disabled, link_only, status_and_eta, or full_with_map. |
| tracking_show_driver_photo | boolean | optional | |
| tracking_show_items | boolean | optional | |
| proof_of_delivery_requirement | string | optional | none, photo, signature, either, or both. |
| proof_retention_days | integer | optional | 7–365 days. |
| driver_notifications_disabled | array | optional | |
| auto_dispatch_propose_enabled | boolean | optional | |
| auto_dispatch_confirm_enabled | boolean | optional | |
| auto_dispatch_confirm_delay_minutes | integer | optional | 0–120 minutes. |
| dry_run | boolean | optional | Defaults to true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/delivery_settings_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"delivery_logistics_enabled": true,
"driver_self_serve_claim_enabled": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.delivery_settings_manage({
"action": "example",
"delivery_logistics_enabled": true,
"driver_self_serve_claim_enabled": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->deliverySettingsManage([
'action' => 'example',
'delivery_logistics_enabled' => true,
'driver_self_serve_claim_enabled' => true,
]);
POSTstore_settings_manage store:write Show or update a store's core settings: display name, phone, address, coordinates,.
Parameters
"show" (default) or "set".
Store display name.
Store phone.
Street address.
City.
Province or state.
Postal or ZIP code.
Latitude of the store.
Longitude of the store.
IANA timezone, e.g. America/Halifax.
ISO 4217 code, e.g. CAD.
ISO 3166-1 alpha-2, e.g. CA.
Locale, e.g. en.
Brand hex colour, e.g. #40B649.
Secondary/accent hex colour, e.g. #E7C98F.
"auto" (default), "white" or "dark" — text colour on primary/accent buttons.
Storefront theme: "classic" (default) or "modern".
Storefront colour mode: "light" or "dark".
Primary hero title, up to 100 characters.
Hero subtitle/eyebrow, up to 150 characters.
Full hero description, up to 500 characters.
Primary hero CTA, up to 50 characters.
Legacy secondary CTA text.
Modern hero eyebrow, up to 60 characters.
Modern secondary CTA label.
Modern secondary CTA URL.
Modern hero card: auto (newest sale), product (pin one), or off (hide).
Active product id to pin on the Modern hero card. Pins the card unless mode is also passed.
Active product name or slug to pin on the Modern hero card. Ignored when hero_spotlight_product_id is set.
Modern spotlight badge label.
Modern spotlight kicker.
Modern spotlight CTA.
Modern ticker: auto, custom, or off.
Modern hero last-call pill: hours, auto, or off.
Storefront age gate minimum age (e.g. 19 for Nova Scotia).
Modern footer notes, one per line (up to 4).
Modern About section heading.
Modern About intro paragraph.
Modern About small label.
Authoritative absolute privacy-policy URL; may be this store's published blog URL.
Optional /delivery page meta description, up to 160 characters.
Absolute Facebook page URL for schema sameAs.
Absolute Instagram profile URL for schema sameAs.
Absolute Twitter profile URL for schema sameAs.
Absolute X.com profile URL for schema sameAs.
Absolute Google Business / Maps URL for schema sameAs.
Absolute Google Business Profile URL for schema sameAs.
Show the tenant-scoped storefront live chat widget.
Include freebie wholesale cost in COGS / profit reports (default true).
Analytics revenue day: "placed" (checkout day) or "delivered" (scheduled delivery calendar day).
Enable Cloudflare Single Redirects for the Wix legacy profile on this tenant zone.
Enable Cloudflare Single Redirects for the WordPress legacy profile on this tenant zone.
Mark WordPress cutover complete (pairs with legacy_wordpress_redirects for CF sync).
Custom ticker rows; replaces existing rows.
Opening hour rows. Replaces existing rows; [] clears.
Default true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| name | string | optional | Store display name. |
| phone | string | optional | Store phone. |
| address | string | optional | Street address. |
| city | string | optional | City. |
| state | string | optional | Province or state. |
| zip | string | optional | Postal or ZIP code. |
| latitude | number | optional | Latitude of the store. |
| longitude | number | optional | Longitude of the store. |
| timezone | string | optional | IANA timezone, e.g. America/Halifax. |
| currency | string | optional | ISO 4217 code, e.g. CAD. |
| country | string | optional | ISO 3166-1 alpha-2, e.g. CA. |
| locale | string | optional | Locale, e.g. en. |
| theme_color | string | optional | Brand hex colour, e.g. #40B649. |
| accent_color | string | optional | Secondary/accent hex colour, e.g. #E7C98F. |
| button_text_color | string | optional | "auto" (default), "white" or "dark" — text colour on primary/accent buttons. |
| storefront_theme | string | optional | Storefront theme: "classic" (default) or "modern". |
| theme_mode | string | optional | Storefront colour mode: "light" or "dark". |
| hero_title | string | optional | Primary hero title, up to 100 characters. |
| hero_subtitle | string | optional | Hero subtitle/eyebrow, up to 150 characters. |
| hero_description | string | optional | Full hero description, up to 500 characters. |
| hero_cta_text | string | optional | Primary hero CTA, up to 50 characters. |
| hero_cta_secondary | string | optional | Legacy secondary CTA text. |
| hero_eyebrow | string | optional | Modern hero eyebrow, up to 60 characters. |
| hero_cta_secondary_label | string | optional | Modern secondary CTA label. |
| hero_cta_secondary_url | string | optional | Modern secondary CTA URL. |
| hero_spotlight_mode | string | optional | Modern hero card: auto (newest sale), product (pin one), or off (hide). |
| hero_spotlight_product_id | integer | optional | Active product id to pin on the Modern hero card. Pins the card unless mode is also passed. |
| hero_spotlight_product | string | optional | Active product name or slug to pin on the Modern hero card. Ignored when hero_spotlight_product_id is set. |
| hero_spotlight_label | string | optional | Modern spotlight badge label. |
| hero_spotlight_kicker | string | optional | Modern spotlight kicker. |
| hero_spotlight_cta | string | optional | Modern spotlight CTA. |
| hero_ticker_mode | string | optional | Modern ticker: auto, custom, or off. |
| hero_status_mode | string | optional | Modern hero last-call pill: hours, auto, or off. |
| minimum_age | integer | optional | Storefront age gate minimum age (e.g. 19 for Nova Scotia). |
| footer_notes | string | optional | Modern footer notes, one per line (up to 4). |
| about_title | string | optional | Modern About section heading. |
| about_lede | string | optional | Modern About intro paragraph. |
| about_eyebrow | string | optional | Modern About small label. |
| privacy_url | string | optional | Authoritative absolute privacy-policy URL; may be this store's published blog URL. |
| delivery_meta_description | string | optional | Optional /delivery page meta description, up to 160 characters. |
| social_facebook | string | optional | Absolute Facebook page URL for schema sameAs. |
| social_instagram | string | optional | Absolute Instagram profile URL for schema sameAs. |
| social_twitter | string | optional | Absolute Twitter profile URL for schema sameAs. |
| social_x | string | optional | Absolute X.com profile URL for schema sameAs. |
| google_business_url | string | optional | Absolute Google Business / Maps URL for schema sameAs. |
| gbp_url | string | optional | Absolute Google Business Profile URL for schema sameAs. |
| live_chat_enabled | boolean | optional | Show the tenant-scoped storefront live chat widget. |
| freebie_cost_in_cogs | boolean | optional | Include freebie wholesale cost in COGS / profit reports (default true). |
| revenue_attribution_date | string | optional | Analytics revenue day: "placed" (checkout day) or "delivered" (scheduled delivery calendar day). |
| legacy_wix_redirects | boolean | optional | Enable Cloudflare Single Redirects for the Wix legacy profile on this tenant zone. |
| legacy_wordpress_redirects | boolean | optional | Enable Cloudflare Single Redirects for the WordPress legacy profile on this tenant zone. |
| wordpress_cutover | boolean | optional | Mark WordPress cutover complete (pairs with legacy_wordpress_redirects for CF sync). |
| hero_ticker_items | array | optional | Custom ticker rows; replaces existing rows. |
| opening_hours | array | optional | Opening hour rows. Replaces existing rows; [] clears. |
| dry_run | boolean | optional | Default true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/store_settings_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"name": "example",
"phone": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.store_settings_manage({
"action": "example",
"name": "example",
"phone": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->storeSettingsManage([
'action' => 'example',
'name' => 'example',
'phone' => 'example',
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- storeobject
- namestring
- slugstring
- phonestring
- addressstring
- citystring
- statestring
- zipstring
- latitudenumber
- longitudenumber
- timezonestring
- currencystring
- countrystring
- localestring
- theme_colorstring
- accent_colorstring
- button_text_colorstring
- storefront_themestring
- theme_modestring
- minimum_ageinteger
- freebie_cost_in_cogsboolean
- revenue_attribution_datestring
- opening_hoursarray
- daysarray
- opensstring
- closesstring
- heroobject
- storefront_themestring
- titlestring
- subtitlestring
- descriptionstring
- cta_textstring
- eyebrowstring
- cta_secondary_labelstring
- cta_secondary_urlstring
- spotlight_modestring
- spotlight_product_idinteger
- spotlight_product_namestring
- spotlight_product_slugstring
- spotlight_labelstring
- spotlight_kickerstring
- spotlight_ctastring
- ticker_modestring
- status_modestring
- ticker_itemsarray
- labelstring
- tagstring
- urlstring
- copyobject
- footer_notesstring
- about_titlestring
- about_ledestring
- about_eyebrowstring
- privacy_urlstring
- delivery_meta_descriptionstring
- paletteobject
- primarystring
- accentstring
- on_primarystring
- on_accentstring
- on_primary_rationumber
- on_accent_rationumber
- primary_accent_rationumber
- warningsarray
Orders & Delivery
orders 1 endpointRead orders, their status, and delivery details.
POSTorder_dashboard orders:read Query orders with filters and stable cursor pagination.
Parameters
Exact order number (optional)
Exact customer email (optional)
Customer phone number, digits or formatted (optional)
Partial customer name match (optional)
Filter by order status
Filter by payment status
Start created date filter (YYYY-MM-DD format)
End created date filter (YYYY-MM-DD format)
ISO-8601 timestamp; only orders updated at or after this time (optional)
Minimum order total in cents
Number of orders to return (default 25, max 100)
Opaque next_cursor from the previous response; omit to start at the newest order
Include order line items for sync/export use (default false)
| Name | Type | Required | Description |
|---|---|---|---|
| order_number | string | optional | Exact order number (optional) |
| customer_email | string | optional | Exact customer email (optional) |
| customer_phone | string | optional | Customer phone number, digits or formatted (optional) |
| customer_name | string | optional | Partial customer name match (optional) |
| status | string | optional | Filter by order status |
| payment_status | string | optional | Filter by payment status |
| date_from | string | optional | Start created date filter (YYYY-MM-DD format) |
| date_to | string | optional | End created date filter (YYYY-MM-DD format) |
| updated_since | string | optional | ISO-8601 timestamp; only orders updated at or after this time (optional) |
| min_total | integer | optional | Minimum order total in cents |
| limit | integer | optional | Number of orders to return (default 25, max 100) |
| cursor | string | optional | Opaque next_cursor from the previous response; omit to start at the newest order |
| include_items | boolean | optional | Include order line items for sync/export use (default false) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/order_dashboard" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"order_number": "example",
"customer_email": "example",
"customer_phone": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.order_dashboard({
"order_number": "example",
"customer_email": "example",
"customer_phone": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->orderDashboard([
'order_number' => 'example',
'customer_email' => 'example',
'customer_phone' => 'example',
]);
Response
- summaryobject
- matched_ordersinteger
- total_revenue_centsinteger
- total_revenuestring
- has_moreboolean
- next_cursorstring
- limitinteger
- include_itemsboolean
- ordersarray
- idinteger
- customer_idinteger
- order_numberstring
- tenantstring
- statusstring
- payment_statusstring
- payment_methodstring
- currencystring
- customer_namestring
- customer_emailstring
- customer_phonestring
- delivery_addressarray
- delivery_notesstring
- notesstring
- subtotal_centsinteger
- subtotalstring
- delivery_fee_centsinteger
- service_fee_centsinteger
- discount_amount_centsinteger
- tax_amount_centsinteger
- total_centsinteger
- totalstring
- coupon_codestring
- coupon_discountstring
- mix_match_discountstring
- loyalty_tier_discountstring
- loyalty_discountstring
- is_asapboolean
- scheduled_atstring
- delivered_atstring
- created_atstring
- updated_atstring
- itemsarray
- idinteger
- product_idinteger
- variation_idinteger
- product_namestring
- variation_namestring
- skustring
- quantityinteger
- unit_price_centsinteger
- total_price_centsinteger
- cost_price_centsinteger
- weight_deductednumber
- discount_amount_centsinteger
- discount_typestring
- is_freebieboolean
- freebie_idinteger
- loyalty_points_earnedinteger
Products & Inventory
catalog 28 endpoints · 9 read · 19 writeProducts, variations, categories, stock levels, and price menus.
POSTinventory_status catalog:read Get inventory status across all tenants or a specific tenant.
Parameters
If true, return only low-stock and out-of-stock items (default false)
| Name | Type | Required | Description |
|---|---|---|---|
| alert_only | boolean | optional | If true, return only low-stock and out-of-stock items (default false) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/inventory_status" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"alert_only": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.inventory_status({
"alert_only": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->inventoryStatus([
'alert_only' => true,
]);
Response
- summaryobject
- total_productsinteger
- in_stockinteger
- low_stock_alertsinteger
- out_of_stockinteger
- low_stock_alertsarray
- tenantstring
- productstring
- quantitynumber
- thresholdnumber
- out_of_stockarray
- tenantstring
- productstring
- in_stock_itemsarray
- tenantstring
- productstring
- quantitynumber
POSTproduct_inspect catalog:read Inspect a specific product including every variation's price, compare_at_price, mix_match_tags, stock, and the tenant's mix & match rule settings.
Parameters
Exact product id (optional if name_query or sku supplied)
Partial product name match (optional if product_id or sku supplied)
Exact SKU of a variation belonging to the product (optional if product_id or name_query supplied). SKUs are unique per tenant.
| Name | Type | Required | Description |
|---|---|---|---|
| product_id | integer | optional | Exact product id (optional if name_query or sku supplied) |
| name_query | string | optional | Partial product name match (optional if product_id or sku supplied) |
| sku | string | optional | Exact SKU of a variation belonging to the product (optional if product_id or name_query supplied). SKUs are unique per tenant. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_inspect" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_id": 10,
"name_query": "example",
"sku": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_inspect({
"product_id": 10,
"name_query": "example",
"sku": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productInspect([
'product_id' => 10,
'name_query' => 'example',
'sku' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- mix_match_settingsobject
- default_quantityinteger
- default_discount_typestring
- default_discount_valuenumber
- rulesarray
- productsarray
- idinteger
- namestring
- slugstring
- statusstring
- storefront_urlstring
- category_idsarray
- tracking_typestring
- inventory_modestring
- stock_quantitynumber
- stock_statusstring
- pricing_structurestring
- variationsarray
- idinteger
- namestring
- is_activeboolean
- price_centsinteger
- price_displaystring
- compare_at_price_centsinteger
- compare_at_price_displaystring
- on_saleboolean
- mix_match_tagsarray
- weight_valuenumber
- stock_quantitynumber
POSTproduct_search catalog:read Search a tenant's product catalog by name (and optionally category + status).
Parameters
Partial product name match (e.g. "Smalls"). Optional if category_id/slug is set.
Restrict to products in this category id.
Restrict to products in this category slug (e.g. "all-flower").
"active", "draft", "archived", or "all" (default).
Max results (default 50, max 100).
| Name | Type | Required | Description |
|---|---|---|---|
| name_query | string | optional | Partial product name match (e.g. "Smalls"). Optional if category_id/slug is set. |
| category_id | integer | optional | Restrict to products in this category id. |
| category_slug | string | optional | Restrict to products in this category slug (e.g. "all-flower"). |
| status | string | optional | "active", "draft", "archived", or "all" (default). |
| limit | integer | optional | Max results (default 50, max 100). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_search" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name_query": "example",
"category_id": 10,
"category_slug": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_search({
"name_query": "example",
"category_id": 10,
"category_slug": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productSearch([
'name_query' => 'example',
'category_id' => 10,
'category_slug' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- summaryobject
- totalinteger
- returnedinteger
- productsarray
- idinteger
- namestring
- slugstring
- statusstring
- storefront_pathstring
- storefront_urlstring
- price_centsinteger
- price_displaystring
- stock_statusstring
- stock_quantitynumber
- category_idsarray
- messagestring
POSTproduct_unit_price_search catalog:read Search and rank a tenant's catalog by computed per-unit price (e.g.
Parameters
Unit to price per: "g", "oz" (default, 28g), or "lb" (448g)
Optional partial product name filter
Minimum price per unit in dollars (optional)
Maximum price per unit in dollars (optional)
"asc" (cheapest first, default) or "desc" (most expensive first)
When true (default), exclude out-of-stock variations
Max results to return (default 25, max 100)
| Name | Type | Required | Description |
|---|---|---|---|
| unit | string | optional | Unit to price per: "g", "oz" (default, 28g), or "lb" (448g) |
| name_query | string | optional | Optional partial product name filter |
| min_price | number | optional | Minimum price per unit in dollars (optional) |
| max_price | number | optional | Maximum price per unit in dollars (optional) |
| sort | string | optional | "asc" (cheapest first, default) or "desc" (most expensive first) |
| only_in_stock | boolean | optional | When true (default), exclude out-of-stock variations |
| limit | integer | optional | Max results to return (default 25, max 100) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_unit_price_search" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"unit": "example",
"name_query": "example",
"min_price": 10.5
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_unit_price_search({
"unit": "example",
"name_query": "example",
"min_price": 10.5
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productUnitPriceSearch([
'unit' => 'example',
'name_query' => 'example',
'min_price' => 10.5,
]);
Response
- tenantobject
- idinteger
- slugstring
- unitstring
- unit_gramsnumber
- summaryobject
- variations_rankedinteger
- products_consideredinteger
- resultsarray
- product_idinteger
- product_namestring
- product_slugstring
- pricing_typestring
- variation_idinteger
- variation_namestring
- weight_value_gramsnumber
- price_centsinteger
- price_displaystring
- price_per_unit_centsnumber
- price_per_unit_displaystring
- stock_quantitynumber
- in_stockboolean
POSTstrain_lookup catalog:read Search the platform strain database — the same catalog vendors search on the.
Parameters
Strain name to search (e.g. "Blue Dream").
| Name | Type | Required | Description |
|---|---|---|---|
| query | string | required | Strain name to search (e.g. "Blue Dream"). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/strain_lookup" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"query": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.strain_lookup({
"query": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->strainLookup([
'query' => 'example',
]);
Response
- querystring
- totalinteger
- strainsarray
- idinteger
- namestring
- slugstring
- typestring
- thc_percentagenumber
- cbd_percentagenumber
- indica_percentagenumber
- sativa_percentagenumber
- short_descriptionstring
- has_hosted_imageboolean
POSTcatalog_flattening_audit catalog:read Read-only.
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_flattening_audit" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_flattening_audit({});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogFlatteningAudit();
Response
- tenant_slugstring
- summaryobject
- flattened_productsinteger
- collapsible_familiesinteger
- blocked_familiesinteger
- products_removed_if_mergedinteger
- familiesarray
- base_namestring
- collapsibleboolean
- blockerstring
- membersarray
- product_idinteger
- namestring
- slugstring
- weight_gramsnumber
- price_centsinteger
- cost_centsinteger
- stock_unitsnumber
POSTcatalog_variant_audit catalog:read Lists explicit unit products and their variations for safe catalog compaction review.
Parameters
Optional case-insensitive product-name filter.
| Name | Type | Required | Description |
|---|---|---|---|
| name_query | string | optional | Optional case-insensitive product-name filter. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_variant_audit" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name_query": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_variant_audit({
"name_query": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogVariantAudit([
'name_query' => 'example',
]);
Response
- tenant_slugstring
- productsarray
- idinteger
- namestring
- slugstring
- strain_typestring
- tracking_typestring
- base_unitstring
- categoriesarray
- variationsarray
- idinteger
- namestring
- price_centsinteger
- stock_quantitynumber
- activeboolean
POSTinventory_audit_lookup catalog:read Look up the historical inventory state of a list of products from the inventory_audit_logs table.
Parameters
List of product IDs to look up.
ISO8601 timestamp. The last quantity_after strictly BEFORE this moment is returned for each variation. Example: "2026-05-03T00:00:00Z".
| Name | Type | Required | Description |
|---|---|---|---|
| product_ids | array | required | List of product IDs to look up. |
| cutoff_iso | string | required | ISO8601 timestamp. The last quantity_after strictly BEFORE this moment is returned for each variation. Example: "2026-05-03T00:00:00Z". |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/inventory_audit_lookup" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_ids": [],
"cutoff_iso": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.inventory_audit_lookup({
"product_ids": [],
"cutoff_iso": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->inventoryAuditLookup([
'product_ids' => [],
'cutoff_iso' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- cutoffstring
- not_found_product_idsarray
- productsarray
- product_idinteger
- product_namestring
- product_slugstring
- current_stateobject
- tracking_typestring
- inventory_modestring
- pricing_structure_idinteger
- product_stock_quantitynumber
- variationsarray
- idinteger
- namestring
- is_activeboolean
- stock_quantitynumber
- price_centsinteger
- weight_valuenumber
- sort_orderinteger
- audit_historyarray
- variation_idinteger
- last_quantity_after_before_cutoffnumber
- last_actionstring
- last_notesstring
- last_reference_typestring
- last_logged_atstring
- variation_currently_existsboolean
- variation_current_namestring
- variation_current_stocknumber
POSTproduct_image_strain_match catalog:read Find products on a tenant's storefront that have no featured image, and.
Parameters
Limit the search to these product ids. Omit to scan all products missing a featured image.
Filter candidate products by name (case-insensitive contains).
Max products to propose matches for. Default 25, max 100.
| Name | Type | Required | Description |
|---|---|---|---|
| product_ids | array | optional | Limit the search to these product ids. Omit to scan all products missing a featured image. |
| search | string | optional | Filter candidate products by name (case-insensitive contains). |
| limit | integer | optional | Max products to propose matches for. Default 25, max 100. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_image_strain_match" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_ids": [],
"search": "example",
"limit": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_image_strain_match({
"product_ids": [],
"search": "example",
"limit": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productImageStrainMatch([
'product_ids' => [],
'search' => 'example',
'limit' => 10,
]);
Response
- tenantobject
- idinteger
- slugstring
- totalinteger
- proposalsarray
- product_idinteger
- product_namestring
- current_featured_imagestring
- proposed_strain_idinteger
- proposed_strain_namestring
- proposed_image_urlstring
- match_methodstring
- confidencestring
POSTcatalog_collapse catalog:write Merges a group of size-split products into ONE product with size options.
Parameters
The group to merge, exactly as returned by catalog_flattening_audit (e.g. "GLITTER BOMB | TOP SHELF FLOWER").
Defaults to TRUE — shows the plan without changing anything. Pass false to actually merge.
| Name | Type | Required | Description |
|---|---|---|---|
| base_name | string | required | The group to merge, exactly as returned by catalog_flattening_audit (e.g. "GLITTER BOMB | TOP SHELF FLOWER"). |
| dry_run | boolean | optional | Defaults to TRUE — shows the plan without changing anything. Pass false to actually merge. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_collapse" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"base_name": "example",
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_collapse({
"base_name": "example",
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogCollapse([
'base_name' => 'example',
'dry_run' => true,
]);
Response
- dry_runboolean
- base_namestring
- survivor_product_idinteger
- survivor_slugstring
- products_removedinteger
- total_gramsnumber
- cost_per_gram_centsinteger
- tiersarray
- labelstring
- weight_gramsnumber
- price_centsinteger
- absorbedarray
- product_idinteger
- namestring
- notesarray
- tenant_slugstring
- next_stepstring
POSTcatalog_variant_compact catalog:write Safely merges explicit same-family unit products into one product with named variants.
Parameters
Complete explicit members: product_id and the clean variant_name for every source product.
| Name | Type | Required | Description |
|---|---|---|---|
| survivor_product_id | integer | required | |
| products | array | required | Complete explicit members: product_id and the clean variant_name for every source product. |
| name | string | required | |
| dry_run | boolean | optional | |
| confirm | boolean | optional | |
| expected_snapshot | string | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_variant_compact" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"survivor_product_id": 10,
"products": [],
"name": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_variant_compact({
"survivor_product_id": 10,
"products": [],
"name": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogVariantCompact([
'survivor_product_id' => 10,
'products' => [],
'name' => 'example',
]);
Response
- dry_runboolean
- tenant_slugstring
- snapshotstring
- survivor_product_idinteger
- namestring
- slugstring
- old_slugsarray
- variantsarray
- idinteger
- namestring
- price_centsinteger
- stock_quantitynumber
- products_removedinteger
- survivor_slugstring
POSTpricing_structure_list catalog:write List all pricing structures for a tenant with their kind (inline|bundle), product count, tracking type,.
Parameters
Filter by kind: "inline" for hidden 1:1 structures, "bundle" for shared structures, or omit for all.
Include tier details for each structure. Defaults to false.
Include the list of product IDs assigned to each structure. Defaults to false.
| Name | Type | Required | Description |
|---|---|---|---|
| kind | string | optional | Filter by kind: "inline" for hidden 1:1 structures, "bundle" for shared structures, or omit for all. |
| include_tiers | boolean | optional | Include tier details for each structure. Defaults to false. |
| include_product_ids | boolean | optional | Include the list of product IDs assigned to each structure. Defaults to false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/pricing_structure_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"kind": "example",
"include_tiers": true,
"include_product_ids": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.pricing_structure_list({
"kind": "example",
"include_tiers": true,
"include_product_ids": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pricingStructureList([
'kind' => 'example',
'include_tiers' => true,
'include_product_ids' => true,
]);
Response
- tenantobject
- idinteger
- slugstring
- summaryobject
- totalinteger
- bundle_countinteger
- inline_countinteger
- structuresarray
- idinteger
- kindstring
- namestring
- tracking_typestring
- familystring
- is_defaultboolean
- product_countinteger
- product_idsarray
- tiersarray
- idinteger
- namestring
- weight_gramsnumber
- price_centsinteger
- price_displaystring
- compare_at_price_centsinteger
- compare_at_price_displaystring
- cost_price_centsinteger
- mix_match_tagsarray
- sort_orderinteger
POSTpricing_structure_upsert catalog:write Create or edit a pricing structure's tiers, name, and tracking type.
Parameters
ID of an existing BUNDLE structure to update. Must NOT be a hidden (inline) structure. Omit to create a new bundle or to edit inline via product_slug/product_id.
Product slug for inline (1:1) mode. Identifies which product's hidden structure to edit. Mutually exclusive with structure_id.
Product id for inline (1:1) mode. Alternative to product_slug. Mutually exclusive with structure_id.
Structure name. Required when creating a bundle. Ignored for inline structures (name is derived from the product name).
Pricing type: simple, weight, unit, matrix, or matrix_unit. Required when creating. For updates, changing tracking_type re-syncs all linked products.
Replacement tier list. Each tier: {name (string, required), weight_grams (number, required for weight/matrix), price (dollars, required), compare_at_price (dollars, nullable), cost_price (dollars, nullable), mix_match_tags (array of strings, nullable)}.
| Name | Type | Required | Description |
|---|---|---|---|
| structure_id | integer | optional | ID of an existing BUNDLE structure to update. Must NOT be a hidden (inline) structure. Omit to create a new bundle or to edit inline via product_slug/product_id. |
| product_slug | string | optional | Product slug for inline (1:1) mode. Identifies which product's hidden structure to edit. Mutually exclusive with structure_id. |
| product_id | integer | optional | Product id for inline (1:1) mode. Alternative to product_slug. Mutually exclusive with structure_id. |
| name | string | optional | Structure name. Required when creating a bundle. Ignored for inline structures (name is derived from the product name). |
| tracking_type | string | optional | Pricing type: simple, weight, unit, matrix, or matrix_unit. Required when creating. For updates, changing tracking_type re-syncs all linked products. |
| tiers | array | optional | Replacement tier list. Each tier: {name (string, required), weight_grams (number, required for weight/matrix), price (dollars, required), compare_at_price (dollars, nullable), cost_price (dollars, nullable), mix_match_tags (array of strings, nullable)}. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/pricing_structure_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"structure_id": 10,
"product_slug": "example",
"product_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.pricing_structure_upsert({
"structure_id": 10,
"product_slug": "example",
"product_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pricingStructureUpsert([
'structure_id' => 10,
'product_slug' => 'example',
'product_id' => 10,
]);
Response
- modestring
- structure_idinteger
- namestring
- tracking_typestring
- tier_countinteger
- products_resyncedinteger
- warningstring
- product_idinteger
- product_namestring
- messagestring
POSTpricing_structure_assign catalog:write Assign a shared bundle pricing structure to one or more products.
Parameters
ID of the shared BUNDLE structure to assign. Must NOT be a hidden (inline) structure.
List of product slugs to assign to this structure. Provide product_slugs or product_ids (or both).
List of product IDs to assign to this structure. Provide product_slugs or product_ids (or both).
| Name | Type | Required | Description |
|---|---|---|---|
| structure_id | integer | required | ID of the shared BUNDLE structure to assign. Must NOT be a hidden (inline) structure. |
| product_slugs | array | optional | List of product slugs to assign to this structure. Provide product_slugs or product_ids (or both). |
| product_ids | array | optional | List of product IDs to assign to this structure. Provide product_slugs or product_ids (or both). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/pricing_structure_assign" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"structure_id": 10,
"product_slugs": [],
"product_ids": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.pricing_structure_assign({
"structure_id": 10,
"product_slugs": [],
"product_ids": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pricingStructureAssign([
'structure_id' => 10,
'product_slugs' => [],
'product_ids' => [],
]);
Response
- structure_idinteger
- structure_namestring
- tracking_typestring
- summaryobject
- assignedinteger
- skippedinteger
- refusedinteger
- not_foundinteger
- resultsarray
- identifierinteger
- product_idinteger
- product_namestring
- statusstring
- reasonstring
- orphaned_structure_deletedinteger
POSTpricing_structure_delete catalog:write Delete one or more pricing structures by ID.
Parameters
List of structure IDs to delete. Bundle structures are always accepted; inline structures are only accepted when product_count=0.
If true, deletes even if products are still assigned (they will be orphaned — use only after migrating products). Requires orphan_products_acknowledged=true alongside.
Explicit acknowledgment that force=true will orphan products. Required when force=true and any structure has product_count > 0. Defaults to false.
| Name | Type | Required | Description |
|---|---|---|---|
| structure_ids | array | required | List of structure IDs to delete. Bundle structures are always accepted; inline structures are only accepted when product_count=0. |
| force | boolean | optional | If true, deletes even if products are still assigned (they will be orphaned — use only after migrating products). Requires orphan_products_acknowledged=true alongside. |
| orphan_products_acknowledged | boolean | optional | Explicit acknowledgment that force=true will orphan products. Required when force=true and any structure has product_count > 0. Defaults to false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/pricing_structure_delete" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"structure_ids": [],
"force": true,
"orphan_products_acknowledged": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.pricing_structure_delete({
"structure_ids": [],
"force": true,
"orphan_products_acknowledged": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pricingStructureDelete([
'structure_ids' => [],
'force' => true,
'orphan_products_acknowledged' => true,
]);
Response
- summaryobject
- deletedinteger
- refusedinteger
- not_foundinteger
- resultsarray
- idinteger
- namestring
- statusstring
- reasonstring
- product_countinteger
- product_count_at_deletioninteger
POSTpricing_structure_restore catalog:write Surgical restore tool.
Parameters
The product whose pricing structure and variations will be rebuilt.
Tracking type for the new inline structure: simple, unit, weight, matrix, matrix_unit.
Inventory mode override: "product" or "variation". If omitted, defaults are applied per tracking_type rules (weight→product, matrix→variation).
When inventory_mode=product, the value to set on products.stock_quantity. Ignored otherwise.
Array of tiers. Each: {name (string, required), price (dollars, required), compare_at_price (dollars, nullable), cost_price (dollars, nullable), weight_grams (number, required for weight/matrix), mix_match_tags (array, nullable), stock_quantity (number, required), restore_variation_id (int, optional — re-uses an existing variation row).}
If true, hard-deletes variations not referenced in tiers. Default false (deactivates them).
| Name | Type | Required | Description |
|---|---|---|---|
| product_id | integer | required | The product whose pricing structure and variations will be rebuilt. |
| tracking_type | string | required | Tracking type for the new inline structure: simple, unit, weight, matrix, matrix_unit. |
| inventory_mode | string | optional | Inventory mode override: "product" or "variation". If omitted, defaults are applied per tracking_type rules (weight→product, matrix→variation). |
| product_stock_quantity | number | optional | When inventory_mode=product, the value to set on products.stock_quantity. Ignored otherwise. |
| tiers | array | required | Array of tiers. Each: {name (string, required), price (dollars, required), compare_at_price (dollars, nullable), cost_price (dollars, nullable), weight_grams (number, required for weight/matrix), mix_match_tags (array, nullable), stock_quantity (number, required), restore_variation_id (int, optional — re-uses an existing variation row).} |
| delete_unreferenced | boolean | optional | If true, hard-deletes variations not referenced in tiers. Default false (deactivates them). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/pricing_structure_restore" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_id": 10,
"tracking_type": "example",
"inventory_mode": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.pricing_structure_restore({
"product_id": 10,
"tracking_type": "example",
"inventory_mode": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pricingStructureRestore([
'product_id' => 10,
'tracking_type' => 'example',
'inventory_mode' => 'example',
]);
Response
- product_idinteger
- product_namestring
- new_structure_idinteger
- tracking_typestring
- inventory_modestring
- tiersarray
- tier_namestring
- variation_idinteger
- actionstring
- stock_quantitynumber
- unreferenced_variationsarray
- variation_idinteger
- namestring
- stock_quantitynumber
- unreferenced_actionstring
POSTproduct_update_by_sku catalog:write Update a simple product's stock quantity and/or price by SKU — the inventory-sync path for an external POS.
Parameters
Exact SKU of the product's variation. SKUs are unique per tenant.
New absolute stock quantity (unit count, not grams). Omit to leave stock unchanged.
New price in dollars (e.g. 24.99). Omit to leave price unchanged.
| Name | Type | Required | Description |
|---|---|---|---|
| sku | string | required | Exact SKU of the product's variation. SKUs are unique per tenant. |
| stock_quantity | number | optional | New absolute stock quantity (unit count, not grams). Omit to leave stock unchanged. |
| price | number | optional | New price in dollars (e.g. 24.99). Omit to leave price unchanged. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_update_by_sku" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"sku": "example",
"stock_quantity": 10.5,
"price": 10.5
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_update_by_sku({
"sku": "example",
"stock_quantity": 10.5,
"price": 10.5
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productUpdateBySku([
'sku' => 'example',
'stock_quantity' => 10.5,
'price' => 10.5,
]);
Response
- product_idinteger
- variation_idinteger
- skustring
- stock_quantitynumber
- price_centsinteger
- updated_fieldsarray
POSTcategory_manage catalog:write List, create, update, or delete a tenant's storefront categories.
Parameters
"list" (default), "create", "update", or "delete".
ID of an existing category. Required for update and delete.
Category name shown to customers. Required when creating.
URL slug, unique per tenant. Auto-generated from name when omitted on create.
Optional category description.
SEO title override (max 60). Empty string clears.
SEO meta description override (max 160). Empty string clears.
Parent category id, or null for a top-level category.
Display order (lower sorts first).
Whether the category is visible on the storefront.
Whether the category appears in the homepage featured grid.
Media library asset id to set as image_path (the branded, customer-facing image).
Media library asset id to set as base_image_path (the unbranded source canvas).
Required (true) for action=delete.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list" (default), "create", "update", or "delete". |
| category_id | integer | optional | ID of an existing category. Required for update and delete. |
| name | string | optional | Category name shown to customers. Required when creating. |
| slug | string | optional | URL slug, unique per tenant. Auto-generated from name when omitted on create. |
| description | string | optional | Optional category description. |
| meta_title | string | optional | SEO title override (max 60). Empty string clears. |
| meta_description | string | optional | SEO meta description override (max 160). Empty string clears. |
| parent_id | integer | optional | Parent category id, or null for a top-level category. |
| sort_order | integer | optional | Display order (lower sorts first). |
| is_active | boolean | optional | Whether the category is visible on the storefront. |
| is_featured | boolean | optional | Whether the category appears in the homepage featured grid. |
| media_id | integer | optional | Media library asset id to set as image_path (the branded, customer-facing image). |
| base_media_id | integer | optional | Media library asset id to set as base_image_path (the unbranded source canvas). |
| confirm | boolean | optional | Required (true) for action=delete. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/category_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"category_id": 10,
"name": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.category_manage({
"action": "example",
"category_id": 10,
"name": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->categoryManage([
'action' => 'example',
'category_id' => 10,
'name' => 'example',
]);
Response
- actionstring
- tenantobject
- idinteger
- slugstring
- totalinteger
- categoriesarray
- idinteger
- namestring
- slugstring
- parent_idinteger
- sort_orderinteger
- is_activeboolean
- is_featuredboolean
- image_urlstring
- base_image_pathstring
- product_countinteger
- categoryobject
- idinteger
- namestring
- slugstring
- parent_idinteger
- sort_orderinteger
- is_activeboolean
- is_featuredboolean
- image_urlstring
- base_image_pathstring
- messagestring
POSTproduct_manage catalog:write Create a product for a tenant.
Parameters
"create" (default) or "update".
Existing product id required for update.
Product name shown to customers. Required for create.
Unit price in dollars (e.g. 24.99). Omit to leave $0 until edited.
SKU for the default variation.
On-hand unit count. Omit to leave unset.
Storefront category ids to attach.
Product description. Strain enrich fills this when omitted.
SEO title override (max 60). Empty string clears.
SEO meta description override (max 160). Empty string clears.
Platform strain id from strain_lookup. Copies strain data onto the product.
If true, do not auto-match or apply a strain from the product name.
Required with variations: exact number of variation rows; partial payloads are rejected.
Complete named variant rows. Each row requires name, price, and stock_quantity.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "create" (default) or "update". |
| product_id | integer | optional | Existing product id required for update. |
| name | string | optional | Product name shown to customers. Required for create. |
| price | number | optional | Unit price in dollars (e.g. 24.99). Omit to leave $0 until edited. |
| sku | string | optional | SKU for the default variation. |
| stock_quantity | number | optional | On-hand unit count. Omit to leave unset. |
| category_ids | array | optional | Storefront category ids to attach. |
| description | string | optional | Product description. Strain enrich fills this when omitted. |
| meta_title | string | optional | SEO title override (max 60). Empty string clears. |
| meta_description | string | optional | SEO meta description override (max 160). Empty string clears. |
| strain_id | integer | optional | Platform strain id from strain_lookup. Copies strain data onto the product. |
| skip_strain_enrich | boolean | optional | If true, do not auto-match or apply a strain from the product name. |
| expected_variation_count | integer | optional | Required with variations: exact number of variation rows; partial payloads are rejected. |
| variations | array | optional | Complete named variant rows. Each row requires name, price, and stock_quantity. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"product_id": 10,
"name": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_manage({
"action": "example",
"product_id": 10,
"name": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productManage([
'action' => 'example',
'product_id' => 10,
'name' => 'example',
]);
Response
- actionstring
- tenantobject
- idinteger
- slugstring
- productobject
- idinteger
- namestring
- slugstring
- strain_idinteger
- featured_imagestring
- inventory_modestring
- variation_countinteger
- strain_appliedobject
- idinteger
- namestring
- confidencestring
- strain_matchesarray
- idinteger
- namestring
- confidencestring
- messagestring
POSTproduct_variation_sync catalog:write Atomically create or reconcile the complete variation list and per-variation inventory for one product.
Parameters
Exact product id
Exact number of rows in variations; rejects partial payloads
Default true; set false only after vendor approval
Complete rows: name, price, cost_price, stock_quantity, optional id, weight_value, type, compare_at_price, mix_match_tags
| Name | Type | Required | Description |
|---|---|---|---|
| product_id | integer | optional | Exact product id |
| expected_variation_count | integer | optional | Exact number of rows in variations; rejects partial payloads |
| dry_run | boolean | optional | Default true; set false only after vendor approval |
| variations | array | optional | Complete rows: name, price, cost_price, stock_quantity, optional id, weight_value, type, compare_at_price, mix_match_tags |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_variation_sync" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_id": 10,
"expected_variation_count": 10,
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_variation_sync({
"product_id": 10,
"expected_variation_count": 10,
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productVariationSync([
'product_id' => 10,
'expected_variation_count' => 10,
'dry_run' => true,
]);
Response
- dry_runboolean
- product_idinteger
- before_countinteger
- after_countinteger
- createdinteger
- updatedinteger
- stock_totalnumber
- messagestring
POSTproduct_visibility_manage catalog:write Set whether tenant products are public or inventory-only without changing.
Parameters
Exact tenant product ids to update.
public or inventory_only.
Preview without writing. Defaults true.
Required true when dry_run=false.
| Name | Type | Required | Description |
|---|---|---|---|
| product_ids | array | optional | Exact tenant product ids to update. |
| visibility | string | optional | public or inventory_only. |
| dry_run | boolean | optional | Preview without writing. Defaults true. |
| confirm | boolean | optional | Required true when dry_run=false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_visibility_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_ids": [],
"visibility": "example",
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_visibility_manage({
"product_ids": [],
"visibility": "example",
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productVisibilityManage([
'product_ids' => [],
'visibility' => 'example',
'dry_run' => true,
]);
Response
- actionstring
- dry_runboolean
- tenantobject
- idinteger
- slugstring
- visibilitystring
- target_statusstring
- productsarray
- idinteger
- namestring
- slugstring
- before_statusstring
- after_statusstring
- actionstring
- inventory_unchangedboolean
- category_ids_unchangedboolean
- inventoryobject
- product_stock_quantitynumber
- product_stock_statusstring
- product_cost_priceinteger
- variation_countinteger
- variationsarray
- idinteger
- stock_quantitynumber
- stock_statusstring
- cost_priceinteger
- is_activeboolean
- category_idsarray
- messagestring
POSTcatalog_import catalog:write Bulk-create categories and products in one call, for onboarding a store from a.
Parameters
Categories to ensure exist. Parents must appear before children.
Products to create (max 100).
Default true.
| Name | Type | Required | Description |
|---|---|---|---|
| categories | array | optional | Categories to ensure exist. Parents must appear before children. |
| products | array | optional | Products to create (max 100). |
| dry_run | boolean | optional | Default true. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_import" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"categories": [],
"products": [],
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_import({
"categories": [],
"products": [],
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogImport([
'categories' => [],
'products' => [],
'dry_run' => true,
]);
Response
- dry_runboolean
- summaryobject
- categories_createdinteger
- categories_existinginteger
- products_createdinteger
- products_skippedinteger
- products_failedinteger
- images_failedinteger
- itemsarray
- kindstring
- namestring
- statusstring
- idinteger
- notestring
POSTproduct_feature_manage catalog:write List or set which products appear in a tenant's curated storefront home.
Parameters
"list" (default) or "set".
"featured" (default), "deals", or "new".
Product ids to update. Required for action=set.
Value to set on the section flag for product_ids. Required for action=set.
Optional start date (YYYY-MM-DD, tenant timezone). Null/omit = now. Only used when featured=true.
Optional end date (YYYY-MM-DD, tenant timezone, end of day UTC). Null/omit = never. Must be on/after starts_at.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list" (default) or "set". |
| section | string | optional | "featured" (default), "deals", or "new". |
| product_ids | array | optional | Product ids to update. Required for action=set. |
| featured | boolean | optional | Value to set on the section flag for product_ids. Required for action=set. |
| starts_at | string | optional | Optional start date (YYYY-MM-DD, tenant timezone). Null/omit = now. Only used when featured=true. |
| ends_at | string | optional | Optional end date (YYYY-MM-DD, tenant timezone, end of day UTC). Null/omit = never. Must be on/after starts_at. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_feature_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"section": "example",
"product_ids": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_feature_manage({
"action": "example",
"section": "example",
"product_ids": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productFeatureManage([
'action' => 'example',
'section' => 'example',
'product_ids' => [],
]);
Response
- actionstring
- sectionstring
- flagstring
- tenantobject
- idinteger
- slugstring
- totalinteger
- productsarray
- idinteger
- namestring
- slugstring
- is_featuredboolean
- is_featured_dealboolean
- is_featured_newboolean
- stock_statusstring
- starts_atstring
- ends_atstring
- statusstring
- updatedarray
- not_foundarray
- messagestring
POSTproduct_image_assign catalog:write Set a product's featured image and/or gallery from the tenant media library.
Parameters
Product id to update.
Tenant media library asset id for featured_image.
Tenant media library asset ids that replace gallery_images (empty array clears).
When true, clear featured_image. Mutually exclusive with media_id.
Preview without writing. Defaults true.
Replace an existing featured_image. Defaults false.
| Name | Type | Required | Description |
|---|---|---|---|
| product_id | integer | optional | Product id to update. |
| media_id | integer | optional | Tenant media library asset id for featured_image. |
| gallery_media_ids | array | optional | Tenant media library asset ids that replace gallery_images (empty array clears). |
| clear_featured | boolean | optional | When true, clear featured_image. Mutually exclusive with media_id. |
| dry_run | boolean | optional | Preview without writing. Defaults true. |
| overwrite | boolean | optional | Replace an existing featured_image. Defaults false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_image_assign" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"product_id": 10,
"media_id": 10,
"gallery_media_ids": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_image_assign({
"product_id": 10,
"media_id": 10,
"gallery_media_ids": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productImageAssign([
'product_id' => 10,
'media_id' => 10,
'gallery_media_ids' => [],
]);
Response
- actionstring
- dry_runboolean
- tenantobject
- idinteger
- slugstring
- productobject
- idinteger
- slugstring
- featured_imagestring
- featured_image_urlstring
- gallery_imagesarray
- changesobject
- featured_imagestring
- gallery_imagesarray
POSTproduct_image_strain_assign catalog:write Apply a hosted platform strain photo to a product's featured_image.
Parameters
Explicit product_id/strain_id pairs to assign. Mutually exclusive with auto_match.
When true, find and assign matches automatically instead of using assignments.
auto_match only: filter candidate products by name.
auto_match only: max products to consider. Default 25, max 100.
Preview without writing. Defaults true.
Replace an existing featured_image. Defaults false.
| Name | Type | Required | Description |
|---|---|---|---|
| assignments | array | optional | Explicit product_id/strain_id pairs to assign. Mutually exclusive with auto_match. |
| auto_match | boolean | optional | When true, find and assign matches automatically instead of using assignments. |
| search | string | optional | auto_match only: filter candidate products by name. |
| limit | integer | optional | auto_match only: max products to consider. Default 25, max 100. |
| dry_run | boolean | optional | Preview without writing. Defaults true. |
| overwrite | boolean | optional | Replace an existing featured_image. Defaults false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_image_strain_assign" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"assignments": [],
"auto_match": true,
"search": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_image_strain_assign({
"assignments": [],
"auto_match": true,
"search": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productImageStrainAssign([
'assignments' => [],
'auto_match' => true,
'search' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- dry_runboolean
- summaryobject
- assignedinteger
- skippedinteger
- failedinteger
- resultsarray
- product_idinteger
- statusstring
- reasonstring
- image_urlstring
POSTsupplier_upsert catalog:write Create or update a product supplier for purchase orders.
Parameters
Existing supplier id to update. Omit to create (or match by name).
Supplier name. Required when creating.
Supplier email for sending purchase orders.
Supplier phone.
License or account number if you store one.
Internal notes about this supplier.
Typical lead time in days (0–365). Defaults to 0 on create.
Whether this supplier can be used on new purchase orders. Defaults to true on create.
| Name | Type | Required | Description |
|---|---|---|---|
| supplier_id | integer | optional | Existing supplier id to update. Omit to create (or match by name). |
| name | string | optional | Supplier name. Required when creating. |
| string | optional | Supplier email for sending purchase orders. | |
| phone | string | optional | Supplier phone. |
| license_number | string | optional | License or account number if you store one. |
| notes | string | optional | Internal notes about this supplier. |
| lead_time_days | integer | optional | Typical lead time in days (0–365). Defaults to 0 on create. |
| is_active | boolean | optional | Whether this supplier can be used on new purchase orders. Defaults to true on create. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/supplier_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"supplier_id": 10,
"name": "example",
"email": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.supplier_upsert({
"supplier_id": 10,
"name": "example",
"email": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->supplierUpsert([
'supplier_id' => 10,
'name' => 'example',
'email' => 'example',
]);
Response
- createdboolean
- supplierobject
- idinteger
- namestring
- emailstring
- phonestring
- license_numberstring
- lead_time_daysinteger
- is_activeboolean
POSTpurchase_order_draft_create catalog:write Create a draft purchase order for a supplier.
Parameters
Supplier id from supplier_upsert.
Optional notes stored on the draft (invoice number, delivery date, etc.).
| Name | Type | Required | Description |
|---|---|---|---|
| supplier_id | integer | optional | Supplier id from supplier_upsert. |
| notes | string | optional | Optional notes stored on the draft (invoice number, delivery date, etc.). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/purchase_order_draft_create" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"supplier_id": 10,
"notes": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.purchase_order_draft_create({
"supplier_id": 10,
"notes": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->purchaseOrderDraftCreate([
'supplier_id' => 10,
'notes' => 'example',
]);
Response
- purchase_orderobject
- idinteger
- po_numberstring
- statusstring
- supplier_idinteger
- edit_pathstring
POSTpurchase_order_line_add catalog:write Add a product line to a draft purchase order.
Parameters
Draft purchase order id from purchase_order_draft_create.
Catalog product id to order.
Size/variation id when the product uses variation inventory.
Quantity to order (grams or units, matching the product).
Unit cost in dollars. Omit to use the last cost for this supplier.
How confident the catalog match is, from 0 to 1. Pass when importing from OCR.
| Name | Type | Required | Description |
|---|---|---|---|
| purchase_order_id | integer | optional | Draft purchase order id from purchase_order_draft_create. |
| product_id | integer | optional | Catalog product id to order. |
| variation_id | integer | optional | Size/variation id when the product uses variation inventory. |
| qty | number | optional | Quantity to order (grams or units, matching the product). |
| unit_cost | number | optional | Unit cost in dollars. Omit to use the last cost for this supplier. |
| match_confidence | number | optional | How confident the catalog match is, from 0 to 1. Pass when importing from OCR. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/purchase_order_line_add" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"purchase_order_id": 10,
"product_id": 10,
"variation_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.purchase_order_line_add({
"purchase_order_id": 10,
"product_id": 10,
"variation_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->purchaseOrderLineAdd([
'purchase_order_id' => 10,
'product_id' => 10,
'variation_id' => 10,
]);
Response
- lineobject
- idinteger
- purchase_order_idinteger
- product_idinteger
- variation_idinteger
- product_namestring
- variation_namestring
- qty_orderednumber
- unit_cost_centsinteger
- match_confidencenumber
Media Library
media 3 endpointsUpload, list, and compose images in the media library.
POSTmedia_list media:write List the images in a tenant's media library — id, public URL, dimensions, filename, folder, and alt.
Parameters
"public" (default), "private", or "all".
Only return assets in this exact library folder.
Filter by a substring of the original filename.
| Name | Type | Required | Description |
|---|---|---|---|
| visibility | string | optional | "public" (default), "private", or "all". |
| folder | string | optional | Only return assets in this exact library folder. |
| search | string | optional | Filter by a substring of the original filename. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/media_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"visibility": "example",
"folder": "example",
"search": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.media_list({
"visibility": "example",
"folder": "example",
"search": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->mediaList([
'visibility' => 'example',
'folder' => 'example',
'search' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- visibilitystring
- totalinteger
- returnedinteger
- truncatedboolean
- assetsarray
- media_idinteger
- urlstring
- original_filenamestring
- mime_typestring
- widthinteger
- heightinteger
- orientationstring
- folderstring
- alt_textstring
- size_bytesinteger
- visibilitystring
- created_atstring
POSTmedia_upload media:write Upload an image into a tenant's media library (the same library the vendor admin uses).
Parameters
Public http(s) URL to fetch the image from. Provide exactly one source.
Local file path to read the image from. Provide exactly one source.
Base64-encoded image bytes (data: prefix optional). Provide exactly one source.
Original filename to record (e.g. "summer-flyer.png"). Defaults to a derived name.
Alt text for accessibility and captions (max 500 chars).
Optional library folder to group the asset under (max 100 chars).
| Name | Type | Required | Description |
|---|---|---|---|
| source_url | string | optional | Public http(s) URL to fetch the image from. Provide exactly one source. |
| source_path | string | optional | Local file path to read the image from. Provide exactly one source. |
| source_base64 | string | optional | Base64-encoded image bytes (data: prefix optional). Provide exactly one source. |
| filename | string | optional | Original filename to record (e.g. "summer-flyer.png"). Defaults to a derived name. |
| alt_text | string | optional | Alt text for accessibility and captions (max 500 chars). |
| folder | string | optional | Optional library folder to group the asset under (max 100 chars). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/media_upload" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"source_url": "example",
"source_path": "example",
"source_base64": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.media_upload({
"source_url": "example",
"source_path": "example",
"source_base64": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->mediaUpload([
'source_url' => 'example',
'source_path' => 'example',
'source_base64' => 'example',
]);
Response
- actionstring
- media_idinteger
- urlstring
- mime_typestring
- widthinteger
- heightinteger
- size_bytesinteger
- original_filenamestring
- alt_textstring
- folderstring
- visibilitystring
- messagestring
POSTmedia_compose media:write Build a finished campaign/storefront creative ON THE SERVER: take a base picture, drop the.
Parameters
Storefront swag mode: composite the platform branding onto this category via SwagImagesService instead of the manual layout below. At most one of category_id or widget_id.
Storefront swag mode: composite the platform branding onto this widget via SwagImagesService instead of the manual layout below. At most one of category_id or widget_id.
ID of a library image to use as the background. Provide exactly one of base_media_id or base_url.
Public http(s) URL of the background image. Provide exactly one of base_media_id or base_url.
ID of a library image to place on top, unaltered. At most one of logo_media_id or logo_url.
Public http(s) URL of the logo to place on top, unaltered.
Large text under the logo (max 120 chars). Wrapped to at most 2 lines.
Smaller text under the headline (max 200 chars). Wrapped to at most 3 lines.
Typeface: anton, bebas, oswald, playfair, sans, serif. Defaults to "sans".
Vertical placement of the whole block: "top", "center" (default) or "bottom".
Logo width as a fraction of the base width, 0.05-0.90. Defaults to 0.30.
Headline colour as #RRGGBB. Defaults to #FFFFFF.
Subtitle colour as #RRGGBB. Defaults to text_color.
Headline size as a fraction of base width, 0.01-0.25. Defaults to 0.07.
Subtitle size as a fraction of base width, 0.01-0.15. Defaults to 0.035.
Darkening behind the logo/text for legibility: "none", "soft" (default) or "strong".
Draw a soft shadow under the text. Defaults to true.
Filename to record for the new asset (e.g. "natal-day-hero.png").
Alt text for accessibility and captions (max 500 chars).
Library folder to group the asset under (max 100 chars).
| Name | Type | Required | Description |
|---|---|---|---|
| category_id | integer | optional | Storefront swag mode: composite the platform branding onto this category via SwagImagesService instead of the manual layout below. At most one of category_id or widget_id. |
| widget_id | integer | optional | Storefront swag mode: composite the platform branding onto this widget via SwagImagesService instead of the manual layout below. At most one of category_id or widget_id. |
| base_media_id | integer | optional | ID of a library image to use as the background. Provide exactly one of base_media_id or base_url. |
| base_url | string | optional | Public http(s) URL of the background image. Provide exactly one of base_media_id or base_url. |
| logo_media_id | integer | optional | ID of a library image to place on top, unaltered. At most one of logo_media_id or logo_url. |
| logo_url | string | optional | Public http(s) URL of the logo to place on top, unaltered. |
| headline | string | optional | Large text under the logo (max 120 chars). Wrapped to at most 2 lines. |
| subtitle | string | optional | Smaller text under the headline (max 200 chars). Wrapped to at most 3 lines. |
| font | string | optional | Typeface: anton, bebas, oswald, playfair, sans, serif. Defaults to "sans". |
| logo_position | string | optional | Vertical placement of the whole block: "top", "center" (default) or "bottom". |
| logo_width_pct | number | optional | Logo width as a fraction of the base width, 0.05-0.90. Defaults to 0.30. |
| text_color | string | optional | Headline colour as #RRGGBB. Defaults to #FFFFFF. |
| subtitle_color | string | optional | Subtitle colour as #RRGGBB. Defaults to text_color. |
| headline_size_pct | number | optional | Headline size as a fraction of base width, 0.01-0.25. Defaults to 0.07. |
| subtitle_size_pct | number | optional | Subtitle size as a fraction of base width, 0.01-0.15. Defaults to 0.035. |
| scrim | string | optional | Darkening behind the logo/text for legibility: "none", "soft" (default) or "strong". |
| text_shadow | boolean | optional | Draw a soft shadow under the text. Defaults to true. |
| filename | string | optional | Filename to record for the new asset (e.g. "natal-day-hero.png"). |
| alt_text | string | optional | Alt text for accessibility and captions (max 500 chars). |
| folder | string | optional | Library folder to group the asset under (max 100 chars). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/media_compose" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"category_id": 10,
"widget_id": 10,
"base_media_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.media_compose({
"category_id": 10,
"widget_id": 10,
"base_media_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->mediaCompose([
'category_id' => 10,
'widget_id' => 10,
'base_media_id' => 10,
]);
Response
- actionstring
- media_idinteger
- urlstring
- mime_typestring
- widthinteger
- heightinteger
- size_bytesinteger
- original_filenamestring
- alt_textstring
- folderstring
- visibilitystring
- composed_layersstring
- wrappedboolean
- category_idinteger
- widget_idinteger
- image_pathstring
- image_urlstring
- messagestring
Customers
customers 9 endpoints · 5 read · 4 writeLook up customers, their addresses, and mailbox health.
POSTcustomer_lookup customers:read Find customers by id, email, phone, or name and return their recent addresses, orders, and support context.
Parameters
Exact customer id (optional)
Exact customer email (optional)
Customer phone number, digits or formatted (optional)
Partial customer name (optional)
Number of matches to return (default 10, max 25)
| Name | Type | Required | Description |
|---|---|---|---|
| customer_id | integer | optional | Exact customer id (optional) |
| string | optional | Exact customer email (optional) | |
| phone | string | optional | Customer phone number, digits or formatted (optional) |
| name | string | optional | Partial customer name (optional) |
| limit | integer | optional | Number of matches to return (default 10, max 25) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_lookup" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_id": 10,
"email": "example",
"phone": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_lookup({
"customer_id": 10,
"email": "example",
"phone": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerLookup([
'customer_id' => 10,
'email' => 'example',
'phone' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- matched_customersinteger
- customersarray
- idinteger
- namestring
- emailstring
- phonestring
- loyalty_pointsinteger
- email_verified_atstring
- last_login_atstring
- default_address_idinteger
- id_verified_atstring
- medical_record_verified_atstring
- phone_verified_atstring
- phone_validation_statusstring
- no_loyaltyboolean
- no_couponsboolean
- deletion_requested_atstring
- email_opt_outboolean
- sms_marketing_opt_outboolean
- sms_notifications_mutedboolean
- addresses_countinteger
- orders_countinteger
- conversation_countinteger
- addressesarray
- idinteger
- labelstring
- addressstring
- latitudenumber
- longitudenumber
- zone_idinteger
- zone_namestring
- is_defaultboolean
- recent_ordersarray
- idinteger
- order_numberstring
- statusstring
- payment_statusstring
- totalinteger
- total_displaystring
- coupon_codestring
- created_atstring
POSTcustomer_addresses customers:read Return a customer's saved addresses, coordinates, saved zones, and zone mismatch diagnostics.
Parameters
Exact customer id (optional)
Exact customer email (optional)
Customer phone number (optional)
| Name | Type | Required | Description |
|---|---|---|---|
| customer_id | integer | optional | Exact customer id (optional) |
| string | optional | Exact customer email (optional) | |
| phone | string | optional | Customer phone number (optional) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_addresses" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_id": 10,
"email": "example",
"phone": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_addresses({
"customer_id": 10,
"email": "example",
"phone": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerAddresses([
'customer_id' => 10,
'email' => 'example',
'phone' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- customerobject
- idinteger
- namestring
- emailstring
- phonestring
- default_address_idinteger
- addressesarray
- idinteger
- labelstring
- addressstring
- latitudenumber
- longitudenumber
- saved_zoneobject
- idinteger
- namestring
- detected_zoneobject
- idinteger
- namestring
- zone_matches_saved_zoneboolean
- is_defaultboolean
POSTcustomer_conversation_context customers:read Find recent email and live-chat conversations whose latest message is from a customer.
Parameters
Number of customer messages to return, from 1 to 25.
| Name | Type | Required | Description |
|---|---|---|---|
| limit | integer | optional | Number of customer messages to return, from 1 to 25. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_conversation_context" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"limit": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_conversation_context({
"limit": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerConversationContext([
'limit' => 10,
]);
Response
- conversationsarray
- conversation_idinteger
- channelstring
- customer_namestring
- subjectstring
- last_customer_messagestring
- last_message_atstring
POSTcustomer_list customers:read Page through all customers for a tenant, optionally filtered to those updated since a given time.
Parameters
ISO-8601 timestamp — only return customers updated at or after this time (optional)
Rows per page (default 25, max 100)
Opaque cursor from a previous response's next_cursor — omit to start from the first page
| Name | Type | Required | Description |
|---|---|---|---|
| updated_since | string | optional | ISO-8601 timestamp — only return customers updated at or after this time (optional) |
| limit | integer | optional | Rows per page (default 25, max 100) |
| cursor | string | optional | Opaque cursor from a previous response's next_cursor — omit to start from the first page |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"updated_since": "example",
"limit": 10,
"cursor": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_list({
"updated_since": "example",
"limit": 10,
"cursor": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerList([
'updated_since' => 'example',
'limit' => 10,
'cursor' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- customersarray
- idinteger
- namestring
- emailstring
- phonestring
- loyalty_pointsinteger
- email_verified_atstring
- last_login_atstring
- id_verified_atstring
- medical_record_verified_atstring
- phone_verified_atstring
- phone_validation_statusstring
- no_loyaltyboolean
- no_couponsboolean
- deletion_requested_atstring
- email_opt_outboolean
- sms_marketing_opt_outboolean
- sms_notifications_mutedboolean
- updated_atstring
- has_moreboolean
- next_cursorstring
POSTmailbox_inspect customers:read Inspect a tenant mailbox: independent INBOX/Sent sync watermarks, errors, recent ingestion counts (inbound/outbound), and a healthy/bootstrap/stalled/quiet verdict.
Parameters
Inspect a platform-owned mailbox (tenant_id IS NULL). When true, tenant_slug is ignored and email_account_id is required.
Specific EmailAccount id (required for platform=true; optional for tenant_slug — defaults to the tenant's single mailbox).
| Name | Type | Required | Description |
|---|---|---|---|
| platform | boolean | optional | Inspect a platform-owned mailbox (tenant_id IS NULL). When true, tenant_slug is ignored and email_account_id is required. |
| email_account_id | integer | optional | Specific EmailAccount id (required for platform=true; optional for tenant_slug — defaults to the tenant's single mailbox). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/mailbox_inspect" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"platform": true,
"email_account_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.mailbox_inspect({
"platform": true,
"email_account_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->mailboxInspect([
'platform' => true,
'email_account_id' => 10,
]);
Response
- accountobject
- idinteger
- tenant_idinteger
- tenant_slugstring
- labelstring
- protocolstring
- hoststring
- portinteger
- usernamestring
- encryptionstring
- folderstring
- is_activeboolean
- leave_on_serverboolean
- sync_stateobject
- last_synced_uidinteger
- last_synced_atstring
- minutes_since_last_syncinteger
- last_sync_errorstring
- last_sync_error_atstring
- minutes_since_last_errorinteger
- sent_last_synced_uidinteger
- sent_last_synced_atstring
- minutes_since_sent_last_syncinteger
- sent_sync_errorstring
- sent_sync_error_atstring
- minutes_since_sent_last_errorinteger
- ingestionobject
- inbound_countinteger
- outbound_countinteger
- total_countinteger
- last_inbound_fetched_atstring
- last_inbound_minutes_agointeger
- verdictobject
- statestring
- explanationstring
- suggested_actionstring
- recent_messagesarray
- idinteger
- directionstring
- from_domainstring
- subject_lengthinteger
- fetched_atstring
- has_attachmentsboolean
POSTcontact_cleanup customers:write Removes contacts that failed email validation from an imported list.
Parameters
Which validation statuses to purge. Defaults to ["invalid"]. Only "invalid" and "risky" are allowed; "unknown" is refused because those contacts are simply not graded yet.
Limit the purge to one contact list. Omit to sweep every list in the store.
Defaults to TRUE — reports what would be deleted without deleting. Pass false to actually delete.
| Name | Type | Required | Description |
|---|---|---|---|
| statuses | array | optional | Which validation statuses to purge. Defaults to ["invalid"]. Only "invalid" and "risky" are allowed; "unknown" is refused because those contacts are simply not graded yet. |
| list_id | integer | optional | Limit the purge to one contact list. Omit to sweep every list in the store. |
| dry_run | boolean | optional | Defaults to TRUE — reports what would be deleted without deleting. Pass false to actually delete. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/contact_cleanup" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"statuses": [],
"list_id": 10,
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.contact_cleanup({
"statuses": [],
"list_id": 10,
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->contactCleanup([
'statuses' => [],
'list_id' => 10,
'dry_run' => true,
]);
POSTcustomer_update customers:write Update a customer's contact fields (name, email, phone) and/or suppress marketing consent (email_opt_out, sms_marketing_opt_out, sms_notifications_muted — one-way, cannot un-suppress).
Parameters
The customer to update
New display name
New email address (must be unique within the tenant)
New phone number, digits or formatted
Set true to suppress marketing email. Cannot be set to false — un-suppression happens in DabDash only.
Set true to suppress marketing texts. Cannot be set to false.
Set true to mute transactional/order SMS notifications. Cannot be set to false.
| Name | Type | Required | Description |
|---|---|---|---|
| customer_id | integer | required | The customer to update |
| name | string | optional | New display name |
| string | optional | New email address (must be unique within the tenant) | |
| phone | string | optional | New phone number, digits or formatted |
| email_opt_out | boolean | optional | Set true to suppress marketing email. Cannot be set to false — un-suppression happens in DabDash only. |
| sms_marketing_opt_out | boolean | optional | Set true to suppress marketing texts. Cannot be set to false. |
| sms_notifications_muted | boolean | optional | Set true to mute transactional/order SMS notifications. Cannot be set to false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_update" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_id": 10,
"name": "example",
"email": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_update({
"customer_id": 10,
"name": "example",
"email": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerUpdate([
'customer_id' => 10,
'name' => 'example',
'email' => 'example',
]);
Response
- customerobject
- idinteger
- namestring
- emailstring
- phonestring
- email_opt_outboolean
- sms_marketing_opt_outboolean
- sms_notifications_mutedboolean
- updated_atstring
- updated_fieldsarray
POSTcustomer_message_drafts_create customers:write Create reply drafts only when the user explicitly asks in their current message to draft or prepare customer replies.
Parameters
One to twenty-five proposed replies.
| Name | Type | Required | Description |
|---|---|---|---|
| drafts | array | optional | One to twenty-five proposed replies. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_message_drafts_create" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"drafts": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_message_drafts_create({
"drafts": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerMessageDraftsCreate([
'drafts' => [],
]);
Response
- draft_countinteger
- review_notestring
- draftsarray
- idinteger
- recipient_namestring
- channelstring
- subjectstring
- original_messagestring
- bodystring
- statusstring
POSTdelivery_delay_message_drafts_create customers:write Create delivery-delay email drafts only when the user explicitly asks in their current message to prepare or send a delivery update.
Parameters
One to twenty-five delivery-delay drafts.
| Name | Type | Required | Description |
|---|---|---|---|
| drafts | array | optional | One to twenty-five delivery-delay drafts. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/delivery_delay_message_drafts_create" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"drafts": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.delivery_delay_message_drafts_create({
"drafts": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->deliveryDelayMessageDraftsCreate([
'drafts' => [],
]);
Promotions
promotions 13 endpoints · 3 read · 10 writeCoupons, freebies, bundle deals, loyalty, and storefront widgets.
POSTpromotion_audit promotions:read Inspect coupons, freebies, mix and match rules, loyalty settings, and storewide sale state for overcharge or missed-discount support tickets.
Parameters
Optional order number to compare against configured promotions
Include inactive or expired promotions too (optional)
| Name | Type | Required | Description |
|---|---|---|---|
| order_number | string | optional | Optional order number to compare against configured promotions |
| include_inactive | boolean | optional | Include inactive or expired promotions too (optional) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/promotion_audit" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"order_number": "example",
"include_inactive": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.promotion_audit({
"order_number": "example",
"include_inactive": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->promotionAudit([
'order_number' => 'example',
'include_inactive' => true,
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- orderobject
- idinteger
- order_numberstring
- statusstring
- payment_statusstring
- subtotalinteger
- delivery_feeinteger
- service_feeinteger
- discount_amountinteger
- coupon_codestring
- coupon_typestring
- coupon_discountinteger
- mix_match_discountinteger
- loyalty_points_redeemedinteger
- loyalty_discountinteger
- totalinteger
- zonestring
- itemsarray
- productstring
- variationstring
- quantityinteger
- unit_priceinteger
- line_totalinteger
- storewide_saleobject
- activeboolean
- typestring
- amountnumber
- catalog_saleobject
- activeboolean
- typestring
- amountnumber
- basisstring
- category_idsarray
- loyaltyobject
- enabledboolean
- points_per_dollarnumber
- redeem_points_per_dollarnumber
- bundlesarray
- idinteger
- namestring
- quantityinteger
- discount_typestring
- discount_valuenumber
- discount_displaystring
- is_activeboolean
- variation_countinteger
- mix_matchobject
- notestring
- rulesarray
- tagstring
- quantityinteger
- discount_typestring
- discount_valuenumber
- tagged_variationsarray
- variation_idinteger
- productstring
- variationstring
- priceinteger
- tagsarray
- couponsarray
- idinteger
- codestring
- typestring
- valuenumber
- min_orderinteger
- max_usesinteger
- used_countinteger
- max_uses_per_customerinteger
- applies_tostring
- applies_to_idsarray
- starts_atstring
- expires_atstring
- is_activeboolean
- freebiesarray
- idinteger
- namestring
- spend_thresholdinteger
- quantityinteger
- is_stackableboolean
- is_activeboolean
- starts_atstring
- ends_atstring
- productstring
- variationstring
POSTcoupon_list promotions:read List a tenant's discount coupons with code, type, value, usage limits, redemption count,.
Parameters
Return only is_active coupons. Defaults to false (all coupons).
| Name | Type | Required | Description |
|---|---|---|---|
| only_active | boolean | optional | Return only is_active coupons. Defaults to false (all coupons). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/coupon_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"only_active": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.coupon_list({
"only_active": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->couponList([
'only_active' => true,
]);
Response
- tenantobject
- idinteger
- slugstring
- summaryobject
- totalinteger
- activeinteger
- exhaustedinteger
- couponsarray
- idinteger
- codestring
- typestring
- valuenumber
- value_unitstring
- min_order_centsinteger
- max_usesinteger
- used_countinteger
- is_exhaustedboolean
- max_uses_per_customerinteger
- limit_match_bystring
- applies_tostring
- is_activeboolean
- starts_atstring
- expires_atstring
- contact_list_idinteger
POSTfreebie_list promotions:read List a tenant's freebie rules ("spend $X, get a free item") with id, name, spend threshold,.
Parameters
Return only is_active freebies. Defaults to false (all freebies).
| Name | Type | Required | Description |
|---|---|---|---|
| only_active | boolean | optional | Return only is_active freebies. Defaults to false (all freebies). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/freebie_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"only_active": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.freebie_list({
"only_active": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->freebieList([
'only_active' => true,
]);
Response
- tenantobject
- idinteger
- slugstring
- summaryobject
- totalinteger
- activeinteger
- freebiesarray
- idinteger
- namestring
- spend_threshold_centsinteger
- product_idinteger
- product_namestring
- is_merch_productboolean
- variation_idinteger
- variation_namestring
- quantityinteger
- is_stackableboolean
- is_activeboolean
- starts_atstring
- ends_atstring
POSTbundle_list promotions:write List a tenant's bundle deals ("mix & match" — e.g.
Parameters
Include the list of attached product variation IDs for each bundle. Defaults to false.
Return only is_active bundles. Defaults to false (all bundles).
| Name | Type | Required | Description |
|---|---|---|---|
| include_variation_ids | boolean | optional | Include the list of attached product variation IDs for each bundle. Defaults to false. |
| only_active | boolean | optional | Return only is_active bundles. Defaults to false (all bundles). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/bundle_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"include_variation_ids": true,
"only_active": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.bundle_list({
"include_variation_ids": true,
"only_active": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->bundleList([
'include_variation_ids' => true,
'only_active' => true,
]);
Response
- tenantobject
- idinteger
- slugstring
- summaryobject
- totalinteger
- activeinteger
- zero_discountinteger
- zero_discount_bundlesarray
- bundlesarray
- idinteger
- namestring
- slugstring
- quantityinteger
- discount_typestring
- discount_valuenumber
- discount_displaystring
- is_activeboolean
- is_exampleboolean
- starts_atstring
- ends_atstring
- variation_countinteger
- variation_idsarray
POSTbundle_upsert promotions:write Create or update a bundle deal (mix & match) on behalf of a tenant.
Parameters
ID of an existing bundle to update. Omit to create a new bundle.
Bundle name shown to vendors and customers (e.g. "Any 4 for $77"). Required when creating.
Trigger threshold — number of cart units that activates the deal. Min 2. Required when creating.
"percent", "fixed" (per-unit dollars), or "fixed_total" (dollars for the whole set). Required when creating.
Percent 0–100 for "percent"; dollars for "fixed" and "fixed_total". Required when creating.
Whether the bundle is live. Defaults to true on create; left unchanged on update unless passed.
Optional start datetime (tenant timezone, stored as UTC). Pass null to clear.
Optional end datetime (tenant timezone, stored as UTC). Must be on/after starts_at. Pass null to clear.
Product variation IDs to apply the bundle to. Omit to leave membership unchanged.
How to apply variation_ids: "replace" (default), "add", or "detach".
Replaces the bundle's membership rule (AND-ed conditions). Each item: {field: unit_price|category_id|exclude_category_id|weight_value|mix_match_tag|product_status|tracking_type, operator: eq|lt|lte|gt|gte|between (default eq), value}. Use exclude_category_id to omit products belonging to a category while matching another category. Pass [] or null to clear the bundle back to fully manual. Preview with bundle_rule_preview before saving. Omit to leave the current rule state untouched.
| Name | Type | Required | Description |
|---|---|---|---|
| bundle_id | integer | optional | ID of an existing bundle to update. Omit to create a new bundle. |
| name | string | optional | Bundle name shown to vendors and customers (e.g. "Any 4 for $77"). Required when creating. |
| quantity | integer | optional | Trigger threshold — number of cart units that activates the deal. Min 2. Required when creating. |
| discount_type | string | optional | "percent", "fixed" (per-unit dollars), or "fixed_total" (dollars for the whole set). Required when creating. |
| discount_value | number | optional | Percent 0–100 for "percent"; dollars for "fixed" and "fixed_total". Required when creating. |
| is_active | boolean | optional | Whether the bundle is live. Defaults to true on create; left unchanged on update unless passed. |
| starts_at | string | optional | Optional start datetime (tenant timezone, stored as UTC). Pass null to clear. |
| ends_at | string | optional | Optional end datetime (tenant timezone, stored as UTC). Must be on/after starts_at. Pass null to clear. |
| variation_ids | array | optional | Product variation IDs to apply the bundle to. Omit to leave membership unchanged. |
| variation_mode | string | optional | How to apply variation_ids: "replace" (default), "add", or "detach". |
| rules | array | optional | Replaces the bundle's membership rule (AND-ed conditions). Each item: {field: unit_price|category_id|exclude_category_id|weight_value|mix_match_tag|product_status|tracking_type, operator: eq|lt|lte|gt|gte|between (default eq), value}. Use exclude_category_id to omit products belonging to a category while matching another category. Pass [] or null to clear the bundle back to fully manual. Preview with bundle_rule_preview before saving. Omit to leave the current rule state untouched. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/bundle_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"bundle_id": 10,
"name": "example",
"quantity": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.bundle_upsert({
"bundle_id": 10,
"name": "example",
"quantity": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->bundleUpsert([
'bundle_id' => 10,
'name' => 'example',
'quantity' => 10,
]);
Response
- actionstring
- bundle_idinteger
- namestring
- quantityinteger
- discount_typestring
- discount_valuenumber
- discount_value_unitstring
- is_activeboolean
- starts_atstring
- ends_atstring
- variation_countinteger
- has_ruleboolean
- rule_added_countinteger
- rule_removed_countinteger
- messagestring
POSTbundle_rule_preview promotions:write Read-only.
Parameters
Preview this bundle's currently stored rule. Omit when previewing an inline `rules` list instead.
Hypothetical rule to preview (not saved). Each item: {field, operator, value} — same shape as bundle_upsert's `rules`. Required when bundle_id is omitted.
| Name | Type | Required | Description |
|---|---|---|---|
| bundle_id | integer | optional | Preview this bundle's currently stored rule. Omit when previewing an inline `rules` list instead. |
| rules | array | optional | Hypothetical rule to preview (not saved). Each item: {field, operator, value} — same shape as bundle_upsert's `rules`. Required when bundle_id is omitted. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/bundle_rule_preview" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"bundle_id": 10,
"rules": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.bundle_rule_preview({
"bundle_id": 10,
"rules": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->bundleRulePreview([
'bundle_id' => 10,
'rules' => [],
]);
Response
- match_countinteger
- sample_truncatedboolean
- samplearray
- variation_idinteger
- product_namestring
- sizestring
- pricenumber
POSTbundle_membership promotions:write Override one variation's membership in one bundle, independent of whatever a bundle's rule.
Parameters
The bundle to change membership in.
The product variation to pin/unpin/exclude/unexclude.
One of: pin, unpin, exclude, unexclude.
| Name | Type | Required | Description |
|---|---|---|---|
| bundle_id | integer | optional | The bundle to change membership in. |
| variation_id | integer | optional | The product variation to pin/unpin/exclude/unexclude. |
| action | string | optional | One of: pin, unpin, exclude, unexclude. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/bundle_membership" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"bundle_id": 10,
"variation_id": 10,
"action": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.bundle_membership({
"bundle_id": 10,
"variation_id": 10,
"action": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->bundleMembership([
'bundle_id' => 10,
'variation_id' => 10,
'action' => 'example',
]);
Response
- bundle_idinteger
- variation_idinteger
- actionstring
- statusstring
- messagestring
POSTbundle_health promotions:write Read-only.
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/bundle_health" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.bundle_health({});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->bundleHealth();
Response
- tenantobject
- idinteger
- slugstring
- conflict_countinteger
- conflictsarray
- variation_idinteger
- variation_labelstring
- cheapest_pricenumber
- bundlesarray
- bundle_idinteger
- bundle_namestring
- pricenumber
POSTcoupon_upsert promotions:write Create or update a discount coupon on behalf of a tenant.
Parameters
ID of an existing coupon to update. Omit to create a new coupon.
Coupon code customers enter at checkout (case-insensitive, stored uppercase). Required when creating.
"percentage", "fixed", or "free_delivery". Required when creating.
Percent 0-100 for "percentage"; dollars for "fixed"; ignored for "free_delivery". Required when creating (pass 0 for free_delivery).
Minimum order subtotal in dollars required to use the coupon. Omit or 0 for no minimum.
ID of a Freebie (from freebie_list) to link, making this a code-triggered freebie. Pass null to unlink.
Total redemption cap across all customers. Omit/null for unlimited.
Redemption cap per customer, matched via limit_match_by. Defaults to 1.
"email", "phone", or "both" — how max_uses_per_customer is enforced. "phone"/"both" require the tenant's phone-at-checkout setting to be on.
"all", "products", or "categories". See tool description for applies_to_ids.
Product ids (applies_to="products") or category ids (applies_to="categories") this coupon is scoped to. All must belong to this tenant. Pass [] to clear.
Newsletter-subscriber-exclusive code: when true, only a registered customer who has NOT opted out of marketing email (email_opt_out=false) can redeem it. Gates to store customers only — never platform leads. Guests are always rejected. Defaults to false.
ID of an existing SubscriptionDiscountLadder to link. Pass null to unlink. See tool description.
Optional tenant-owned manual or Smart List id. Only list members may redeem the coupon; pass null to unlink.
Mounting ladder: percent off for orders before start_order_index. 0-100. See tool description.
Mounting ladder: percent the discount climbs each order once past start_order_index. 0-100. See tool description.
Mounting ladder: ceiling percent the discount pegs at once reached. 0-100. See tool description.
Mounting ladder: 1-based order number the climb begins at. See tool description.
Whether the coupon is live. Defaults to true on create; left unchanged on update unless passed.
Optional start date (tenant timezone, stored as UTC start-of-day). Pass null to clear.
Optional expiry date (tenant timezone, stored as UTC end-of-day). Must be on/after starts_at. Pass null to clear.
| Name | Type | Required | Description |
|---|---|---|---|
| coupon_id | integer | optional | ID of an existing coupon to update. Omit to create a new coupon. |
| code | string | optional | Coupon code customers enter at checkout (case-insensitive, stored uppercase). Required when creating. |
| type | string | optional | "percentage", "fixed", or "free_delivery". Required when creating. |
| value | number | optional | Percent 0-100 for "percentage"; dollars for "fixed"; ignored for "free_delivery". Required when creating (pass 0 for free_delivery). |
| min_order | number | optional | Minimum order subtotal in dollars required to use the coupon. Omit or 0 for no minimum. |
| freebie_id | integer | optional | ID of a Freebie (from freebie_list) to link, making this a code-triggered freebie. Pass null to unlink. |
| max_uses | integer | optional | Total redemption cap across all customers. Omit/null for unlimited. |
| max_uses_per_customer | integer | optional | Redemption cap per customer, matched via limit_match_by. Defaults to 1. |
| limit_match_by | string | optional | "email", "phone", or "both" — how max_uses_per_customer is enforced. "phone"/"both" require the tenant's phone-at-checkout setting to be on. |
| applies_to | string | optional | "all", "products", or "categories". See tool description for applies_to_ids. |
| applies_to_ids | array | optional | Product ids (applies_to="products") or category ids (applies_to="categories") this coupon is scoped to. All must belong to this tenant. Pass [] to clear. |
| requires_subscribed_customer | boolean | optional | Newsletter-subscriber-exclusive code: when true, only a registered customer who has NOT opted out of marketing email (email_opt_out=false) can redeem it. Gates to store customers only — never platform leads. Guests are always rejected. Defaults to false. |
| subscription_ladder_id | integer | optional | ID of an existing SubscriptionDiscountLadder to link. Pass null to unlink. See tool description. |
| contact_list_id | integer | optional | Optional tenant-owned manual or Smart List id. Only list members may redeem the coupon; pass null to unlink. |
| ladder_start_percent | integer | optional | Mounting ladder: percent off for orders before start_order_index. 0-100. See tool description. |
| ladder_step_percent | integer | optional | Mounting ladder: percent the discount climbs each order once past start_order_index. 0-100. See tool description. |
| ladder_cap_percent | integer | optional | Mounting ladder: ceiling percent the discount pegs at once reached. 0-100. See tool description. |
| ladder_start_order_index | integer | optional | Mounting ladder: 1-based order number the climb begins at. See tool description. |
| is_active | boolean | optional | Whether the coupon is live. Defaults to true on create; left unchanged on update unless passed. |
| starts_at | string | optional | Optional start date (tenant timezone, stored as UTC start-of-day). Pass null to clear. |
| expires_at | string | optional | Optional expiry date (tenant timezone, stored as UTC end-of-day). Must be on/after starts_at. Pass null to clear. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/coupon_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"coupon_id": 10,
"code": "example",
"type": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.coupon_upsert({
"coupon_id": 10,
"code": "example",
"type": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->couponUpsert([
'coupon_id' => 10,
'code' => 'example',
'type' => 'example',
]);
Response
- actionstring
- coupon_idinteger
- codestring
- typestring
- valuenumber
- value_unitstring
- min_order_centsinteger
- freebie_idinteger
- subscription_ladder_idinteger
- contact_list_idinteger
- applies_tostring
- applies_to_idsarray
- requires_subscribed_customerboolean
- is_activeboolean
- starts_atstring
- expires_atstring
- messagestring
POSTcatalog_sale_manage promotions:write Apply or remove a category shelf sale.
Parameters
"show" (default), "apply", or "remove".
"percent" or "flat". Required for apply.
Percent 0-100, or dollars off the Was price. Required for apply.
Category ids. Subcategories are included. Required for apply.
For remove: "restore" (default) puts the remembered sale back. "keep" makes the new price regular and forgets the old sale.
Defaults true for apply and remove.
Must be true when dry_run=false.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default), "apply", or "remove". |
| type | string | optional | "percent" or "flat". Required for apply. |
| amount | number | optional | Percent 0-100, or dollars off the Was price. Required for apply. |
| category_ids | array | optional | Category ids. Subcategories are included. Required for apply. |
| mode | string | optional | For remove: "restore" (default) puts the remembered sale back. "keep" makes the new price regular and forgets the old sale. |
| dry_run | boolean | optional | Defaults true for apply and remove. |
| confirm | boolean | optional | Must be true when dry_run=false. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/catalog_sale_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"type": "example",
"amount": 10.5
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.catalog_sale_manage({
"action": "example",
"type": "example",
"amount": 10.5
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->catalogSaleManage([
'action' => 'example',
'type' => 'example',
'amount' => 10.5,
]);
Response
- actionstring
- appliedboolean
- dry_runboolean
- saleobject
- activeboolean
- typestring
- amountnumber
- basisstring
- category_idsarray
- remembered_variationsinteger
- variationsinteger
- modestring
- samplesarray
POSTfreebie_upsert promotions:write Create or update a freebie rule ("spend $X, get a free item") on behalf of a tenant.
Parameters
ID of an existing freebie to update. Omit to create a new freebie.
Freebie name shown to vendors (e.g. "Spend $50 Get Papers"). Required when creating.
The product given away. Must belong to this tenant. Required when creating.
Optional specific variation of product_id to give away. Must belong to this tenant. Pass null to clear.
Minimum cart spend in dollars that triggers this freebie. Required when creating.
How many units of the product/variation are given away once triggered. Required when creating.
Whether this rule can combine with other freebie rules on the same order. Defaults to false.
Whether the freebie is live. Defaults to true on create; left unchanged on update unless passed.
Optional start date (tenant timezone, stored as UTC). Pass null to clear.
Optional end date (tenant timezone, stored as UTC). Must be on/after starts_at. Pass null to clear.
Category IDs to scope this freebie to. Must belong to this tenant; foreign ids are ignored. Omit to leave unchanged; pass an empty array to clear all.
| Name | Type | Required | Description |
|---|---|---|---|
| freebie_id | integer | optional | ID of an existing freebie to update. Omit to create a new freebie. |
| name | string | optional | Freebie name shown to vendors (e.g. "Spend $50 Get Papers"). Required when creating. |
| product_id | integer | optional | The product given away. Must belong to this tenant. Required when creating. |
| variation_id | integer | optional | Optional specific variation of product_id to give away. Must belong to this tenant. Pass null to clear. |
| spend_threshold | number | optional | Minimum cart spend in dollars that triggers this freebie. Required when creating. |
| quantity | integer | optional | How many units of the product/variation are given away once triggered. Required when creating. |
| is_stackable | boolean | optional | Whether this rule can combine with other freebie rules on the same order. Defaults to false. |
| is_active | boolean | optional | Whether the freebie is live. Defaults to true on create; left unchanged on update unless passed. |
| starts_at | string | optional | Optional start date (tenant timezone, stored as UTC). Pass null to clear. |
| ends_at | string | optional | Optional end date (tenant timezone, stored as UTC). Must be on/after starts_at. Pass null to clear. |
| category_ids | array | optional | Category IDs to scope this freebie to. Must belong to this tenant; foreign ids are ignored. Omit to leave unchanged; pass an empty array to clear all. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/freebie_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"freebie_id": 10,
"name": "example",
"product_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.freebie_upsert({
"freebie_id": 10,
"name": "example",
"product_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->freebieUpsert([
'freebie_id' => 10,
'name' => 'example',
'product_id' => 10,
]);
Response
- actionstring
- freebie_idinteger
- namestring
- product_idinteger
- variation_idinteger
- spend_threshold_centsinteger
- quantityinteger
- is_stackableboolean
- is_activeboolean
- starts_atstring
- ends_atstring
- category_countinteger
- messagestring
POSTloyalty_manage promotions:write Show or configure a store's points-based loyalty program, including vendor-defined.
Parameters
"show" (default) or "set".
Turn the loyalty program on or off.
Points earned per dollar spent (0.01–1000).
Points needed to redeem one dollar (1–100000).
When true, orders using a coupon earn no points.
Enable the configured lifetime tier ladder.
Lifetime tier definitions, sorted automatically by lifetime_points.
Customer ID for set_customer_lifetime.
Explicit lifetime points for set_customer_lifetime.
Default true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| enabled | boolean | optional | Turn the loyalty program on or off. |
| points_per_dollar | number | optional | Points earned per dollar spent (0.01–1000). |
| redeem_points_per_dollar | integer | optional | Points needed to redeem one dollar (1–100000). |
| skip_on_coupon | boolean | optional | When true, orders using a coupon earn no points. |
| tiers_enabled | boolean | optional | Enable the configured lifetime tier ladder. |
| tiers | array | optional | Lifetime tier definitions, sorted automatically by lifetime_points. |
| customer_id | integer | optional | Customer ID for set_customer_lifetime. |
| lifetime_points | integer | optional | Explicit lifetime points for set_customer_lifetime. |
| dry_run | boolean | optional | Default true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/loyalty_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"enabled": true,
"points_per_dollar": 10.5
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.loyalty_manage({
"action": "example",
"enabled": true,
"points_per_dollar": 10.5
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->loyaltyManage([
'action' => 'example',
'enabled' => true,
'points_per_dollar' => 10.5,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- loyaltyobject
- enabledboolean
- points_per_dollarnumber
- redeem_points_per_dollarinteger
- skip_on_couponboolean
- tiers_enabledboolean
- tiersarray
- customerobject
POSTwidget_manage promotions:write List, create, update, or delete a tenant's homepage marketing widgets (the hero slider cards.
Parameters
"list" (default), "create", "update", or "delete".
ID of an existing widget. Required for update and delete.
Widget headline. Required when creating.
Widget sub-label shown under the headline.
Call-to-action button text (e.g. "Shop Now").
"product", "category", "mix_match", or "featured". See LINK_TYPE in the tool description.
Target product id when link_type=product.
Target category id when link_type=category.
Target mix & match tag when link_type=mix_match.
Display order (lower sorts first).
Whether the widget is visible on the storefront.
Media library asset id to set as image_path (the branded, customer-facing image).
Media library asset id to set as base_image_path (the unbranded source canvas).
Required (true) for action=delete.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list" (default), "create", "update", or "delete". |
| widget_id | integer | optional | ID of an existing widget. Required for update and delete. |
| title | string | optional | Widget headline. Required when creating. |
| subtitle | string | optional | Widget sub-label shown under the headline. |
| cta_text | string | optional | Call-to-action button text (e.g. "Shop Now"). |
| link_type | string | optional | "product", "category", "mix_match", or "featured". See LINK_TYPE in the tool description. |
| product_id | integer | optional | Target product id when link_type=product. |
| category_id | integer | optional | Target category id when link_type=category. |
| mix_match_tag | string | optional | Target mix & match tag when link_type=mix_match. |
| sort_order | integer | optional | Display order (lower sorts first). |
| is_active | boolean | optional | Whether the widget is visible on the storefront. |
| media_id | integer | optional | Media library asset id to set as image_path (the branded, customer-facing image). |
| base_media_id | integer | optional | Media library asset id to set as base_image_path (the unbranded source canvas). |
| confirm | boolean | optional | Required (true) for action=delete. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/widget_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"widget_id": 10,
"title": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.widget_manage({
"action": "example",
"widget_id": 10,
"title": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->widgetManage([
'action' => 'example',
'widget_id' => 10,
'title' => 'example',
]);
Response
- actionstring
- tenantobject
- idinteger
- slugstring
- totalinteger
- widgetsarray
- idinteger
- titlestring
- subtitlestring
- cta_textstring
- link_typestring
- destination_urlstring
- sort_orderinteger
- is_activeboolean
- image_urlstring
- base_image_pathstring
- widgetobject
- idinteger
- titlestring
- subtitlestring
- cta_textstring
- link_typestring
- destination_urlstring
- sort_orderinteger
- is_activeboolean
- image_urlstring
- base_image_pathstring
- messagestring
Zones
zones 4 endpoints · 1 read · 3 writeCheck whether an address falls inside a delivery zone.
POSTzone_diagnostics zones:read Inspect zone polygons against customer or order coordinates to explain why an address is inside or outside delivery coverage.
Parameters
Saved customer address id to inspect (optional)
Order number whose delivery address should be checked (optional)
Specific zone to compare against (optional)
Manual latitude to test (optional)
Manual longitude to test (optional)
| Name | Type | Required | Description |
|---|---|---|---|
| customer_address_id | integer | optional | Saved customer address id to inspect (optional) |
| order_number | string | optional | Order number whose delivery address should be checked (optional) |
| zone_id | integer | optional | Specific zone to compare against (optional) |
| latitude | number | optional | Manual latitude to test (optional) |
| longitude | number | optional | Manual longitude to test (optional) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/zone_diagnostics" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_address_id": 10,
"order_number": "example",
"zone_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.zone_diagnostics({
"customer_address_id": 10,
"order_number": "example",
"zone_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->zoneDiagnostics([
'customer_address_id' => 10,
'order_number' => 'example',
'zone_id' => 10,
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- sourcestring
- address_coordinatesobject
- latitudenumber
- longitudenumber
- saved_zoneobject
- idinteger
- namestring
- insideboolean
- detected_zoneobject
- idinteger
- namestring
- priorityinteger
- zonesarray
- idinteger
- namestring
- priorityinteger
- delivery_feeinteger
- service_feeinteger
- min_orderinteger
- colorstring
- insideboolean
- polygon_pointsinteger
- polygonarray
POSTzone_upsert zones:write Create or update a delivery/pickup/shipping zone.
Parameters
Existing zone to update.
Zone name, e.g. "Halifax". Required to create.
Boundary points.
Circle centre latitude (with center_lng and radius_km).
Circle centre longitude.
Circle radius in km (0.1–200).
Delivery fee in dollars.
Service fee in dollars.
Minimum order in dollars.
Map colour hex, e.g. #3B82F6.
Whether the zone accepts orders.
Overlap priority (lower number wins).
delivery (default), pickup, or shipping.
Default true.
| Name | Type | Required | Description |
|---|---|---|---|
| zone_id | integer | optional | Existing zone to update. |
| name | string | optional | Zone name, e.g. "Halifax". Required to create. |
| polygon | array | optional | Boundary points. |
| center_lat | number | optional | Circle centre latitude (with center_lng and radius_km). |
| center_lng | number | optional | Circle centre longitude. |
| radius_km | number | optional | Circle radius in km (0.1–200). |
| delivery_fee | number | optional | Delivery fee in dollars. |
| service_fee | number | optional | Service fee in dollars. |
| min_order | number | optional | Minimum order in dollars. |
| color | string | optional | Map colour hex, e.g. #3B82F6. |
| is_active | boolean | optional | Whether the zone accepts orders. |
| priority | integer | optional | Overlap priority (lower number wins). |
| fulfillment_type | string | optional | delivery (default), pickup, or shipping. |
| dry_run | boolean | optional | Default true. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/zone_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"zone_id": 10,
"name": "example",
"polygon": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.zone_upsert({
"zone_id": 10,
"name": "example",
"polygon": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->zoneUpsert([
'zone_id' => 10,
'name' => 'example',
'polygon' => [],
]);
Response
- dry_runboolean
- createdboolean
- appliedboolean
- zoneobject
- idinteger
- namestring
- slugstring
- polygon_pointsinteger
- delivery_feenumber
- service_feenumber
- min_ordernumber
- is_activeboolean
- fulfillment_typestring
POSTzone_clone zones:write Clone every polygon zone from a source tenant into the target tenant while.
Parameters
Tenant whose polygon zones should be cloned.
Replace all existing target zones; required for a full coverage clone.
Required with replace_existing=true when applying.
Default true; preview without writing.
| Name | Type | Required | Description |
|---|---|---|---|
| source_tenant_slug | string | required | Tenant whose polygon zones should be cloned. |
| replace_existing | boolean | optional | Replace all existing target zones; required for a full coverage clone. |
| confirm | boolean | optional | Required with replace_existing=true when applying. |
| dry_run | boolean | optional | Default true; preview without writing. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/zone_clone" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"source_tenant_slug": "example",
"replace_existing": true,
"confirm": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.zone_clone({
"source_tenant_slug": "example",
"replace_existing": true,
"confirm": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->zoneClone([
'source_tenant_slug' => 'example',
'replace_existing' => true,
'confirm' => true,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- source_zone_countinteger
- existing_target_zone_countinteger
- cloned_zone_countinteger
- tier_mappingarray
- source_min_ordernumber
- target_zonestring
- target_min_ordernumber
- delivery_feenumber
- service_feenumber
- polygon_pointsinteger
- messagestring
POSTzone_manage zones:write List or delete a tenant's delivery zones.
Parameters
"list" (default) or "delete".
List of zone IDs to delete. Required for action=delete.
Required (true) for action=delete.
If true, deletes a zone even if orders/customer addresses/delivery slots still reference it (those rows are NOT deleted — their zone_id becomes orphaned). Use only after confirming that is acceptable.
Default true for action=delete. Report what would happen without writing.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list" (default) or "delete". |
| zone_ids | array | optional | List of zone IDs to delete. Required for action=delete. |
| confirm | boolean | optional | Required (true) for action=delete. |
| force | boolean | optional | If true, deletes a zone even if orders/customer addresses/delivery slots still reference it (those rows are NOT deleted — their zone_id becomes orphaned). Use only after confirming that is acceptable. |
| dry_run | boolean | optional | Default true for action=delete. Report what would happen without writing. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/zone_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"zone_ids": [],
"confirm": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.zone_manage({
"action": "example",
"zone_ids": [],
"confirm": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->zoneManage([
'action' => 'example',
'zone_ids' => [],
'confirm' => true,
]);
Response
- actionstring
- tenantobject
- idinteger
- slugstring
- dry_runboolean
- totalinteger
- zonesarray
- idinteger
- namestring
- slugstring
- is_activeboolean
- is_exampleboolean
- fulfillment_typestring
- priorityinteger
- delivery_feeinteger
- service_feeinteger
- min_orderinteger
- orders_countinteger
- customer_addresses_countinteger
- delivery_slots_countinteger
- summaryobject
- deletedinteger
- refusedinteger
- not_foundinteger
- resultsarray
- idinteger
- namestring
- statusstring
- reasonstring
Analytics
analytics 4 endpointsRevenue, product, traffic, and search performance reporting.
POSTanalytics_query analytics:read Run read-only analytics queries against the production database.
Parameters
The report to run
Start date for the report period (YYYY-MM-DD, default: 30 days ago)
End date for the report period (YYYY-MM-DD, default: today)
| Name | Type | Required | Description |
|---|---|---|---|
| report | string | required | The report to run |
| date_from | string | optional | Start date for the report period (YYYY-MM-DD, default: 30 days ago) |
| date_to | string | optional | End date for the report period (YYYY-MM-DD, default: today) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/analytics_query" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"report": "example",
"date_from": "example",
"date_to": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.analytics_query({
"report": "example",
"date_from": "example",
"date_to": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->analyticsQuery([
'report' => 'example',
'date_from' => 'example',
'date_to' => 'example',
]);
Response
- reportstring
- periodobject
- fromstring
- tostring
- tenantstring
- resultsstring
POSTgoogle_analytics analytics:read Query Google Analytics (GA4) data for a tenant with a connected GA integration.
Parameters
The report type to run
Number of days to look back (default 30, max 365)
| Name | Type | Required | Description |
|---|---|---|---|
| report | string | required | The report type to run |
| days | integer | optional | Number of days to look back (default 30, max 365) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/google_analytics" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"report": "example",
"days": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.google_analytics({
"report": "example",
"days": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->googleAnalytics([
'report' => 'example',
'days' => 10,
]);
Response
- scopestring
- propertystring
- property_idstring
- reportstring
- daysinteger
- resultsstring
POSTsearch_console analytics:read Query Google Search Console data for the platform (dabdash.com) or a specific tenant with a connected GSC integration.
Parameters
The report type to run
Number of days to look back (default 30, max 365)
| Name | Type | Required | Description |
|---|---|---|---|
| report | string | required | The report type to run |
| days | integer | optional | Number of days to look back (default 30, max 365) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/search_console" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"report": "example",
"days": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.search_console({
"report": "example",
"days": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->searchConsole([
'report' => 'example',
'days' => 10,
]);
Response
- scopestring
- site_urlstring
- reportstring
- daysinteger
- resultsstring
POSTproduct_profitability analytics:read Rank a tenant's products by real net margin using order-line COGS.
Parameters
Start date YYYY-MM-DD (default: 90 days ago in tenant TZ).
End date YYYY-MM-DD (default: today in tenant TZ).
"margin" (default), "revenue", or "units".
Max products to return (default 20, max 50).
Threshold for promo_headroom_ok (default 25).
When true, drop out-of-stock catalog products (default false).
When true (default), only lines with cost_price > 0 are ranked.
| Name | Type | Required | Description |
|---|---|---|---|
| date_from | string | optional | Start date YYYY-MM-DD (default: 90 days ago in tenant TZ). |
| date_to | string | optional | End date YYYY-MM-DD (default: today in tenant TZ). |
| sort | string | optional | "margin" (default), "revenue", or "units". |
| limit | integer | optional | Max products to return (default 20, max 50). |
| min_margin_percent | number | optional | Threshold for promo_headroom_ok (default 25). |
| only_in_stock | boolean | optional | When true, drop out-of-stock catalog products (default false). |
| require_cost | boolean | optional | When true (default), only lines with cost_price > 0 are ranked. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/product_profitability" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"date_from": "example",
"date_to": "example",
"sort": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.product_profitability({
"date_from": "example",
"date_to": "example",
"sort": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->productProfitability([
'date_from' => 'example',
'date_to' => 'example',
'sort' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- periodobject
- fromstring
- tostring
- summaryobject
- products_rankedinteger
- products_with_costinteger
- promo_headroom_countinteger
- min_margin_percentnumber
- productsarray
- product_idinteger
- namestring
- slugstring
- units_soldinteger
- revenue_centsinteger
- cogs_centsinteger
- margin_centsinteger
- margin_percentnumber
- stock_statusstring
- is_featuredboolean
- promo_headroom_okboolean
- has_cost_databoolean
Marketing
marketing 25 endpoints · 6 read · 19 writeCreate campaigns and configure abandoned-cart recovery.
POSTcampaign_audience_inspect marketing:read Split the tenant's campaign audience into warm (≥1 past order) vs cold (no order history).
Parameters
Contact list IDs to scope the split. Omit or pass [] to use all subscribed contacts + customers.
Include store customers in the audience. Defaults to true.
"email" or "sms". Defaults to email.
| Name | Type | Required | Description |
|---|---|---|---|
| contact_list_ids | array | optional | Contact list IDs to scope the split. Omit or pass [] to use all subscribed contacts + customers. |
| include_customers | boolean | optional | Include store customers in the audience. Defaults to true. |
| channel | string | optional | "email" or "sms". Defaults to email. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_audience_inspect" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"contact_list_ids": [],
"include_customers": true,
"channel": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_audience_inspect({
"contact_list_ids": [],
"include_customers": true,
"channel": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignAudienceInspect([
'contact_list_ids' => [],
'include_customers' => true,
'channel' => 'example',
]);
Response
- tenantobject
- idinteger
- slugstring
- channelstring
- include_customersboolean
- warminteger
- coldinteger
- guidancestring
POSTcampaign_link_audit marketing:read Audit every href in a draft campaign's HTML against the tenant catalog.
Parameters
Draft/campaign id to audit. Required unless html_body is passed.
Optional HTML override (e.g. a body you are about to upsert).
When true, HEAD/GET each absolute storefront URL (default false).
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | optional | Draft/campaign id to audit. Required unless html_body is passed. |
| html_body | string | optional | Optional HTML override (e.g. a body you are about to upsert). |
| check_http | boolean | optional | When true, HEAD/GET each absolute storefront URL (default false). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_link_audit" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"html_body": "example",
"check_http": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_link_audit({
"campaign_id": 10,
"html_body": "example",
"check_http": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignLinkAudit([
'campaign_id' => 10,
'html_body' => 'example',
'check_http' => true,
]);
Response
- campaign_idinteger
- tenantobject
- idinteger
- slugstring
- summaryobject
- links_totalinteger
- product_linksinteger
- category_linksinteger
- blocking_countinteger
- warning_countinteger
- linksarray
- blocking_issuesarray
- warningsarray
- ok_to_sendboolean
- messagestring
POSTcampaign_spam_score marketing:read Score vendor campaign copy for inbox risk (email HTML or SMS).
Parameters
Load content from this campaign. Omit to score inline subject/html_body or sms_body.
"email" or "sms". Required when scoring inline content without campaign_id.
Email subject (inline mode).
Email HTML body (inline mode).
SMS body (inline mode).
If true, fold the send-time deep check into the same 0–100 score (email only). Default false (live rules).
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | optional | Load content from this campaign. Omit to score inline subject/html_body or sms_body. |
| channel | string | optional | "email" or "sms". Required when scoring inline content without campaign_id. |
| subject | string | optional | Email subject (inline mode). |
| html_body | string | optional | Email HTML body (inline mode). |
| sms_body | string | optional | SMS body (inline mode). |
| for_send | boolean | optional | If true, fold the send-time deep check into the same 0–100 score (email only). Default false (live rules). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_spam_score" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"channel": "example",
"subject": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_spam_score({
"campaign_id": 10,
"channel": "example",
"subject": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignSpamScore([
'campaign_id' => 10,
'channel' => 'example',
'subject' => 'example',
]);
Response
- scoreinteger
- bandstring
- channelstring
- summarystring
- versionstring
- findingsarray
- codestring
- severitystring
- penaltyinteger
- messagestring
- hintstring
- evidencestring
- can_sendboolean
- min_send_scoreinteger
- deep_check_appliedboolean
- spamassassin_scorenumber
- deep_check_rulesarray
- namestring
- scorenumber
- descriptionstring
- deep_check_errorstring
- campaign_idinteger
- messagestring
POSTcampaign_preview_image marketing:read Render a draft email campaign as a PNG screenshot so you (and the vendor) can.
Parameters
Campaign whose stored html_body to screenshot. Omit when passing html_body inline.
Inline email HTML to screenshot (unsaved markup). Ignored when campaign_id is set.
"desktop" (default, 600px) or "mobile" (390px).
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | optional | Campaign whose stored html_body to screenshot. Omit when passing html_body inline. |
| html_body | string | optional | Inline email HTML to screenshot (unsaved markup). Ignored when campaign_id is set. |
| viewport | string | optional | "desktop" (default, 600px) or "mobile" (390px). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_preview_image" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"html_body": "example",
"viewport": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_preview_image({
"campaign_id": 10,
"html_body": "example",
"viewport": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignPreviewImage([
'campaign_id' => 10,
'html_body' => 'example',
'viewport' => 'example',
]);
Response
- campaign_idinteger
- viewportstring
- widthinteger
- media_idinteger
- image_urlstring
- vision_availableboolean
- vision_reviewstring
- messagestring
POSTcampaign_get marketing:read Read a campaign back, including the message body you are about to edit.
Parameters
ID of the campaign to read.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the campaign to read. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_get" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_get({
"campaign_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignGet([
'campaign_id' => 10,
]);
Response
- campaign_idinteger
- namestring
- channelstring
- subjectstring
- fallback_first_namestring
- modestring
- statusstring
- audience_includes_customersboolean
- mailgun_domain_idsarray
- mailgun_pacestring
- contact_listsarray
- idinteger
- namestring
- kindstring
- default_typestring
- saved_webhook_idinteger
- webhook_urlstring
- webhook_health_urlstring
- throttle_per_minuteinteger
- throttle_per_hourinteger
- send_interval_minutesinteger
- send_window_enabledboolean
- send_window_frominteger
- send_window_tointeger
- send_window_daysarray
- html_bodystring
- html_body_lengthinteger
- plain_bodystring
- sms_bodystring
- sms_body_lengthinteger
- messagestring
POSTcampaign_list marketing:read List recent vendor email/SMS campaigns for a tenant so you can find campaign_id.
Parameters
Optional status filter: draft, scheduled, sending, paused, recovering, completed, cancelled, failed.
Optional "email" or "sms".
Optional name/subject search (case-insensitive substring).
Max rows (default 25, max 100).
| Name | Type | Required | Description |
|---|---|---|---|
| status | string | optional | Optional status filter: draft, scheduled, sending, paused, recovering, completed, cancelled, failed. |
| channel | string | optional | Optional "email" or "sms". |
| q | string | optional | Optional name/subject search (case-insensitive substring). |
| limit | integer | optional | Max rows (default 25, max 100). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_list" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"status": "example",
"channel": "example",
"q": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_list({
"status": "example",
"channel": "example",
"q": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignList([
'status' => 'example',
'channel' => 'example',
'q' => 'example',
]);
Response
- countinteger
- campaignsarray
- campaign_idinteger
- namestring
- channelstring
- subjectstring
- modestring
- statusstring
- audience_includes_customersboolean
- contact_list_countinteger
- mailgun_pacestring
- updated_atstring
- messagestring
POSTabandoned_cart_recovery_manage marketing:write Show or configure one-time abandoned-cart recovery emails for a tenant.
Parameters
"show" (default) or "set".
Enable or disable abandoned-cart recovery emails.
Hours a cart must remain idle before recovery email (1–168; defaults to 24).
Defaults to true for set; pass false to apply.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| enabled | boolean | optional | Enable or disable abandoned-cart recovery emails. |
| delay_hours | integer | optional | Hours a cart must remain idle before recovery email (1–168; defaults to 24). |
| dry_run | boolean | optional | Defaults to true for set; pass false to apply. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/abandoned_cart_recovery_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"enabled": true,
"delay_hours": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.abandoned_cart_recovery_manage({
"action": "example",
"enabled": true,
"delay_hours": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->abandonedCartRecoveryManage([
'action' => 'example',
'enabled' => true,
'delay_hours' => 10,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- recoveryobject
- enabledboolean
- delay_hoursinteger
- requires_complete_tenant_smtpboolean
- sends_immediatelyboolean
POSTnotification_settings_manage marketing:write Show or configure tenant-wide vendor order, low-stock, digest, restock, and.
Parameters
"show" (default) or "set".
24-hour HH:MM.
1–180 days.
Contact form and enquiry email together. Off hides the storefront contact form and stops the email.
Defaults to true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| notify_new_order | boolean | optional | |
| notify_new_order_push | boolean | optional | |
| notify_low_stock | boolean | optional | |
| notify_low_stock_push | boolean | optional | |
| notify_low_stock_digest | boolean | optional | |
| low_stock_digest_time | string | optional | 24-hour HH:MM. |
| low_stock_sold_window_days | integer | optional | 1–180 days. |
| notify_restock_request | boolean | optional | |
| notify_new_enquiry | boolean | optional | Contact form and enquiry email together. Off hides the storefront contact form and stops the email. |
| dry_run | boolean | optional | Defaults to true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/notification_settings_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"notify_new_order": true,
"notify_new_order_push": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.notification_settings_manage({
"action": "example",
"notify_new_order": true,
"notify_new_order_push": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->notificationSettingsManage([
'action' => 'example',
'notify_new_order' => true,
'notify_new_order_push' => true,
]);
POSTreviews_manage marketing:write Show or configure verified-purchase product reviews for a tenant, and preview or.
Parameters
"show" (default), "set", "hide", or "unhide".
Allow verified customers to submit product reviews.
Product review ID for hide or unhide.
Defaults to true for set, hide, and unhide; pass false to apply.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default), "set", "hide", or "unhide". |
| enabled | boolean | optional | Allow verified customers to submit product reviews. |
| review_id | integer | optional | Product review ID for hide or unhide. |
| dry_run | boolean | optional | Defaults to true for set, hide, and unhide; pass false to apply. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/reviews_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"enabled": true,
"review_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.reviews_manage({
"action": "example",
"enabled": true,
"review_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->reviewsManage([
'action' => 'example',
'enabled' => true,
'review_id' => 10,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- reviewsobject
- enabledboolean
- totalinteger
- visibleinteger
- hiddeninteger
- reviewobject
POSTcampaign_upsert marketing:write Create or edit a vendor email/SMS campaign (vendor → their customers; NOT platform drip-to-leads).
Parameters
ID of an existing campaign to edit. Omit to create a new draft.
Internal campaign name (max 120 chars). Required when creating.
"email" (default) or "sms" (text blast). Only set on create.
Email subject line shown to recipients (max 200 chars). Required when creating an email campaign.
Stand-in when {{first_name}} is blank (max 80). Empty string clears. Omit on update to keep.
Full email HTML. Sanitized on save. Use {{unsubscribe_url}}, {{first_name}}, {{last_name}} tokens.
Text message body for SMS campaigns (max 1600 chars). Required when creating a text campaign.
Optional plain-text alternative. Auto-derived from the HTML at send time if omitted.
"smtp" (default), "webhook", or "mailgun" (HTTP API with domain rotation). Left unchanged on update unless passed.
When mode is mailgun: Ready tenant_mailgun_domains ids to round-robin. Required when setting mode=mailgun.
Whether to include the tenant's customers in the audience. Defaults to true on create.
Manual or Smart List ids to attach. Pass [] to clear. Omit to leave unchanged on update.
When mode is mailgun: "drip" (default) or "blast".
When mode is webhook: saved TenantWebhook id. Prefer this over inline webhook_url.
Inline webhook URL when mode=webhook and no saved_webhook_id.
Optional HTTPS health-check URL for webhook mode.
Custom headers for inline webhook mode (max 20).
Optional send throttle cap per minute.
Optional send throttle cap per hour.
Minutes between individual sends (1–30).
Restrict sends to a daily window.
Send window start hour 0–23 (tenant timezone).
Send window end hour 0–23 (tenant timezone).
ISO weekdays 1–7 when send_window_enabled.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | optional | ID of an existing campaign to edit. Omit to create a new draft. |
| name | string | optional | Internal campaign name (max 120 chars). Required when creating. |
| channel | string | optional | "email" (default) or "sms" (text blast). Only set on create. |
| subject | string | optional | Email subject line shown to recipients (max 200 chars). Required when creating an email campaign. |
| fallback_first_name | string | optional | Stand-in when {{first_name}} is blank (max 80). Empty string clears. Omit on update to keep. |
| html_body | string | optional | Full email HTML. Sanitized on save. Use {{unsubscribe_url}}, {{first_name}}, {{last_name}} tokens. |
| sms_body | string | optional | Text message body for SMS campaigns (max 1600 chars). Required when creating a text campaign. |
| plain_body | string | optional | Optional plain-text alternative. Auto-derived from the HTML at send time if omitted. |
| mode | string | optional | "smtp" (default), "webhook", or "mailgun" (HTTP API with domain rotation). Left unchanged on update unless passed. |
| mailgun_domain_ids | array | optional | When mode is mailgun: Ready tenant_mailgun_domains ids to round-robin. Required when setting mode=mailgun. |
| audience_includes_customers | boolean | optional | Whether to include the tenant's customers in the audience. Defaults to true on create. |
| contact_list_ids | array | optional | Manual or Smart List ids to attach. Pass [] to clear. Omit to leave unchanged on update. |
| mailgun_pace | string | optional | When mode is mailgun: "drip" (default) or "blast". |
| saved_webhook_id | integer | optional | When mode is webhook: saved TenantWebhook id. Prefer this over inline webhook_url. |
| webhook_url | string | optional | Inline webhook URL when mode=webhook and no saved_webhook_id. |
| webhook_health_url | string | optional | Optional HTTPS health-check URL for webhook mode. |
| webhook_headers | array | optional | Custom headers for inline webhook mode (max 20). |
| throttle_per_minute | integer | optional | Optional send throttle cap per minute. |
| throttle_per_hour | integer | optional | Optional send throttle cap per hour. |
| send_interval_minutes | integer | optional | Minutes between individual sends (1–30). |
| send_window_enabled | boolean | optional | Restrict sends to a daily window. |
| send_window_from | integer | optional | Send window start hour 0–23 (tenant timezone). |
| send_window_to | integer | optional | Send window end hour 0–23 (tenant timezone). |
| send_window_days | array | optional | ISO weekdays 1–7 when send_window_enabled. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"name": "example",
"channel": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_upsert({
"campaign_id": 10,
"name": "example",
"channel": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignUpsert([
'campaign_id' => 10,
'name' => 'example',
'channel' => 'example',
]);
Response
- actionstring
- campaign_idinteger
- namestring
- channelstring
- subjectstring
- fallback_first_namestring
- modestring
- statusstring
- audience_includes_customersboolean
- mailgun_domain_idsarray
- mailgun_pacestring
- contact_listsarray
- idinteger
- namestring
- kindstring
- default_typestring
- saved_webhook_idinteger
- webhook_urlstring
- throttle_per_minuteinteger
- throttle_per_hourinteger
- send_interval_minutesinteger
- send_window_enabledboolean
- messagestring
- webhook_signing_secretstring
- sms_body_lengthinteger
- html_body_lengthinteger
- has_unsubscribe_tokenboolean
- spam_scoreinteger
- spam_bandstring
- spam_summarystring
- spam_can_sendboolean
- spam_min_send_scoreinteger
- spam_findingsarray
- codestring
- severitystring
- penaltyinteger
- messagestring
- hintstring
- evidencestring
POSTcampaign_apply_template marketing:write Apply a built-in system email template to a DRAFT campaign, replacing its html_body with the.
Parameters
ID of the DRAFT campaign to apply the template to.
System template id (e.g. "summer-new-arrivals"). Omit with use_month_default=true to apply this month's calendar default.
When true and template_id is omitted, applies the month_calendar default for month (or the current month in the tenant timezone).
Calendar month 1-12 for month_calendar lookup when use_month_default is true. Defaults to the current month.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the DRAFT campaign to apply the template to. |
| template_id | string | optional | System template id (e.g. "summer-new-arrivals"). Omit with use_month_default=true to apply this month's calendar default. |
| use_month_default | boolean | optional | When true and template_id is omitted, applies the month_calendar default for month (or the current month in the tenant timezone). |
| month | integer | optional | Calendar month 1-12 for month_calendar lookup when use_month_default is true. Defaults to the current month. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_apply_template" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"template_id": "example",
"use_month_default": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_apply_template({
"campaign_id": 10,
"template_id": "example",
"use_month_default": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignApplyTemplate([
'campaign_id' => 10,
'template_id' => 'example',
'use_month_default' => true,
]);
Response
- errorstring
- available_templatesarray
- idstring
- namestring
- descriptionstring
- actionstring
- campaign_idinteger
- template_idstring
- use_month_defaultboolean
- monthinteger
- themestring
- archetypestring
- html_body_lengthinteger
- has_unsubscribe_tokenboolean
- messagestring
POSTcampaign_generate_flyer marketing:write Generate BESPOKE flyer artwork for a campaign from the shop's own product photos, then drop it.
Parameters
What the flyer is for, in plain words. E.g. "September restock — cosy autumn mood, warm light".
Product IDs to feature. Their photos anchor the artwork. Omit to auto-pick the newest featured products that have images.
DRAFT campaign to place the artwork into. Omit to only add it to the media library.
1-based image slot to fill. Defaults to 1, the hero slot.
Shape of the artwork: "4:3" (default, email banner), "1:1", "16:9", "3:4". Anything else falls back to the default.
Alt text for the placed image. Defaults to the theme.
Media library ids of images to use as one-off style/composition references for THIS generation (e.g. a past flyer the vendor just attached to this chat — its media_id is noted right after the attachment). Max 3. Not persisted; use campaign_flyer_style_pack for a look that should repeat.
| Name | Type | Required | Description |
|---|---|---|---|
| theme | string | required | What the flyer is for, in plain words. E.g. "September restock — cosy autumn mood, warm light". |
| product_ids | array | optional | Product IDs to feature. Their photos anchor the artwork. Omit to auto-pick the newest featured products that have images. |
| campaign_id | integer | optional | DRAFT campaign to place the artwork into. Omit to only add it to the media library. |
| slot_index | integer | optional | 1-based image slot to fill. Defaults to 1, the hero slot. |
| aspect_ratio | string | optional | Shape of the artwork: "4:3" (default, email banner), "1:1", "16:9", "3:4". Anything else falls back to the default. |
| alt_text | string | optional | Alt text for the placed image. Defaults to the theme. |
| reference_media_ids | array | optional | Media library ids of images to use as one-off style/composition references for THIS generation (e.g. a past flyer the vendor just attached to this chat — its media_id is noted right after the attachment). Max 3. Not persisted; use campaign_flyer_style_pack for a look that should repeat. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_generate_flyer" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"theme": "example",
"product_ids": [],
"campaign_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_generate_flyer({
"theme": "example",
"product_ids": [],
"campaign_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignGenerateFlyer([
'theme' => 'example',
'product_ids' => [],
'campaign_id' => 10,
]);
Response
- actionstring
- media_idinteger
- image_urlstring
- campaign_idinteger
- placedboolean
- filled_placeholderboolean
- remaining_slotsinteger
- featured_productsarray
- messagestring
POSTcampaign_flyer_style_pack marketing:write Teach campaign_generate_flyer what this shop's flyers look like, using their OWN past work.
Parameters
"show" (default behaviour), "set", or "clear".
set: a short name for the pack, e.g. "Past in-house flyers".
set: the art direction, one short line each. Replaces what is saved.
set: media library ids to use as style references. They move into the style-reference folder.
clear: also take the images out of the style-reference folder. They stay in the library.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | required | "show" (default behaviour), "set", or "clear". |
| label | string | optional | set: a short name for the pack, e.g. "Past in-house flyers". |
| prompt_lines | array | optional | set: the art direction, one short line each. Replaces what is saved. |
| media_ids | array | optional | set: media library ids to use as style references. They move into the style-reference folder. |
| clear_images | boolean | optional | clear: also take the images out of the style-reference folder. They stay in the library. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_flyer_style_pack" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"label": "example",
"prompt_lines": []
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_flyer_style_pack({
"action": "example",
"label": "example",
"prompt_lines": []
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignFlyerStylePack([
'action' => 'example',
'label' => 'example',
'prompt_lines' => [],
]);
Response
- actionstring
- tenant_slugstring
- enabledboolean
- labelstring
- prompt_linesarray
- imagesarray
- images_used_per_flyerinteger
- messagestring
POSTcampaign_set_image marketing:write Drop an image from the tenant's media library into a DRAFT campaign — no link copying, no manual.
Parameters
ID of the DRAFT campaign to place the image into.
ID of a public image in the tenant's media library to insert.
1-based placeholder to fill when the body has more than one. Defaults to the first.
Override alt text. Defaults to the media asset's own alt text, then the campaign name.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the DRAFT campaign to place the image into. |
| media_id | integer | required | ID of a public image in the tenant's media library to insert. |
| slot_index | integer | optional | 1-based placeholder to fill when the body has more than one. Defaults to the first. |
| alt_text | string | optional | Override alt text. Defaults to the media asset's own alt text, then the campaign name. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_set_image" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"media_id": 10,
"slot_index": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_set_image({
"campaign_id": 10,
"media_id": 10,
"slot_index": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignSetImage([
'campaign_id' => 10,
'media_id' => 10,
'slot_index' => 10,
]);
Response
- actionstring
- campaign_idinteger
- media_idinteger
- image_urlstring
- filled_placeholderboolean
- appendedboolean
- image_in_bodyboolean
- messagestring
POSTcampaign_send_test marketing:write Send a single test copy of a campaign so the design and copy can be reviewed before the real send.
Parameters
ID of the campaign to send a test copy of.
Email address for an email campaign test copy.
Phone number for a text campaign test copy (E.164 or local format).
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the campaign to send a test copy of. |
| to_email | string | optional | Email address for an email campaign test copy. |
| to_phone | string | optional | Phone number for a text campaign test copy (E.164 or local format). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_send_test" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"to_email": "example",
"to_phone": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_send_test({
"campaign_id": 10,
"to_email": "example",
"to_phone": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignSendTest([
'campaign_id' => 10,
'to_email' => 'example',
'to_phone' => 'example',
]);
Response
- actionstring
- channelstring
- campaign_idinteger
- sent_tostring
- messagestring
POSTcampaign_launch marketing:write Start, schedule, or cancel a vendor campaign after it is ready.
Parameters
Campaign id.
"send_now", "schedule", or "cancel".
Required for schedule: local datetime in the store timezone (e.g. "2026-11-10 09:00").
Default true.
Must be true to apply (with dry_run=false).
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | Campaign id. |
| action | string | required | "send_now", "schedule", or "cancel". |
| scheduled_at | string | optional | Required for schedule: local datetime in the store timezone (e.g. "2026-11-10 09:00"). |
| dry_run | boolean | optional | Default true. |
| confirm | boolean | optional | Must be true to apply (with dry_run=false). |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_launch" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"action": "example",
"scheduled_at": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_launch({
"campaign_id": 10,
"action": "example",
"scheduled_at": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignLaunch([
'campaign_id' => 10,
'action' => 'example',
'scheduled_at' => 'example',
]);
Response
- actionstring
- dry_runboolean
- campaign_idinteger
- statusstring
- scheduled_atstring
- messagestring
POSTcampaign_recipients_requeue marketing:write Unstick a vendor email/SMS campaign that auto-paused or stalled mid-send.
Parameters
ID of the campaign to unstick.
Reset failed recipients to pending. Default true.
Reset stuck status=sending recipients to pending. Default true.
Retry recipients listed in the campaign sending error log (retryable types only). Default false.
Max immediate send jobs when retry_sending_log_errors=true (default 200, max 500).
If true (default), report counts without writing. Pass false to apply.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the campaign to unstick. |
| include_failed | boolean | optional | Reset failed recipients to pending. Default true. |
| reset_stale_sending | boolean | optional | Reset stuck status=sending recipients to pending. Default true. |
| retry_sending_log_errors | boolean | optional | Retry recipients listed in the campaign sending error log (retryable types only). Default false. |
| dispatch_limit | integer | optional | Max immediate send jobs when retry_sending_log_errors=true (default 200, max 500). |
| dry_run | boolean | optional | If true (default), report counts without writing. Pass false to apply. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_recipients_requeue" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"include_failed": true,
"reset_stale_sending": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_recipients_requeue({
"campaign_id": 10,
"include_failed": true,
"reset_stale_sending": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignRecipientsRequeue([
'campaign_id' => 10,
'include_failed' => true,
'reset_stale_sending' => true,
]);
Response
- actionstring
- dry_runboolean
- tenant_slugstring
- campaign_idinteger
- campaign_namestring
- previous_statusstring
- statusstring
- pending_beforeinteger
- failed_beforeinteger
- sending_beforeinteger
- failed_requeuedinteger
- sending_resetinteger
- pending_afterinteger
- failed_afterinteger
- sending_log_error_rowsinteger
- sending_log_recipients_matchedinteger
- sending_log_recipients_resetinteger
- sending_log_jobs_dispatchedinteger
- messagestring
POSTcampaign_control marketing:write Pause or resume a vendor email/SMS campaign.
Parameters
ID of the campaign to pause or resume.
"pause" or "resume".
If true (default), report without writing. Pass false to apply.
| Name | Type | Required | Description |
|---|---|---|---|
| campaign_id | integer | required | ID of the campaign to pause or resume. |
| action | string | required | "pause" or "resume". |
| dry_run | boolean | optional | If true (default), report without writing. Pass false to apply. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/campaign_control" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"campaign_id": 10,
"action": "example",
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.campaign_control({
"campaign_id": 10,
"action": "example",
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->campaignControl([
'campaign_id' => 10,
'action' => 'example',
'dry_run' => true,
]);
Response
- actionstring
- dry_runboolean
- tenant_slugstring
- campaign_idinteger
- campaign_namestring
- previous_statusstring
- statusstring
- messagestring
POSTcontact_list_manage marketing:write Discover and manage contact lists (manual + Smart) for campaigns, coupons, and Klaviyo.
Parameters
"list", "show", "create_manual", "rename", or "delete".
Required for show/rename/delete.
Required for create_manual; optional for rename.
Optional description.
"lead" or "customer" (manual lists).
Optional filter for list: "manual" or "smart".
Default true for delete.
Required true to delete.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list", "show", "create_manual", "rename", or "delete". |
| list_id | integer | optional | Required for show/rename/delete. |
| name | string | optional | Required for create_manual; optional for rename. |
| description | string | optional | Optional description. |
| default_type | string | optional | "lead" or "customer" (manual lists). |
| kind | string | optional | Optional filter for list: "manual" or "smart". |
| dry_run | boolean | optional | Default true for delete. |
| confirm | boolean | optional | Required true to delete. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/contact_list_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"list_id": 10,
"name": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.contact_list_manage({
"action": "example",
"list_id": 10,
"name": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->contactListManage([
'action' => 'example',
'list_id' => 10,
'name' => 'example',
]);
Response
- actionstring
- listsarray
- listobject
- dry_runboolean
- messagestring
POSTsmart_list_manage marketing:write Create, edit, preview, or delete Smart Lists (dynamic customer audiences).
Parameters
"list", "show", "upsert", "preview", or "delete".
Existing Smart List id for show/update/delete/preview.
Required for upsert create/update.
SmartListDefinition v1 object.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "list", "show", "upsert", "preview", or "delete". |
| list_id | integer | optional | Existing Smart List id for show/update/delete/preview. |
| name | string | optional | Required for upsert create/update. |
| description | string | optional | |
| definition | object | optional | SmartListDefinition v1 object. |
| dry_run | boolean | optional | |
| confirm | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/smart_list_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"list_id": 10,
"name": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.smart_list_manage({
"action": "example",
"list_id": 10,
"name": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->smartListManage([
'action' => 'example',
'list_id' => 10,
'name' => 'example',
]);
Response
- actionstring
- listsarray
- listobject
- previewobject
- dry_runboolean
- messagestring
POSTsuppression_manage marketing:write Inspect or lift email suppressions / campaign unsubscribes for a tenant.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | |
| string | optional | ||
| limit | integer | optional | |
| dry_run | boolean | optional | |
| confirm | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/suppression_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"email": "example",
"limit": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.suppression_manage({
"action": "example",
"email": "example",
"limit": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->suppressionManage([
'action' => 'example',
'email' => 'example',
'limit' => 10,
]);
Response
- actionstring
- customersarray
- contactsarray
- affectedinteger
- dry_runboolean
- messagestring
POSTseo_max_image_manage marketing:write Manage the SEO Max product-image rollout without Artisan commands or seed data.
Parameters
status, configure, backfill, or submit.
Backfill batch size, 1-100 (default 25).
Resume after this product ID.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | status, configure, backfill, or submit. |
| avif_enabled | boolean | optional | |
| image_sitemap_enabled | boolean | optional | |
| limit | integer | optional | Backfill batch size, 1-100 (default 25). |
| after_id | integer | optional | Resume after this product ID. |
| dry_run | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/seo_max_image_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"avif_enabled": true,
"image_sitemap_enabled": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.seo_max_image_manage({
"action": "example",
"avif_enabled": true,
"image_sitemap_enabled": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->seoMaxImageManage([
'action' => 'example',
'avif_enabled' => true,
'image_sitemap_enabled' => true,
]);
POSTseo_settings_manage marketing:write Show or update a tenant's standard SEO and SEO MAX settings.
Parameters
"show" (default) or "set".
Organization JSON-LD object.
Defaults to true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| home_title | string | optional | |
| home_description | string | optional | |
| home_keywords | array | optional | |
| product_title_template | string | optional | |
| product_description_template | string | optional | |
| category_title_template | string | optional | |
| blog_title_template | string | optional | |
| organization_schema | array | optional | Organization JSON-LD object. |
| sitemap_enabled | boolean | optional | |
| og_default_image | string | optional | |
| twitter_handle | string | optional | |
| seo_max_enabled | boolean | optional | |
| seo_max_keywords | array | optional | |
| seo_max_excluded_keywords | array | optional | |
| seo_max_voice | string | optional | |
| seo_max_location | string | optional | |
| seo_max_schedule_day | integer | optional | |
| seo_max_schedule_time | string | optional | |
| seo_max_frequency_days | integer | optional | |
| seo_max_auto_publish | boolean | optional | |
| seo_max_language | string | optional | |
| seo_max_avif_images_enabled | boolean | optional | |
| seo_max_image_sitemap_enabled | boolean | optional | |
| dry_run | boolean | optional | Defaults to true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/seo_settings_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"home_title": "example",
"home_description": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.seo_settings_manage({
"action": "example",
"home_title": "example",
"home_description": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->seoSettingsManage([
'action' => 'example',
'home_title' => 'example',
'home_description' => 'example',
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- seoobject
POSTblog_import marketing:write Create many blog posts (and the storefront's legal pages) in one call.
Parameters
Posts to create (max 50).
Update posts whose slug already exists. Default false.
Default true.
| Name | Type | Required | Description |
|---|---|---|---|
| posts | array | optional | Posts to create (max 50). |
| update_existing | boolean | optional | Update posts whose slug already exists. Default false. |
| dry_run | boolean | optional | Default true. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/blog_import" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"posts": [],
"update_existing": true,
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.blog_import({
"posts": [],
"update_existing": true,
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->blogImport([
'posts' => [],
'update_existing' => true,
'dry_run' => true,
]);
Response
- dry_runboolean
- summaryobject
- createdinteger
- updatedinteger
- skippedinteger
- images_failedinteger
- itemsarray
- slugstring
- titlestring
- statusstring
- idinteger
- notestring
POSTtenant_blog_upsert marketing:write Update an existing tenant (vendor) blog post's fields — title, excerpt, body,.
Parameters
Existing tenant blog post id. Provide this or slug.
Existing tenant blog post slug. Provide this or post_id.
Post title.
Short summary or teaser copy.
Full HTML body for the post.
Editorial category label, e.g. guides, news, tips, reviews.
Clear only: empty/null removes the featured image. http(s) URLs are refused — use media_id. Ignored when media_id is also given.
Tenant media library asset id (from media_list / media_upload) to use as the featured image. Required to set a photo.
SEO title tag text.
SEO meta description text.
Absolute URL for the Open Graph image.
Publish or unpublish the post.
Preview without writing. Defaults true.
| Name | Type | Required | Description |
|---|---|---|---|
| post_id | integer | optional | Existing tenant blog post id. Provide this or slug. |
| slug | string | optional | Existing tenant blog post slug. Provide this or post_id. |
| title | string | optional | Post title. |
| excerpt | string | optional | Short summary or teaser copy. |
| body | string | optional | Full HTML body for the post. |
| category | string | optional | Editorial category label, e.g. guides, news, tips, reviews. |
| featured_image | string | optional | Clear only: empty/null removes the featured image. http(s) URLs are refused — use media_id. Ignored when media_id is also given. |
| media_id | integer | optional | Tenant media library asset id (from media_list / media_upload) to use as the featured image. Required to set a photo. |
| meta_title | string | optional | SEO title tag text. |
| meta_description | string | optional | SEO meta description text. |
| og_image | string | optional | Absolute URL for the Open Graph image. |
| is_published | boolean | optional | Publish or unpublish the post. |
| dry_run | boolean | optional | Preview without writing. Defaults true. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_blog_upsert" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"post_id": 10,
"slug": "example",
"title": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_blog_upsert({
"post_id": 10,
"slug": "example",
"title": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantBlogUpsert([
'post_id' => 10,
'slug' => 'example',
'title' => 'example',
]);
Integrations
integrations 12 endpoints · 3 read · 9 writeConfigure storefront appearance and manage connected third-party systems.
POSTcustomer_block_status integrations:read Read a customer's normalized email/phone block status within one tenant.
Parameters
Exact customer ID from customer_lookup; never guess from a name
| Name | Type | Required | Description |
|---|---|---|---|
| customer_id | integer | required | Exact customer ID from customer_lookup; never guess from a name |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_block_status" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_block_status({
"customer_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerBlockStatus([
'customer_id' => 10,
]);
Response
- tenant_slugstring
- customer_idinteger
- customer_namestring
- emailstring
- phonestring
- email_block_idinteger
- phone_block_idinteger
- email_block_reasonstring
- phone_block_reasonstring
- email_blockedboolean
- phone_blockedboolean
- snapshotstring
- scopestring
POSTpush_notification_diagnostics integrations:read Diagnose push notification (FCM) delivery for a vendor.
Parameters
Lookback window for notification history in hours (default 72, max 720)
Max recent notifications to return (default 50, max 200)
| Name | Type | Required | Description |
|---|---|---|---|
| hours | integer | optional | Lookback window for notification history in hours (default 72, max 720) |
| limit | integer | optional | Max recent notifications to return (default 50, max 200) |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/push_notification_diagnostics" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"hours": 10,
"limit": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.push_notification_diagnostics({
"hours": 10,
"limit": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->pushNotificationDiagnostics([
'hours' => 10,
'limit' => 10,
]);
Response
- tenantobject
- idinteger
- slugstring
- namestring
- is_activeboolean
- vendor_userobject
- idinteger
- namestring
- emailstring
- firebase_configobject
- configuredboolean
- credentials_sourcestring
- project_idstring
- statusstring
- token_healthstring
- notification_settingsobject
- notify_new_order_pushboolean
- notify_new_order_emailboolean
- notify_low_stockboolean
- notify_restock_requestboolean
- notestring
- recent_notificationsobject
- lookback_hoursinteger
- totalinteger
- push_sent_countinteger
- email_sent_countinteger
- neither_sent_countinteger
- push_rate_pctnumber
- by_typeobject
- entriesarray
- idinteger
- typestring
- titlestring
- push_sentboolean
- email_sentboolean
- is_readboolean
- read_atstring
- created_atstring
- diagnosisobject
- overall_statusstring
- blockersarray
- warningsarray
- summarystring
POSTmetrc_diagnostics integrations:read Returns a JSON summary of Metrc compliance status for a tenant: integration mode, sync states, audit log counts by HTTP status, and pending/failed report counts.
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/metrc_diagnostics" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.metrc_diagnostics({});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->metrcDiagnostics();
Response
- tenantobject
- idinteger
- slugstring
- namestring
- integrationstring
- sync_statesarray
- resourcestring
- last_run_atstring
- last_errorstring
- staleboolean
- audit_log_counts_by_http_statusobject
- report_counts_by_statusobject
- last_reconciliation_runobject
- run_atstring
- matched_countinteger
- drifted_countinteger
- notestring
POSTcustomer_block_manage integrations:write Block or unblock a customer's current email and/or phone using existing tenant Security lists.
Parameters
Exact customer ID from customer_lookup; never guess from a name
Default both. Select email or phone explicitly if the other is missing/invalid.
Audit reason, 1–255 characters
Default true: preview without changing any block
Must be true when applying an authorized mutation
Snapshot from customer_block_status or preview; required when dry_run=false
| Name | Type | Required | Description |
|---|---|---|---|
| customer_id | integer | required | Exact customer ID from customer_lookup; never guess from a name |
| action | string | required | |
| target | string | optional | Default both. Select email or phone explicitly if the other is missing/invalid. |
| reason | string | required | Audit reason, 1–255 characters |
| dry_run | boolean | optional | Default true: preview without changing any block |
| confirm | boolean | optional | Must be true when applying an authorized mutation |
| expected_snapshot | string | optional | Snapshot from customer_block_status or preview; required when dry_run=false |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/customer_block_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"customer_id": 10,
"action": "example",
"target": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.customer_block_manage({
"customer_id": 10,
"action": "example",
"target": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->customerBlockManage([
'customer_id' => 10,
'action' => 'example',
'target' => 'example',
]);
Response
- tenant_slugstring
- customer_idinteger
- customer_namestring
- emailstring
- phonestring
- email_block_idinteger
- phone_block_idinteger
- email_block_reasonstring
- phone_block_reasonstring
- email_blockedboolean
- phone_blockedboolean
- snapshotstring
- scopestring
- actionstring
- targetstring
- dry_runboolean
- changed_identifiersarray
POSTstorefront_theme_manage integrations:write Show or update Modern storefront theme data: hero copy, the optional hero.
Parameters
"show" (default) or "set".
WhatsApp number. Adds a Chat button. Leave empty to hide it.
Show email signup
Signup heading. Use | to colour the second part. Maximum 60 characters.
Signup text Maximum 140 characters.
Signup button Maximum 20 characters.
Show departments
Departments heading Maximum 60 characters.
Show service areas
Service areas heading Maximum 60 characters.
Show footer notes
Notes under the delivery areas. One per line. Update your hours, prices and service details here. Leave empty to hide. Maximum 60 characters.
Show this section
Small label Maximum 40 characters.
Heading Maximum 80 characters.
Text Maximum 240 characters.
Show this section
Small label Maximum 40 characters.
Heading. Use | to colour the second part. Maximum 60 characters.
Text Maximum 240 characters.
Show this banner
Small label Maximum 40 characters.
Heading Maximum 40 characters.
Amount. For example: 75 Maximum 12 characters.
Text after the amount Maximum 30 characters.
Tags. One per line. For example: $50 minimum. Maximum 30 characters.
Show this section
Small label Maximum 40 characters.
Heading. Use | to colour the second part. Maximum 60 characters.
Show this section
Small label Maximum 40 characters.
Heading Maximum 80 characters.
Intro text Maximum 400 characters.
Cards heading Maximum 60 characters.
Closing text. Two lines at most. The second one is bold. Maximum 320 characters.
Closing button. Links to your products. Maximum 30 characters.
Show this section
Small label Maximum 40 characters.
Heading Maximum 80 characters.
Replace About cards. Each card needs a title and body; up to 8.
Storefront theme: classic or modern.
Hero title. Use | to colour the second part.
Hero subtitle.
Hero description.
Hero primary button.
Legacy secondary hero button text.
Small line above the Modern hero title.
Modern secondary button text.
Modern secondary button link: https://… or a site path.
Optional hero product card: auto, product, or off.
Active product id to feature in the hero card.
Active product name or slug to feature. Ignored when an id is passed.
Hero card badge, up to 20 characters.
Hero card caption, up to 30 characters.
Hero card button, up to 24 characters.
Deals bar: auto, custom, or off.
Online or last-call pill: hours, auto, or off.
Custom deals-bar messages. Replaces the current list.
Defaults to true for set; pass false to apply.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| whatsapp_number | string | optional | WhatsApp number. Adds a Chat button. Leave empty to hide it. |
| footer_newsletter_enabled | boolean | optional | Show email signup |
| footer_newsletter_title | string | optional | Signup heading. Use | to colour the second part. Maximum 60 characters. |
| footer_newsletter_text | string | optional | Signup text Maximum 140 characters. |
| footer_newsletter_button | string | optional | Signup button Maximum 20 characters. |
| footer_show_departments | boolean | optional | Show departments |
| footer_departments_title | string | optional | Departments heading Maximum 60 characters. |
| footer_show_areas | boolean | optional | Show service areas |
| footer_areas_title | string | optional | Service areas heading Maximum 60 characters. |
| footer_show_notes | boolean | optional | Show footer notes |
| footer_notes | string | optional | Notes under the delivery areas. One per line. Update your hours, prices and service details here. Leave empty to hide. Maximum 60 characters. |
| show_home_widgets | boolean | optional | Show this section |
| home_widgets_eyebrow | string | optional | Small label Maximum 40 characters. |
| home_widgets_title | string | optional | Heading Maximum 80 characters. |
| home_widgets_text | string | optional | Text Maximum 240 characters. |
| show_home_gifts | boolean | optional | Show this section |
| home_gifts_eyebrow | string | optional | Small label Maximum 40 characters. |
| home_gifts_title | string | optional | Heading. Use | to colour the second part. Maximum 60 characters. |
| home_gifts_text | string | optional | Text Maximum 240 characters. |
| delivery_band_enabled | boolean | optional | Show this banner |
| delivery_band_kicker | string | optional | Small label Maximum 40 characters. |
| delivery_band_headline | string | optional | Heading Maximum 40 characters. |
| delivery_band_amount | string | optional | Amount. For example: 75 Maximum 12 characters. |
| delivery_band_note | string | optional | Text after the amount Maximum 30 characters. |
| delivery_band_pills | string | optional | Tags. One per line. For example: $50 minimum. Maximum 30 characters. |
| show_home_fresh | boolean | optional | Show this section |
| home_fresh_eyebrow | string | optional | Small label Maximum 40 characters. |
| home_fresh_title | string | optional | Heading. Use | to colour the second part. Maximum 60 characters. |
| show_home_about | boolean | optional | Show this section |
| about_eyebrow | string | optional | Small label Maximum 40 characters. |
| about_title | string | optional | Heading Maximum 80 characters. |
| about_lede | string | optional | Intro text Maximum 400 characters. |
| about_heading | string | optional | Cards heading Maximum 60 characters. |
| about_closer | string | optional | Closing text. Two lines at most. The second one is bold. Maximum 320 characters. |
| about_cta_label | string | optional | Closing button. Links to your products. Maximum 30 characters. |
| show_home_area | boolean | optional | Show this section |
| area_eyebrow | string | optional | Small label Maximum 40 characters. |
| area_title | string | optional | Heading Maximum 80 characters. |
| about_cards | array | optional | Replace About cards. Each card needs a title and body; up to 8. |
| storefront_theme | string | optional | Storefront theme: classic or modern. |
| hero_title | string | optional | Hero title. Use | to colour the second part. |
| hero_subtitle | string | optional | Hero subtitle. |
| hero_description | string | optional | Hero description. |
| hero_cta_text | string | optional | Hero primary button. |
| hero_cta_secondary | string | optional | Legacy secondary hero button text. |
| hero_eyebrow | string | optional | Small line above the Modern hero title. |
| hero_cta_secondary_label | string | optional | Modern secondary button text. |
| hero_cta_secondary_url | string | optional | Modern secondary button link: https://… or a site path. |
| hero_spotlight_mode | string | optional | Optional hero product card: auto, product, or off. |
| hero_spotlight_product_id | integer | optional | Active product id to feature in the hero card. |
| hero_spotlight_product | string | optional | Active product name or slug to feature. Ignored when an id is passed. |
| hero_spotlight_label | string | optional | Hero card badge, up to 20 characters. |
| hero_spotlight_kicker | string | optional | Hero card caption, up to 30 characters. |
| hero_spotlight_cta | string | optional | Hero card button, up to 24 characters. |
| hero_ticker_mode | string | optional | Deals bar: auto, custom, or off. |
| hero_status_mode | string | optional | Online or last-call pill: hours, auto, or off. |
| hero_ticker_items | array | optional | Custom deals-bar messages. Replaces the current list. |
| dry_run | boolean | optional | Defaults to true for set; pass false to apply. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/storefront_theme_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"whatsapp_number": "example",
"footer_newsletter_enabled": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.storefront_theme_manage({
"action": "example",
"whatsapp_number": "example",
"footer_newsletter_enabled": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->storefrontThemeManage([
'action' => 'example',
'whatsapp_number' => 'example',
'footer_newsletter_enabled' => true,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- theme_fieldsobject
- whatsapp_numberstring
- footer_newsletter_enabledboolean
- footer_newsletter_titlestring
- footer_newsletter_textstring
- footer_newsletter_buttonstring
- footer_show_departmentsboolean
- footer_departments_titlestring
- footer_show_areasboolean
- footer_areas_titlestring
- footer_show_notesboolean
- footer_notesstring
- show_home_widgetsboolean
- home_widgets_eyebrowstring
- home_widgets_titlestring
- home_widgets_textstring
- show_home_giftsboolean
- home_gifts_eyebrowstring
- home_gifts_titlestring
- home_gifts_textstring
- delivery_band_enabledboolean
- delivery_band_kickerstring
- delivery_band_headlinestring
- delivery_band_amountstring
- delivery_band_notestring
- delivery_band_pillsstring
- show_home_freshboolean
- home_fresh_eyebrowstring
- home_fresh_titlestring
- show_home_aboutboolean
- about_eyebrowstring
- about_titlestring
- about_ledestring
- about_headingstring
- about_closerstring
- about_cta_labelstring
- show_home_areaboolean
- area_eyebrowstring
- area_titlestring
- about_cardsarray
- titlestring
- bodystring
- iconstring
- heroobject
- storefront_themestring
- titlestring
- subtitlestring
- descriptionstring
- cta_textstring
- eyebrowstring
- cta_secondary_labelstring
- cta_secondary_urlstring
- spotlight_modestring
- spotlight_product_idinteger
- spotlight_product_namestring
- spotlight_product_slugstring
- spotlight_labelstring
- spotlight_kickerstring
- spotlight_ctastring
- ticker_modestring
- status_modestring
- ticker_itemsarray
- labelstring
- tagstring
- urlstring
POSTtenant_domain_manage integrations:write Show, connect, verify, or remove a store's custom domain (e.g.
Parameters
"show" (default), "set", "verify", or "remove".
Bare hostname for set, e.g. maritimesmoke.com.
Default true for set and remove.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default), "set", "verify", or "remove". |
| domain | string | optional | Bare hostname for set, e.g. maritimesmoke.com. |
| dry_run | boolean | optional | Default true for set and remove. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_domain_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"domain": "example",
"dry_run": true
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_domain_manage({
"action": "example",
"domain": "example",
"dry_run": true
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantDomainManage([
'action' => 'example',
'domain' => 'example',
'dry_run' => true,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- verified_nowboolean
- domainobject
- custom_domainstring
- verifiedboolean
- txt_record_namestring
- txt_record_valuestring
- default_urlstring
POSTtenant_smtp_manage integrations:write Show or update Advanced store SMTP (manual host/user/password).
Parameters
"show" (default) or "set".
SMTP hostname.
SMTP port; 25 is not allowed.
SMTP authentication username.
SMTP password; write-only and never returned.
SMTP encryption: tls or ssl.
RFC-valid sender address authorized by the provider.
Displayed sender name.
Optional. When false, hides Subscribe & Save upsell emails/UI for this tenant.
Default true for set.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| smtp_host | string | optional | SMTP hostname. |
| smtp_port | integer | optional | SMTP port; 25 is not allowed. |
| smtp_username | string | optional | SMTP authentication username. |
| smtp_password | string | optional | SMTP password; write-only and never returned. |
| smtp_encryption | string | optional | SMTP encryption: tls or ssl. |
| smtp_from_address | string | optional | RFC-valid sender address authorized by the provider. |
| smtp_from_name | string | optional | Displayed sender name. |
| subscription_upsell_enabled | boolean | optional | Optional. When false, hides Subscribe & Save upsell emails/UI for this tenant. |
| dry_run | boolean | optional | Default true for set. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_smtp_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"smtp_host": "example",
"smtp_port": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_smtp_manage({
"action": "example",
"smtp_host": "example",
"smtp_port": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantSmtpManage([
'action' => 'example',
'smtp_host' => 'example',
'smtp_port' => 10,
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- changesarray
- smtpobject
- hoststring
- portinteger
- usernamestring
- password_presentboolean
- encryptionstring
- from_addressstring
- from_namestring
POSTtenant_mailgun_manage integrations:write Show or manage a tenant's Mailgun Send Email setup (campaigns + hybrid SMTP).
Parameters
"show" (default), "connect", "disconnect", "sync", "add_domain", "verify_domain", "autoconfigure", or "bootstrap_smtp".
Mailgun private API key (connect only; write-only).
Mailgun region: us or eu. Defaults to us.
Sending name FQDN for add_domain / verify_domain / bootstrap_smtp.
Local tenant_mailgun_domains id for verify_domain / bootstrap_smtp.
When true, bootstrap_smtp overwrites complete non-Mailgun SMTP.
Default true for mutating actions.
Must be true when applying connect, disconnect, autoconfigure, or bootstrap_smtp with force_smtp.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default), "connect", "disconnect", "sync", "add_domain", "verify_domain", "autoconfigure", or "bootstrap_smtp". |
| api_key | string | optional | Mailgun private API key (connect only; write-only). |
| region | string | optional | Mailgun region: us or eu. Defaults to us. |
| domain | string | optional | Sending name FQDN for add_domain / verify_domain / bootstrap_smtp. |
| domain_id | integer | optional | Local tenant_mailgun_domains id for verify_domain / bootstrap_smtp. |
| force_smtp | boolean | optional | When true, bootstrap_smtp overwrites complete non-Mailgun SMTP. |
| dry_run | boolean | optional | Default true for mutating actions. |
| confirm | boolean | optional | Must be true when applying connect, disconnect, autoconfigure, or bootstrap_smtp with force_smtp. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_mailgun_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"api_key": "example",
"region": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_mailgun_manage({
"action": "example",
"api_key": "example",
"region": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantMailgunManage([
'action' => 'example',
'api_key' => 'example',
'region' => 'example',
]);
Response
- actionstring
- dry_runboolean
- appliedboolean
- setup_urlstring
- connectedboolean
- regionstring
- has_ready_domainboolean
- smtp_completeboolean
- domainsarray
- idinteger
- domainstring
- statusstring
- enabledboolean
- provision_sourcestring
- messagestring
- changesarray
POSTtenant_klaviyo_manage integrations:write Show or manage a tenant's BYO Klaviyo integration (profiles, list sync, Smart List.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | |
| api_key | string | optional | |
| default_list_id | string | optional | |
| mapped_contact_list_id | integer | optional | |
| smart_list_ids | array | optional | |
| smart_list_sync_enabled | boolean | optional | |
| dry_run | boolean | optional | |
| confirm | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_klaviyo_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"api_key": "example",
"default_list_id": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_klaviyo_manage({
"action": "example",
"api_key": "example",
"default_list_id": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantKlaviyoManage([
'action' => 'example',
'api_key' => 'example',
'default_list_id' => 'example',
]);
Response
- actionstring
- dry_runboolean
- connectedboolean
- settingsobject
- klaviyo_listsarray
- messagestring
POSTtenant_twilio_manage integrations:write Show or manage a tenant's Twilio SMS connection (required for text campaigns).
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | |
| account_sid | string | optional | |
| auth_token | string | optional | |
| from_number | string | optional | |
| messaging_service_sid | string | optional | |
| to_phone | string | optional | |
| dry_run | boolean | optional | |
| confirm | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_twilio_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"account_sid": "example",
"auth_token": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_twilio_manage({
"action": "example",
"account_sid": "example",
"auth_token": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantTwilioManage([
'action' => 'example',
'account_sid' => 'example',
'auth_token' => 'example',
]);
Response
- actionstring
- dry_runboolean
- connectedboolean
- from_numberstring
- messaging_service_sidstring
- sent_tostring
- messagestring
POSTwebhook_manage integrations:write List, create, update, or delete saved tenant webhooks (order events + campaign webhook mode).
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | |
| webhook_id | integer | optional | |
| label | string | optional | |
| url | string | optional | |
| health_url | string | optional | |
| events | array | optional | |
| is_active | boolean | optional | |
| custom_headers | array | optional | |
| dry_run | boolean | optional | |
| confirm | boolean | optional |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/webhook_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"webhook_id": 10,
"label": "example"
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.webhook_manage({
"action": "example",
"webhook_id": 10,
"label": "example"
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->webhookManage([
'action' => 'example',
'webhook_id' => 10,
'label' => 'example',
]);
Response
- actionstring
- webhooksarray
- webhookobject
- signing_secretstring
- dry_runboolean
- messagestring
POSTtenant_branding_manage integrations:write Show or update a tenant's store logo, homepage hero image, and BIMI email.
Parameters
"show" (default) or "set".
Library asset to use as the store logo. Required to change the logo.
Library asset to use as the homepage hero (settings.hero_image_path).
When true, remove the homepage hero. Mutually exclusive with hero_media_id.
Public http(s) URL of a BIMI SVG. Provide exactly one BIMI source.
Local file path of a BIMI SVG. Provide exactly one BIMI source.
Base64-encoded BIMI SVG bytes. Provide exactly one BIMI source.
If true (the default for set), report only and write nothing.
| Name | Type | Required | Description |
|---|---|---|---|
| action | string | optional | "show" (default) or "set". |
| media_id | integer | optional | Library asset to use as the store logo. Required to change the logo. |
| hero_media_id | integer | optional | Library asset to use as the homepage hero (settings.hero_image_path). |
| clear_hero | boolean | optional | When true, remove the homepage hero. Mutually exclusive with hero_media_id. |
| source_url | string | optional | Public http(s) URL of a BIMI SVG. Provide exactly one BIMI source. |
| source_path | string | optional | Local file path of a BIMI SVG. Provide exactly one BIMI source. |
| source_base64 | string | optional | Base64-encoded BIMI SVG bytes. Provide exactly one BIMI source. |
| dry_run | boolean | optional | If true (the default for set), report only and write nothing. |
curl -X POST "https://{your-store-slug}.dabdash.com/api/v1/tools/tenant_branding_manage" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"action": "example",
"media_id": 10,
"hero_media_id": 10
}'
import { DabDash } from '@shadow-software/dabdash-sdk';
const dabdash = new DabDash({ token: process.env.DABDASH_API_TOKEN });
const result = await dabdash.tools.tenant_branding_manage({
"action": "example",
"media_id": 10,
"hero_media_id": 10
});
use ShadowSoftware\DabDash\DabDashClient;
$dabdash = new DabDashClient(token: $_ENV['DABDASH_API_TOKEN']);
$result = $dabdash->tools()->tenantBrandingManage([
'action' => 'example',
'media_id' => 10,
'hero_media_id' => 10,
]);
Response
- actionstring
- dry_runboolean
- tenantobject
- idinteger
- slugstring
- storefront_urlstring
- logo_pathstring
- logo_urlstring
- hero_image_pathstring
- hero_image_urlstring
- bimi_logo_pathstring
- bimi_urlstring
- bimi_txtobject
- namestring
- typestring
- valuestring
- cloudflare_connectedboolean
- dns_updatedboolean
- would_set_logoboolean
- would_set_heroboolean
- would_clear_heroboolean
- would_set_bimiboolean
- messagestring
Errors
Every non-2xx response is JSON with an error code and a human-readable
message. Codes are consistent across every tool — read this once instead of per endpoint.
Missing, invalid, or expired bearer token for this store.
The store's subscription has lapsed with no active trial or grace period.
A read-only token was used to call a write tool.
The tool name in the URL doesn't match any available tool.
A required parameter was missing or malformed — see the response's errors object for which field.
The request was well-formed, but the tool itself rejected it (e.g. a business rule, or a record that doesn't exist).
Something went wrong on our end. The message is always generic — check the request id if you contact support.
| Status | error | Meaning |
|---|---|---|
| 401 | unauthenticated | Missing, invalid, or expired bearer token for this store. |
| 402 | subscription_required | The store's subscription has lapsed with no active trial or grace period. |
| 403 | forbidden | A read-only token was used to call a write tool. |
| 404 | tool_not_found | The tool name in the URL doesn't match any available tool. |
| 422 | validation_failed | A required parameter was missing or malformed — see the response's errors object for which field. |
| 422 | tool_error | The request was well-formed, but the tool itself rejected it (e.g. a business rule, or a record that doesn't exist). |
| 500 | internal_error | Something went wrong on our end. The message is always generic — check the request id if you contact support. |
