cancel
Showing results for 
Search instead for 
Did you mean: 

How include an authorization token in a Service Task

50022756
Explorer

I want to update the conversation of a SAP Conversational AI chatbot in the last step of my SCP workflow. I've already got this by using Postman but when I try to do it by using a Service Taks of my workflow I noticed that I can't use the Developer Token of the chatbot anywhere... I can't use it in the destination parameters (only admits OAuth2 with clientId and clientSecret that SAP CAI chatbot doesn't have... and I can't include it in any field or the Service Task settings because headers is forbidden so... I've tried to include it into the "request" JSON object (as a similar way of the use of irpaTriggerToken key for iRPA bot callings) but It doesn't work with "token" nor "Authorization" keys.

Anyone knows how include that token code (developer token) in the Service Taks?

View Entire Topic
Archana
Product and Topic Expert
Product and Topic Expert
0 Kudos

Header parameters are not possible in Workflow Service Task.

50022756
Explorer
0 Kudos

Thanks for your reply Archana!

I know there is no way to add Headers but... to call iRPA bot you CAN pass the Header attribute "irpa-trigger-token" with an alternative way: in the Request JSON object with a key called "irpaTriggerToken". My question is about finding a similar way to do this with the SAP Conversational AI API call.

If you must use that Developer token to send a message to the SAP Conversational AI conversation, there must be ANY way to put that token in the request right? If not... would mean that It's impossible to send a message to the SAP Conversational AI conversation from a Service Taks of a SCP workflow (hard to belive, don't you).

Jose.

vbalko-claimate
Active Participant
0 Kudos

You still can use CPI or some other message broker as a proxy for message enrichment.

Not the prettiest solution, but should work.

50022756
Explorer
0 Kudos

Thanks Vladimir! I don't know so much about CPI or the use of message broker but I'll try to investigate it.