Skip to main content

Class: AdminProductsResource

Hierarchy

  • default

    AdminProductsResource

Methods

addOption

addOption(id, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
payloadAdminPostProductsProductOptionsReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:124


create

create(payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
payloadAdminPostProductsReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:23


createVariant

createVariant(id, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
payloadAdminPostProductsProductVariantsReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:96


delete

delete(id, customHeaders?): ResponsePromise<AdminProductsDeleteRes>

Parameters

NameType
idstring
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsDeleteRes>

Defined in

medusa-js/src/resources/admin/products.ts:48


deleteOption

deleteOption(id, optionId, customHeaders?): ResponsePromise<AdminProductsDeleteOptionRes>

Parameters

NameType
idstring
optionIdstring
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsDeleteOptionRes>

Defined in

medusa-js/src/resources/admin/products.ts:143


deleteVariant

deleteVariant(id, variantId, customHeaders?): ResponsePromise<AdminProductsDeleteVariantRes>

Parameters

NameType
idstring
variantIdstring
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsDeleteVariantRes>

Defined in

medusa-js/src/resources/admin/products.ts:115


list

list(query?, customHeaders?): ResponsePromise<AdminProductsListRes>

Parameters

NameType
query?AdminGetProductsParams
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsListRes>

Defined in

medusa-js/src/resources/admin/products.ts:56


listTags

listTags(customHeaders?): ResponsePromise<AdminProductsListTagsRes>

Parameters

NameType
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsListTagsRes>

Defined in

medusa-js/src/resources/admin/products.ts:80


listTypes

listTypes(customHeaders?): ResponsePromise<AdminProductsListTypesRes>

Deprecated

Use list instead.

Parameters

NameType
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsListTypesRes>

Defined in

medusa-js/src/resources/admin/products.ts:73


retrieve

retrieve(id, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:31


setMetadata

setMetadata(id, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
payloadAdminPostProductsProductMetadataReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:87


update

update(id, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
payloadAdminPostProductsProductReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:39


updateOption

updateOption(id, optionId, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
optionIdstring
payloadAdminPostProductsProductOptionsOption
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:133


updateVariant

updateVariant(id, variantId, payload, customHeaders?): ResponsePromise<AdminProductsRes>

Parameters

NameType
idstring
variantIdstring
payloadAdminPostProductsProductVariantsVariantReq
customHeadersRecord<string, any>

Returns

ResponsePromise<AdminProductsRes>

Defined in

medusa-js/src/resources/admin/products.ts:105