Authentication of http task

I want to do a GET & POST API call and the best task to do this is HTTP task but I am not getting the options to send the authentication details like user id password or certificates.

can someone guide me on how to do this?

Hey @ROY, what exactly you are looking for? I am not an expert, but the way I used HTTP task is to add a header “Authentication” and provide relevant value (Basic auth in my case).

HI @kamilk , thanks for your response.
I am using password and certificate-based authentication in my API calls.

For Password: I am able to send the header “authentication: Basic xxxxx” and it works
but how do I create this xxxx (encoded password)
For Certificate: how do I send the certificate along with my HTTP request.

Hey @ROY

As per value for the header, I guess you either get that as a variable provided somehow during process (form, REST, etc.) or you might want to take it from environment variables setup when spinning up Flowable (Shell task could help here to retrieve it, store as variable and then use in espression). You might want to use Shell/Script tasks to do the dirty work for you.

As per simple TLS (I guess this is what you are looking for), it might be as “simple” as adding certificates (JKS, truststore etc. files) to Flowable deployment and add java/spring related properties to Flowable process. If I understand it correctly, then HTTP client underneath will trigger HTTP requests with desired TLS in place. If that won’t work, then you might need to play with Flowable code to achieve that.

I didn’t try all of the above, but I’ve been playing with Flowable for some time and while it might not offer all features out of a package, I was able to achieve a lot by connecting different task types (including scripting).

You have to consider that if your requirement is too complex to be done by low/no-code Flowable components, you might want to develop small facade (web) service for handling complex REST calls to downstream systems and call it from Flowable.

1 Like