How can I have a service user authenticating to Foundry via OAuth2 to perform actions via webhook?

I would to have in Foundry:

  • An Action that triggers a webhook
  • This webhook will perform an API Call to Foundry to perform something
  • This webhook will be executed as a service user, and not the actual user calling the API

Question: How to set this up ?

To my understanding:

  • I can create a Third party application in Developer Console, which will get me a service user, which I can grant access to specific resources/etc.
  • I can create an outbound application to store the Oauth2 credentials (client id/client secret) so that I can use this “authentication mechanism” in a Data Connection source
  • I can create a REST data connection source which users the outbound application credentials to execute the API calls
  • I can then create a webhook on this source

There is a simpler way, described in the section “Build a Webhook that performs the client credentials handshake”
https://www.palantir.com/docs/foundry/data-connection/webhooks-reference/#client-credentials-grant

Note: the url to get the token will be /multipass/api/oauth2/token

In short, one can setup a secret on the source with the client_id/client_secret, and perform one API call more in the chain of webhooks, that first performs the Oauth call to get a valid token:

1 Like

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.