Is the Payload Correct for Deploying a Shopify New Product Update Trigger via Connect?

This topic was automatically generated from Slack. You can find the original thread here.

Hello team - trying to deploy a shopify new product update trigger via connect… however been getting this error… can anyone confirm if this payload is correct?

{
    "triggerId": "shopify_developer_app-new-product-updated",
    "externalUserId": <externalUserId>,
    "webhookUrl": "https://webhook-test.com/30ed02837ceed23590da98e58a32459d",
    "configuredProps": {
        "app": {
            "authProvisionId": "app_qeh7a4"
        },
        "projectId": "proj_VbsJbEP"
    }
}

image.png

Hey , the auth provision ID looks off. I suspect you’re inputting the app ID, while it should be the account ID.

Check the doc here https://pipedream.com/docs/connect/components/#configure-the-component

Hello thanks a lot for the response…actually tried the account id previously also but had this error…

Hi , could you share the minimal steps to reproduce your issue if possible?

For example, could you share the code you used to deploy the trigger?

hello thanks… so cloned “managed-auth-basic-next-app” …

and added this on server.ts

export async function deployTrigger(triggerId: string, externalUserId: string, webhookUrl: string , configuredProps: any) {
    console.log("Server: deployTrigger called with:", {
        triggerId,
        externalUserId,
        webhookUrl,
        configuredProps
    });
    try {
        const requestOpts: DeployTriggerOpts = {
            triggerId,
            externalUserId,
            webhookUrl,
            configuredProps,
        };

        
        const response: DeployTriggerResponse = await pd.deployTrigger(requestOpts);
        console.log("Server: deployTrigger response:", response);
    } catch (error) {
        console.error("Server: deployTrigger error:", error);
        throw error;
    }
}

and added this on client.tsx to deploy the trigger

const handleDeployTrigger = async () => {
        const webhookUrl = "https://webhook-test.com/30ed02837ceed23590da98e58a32459d";
        const triggerId = `shopify_developer_app-new-product-updated`;
        const configuredProps = {
            app: {
                authProvisionId: "apn_WYhKXma",
            }, 
            projectId: "proj_VbsJbEP",
        };
        try {
            const res = await deployTrigger(triggerId, externalUserId, webhookUrl, configuredProps);
            console.log("deployTrigger SUCCESS:", res);
        } catch (error) {
            console.error("Error deploying trigger:", error);
            // Log additional error details
            if (error instanceof Error) {
                console.error("Error message:", error.message);
                console.error("Error stack:", error.stack);
            }
        }
    };

also i tried a different shopify account and used the builder… i think got the same error…

Got it . We’ll take a look and get back to you.

Hi @U05FUC30Q01, could you help me to take a look once you have a chance :pray:

super super thanks a lot guys…

Hey , it may be something related to your configuration. Could you try in our demo app and check the code/debug tab and see if the configuration matches what you’re sending?

Hello thanks a lot… sorry but got an error…

for getaccounts…

and for deploy…

What did you receive in the webhookUrl (webhook-test.com)?

do you have an account for Shopify Developer? Would you mind checking if there’s an error in the component trigger?

sorry didnt recieve any on my webhook

F.Y.I The product update works on Pipedream UI

yups also tried to add that shopify account using pipedream ui and didnt have any issues… considering now that there is something im missing when depoying via pipedream connect deploy trigger…

I tested on Pipedream connect demo and I can deploy the trigger (image below).

, could you try to create a new Pipedream HTTP source and use it for the webhook url to see if it works? It works for my case

Hello thanks a lot… unfortunately tried it… still got the same error… i think will try a different shopify account… or maybe a different app…