> ## Documentation Index
> Fetch the complete documentation index at: https://docs.subtotal.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Core Concepts

> Learn the core concepts behind how Subtotal works.

## OverviewSubtotal's platform is built around permissioned connections between shoppers, brands, and retailers.At its core, Subtotal helps brands connect with retail shoppers and access first-party purchase data that can be used to power loyalty, marketing, analytics, and more.This page introduces the key concepts that appear throughout the Subtotal platform and documentation.***## ConnectionsA **connection** represents the relationship between:- a shopper
- a retailer account
- and a brandConnections are created when a shopper successfully links a retailer account to a brand’s app or website using [Subtotal Link](https://docs.subtotal.com/docs/subtotal-link).***## PurchasesA **purchase** represents a transaction from a connected retailer account. Its status is `pending`, `shipped`, `ready_for_pickup`, `completed`, or `cancelled`, or `null` when Subtotal has not observed a status.Each purchase includes structured metadata describing the full details of the transaction:- Identifiers (purchase ID, retailer, connection ID)

- Timestamps (order date, fulfillment date when available)

- Transaction totals (subtotal, tax, discounts, shipping, total)

- Items (product name, brand, upc, quantity, price, and other metadata)Subtotal continuously syncs new purchases from connected retailer accounts and evaluates each one in real time against a consumer’s sharing preferences. When a purchase is eligible, it becomes available to brands as verified retail purchase data.***## EventsSubtotal turns purchases and account activity into **events**.Events are the primary way Subtotal communicates activity to downstream systems and integrations. Examples include:- a shopper connecting a retailer account
- a purchase being shared with a brand
- a retailer account requiring re-authenticationEvents can be delivered in real time and are used to power workflows such as loyalty rewards, personalized messaging, analytics updates, and more.### Triggers

\<table><thead><tr><th scope="col">Trigger</th>
          
          \<th scope="col">Sent when</th></tr></thead>
      \<tbody><tr><td>Purchase shared</td>
            
            \<td>A purchase is shared with your brand: a new purchase from a linked
account, or the history shared when an account connects or
reconnects.</td></tr>
        \<tr><td>Account connected</td>
            
            \<td>A consumer links a retail account. It fires once per connection. Webhooks (connection.activated) and Attentive send it on every sign in.</td></tr>
        \<tr><td>Account reconnected</td>
            
            \<td>A connection signs in after it has lost access at least once. From
then on it fires on every sign in, including routine ones.</td></tr>
        \<tr><td>Account needs reconnecting</td>
            
            \<td>A connection loses access at the retailer.</td></tr>
        \<tr><td>Account disconnected</td>
            
            \<td>The consumer, or your app through the API, disconnects the
connection.</td></tr>
        \<tr><td>Profile shared</td>
            
            \<td>Subtotal first collects a retail account's profile, and it
goes once to each connection linked to that account at that
moment, not to a connection made later.</td></tr>
        \<tr><td>Profile updated</td>
            
            \<td>A collected profile changes.</td></tr></tbody></table>

A purchase event is sent as soon as the purchase is shared, which can be before the order ships or completes. **Wait for the purchase to complete** holds the event until the order completes. It is available for [Klaviyo events](https://docs.subtotal.com/docs/integrations/klaviyo/event-types.md#wait-for-the-purchase-to-complete), [webhook subscriptions](https://docs.subtotal.com/docs/webhooks/configuration.md#wait-for-the-purchase-to-complete), and loyalty earning actions in [Rivo](https://docs.subtotal.com/docs/integrations/rivo/purchases.md#wait-for-the-purchase-to-complete), [Smile](https://docs.subtotal.com/docs/integrations/smile/purchases.md#wait-for-the-purchase-to-complete), [Yotpo](https://docs.subtotal.com/docs/integrations/yotpo/purchases.md#wait-for-the-purchase-to-complete), and [Okendo](https://docs.subtotal.com/docs/integrations/okendo/purchases.md#wait-for-the-purchase-to-complete).***## AppsAn **app** is an integration that connects Subtotal to an external system, such as a marketing platform, loyalty provider, data warehouse, or internal service.Apps allow teams to activate purchase data without building custom infrastructure. For example, brands can use Subtotal apps to trigger flows in email or SMS tools, update customer profiles, or sync data into analytics platforms.***## API and webhooksThe **Subtotal API** provides programmatic access to core platform functionality, including managing connections and accessing purchase data.**Webhooks** allow Subtotal to push real-time events to your systems as they occur, enabling event-driven architectures and timely customer experiences.***## Putting it all togetherAt a high level, Subtotal works like this:1) A shopper connects a retailer account to a brand using Subtotal
2) Subtotal detects purchases made through that account
3) Purchases are matched to brand products
4) Activity is emitted as real-time events
5) Brands use those events to power engagement, loyalty, and insightsThese concepts appear throughout the documentation and platform. As you continue, you’ll see how they apply to specific integrations, APIs, and use cases.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.