Alteryx Designer Desktop Discussions

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

Connection with API error code 415: Unsupported Media Type

Muhummad_Solehudin
7 - Meteor

image.png 

I have a problem when connect with API, the connection have the error 415 Unsupported Media Type that I don' know to solve it.

This is my URL API

Muhummad_Solehudin_1-1634699430329.png


and this is the download tool configuration 

 

Muhummad_Solehudin_2-1634699507555.png

Muhummad_Solehudin_3-1634699533095.png

 

 

9 REPLIES 9
apathetichell
18 - Pollux

try hardcoding Name Content-Type with a Value of application/problem+json in your header tab in the download tool.

 

my usual strategy is run in Postman and then transcribe to Alteryx...

 

also your query string/body probably isn't the same as your URL - but you have it set as such.

Muhummad_Solehudin
7 - Meteor

I've tried this one but still same error

apathetichell
18 - Pollux

does it work in Postman?

swadson
7 - Meteor

Looking for a solution for this. Any help appreciated. I am trying to get a JWT by sending a POST call, but I get a similar error message

 

HTTP/1.1 415 Unsupported Media Type
Server: Kestrel
X-Powered-By: ASP.NET
Date: Mon, 24 Apr 2023 14:24:46 GMT
Content-Length: 0

 

When i use Postman, I get the JWT without any error. I am unable to configure the Alteryx Download tool

 

 

swadson_0-1682351886475.png

 

swadson_1-1682351967626.png

 

apathetichell
18 - Pollux

@swadson Postman autogenerates content-type - it's probably something like json/application - hard code this value in headers (ie content-type/json/application) - re-run.

swadson
7 - Meteor

@apathetichell  - Thank you!

 

I am not sure if I am doing it right. Below is the change I that I did. 

 

swadson_0-1682354420172.png

 

 

Now I get  Bad request error

 

HTTP/1.1 400 Bad Request
Content-Type: text/html; charset=us-ascii
Server: Microsoft-HTTPAPI/2.0
Date: Mon, 24 Apr 2023 16:38:55 GMT
Connection: close
Content-Length: 339

 

 

swadson
7 - Meteor

@aparthetichell - By the way, I am making this API call to an application that was built by our vendor.

apathetichell
18 - Pollux

@swadson- what does postman say is your content-type? I usually just hardcode it - as opposed to sending in a field (click add in the section above on the headers screen) see if postman creates other headers which are not replicated by Alteryx. You can also toggle on the code section of Postman (right options) to see the Curl command - basically you will be replicating that in Alteryx.

 

honestly there's some nuance here - and sometimes nuance within the Content-Type but the 415 error usually refers to that.

swadson
7 - Meteor

@apathetichell - I found the issue, seems like content-type is case sensitive. I am able to get the JWT now. Thank you!!

Labels