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

# sale.created

> Receive an attributed sale with revenue, customer, click, and link context.

Biqli sends `sale.created` when conversion tracking records a new sale. A retried tracking request that replays an existing idempotent result does not create a second sale event.

## Example payload

```json theme={null}
{
  "id": "evt_01m2examplesale000000000000",
  "event": "sale.created",
  "createdAt": "2026-09-14T15:15:00+00:00",
  "data": {
    "eventName": "Purchase",
    "externalId": "order_1842",
    "customer": {
      "id": "biq_cus_01M2EXAMPLE00000000000000",
      "externalId": "customer_1842",
      "email": "ada@example.com",
      "name": "Ada Lovelace",
      "avatar": null
    },
    "click": {
      "id": "click_example_1842",
      "timestamp": "2026-09-14T15:04:59+00:00",
      "country": "US",
      "city": "San Francisco",
      "region": "California",
      "browser": "Chrome",
      "browserVersion": "128",
      "platform": "Mac OS",
      "platformVersion": "14",
      "device": "desktop",
      "referrer": "https://example.com",
      "source": null
    },
    "link": {
      "id": "biq_lnk_01M2EXAMPLE00000000000000",
      "externalId": "campaign_1842",
      "name": "Autumn campaign",
      "url": "https://example.com/autumn",
      "shortUrl": "https://biq.li/autumn",
      "key": "autumn",
      "description": null,
      "active": true,
      "expiresAt": null,
      "workspaceId": "biq_ws_01M2EXAMPLE000000000000000",
      "createdAt": "2026-09-14T13:40:23+00:00",
      "updatedAt": "2026-09-14T13:40:23+00:00"
    },
    "sale": {
      "amount": 54.99,
      "amountUsd": 54.99,
      "currency": "USD",
      "productId": "product_1842",
      "productName": "Pro plan"
    },
    "metadata": {
      "billingInterval": "monthly"
    }
  }
}
```

## Money fields

<Warning>
  Outbound webhook `sale.amount` and `sale.amountUsd` values are decimal **major currency units**. For example, `54.99` means 54 dollars and 99 cents. This differs from the tracking API request, where `amount: 5499` is an integer in minor units.
</Warning>

* `sale.currency` is an uppercase ISO 4217 currency code.
* `sale.amountUsd` is the stored USD-normalized value and can be `null`.
* Product fields can be `null`.
* Conversion click context intentionally omits the IP address.
* `metadata` is integration-defined JSON and can be `null`.

If the attributed link was later deleted, `data.link` contains its preserved historical values and `deleted: true`.
