Product/sku deletion fixes
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import { WebflowClient } from "@blade-and-brawn/commerce";
|
||||
import { env } from "../util";
|
||||
|
||||
const webflow = new WebflowClient({
|
||||
siteId: env.WEBFLOW_SITE_ID,
|
||||
collectionIds: {
|
||||
products: env.WEBFLOW_COLLECTION_PRODUCTS_ID,
|
||||
skus: env.WEBFLOW_COLLECTION_SKUS_ID
|
||||
},
|
||||
token: env.WEBFLOW_AUTH,
|
||||
webhookSecret: env.WEBFLOW_WEBHOOK_SECRET,
|
||||
});
|
||||
|
||||
const collections = await webflow.Collections.list();
|
||||
console.log(collections);
|
||||
@@ -40,7 +40,10 @@ try {
|
||||
console.log("Registering webflow webhooks...");
|
||||
const webflow = new WebflowClient({
|
||||
siteId: env.WEBFLOW_SITE_ID,
|
||||
collectionsId: env.WEBFLOW_COLLECTION_ID,
|
||||
collectionIds: {
|
||||
products: env.WEBFLOW_COLLECTION_PRODUCTS_ID,
|
||||
skus: env.WEBFLOW_COLLECTION_SKUS_ID
|
||||
},
|
||||
token: env.WEBFLOW_AUTH,
|
||||
webhookSecret: env.WEBFLOW_WEBHOOK_SECRET,
|
||||
});
|
||||
|
||||
@@ -33,7 +33,10 @@ const printful = new PrintfulClient({
|
||||
|
||||
const webflow = new WebflowClient({
|
||||
siteId: env.WEBFLOW_SITE_ID,
|
||||
collectionsId: env.WEBFLOW_COLLECTION_ID,
|
||||
collectionIds: {
|
||||
products: env.WEBFLOW_COLLECTION_PRODUCTS_ID,
|
||||
skus: env.WEBFLOW_COLLECTION_SKUS_ID
|
||||
},
|
||||
token: env.WEBFLOW_AUTH,
|
||||
webhookSecret: env.WEBFLOW_WEBHOOK_SECRET,
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user