11-28-2023 11:32 AM
Hello all,
I have created a triggered task to receive the webhooks generated from another web application when changes are detected. This works well with Postman, I can use the task URL and the authentication token in the Authorization header, and SL executes the pipeline.
The application that sends the webhooks has a very simple configurable interface where only the URL and the token can be configured, and I was told that the token is passed as parameter to the URL using the key "x-customapp-token".
Of course SL rejects the connection because the application is not authorized, so I tried to map the token sent as "x-customapp-token" to an authorization header using a mapper in an open-end pipeline, but that doesn't work.
Is there a way to map this token somehow so that the application can be authenticated?
Thanks!
JF
Solved! Go to Solution.
11-28-2023 11:52 AM
@jfpelletier - if you can't get the webhook to pass the Authorization Bearer token in the HTTP header parameters, you can always specify the bearer token as a query parameter. See the Running a Triggered Task documentation and refer to the "Run a Pipeline using a Bearer token for authentication through the bearer_token query parameter" example.
Hope this helps!
11-28-2023 11:52 AM
@jfpelletier - if you can't get the webhook to pass the Authorization Bearer token in the HTTP header parameters, you can always specify the bearer token as a query parameter. See the Running a Triggered Task documentation and refer to the "Run a Pipeline using a Bearer token for authentication through the bearer_token query parameter" example.
Hope this helps!
11-28-2023 12:24 PM
Hello @koryknick,
Thanks a lot for this! I actually already saw that documentation and didn't think it would work because I thought that the "bearer_token" query parameter was a specific case used as example.
I was wrong and it worked perfectly first time (I should have tried harder...). Anyway thanks a lot again!
Kind regards,
JF