Changelog #45
·
Shopify Integration
CTO, Trigger.dev
Shopify is an e-commerce platform that needs no introduction.
You can now use our new Shopify Integration to easily add webhook triggers and perform tasks on Shopify resources:
_23client.defineJob({_23 id: "shopify-create-customized-product",_23 name: "Shopify - Create Customized Product",_23 version: "1.0.0",_23 integrations: {_23 shopify,_23 },_23 trigger: shopify.on("customers/create"),_23 run: async (payload, io, ctx) => {_23 const firstName = payload.first_name;_23_23 // Create a customized product_23 const product = await io.shopify.rest.Product.save("teapot", {_23 fromData: {_23 title: `${firstName}'s Teapot`,_23 },_23 });_23_23 return {_23 message: `Hi, ${firstName}! Bet you'll love this: ${product.title}`,_23 };_23 },_23});
This is the first integration to use our updated Webhook Triggers which come with a new UI. The dashboard can be found under Triggers -> Webhook Triggers
. You can now see both webhook registrations and deliveries!
See more details in the Shopify integration docs.