Join the Alteryx Community’s Maveryx Summer Cup event! Compete, network with others, and earn your gold through a series of challenges from July 24th to August 11th. Learn more about the event here.

Alteryx Designer Desktop Discussions

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

Getting an access token from OAUTH2

craigja
8 - Asteroid

Im trying to access an API that contains training information on individuals in my company - the API is using OAuth2 to issue a token but I cant get it to do that!  The developer that Im working with, has Postman installed on his machine and can request and get a token without issue but I get the following error:

{"status":"401","timeStamp":"2020-10-28T15:39:25+0000","error":{"errorId":"5b4095aa-e582-43ac-86a1-8508a3e9520c","message":null,"code":"invalid_client","description":"invalid_client","details":null}}

 

I have the Download tool setup as follows (I have put asterisks in place of the actual ClientID and Secret :

craigja_0-1603900725740.png

 

I dont see what Im doing wrong, or different from Postman!  

 

 

14 REPLIES 14
apathetichell
19 - Altair

@alt_tush - @BrandonB would be the one to ask - but I'd strongly recommend posting some information on your errors. API's aren't the kind of thing were you have a lift and shift workflow and suddenly everything is awesome. This is usually because:

 

1) Security. Tokens/ClientIDs/ClientSecrets are specific to individuals and if I'm building a workflow that works for me - it will not work for you unless I compromise my credentials (and vice versa).

2) Wildly different APIs - without knowing what you are building an API for (ie what the API schema is) it can be totally off.

BrandonB
Alteryx
Alteryx

@alt_tush, this is a two download tool process. The first download tool has to call an authentication endpoint and pass the client ID, secret, etc. You put this endpoint in a Text input tool and then follow it with a Download tool where you enter the appropriate headers/payload. 

 

Please take a look at this link for some images of workflow examples and a walk through of working with APIs: https://community.alteryx.com/t5/Engine-Works/APIs-for-Beginners-Integrate-All-the-Systems/ba-p/8074... 

alt_tush
9 - Comet

Hell oapathetichell,

 

Yes, you are right. It is not simply lift and shift the workfow. But I just want to understand the steps if i want to implement the API connectivity using Alteryx what all steps or parameters are required.

 

Thank you for your response :)

bny_abo
6 - Meteoroid

Does anyone have a curl command version of getting the authorization token specifying the API Key and Secret?

apathetichell
19 - Altair

Use postman and toggle to show code.

Labels