Best answer

What is the correct return value for perform Unsubscribe?

  • 23 June 2022
  • 1 reply
  • 98 views

All of the examples for unsubscribing a REST HOOK, including the code generated from the form based app, show the function returning a value, for instance:
https://github.com/zapier/zapier-platform/blob/master/example-apps/rest-hooks/triggers/recipe.js
 

Unfortunately all of the examples merely show passing through the return from the web request without any particular detail and as far as I can find it is nowhere documented what the upstream code *expects* to be returned here or what the implications of various options are. 

Does the the return value of this function actually do anything?

icon

Best answer by Zane 30 June 2022, 16:38

View original

This post has been closed for comments. Please create a new post if you need help or have a question about this topic.

1 reply

Userlevel 7
Badge +9

I don’t think Zapier is doing anything with the body from the unsubscribe response. I think Zapier will, at most, just look for a 200 status to ensure the unsubscribe request didn’t fail. Unsubscribe is called when the Zap is paused… so there wouldn’t be anything in the workflow to pass that data to, and the subscription on Zapier’s side is gone at that point.