Download .CSV via external API

Hello,
I’m using Appgyver to create a website in which a user passes in their username and pin and can download their data in the form of a .CSV file for use on their computer.

At the moment I have an external API in which when hit downloads a .CSV file. I understand that the data tab in composer expects the data sent and received to be in JSON format so can’t use that method to connect to the API.

I want to be able to hit the endpoint with a JSON POST request with the following body:

HTTP Method: POST
HTTP Request Type (Content-Type): application/json
HTTP Body example:
{
“username”: “test”,
“pin”: “1111”
}
HTTP Response Type (Accept): application/xml

Is there a proper method for achieving this? I’ve tried using a HTTP request (see below), but to no avail. And am now a bit stuck, i’d say the documentation is a bit lacking.

Thanks for your help!

1 Like

Hi, were you able to implement this? You can put “accept: application/xml” in the list of headers.

1 Like