Securing web service communication from custom database connection

I want to validate the user data on my internal database through exposing a web service. How can i secure the connection between Auth0 (in cloud) and my web service?

The custom database connection scripts that will perform the calls to your service are pretty much equivalent to Node.js code (not all NPM packages are available) so you can consider use any authentication scheme supported by the available packages.

For example, for calling an HTTP API you could consider including an API key in the requests performed through the custom scripts, or just use HTTP basic authentication. In addition, for additional security you can restrict calls to the specific IP addresses used by the Auth0 service to perform the outgoing calls. When configuring a custom database script the IP addresses in question are listed in a note panel below the script code.