Skip to main content
This event is triggered whenever a user adds a new connection. The registered handler runs before the connection is saved, meaning that if the handler throws an error, the connection will not be created. You can use handler to validate the connection and ensure that any necessary setup code has run successfully.

Example

Here’s an example that creates a webhook handler.
TypeScript
When the event handler is invoked the new connection is only available as argument. It will not be available from usual Server SDK Connection functions (getUserConnection() / getWorkspaceConnection()).