Delete a Product
DELETE
Delete by ID
https://api.moltin.com/v2/products/:id
You can quickly delete a Product by ID.
Path Parameters:
Name | Required | Type | Description |
---|---|---|---|
id | Required | string | The ID for the Product to delete. |
Headers:
Name | Required | Type | Description |
---|---|---|---|
Authorization | Required | string | The Bearer token to grant access to the API. |
204 No Content
curl -X DELETE https://api.moltin.com/v2/products/:id \
-H "Authorization: Bearer XXXX"
const MoltinGateway = require('@moltin/sdk').gateway
const Moltin = MoltinGateway({
client_id: 'X',
client_secret: 'X'
})
const id = 'XXXX'
Moltin.Products.Delete(id).then(response => {
// Do something
})
const { MoltinClient } = require('@moltin/request')
const client = new MoltinClient({
client_id: 'X',
client_secret: 'X'
})
const id = 'XXXX'
client
.delete(`products/${id}`)
.then(console.log)
.catch(console.error)