Requesting token

Hi!

I have entered my information to get POST a request for my token, but it seems to be only responding with an HTML.

I selected POST
URL: https://cloud.uipath.com/{personal}/n8nflow/identity_/connect/token
Header: Content-Type application/x-www-form-urlencoded
Body Content Type: Raw
Content Type: application/x-www-form-urlencoded
Body; grant_type=client_credentials&client_id={personal}&client_secret={personal}=OR.Execution OR.Jobs OR.Users

I have tried multiple different approaches to how I enter my data, but it seems to always be outputting the HTML.

JSON of HTML output:

[
{
“data”: “<html lang="en"><base href="/identity_/web/">\n <meta charset="utf-8">\n UiPath\n\n <meta name="viewport" content="width=device-width, initial-scale=1">\n <meta http-equiv="X-UA-Compatible" content="IE=edge">\n <link rel="icon" type="image/x-icon" href="favicon.png">\n <link rel="stylesheet" type="text/css" href="css/material-icons/material-icons-fontface.css" media="print" onload="this.media=‘all’"><link rel="stylesheet" href="css/material-icons/material-icons-fontface.css">\n <link rel="stylesheet" type="text/css" href="css/noto/noto-font-jp-zh-woff.css" media="print" onload="this.media=‘all’"><link rel="stylesheet" href="css/noto/noto-font-jp-zh-woff.css">\n <link rel="stylesheet" type="text/css" href="css/noto/noto-font-jp-zh.css" media="print" onload="this.media=‘all’"><link rel="stylesheet" href="css/noto/noto-font-jp-zh.css">\nhtml,body{height:100%}body{margin:0;font-family:Roboto,Noto Sans JP,Noto Sans SC,Helvetica Neue,Arial,sans-serif}<link rel="stylesheet" href="styles.11b6763be3459e56.css" media="print" onload="this.media=‘all’"><link rel="stylesheet" href="styles.11b6763be3459e56.css">\n\n\n \n<script src="runtime.4c1047318e93a4c9.js" type="module"><script src="polyfills.91c5477eede06776.js" type="module"><script src="main.fb5427bd8de206d4.js" type="module">\n\n\n”
}
]

Hi @Kieron_Smyle

Could you please confirm n8nflow is your tenant name? I see you are passing org name as well as tenant name. Please remove tenant name.

Endpoint only needs to be like below:
https://cloud.uipath.com/{your org name goes here}/identity_/connect/token

for e.g. if my org name is sonali, it should look like below:
https://cloud.uipath.com/sonali/identity_/connect/token

it will work.

Can you check this article?

https://uipath.my.salesforce-sites.com/CaseView/articles/en_US/Knowledge/How-To-Make-Orchestrator-API-Requests-Using-HTTP-Request-Activities-or-Orchestrator-HTTP-Request

Check this step by step guide:

Check if you built the token retrieval as below:

Method: POST
URL: https://cloud.uipath.com/identity_/connect/token
Body as x-www-form-urlencoded