PDP Functions
The Product Details dropin provides two functions for retrieving the product details data to display: getProductData and getRefinedProduct.
getProductData
This function returns the product data for a given product sku
. It takes sku
as a parameter.
import { getProductData } from '@/pdp/api/getProductData';
getProductData(sku: string);
getRefinedProduct
A function that returns refined product’s data. It takes sku
and optionUIDs
as parameters.
import { getRefinedProduct } from '@/pdp/api/getRefinedProduct';
getRefinedProduct(sku: string, optionUIDs: string[]);