Issue with the servicenow- uipath spoke integration: actions not passing inputs

Gaurav Vaze
Kilo Sage

Hello experts,

I am working on integration request to integrate with UiPath

I have installed the spoke and connection is done

Now when I am trying to use the action Add Item to Queue, I was getting dynamic input error

after diving deep, I saw the 2 interdependent actions- Get Folders and Get queues were turned off, so I copied them and activated

Yet I had same error for queue name

so instead, I used the toggle script and returned the queue name

Now the main problem is I want to pass the specific content in the form of array.object form, which I managed through script
but when the action is fired, even when the input is going well, I see output as Null

The queue is getting fired at Uipath but yet the specific content is not there

GauravVaze_0-1768581004997.pngGauravVaze_1-1768581111363.png

 



Has anyone previously worked on UiPath integration, and know the workaround then please LMK

any help will be highly appreciated

Thank you!

 

 

Gaurav Vaze

ServiceNow Developer

8 REPLIES 8

Matthew_13
Mega Sage

Hi Buddy,

This looks like a payload/serialization issue rather than the queue failing.

UiPath will still create the queue item even if the SpecificContent you send doesn’t match what Orchestrator expects — in that case it just comes through as null, which is exactly what you’re seeing.

What usually fixes it:

  • Send SpecificContent as a simple key/value object (dictionary), not an array and not a JSON string.
    If you’re doing JSON.stringify(), remove that and pass the object directly.

  • Confirm what ServiceNow is actually sending outbound.
    Turn on spoke/execution logging and compare the request body to a working Postman call to UiPath’s “Add Queue Item” API.

  • If the spoke action still won’t map it correctly, the workaround is to skip the spoke for this part and use a direct RESTMessageV2 call so you can control the exact JSON body.

Basically: UiPath expects SpecificContent = key/value JSON, and if it’s sent in the wrong structure, it gets ignored and ends up null.

 

@Gaurav Vaze - Please mark Accepted Solution and Thumbs Up if you find Helpful 🙂

MJG

Hello @Matthew_13 

I have tried using sending only object instead of array or string

example

var input = {
    "Request item": "RITM0729860",
    "Requested for": "Angelica Cartagena",
    "Type of Request": "Creation of New Pool",
    "Pool Name": "Geriatrics Registration Pool - Belmont",
    "List of Users/Members": "Angelica Cartagena, Hector Sanchez Vazquez, Monika Carbonell Ayala",
    "Category Of Request": "Add Pool",
    "Pool Owner/Lead": "Angelica Cartagena"
};

return input;

But the results are the same giving Specific Content as Null

 

 

 

Hi Buddy,

ServiceNow ignores return in Flow Designer.
That’s why Specific Content = null.

You must assign the value to outputs.

Working fix:

outputs.specific_content = JSON.stringify({
    "Request item": "RITM0729860",
    "Requested for": "Angelica Cartagena",
    "Type of Request": "Creation of New Pool",
    "Pool Name": "Geriatrics Registration Pool - Belmont",
    "List of Users/Members": "Angelica Cartagena, Hector Sanchez Vazquez, Monika Carbonell Ayala",
    "Category Of Request": "Add Pool",
    "Pool Owner/Lead": "Angelica Cartagena"
});

Rule to remember:
return
outputs.<name>

 

@Gaurav Vaze - Please mark Accepted Solution and Thumbs Up if you find Helpful 

MJG

Going with that direction, I also created an action that can return the expected input as key value pair

but even that is resulting in the same

and talking about your script, your previous response and this one are contradictory

1st response- 

  • Send SpecificContent as a simple key/value object (dictionary), not an array and not a JSON string.
    If you’re doing JSON.stringify(), remove that and pass the object directly.

Second one is using the same method

JSON.stringify({
    "Request item": "RITM0729860",

This is quite confusing
do you have any working example where have used the uipath spoke action and passed inputs?