Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

S48 1126 r d automation of webhook triggered http functions #60

Open
wants to merge 46 commits into
base: master
Choose a base branch
from

Conversation

joeward98
Copy link

No description provided.

…e webhook creation payloads, which are written to a file in .build
…ith every cloudseed build, for handling all BC webhooks
…ions' of bitbucket.org:joeward/cloud-seed-testing into S48-1126-r-d-automation-of-webhook-triggered-http-functions
@joeward98
Copy link
Author

joeward98 commented Oct 19, 2022

Current limitations: doesn't reliably handle hooks in form foo/bar/*

export type WebhookConfig = {
type: "webhook";
webhook: {
type: "bigcommerce";

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

will this always be bigcommerce?

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It could be extended to other webhook types in future. But for now its only bigcommerce

Copy link

@ansnaldo ansnaldo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.
Would be good to have the followings :

  • Ability to specify custom headers while creating the webhook
  • Ability to specify multiple topics for one function (ie: make the scope an array or comma separated string?)

};

export function getPubSubTopicName(scope: string, type: string): string {
return `webhook-${type}-${scope.split("/").join("-")}`;

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this could be getWebhookPubSubTopicName() ?

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

Successfully merging this pull request may close these issues.

None yet

2 participants