App. Docs
Sales Channel
Encapsulates a connection to a commerce platform (Shopify, Amazon, eBay, or Stockmate default). Stores settings and mappings, and links listings to variants for analytics and fulfilment.
Setup
- Navigate to Sales Channels and create a new channel of type Stockmate (manual).
- Give it a clear name (e.g. "Retail", "Wholesale", or "Pop-up Store").
- Adjust any channel-specific settings in channelData (tax, pricing rules, labels), and optionally define mappings used by automations.
- Activate the channel when you are ready to associate listings and transact.
Attributes
sales-channel.schema.ts
1type SalesChannel = {
2 // Unique identifier for the channel (per company)
3 id: string; // uuid
4
5 // Audit fields
6 modifiedAt?: Date;
7 modifiedById?: string; // uuid
8 modifiedByEmail?: string;
9 modifiedByEndpoint?: string;
10
11 // Company ownership
12 companyId: string; // uuid
13 company: Company; // reference
14
15 // Human-readable identifier
16 name: string;
17
18 // The provider/platform for this channel
19 type: "stockmate" | "shopify" | "amazon" | "ebay"; // ChannelType
20
21 // Whether the channel is active for listing/sync operations
22 isActive: boolean; // default: false
23
24 // Arbitrary provider-specific settings (app extensions, credentials, flags)
25 channelData?: Record<string, unknown>;
26
27 // Field mappings between external systems and Stockmate
28 mappings?: Record<string, unknown>;
29
30 // Listings that belong to this channel
31 listings: Listing[];
32}
Usage
Sales Channels are used to group listings by platform or context and to store provider-specific configuration. They power filtering for sales analytics and will be used by fulfilment flows to route orders and updates per connection.
Relationship to Listings
Each Listing belongs to exactly one Sales Channel via its salesChannel field. This lets you keep unique SKUs, barcodes, and prices per channel while sharing inventory at the variant level.