Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Download Tool/API Help

craigja
8 - Asteroid

Hi,

 

Im trying to connect to an online API to download some information (this is a cloud based application that has some of our company data in it, its not public data).  The team was using PowerAutomate but the process they had was taking over an hour - Alteryx completes it in under 1 second 😁 .  So Im trying to replicate the API call that PowerAutomate calls to get the initial data (I then will need to parse the JSON, so expect anther help request!).  The PowerAutomate HTTP2 tool, has the URL and 3 required fields and works fine, returning JSON data

 

  • Authentication - which when I look at the code that PowerAutomate creates/runs it seems to be called Type and is set to Basic, but Ive tried using Type and Authentication and neither works
  • Username
  • Password.

 

Ive tried configuring the download tool and have tried adding Authentication/Type, username and password in the headers section and also in the payload section and also tried entering the username and password in the Connection section, but all I get is {"Error":"Authorization header not found."} HTTP/1.1 400 Bad Request

 

Does anybody have anything else I can try?

2 REPLIES 2
CoG
13 - Pulsar

This might be a great question for your IT team or whoever on the IT team manages the internal API to get proper implementation/framework. That being said the standard for basic auth for API call is a single header field that looks like this:

"Authorization: Basic [base64(username:password)]"

 

So if username is: "ServiceAccount100"

and password is: "SuperSecret123!"

 

Then you first need to join the username and password with colon: "ServiceAccount100:SuperSecret123!"

Then Base64 encode it: "U2VydmljZUFjY291bnQxMDA6U3VwZXJTZWNyZXQxMjMh"

 

So your final header field for the API call would look like:

"Authorization: Basic U2VydmljZUFjY291bnQxMDA6U3VwZXJTZWNyZXQxMjMh"

 

Or in the Download Tool it could look like:

NameValue
AuthorizationBasic U2VydmljZUFjY291bnQxMDA6U3VwZXJTZWNyZXQxMjMh

 

craigja
8 - Asteroid

That has worked perfectly!

Labels