[SDK: Node] Add Webhook endpoints/interface #3
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes
Adds comprehensive Webhooks v2 client support to the tango-node SDK.
Added
listWebhookEventTypes()to discover supported event types and subject typeslistWebhookSubscriptions()- List subscriptions with tier-capped pagination (page+page_size)getWebhookSubscription()- Get a single subscription by IDcreateWebhookSubscription()- Create a new subscriptionupdateWebhookSubscription()- Update subscription name and/or payloaddeleteWebhookSubscription()- Delete a subscriptionlistWebhookEndpoints()- List endpoints with standard paginationgetWebhookEndpoint()- Get a single endpoint by IDcreateWebhookEndpoint()- Create a new endpoint (one per user)updateWebhookEndpoint()- Update endpoint callback URL and/or active statusdeleteWebhookEndpoint()- Delete an endpointtestWebhookDelivery()- Send a test webhook to verify endpoint connectivitygetWebhookSamplePayload()- Fetch sample payloads for development/testingWebhookSubscription,WebhookEndpoint,WebhookEventType, etc.)Changed
PATCH,PUT, andDELETEmethods (previously onlyGETandPOST)Why
This implements the full Webhooks v2 API surface area from the Tango server, enabling SDK users to:
Testing
Notes
page+page_size(tier-capped), while endpoints usepage+limitsubject_ids) require Enterprise tierRelated
Resolves makegov/tango#1275