Class: AdminProductsResource
Hierarchy
default
↳
AdminProductsResource
Methods
addOption
▸ addOption(id
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
payload | AdminPostProductsProductOptionsReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:124
create
▸ create(payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
payload | AdminPostProductsReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:23
createVariant
▸ createVariant(id
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
payload | AdminPostProductsProductVariantsReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:96
delete
▸ delete(id
, customHeaders?
): ResponsePromise
<AdminProductsDeleteRes
>
Parameters
Name | Type |
---|---|
id | string |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsDeleteRes
>
Defined in
medusa-js/src/resources/admin/products.ts:48
deleteOption
▸ deleteOption(id
, optionId
, customHeaders?
): ResponsePromise
<AdminProductsDeleteOptionRes
>
Parameters
Name | Type |
---|---|
id | string |
optionId | string |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsDeleteOptionRes
>
Defined in
medusa-js/src/resources/admin/products.ts:143
deleteVariant
▸ deleteVariant(id
, variantId
, customHeaders?
): ResponsePromise
<AdminProductsDeleteVariantRes
>
Parameters
Name | Type |
---|---|
id | string |
variantId | string |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsDeleteVariantRes
>
Defined in
medusa-js/src/resources/admin/products.ts:115
list
▸ list(query?
, customHeaders?
): ResponsePromise
<AdminProductsListRes
>
Parameters
Name | Type |
---|---|
query? | AdminGetProductsParams |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsListRes
>
Defined in
medusa-js/src/resources/admin/products.ts:56
listTags
▸ listTags(customHeaders?
): ResponsePromise
<AdminProductsListTagsRes
>
Parameters
Name | Type |
---|---|
customHeaders | Record <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
Name | Type |
---|---|
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsListTypesRes
>
Defined in
medusa-js/src/resources/admin/products.ts:73
retrieve
▸ retrieve(id
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:31
setMetadata
▸ setMetadata(id
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
payload | AdminPostProductsProductMetadataReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:87
update
▸ update(id
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
payload | AdminPostProductsProductReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:39
updateOption
▸ updateOption(id
, optionId
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
optionId | string |
payload | AdminPostProductsProductOptionsOption |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>
Defined in
medusa-js/src/resources/admin/products.ts:133
updateVariant
▸ updateVariant(id
, variantId
, payload
, customHeaders?
): ResponsePromise
<AdminProductsRes
>
Parameters
Name | Type |
---|---|
id | string |
variantId | string |
payload | AdminPostProductsProductVariantsVariantReq |
customHeaders | Record <string , any > |
Returns
ResponsePromise
<AdminProductsRes
>