Add Queue through API errror

Hi All,

I am trying to add transactions in to Queue with Postman, but we are getting the below error.

{
“message”: “An error has occurred.”,
“errorCode”: 0,
“resourceIds”: null
}

PFB the details :
End Point used : https://XXXX.com/odata/Queues/UiPathODataSvc.AddQueueItem()
Body :
{
“itemData”: {
“Name”: “Auto_As_A_Service”",
“Priority”: “Normal”,
“SpecificContent”: {
“First”: “Some String Value Here”,
“First@odata.type”: “#String”,
“Second”: 516,
“Fourth”: “Did I skip the Third value?”,
“AnotherKey”: true
}
}
}

Headers : Authorization: Bearer “Token”

I still get the error, please help me out on this one. If this works then we are planning to implement the same using python.
Thanks
Vinod

Hi @vinodcrimson try once check in swagger.

1 Like

@kalyanDev - I have even tried it i get the same error. Authentication works fine, but only this method / api does not work

1 Like

For end point why you have added the these () in the last

@kalyanDev - I got that from the documentation, but now i tried without that too. Still no help.

swagger/ui/index#!/Queues/Queues_BulkAddQueueItems) [/odata/Queues/UiPathODataSvc.BulkAddQueueItems did you tried this.

@kalyanDev - This Endpoint gives me 200 OK Status code but the transanctions are not added to the Queues in Orchestrator. PFB the response message.

**

UiPath Orchestrator
**

Please let me know if anything can be done.

FYI

Orchestrator, Studio ( version : 2018.2.3)

What is the response you got?

!DOCTYPE html>
html lang=“en”>
head>
meta charset=“utf-8”>
meta http-equiv=“X-UA-Compatible” content=“IE=edge”>
meta name=“viewport” content=“width=device-width, initial-scale=1”>
meta name=“description” content="">
meta name=“author” content="">
title>UiPath Orchestrator >/title>
link rel=“shortcut icon” href="/favicon.ico">
base href="/">
link rel=‘stylesheet’ type=‘text/css’ href=’/dist/css/roboto/roboto-fontface.css?v=2018.2.3.0’ />
link rel=‘stylesheet’ type=‘text/css’ href=’/dist/css/noto/noto-fontface-cjk-jp.css?v=2018.2.3.0’ />
link rel=‘stylesheet’ type=‘text/css’ href=’/dist/css/material-icons/material-icons.css?v=2018.2.3.0’ />
link rel=‘stylesheet’ type=‘text/css’ href=’/dist/css/material-icons/material-icons-style.css?v=2018.2.3.0’ />
link rel=‘stylesheet’ type=‘text/css’ href=’/dist/styles.bundle.css?v=2018.2.3.0’ />
/head>
body>
div>>/div>
ui-app>
div class=“loader”>>/div>
/ui-app>
script src=’/dist/inline.bundle.js?v=2018.2.3.0’ type=‘text/javascript’>>/script>
script src=’/dist/scripts.bundle.js?v=2018.2.3.0’ type=‘text/javascript’>>/script>
script src="/signalr/hubs">>/script>
script src=’/dist/main.bundle.js?v=2018.2.3.0’ type=‘text/javascript’>>/script>
/body>
/html>

did you got same in swagger if yes then check once with support team. and you are getting 200 ok status but items are not adding right?

@vinodcrimson

The base API Call works using Cloud Orchestrator 2019.10 (My current version @ platform.uipath.com). It is certainly without the “()”.

I took your body, and changed the Name property to the name of a test queue I maintain. Put it into Postman, and it worked.

I do not know if there was a bug in Orchestrator 2018.2.3, but the API request absolutely works in 2019.10.

– Michael

@mjdeale - could you please let me know what have you used in headers?

Because it works fine when I try from swagger. So I don’t think we have a problem in API.

1 Like

@kalyanDev
it works fine when I try from swagger. So I don’t think we have a problem in API

Attached are my headers from Postman, though, remember I am using the 2019.10 Cloud Orchestrator. that means i have the latest version of the REST API and Orchestrator. If you are on 2018.2 (Like I think you are), your headers probably won’t include the FolderPath or the TenantName, but might include the OU.

– M

Hi Michael,

I have the same issue with empty data out of API calls. In Postman - fine; Authorization works; API call actually works (200 OK); the same 4 headers, but still no data out of GET/POST requests (excl. POST Authorization request that works).

Have you found a solution?

Best

Andrey

1 Like

Hi @mjdeale @vinodcrimson

I m also facing a similar issue, but in my issue is explained better in this post:

if any one of you got any solution to this type of problem your help is highly appreciated.

Thanks
Anil Kumar

@Anil_choudhary

Replied to you on the other thread. I think you are missing the X-UIPATH-DefaultFolder header.

Example headers in Postman are in an image in an earlier post on this thread.

Hi,

Thanks a lot for your reply but i guess, its something to do with the Authentication and cloud servers.
Yes i added all the details.

Thanks

HI Anil/Vinod / All
Can you please share the code which works to add items to Queue using API

I am currently working on this scenario where i need to update the queue items using API

Please help me in this regards

Srini