Authenticating the probe Using OAuth authentication

The Web Hook and Web Socket transports support OAuth authentication with an OAuth server to request access to a restricted resource using an access token.

To request an access token, the transport uses the resource owner password credential grant method, whereby the probe sends a token request to the token end point specified by the tokenEndpointURI property in the restWebhookTransport.properties file.

Along with the token request, the probe sends the resource credentials specified by the Username and Password properties in the message_bus.props file to log into the OAuth server.

In response, the token end point sends to the probe the access_token and refresh_token.

The probe will send the access_token to gain access to the restricted resource and will send the refresh_token to refresh the access token shortly before it expires.

For OAuth servers that require a client to authenticate using the basic authentication method, set the <code> basicAuthenticationUsername and basicAuthenticationPassword properties.

Set the clientId and clientSecret properties to send the credentials in the POST request body.

Set the scope property to specify a comma-separated list of scopes to set in the access token request.

To use the access token in another transport property, use the ++OAuth.access_token++ variable name in the transport property. For example, to use this in the Web Hook transport httpHeader property: httpHeader=Authorization=Bearer ++Oauth.access_token++