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

# Tolstoy Library

> Run your shoppable video workspace from chat — media library, shoppable widgets, product tagging, multi-store, and Meta ads.

The **Tolstoy Library** MCP server turns any AI client into a control surface for your shoppable video workspace.

```
https://apilb.gotolstoy.com/mcp/v1/library/mcp
```

See [Connect a client](/mcp/connect) to add it. The tools below are grouped by what they manage.

## Media assets

Your library of videos, images, social imports, and AI Studio drafts.

| Tool            | What it does                                                                                       |
| --------------- | -------------------------------------------------------------------------------------------------- |
| `list_assets`   | List your most recent library assets, with optional type and favorite filters.                     |
| `search_assets` | Search the library by query (name, UGC creator).                                                   |
| `get_asset`     | Fetch full details for one or more assets, including tagged products, playlists, and Shopify tags. |
| `update_asset`  | Rename an asset or toggle its favorite status.                                                     |

## Shoppable widgets

Onsite video widgets shoppers see on your storefront — Stories, Carousel, Spotlight, For You Feed, Tile, Collection Grid, and Bubble Feed.

| Tool            | What it does                                                                                                                                    |
| --------------- | ----------------------------------------------------------------------------------------------------------------------------------------------- |
| `list_widgets`  | List your onsite shoppable widgets, live or draft, with type and status.                                                                        |
| `get_widget`    | Inspect a widget: type, live status, content selection, and the actual videos it shows — pass a `productId` to preview a specific product page. |
| `create_widget` | Create a new shoppable widget from a template, with the platform's defaults.                                                                    |
| `update_widget` | Rename, publish/unpublish, toggle PDP mode, or replace a widget's content selection.                                                            |

<Note>
  Setting a widget live activates it in Tolstoy; appearing on the storefront also needs the Tolstoy app embed enabled in your Shopify theme (a one-time setup per store). The publish result returns the exact steps.
</Note>

## Products & shoppability

Make videos shoppable by tagging store products on them.

| Tool                | What it does                                                                                                        |
| ------------------- | ------------------------------------------------------------------------------------------------------------------- |
| `search_products`   | Find a store product by title to get its product id.                                                                |
| `tag_video_product` | Tag (or untag) products on a video — tagged videos feed product-tagged playlists and show on those products' pages. |

## Stores

| Tool          | What it does                                                                                      |
| ------------- | ------------------------------------------------------------------------------------------------- |
| `list_stores` | List the connected stores on your account. Widget, product, and ads tools can target any of them. |

## Paid ads

Read-only insight and creative upload for Meta ads — no tool moves ad spend.

| Tool                          | What it does                                                                                                 |
| ----------------------------- | ------------------------------------------------------------------------------------------------------------ |
| `list_ad_campaigns`           | List your Meta ad campaigns with real delivery status (not just paused/active).                              |
| `get_ads_performance`         | Meta ads performance — spend, ROAS, CTR, purchases — per campaign, ad set, or ad.                            |
| `publish_to_meta_ads_library` | Push a library video or image into Meta Ads Manager, ready for ad creation. No campaign or spend is created. |

## Example: make a video shoppable end to end

> "Make my unboxing video shoppable for the DBTK 1 shirt, put it in a Stories widget, publish it, and show me how my ads are doing."

1. `search_assets` → find the unboxing video.
2. `search_products` → find DBTK 1's product id.
3. `tag_video_product` → tag the product on the video.
4. `create_widget` → a Stories widget (starts as a draft).
5. `get_widget` with the product id → confirm the video shows on that product's page.
6. `update_widget` with `live: true` → publish, then follow the returned app-embed steps.
7. `get_ads_performance` → check spend and ROAS.
