addProductMedia( )


Adds media items by ID to a product.

The addProductMedia() function returns a Promise that resolves when the adding of the media (images or videos) to a product has started.

Limitation The URL is not validated and no event is triggered to indicate if the media was added successfully.

Method Declaration
Copy
Method Parameters
productIdstringRequired

Product ID.


mediaArray<Media>Required

Sources of media items already uploaded to the Wix site.

Was this helpful?
Yes
No