import * as Options from '../options'; import { ProductVariant, ProductVariantCreate, ProductVariantUpdate } from '../interfaces'; import { BaseService } from '../infrastructure'; /** * A service for manipulating a blog's product variants. */ export declare class ProductVariants extends BaseService { constructor(shopDomain: string, accessToken: string); /** * Gets a variant with the given id. * @param id Id of the variant being retrieved. * @param options Options for filtering the result. */ get(id: number, options?: Options.ProductVariantGetOptions): Promise; /** * Lists up to 250 variants for the given product. * @param productId Id of the product that the variants belong to. * @param options Options for filtering the results. */ list(productId: number, options?: Options.ProductVariantListOptions): Promise; /** * Counts the variants on the given product. * @param productId Id of the product that the variants belong to. */ count(productId: number): Promise; /** * Creates a new product variant * @param productId Id of the product that the varaint belongs to. * @param productVariant The updated variant. */ create(productId: number, variant: ProductVariantCreate): Promise; /** * Updates an variant with the given id. * @param id Id of the variant. * @param productVariant The updated variant. */ update(id: number, variant: ProductVariantUpdate): Promise; /** * Deletes the variant with the given variantId. * @param productId Id of the product that the varaint belongs to. * @param variantId Id of the variant to delete. */ delete(productId: number, variantId: number): Promise; } export default ProductVariants;