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

# Products

> Query products, variants, pricing, media, and deliverables from the Storefront API.

## Queries

### `product`

Fetch a single published product by UID.

```graphql theme={null}
query Product($uid: UUID!) {
  product(uid: $uid) {
    uid
    name
    tagline
    description
    contentBlocks
    variants {
      uid
      name
      inventoryCount
      prices {
        uid
        currency
        isDefault
        recurringInterval
        price {
          ... on LinearProductPriceConfig {
            priceModel
            unitPrice
          }
          ... on VolumeProductPriceConfig {
            priceModel
            tiers {
              firstUnit
              lastUnit
              unitPrice
            }
          }
        }
      }
      media {
        uid
        type
        url
        alt
      }
      deliverables {
        uid
        name
        type
        description
      }
    }
    defaultVariant {
      uid
      name
    }
    createdAt
    updatedAt
  }
}
```

### `productsByStoreUid`

List all published products in a store.

```graphql theme={null}
query StoreProducts($storeUid: UUID!) {
  productsByStoreUid(storeUid: $storeUid) {
    uid
    name
    tagline
    description
    defaultVariant {
      uid
      prices {
        currency
        isDefault
        price {
          ... on LinearProductPriceConfig {
            unitPrice
          }
        }
      }
      media {
        uid
        url
        alt
      }
    }
  }
}
```

## Types

### Product

| Field            | Type               | Description               |
| ---------------- | ------------------ | ------------------------- |
| `uid`            | `UUID`             | Product ID                |
| `name`           | `String`           | Product name              |
| `tagline`        | `String?`          | Short description         |
| `description`    | `String?`          | Full description          |
| `contentBlocks`  | `[JSON]?`          | Structured content blocks |
| `variants`       | `[ProductVariant]` | Product variants          |
| `defaultVariant` | `ProductVariant`   | Default variant           |
| `createdAt`      | `DateTime`         |                           |
| `updatedAt`      | `DateTime`         |                           |

### ProductVariant

| Field            | Type                   | Description               |
| ---------------- | ---------------------- | ------------------------- |
| `uid`            | `UUID`                 | Variant ID                |
| `name`           | `String?`              | Variant name              |
| `inventoryCount` | `Int?`                 | Current stock level       |
| `prices`         | `[ProductPrice]`       | Variant prices            |
| `media`          | `[Media]`              | Variant images and videos |
| `deliverables`   | `[ProductDeliverable]` | Digital deliverables      |

### ProductPrice

| Field               | Type                                                   | Description                                                                  |
| ------------------- | ------------------------------------------------------ | ---------------------------------------------------------------------------- |
| `uid`               | `UUID`                                                 | Price ID                                                                     |
| `currency`          | `String`                                               | ISO currency code                                                            |
| `isDefault`         | `Boolean`                                              | Whether this is the default price                                            |
| `recurringInterval` | `MONTH \| YEAR \| null`                                | Billing interval for subscriptions                                           |
| `trialDuration`     | `String?`                                              | Trial period (`ONE_DAY`, `THREE_DAYS`, `ONE_WEEK`, `TWO_WEEKS`, `ONE_MONTH`) |
| `price`             | `LinearProductPriceConfig \| VolumeProductPriceConfig` | Pricing model                                                                |

### LinearProductPriceConfig

| Field        | Type     | Description                                    |
| ------------ | -------- | ---------------------------------------------- |
| `priceModel` | `LINEAR` |                                                |
| `unitPrice`  | `Float`  | Price per unit in minor currency units (cents) |

### VolumeProductPriceConfig

| Field        | Type                | Description             |
| ------------ | ------------------- | ----------------------- |
| `priceModel` | `VOLUME`            |                         |
| `tiers`      | `[VolumeTierPrice]` | Tiered pricing brackets |

### Media

| Field  | Type                               | Description |
| ------ | ---------------------------------- | ----------- |
| `uid`  | `UUID`                             | Media ID    |
| `type` | `IMAGE \| VIDEO \| EXTERNAL_VIDEO` | Media type  |
| `url`  | `String?`                          | CDN URL     |
| `alt`  | `String?`                          | Alt text    |

### ProductDeliverable

| Field         | Type                                          | Description      |
| ------------- | --------------------------------------------- | ---------------- |
| `uid`         | `UUID`                                        | Deliverable ID   |
| `name`        | `String`                                      | Name             |
| `type`        | `DOWNLOAD \| CONTENT_UNLOCK \| EXTERNAL_LINK` | Deliverable type |
| `description` | `String?`                                     | Description      |
