Create assets
Create assets
POST
/
partners
/
assets
Authentication
string
*
Authentication
Required
string
object
assets
array
*
assets
Required
array
The list of assets to store
Parameters
The list of assets to store
Asset structure
type Asset = {
externalId: string;
videoUrl: string;
posterUrl: string;
shopId: string;
products: Product[];
appUrl: string;
};
type Product = {
id: string;
title?: string;
imageUrls?: string[];
};
Example
{
"externalId": "1",
"videoUrl": "https://cdn.shopify.com/video.mp4",
// video preview image (must be hosted on Shopify cdn)
"posterUrl": "https://cdn.shopify.com/image.jpg",
// Shopify store id
"shopId": "gid://shopify/Shop/123",
// store MyShopify domain
"appUrl": "tolstoy.myshopify.com",
// a list of products linked to the video
"products": [
{
// Shopify product id (required)
"id": "gid://shopify/Product/1",
// product title (optional)
"title": "Product title",
// an array of product images (optional)
"imageUrls": ["https://test.myshopify.com/81f3345adfd6.jpg"]
}
]
}