Skip to content
This repository has been archived by the owner on Jul 12, 2019. It is now read-only.

I think we're requiring hook payloads to contain an id #32

Closed
codekirei opened this issue May 5, 2017 · 6 comments
Closed

I think we're requiring hook payloads to contain an id #32

codekirei opened this issue May 5, 2017 · 6 comments
Assignees
Labels

Comments

@codekirei
Copy link

AFAICT we're doing the trigger has id check on hook trigger data. Is this intentional? Makes sense for polling triggers, but seems odd that we're also running it against hooks.

https://github.com/zapier/zapier-platform-core/blob/master/src/checks/trigger-has-id.js

@bcooksey
Copy link
Contributor

bcooksey commented May 5, 2017

Yup, we are requiring that. We have this shouldRun, but for the id check, this is simply looking to see if it's a trigger.

We can discuss if this is a bug or a reasonable constraint.

@codekirei
Copy link
Author

Cool, thanks for confirming! As for whether it's a reasonable constraint, what was the original inspiration for this check? I imagine we want to make sure polling trigger data includes an id for deduplication, but that doesn't apply for hooks.

Is there another reason we're wanting to ensure trigger data contains an id? If not, I'd be in favor of restricting this restraint to just polling triggers.

If we do decide to stick with this as-is, we'll probably want to be a bit more explicit about this requirement in our docs — I'm happy to make the that update if that's the consensus.

@bryanhelmig
Copy link
Member

I'd be in favor of restricting this restraint to just polling triggers.

That sounds reasonable!

@xavdid
Copy link
Contributor

xavdid commented May 10, 2017

+1 to just polling triggers to semi-match the v2 setup

@bcooksey bcooksey added bug and removed question labels May 11, 2017
@bcooksey
Copy link
Contributor

In that case, we can schedule a fix

@xavdid
Copy link
Contributor

xavdid commented May 11, 2017

Sweet. I was going to grab this and #25, since they seem very related

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

5 participants