Passing a Binary File Body Through Xano External API

Options

Hi All,

I am attempting to upload a CSV to external service using an API (storage.googleapis.com).

My process involves creating a CSV file from a data source and sending it through the API via a PUT request.

I have the first part of the process which creates a CSV file working.

I also have the second part of the process responsible for the PUT call working in Postman.


Running the the first part, manually downloading the CSV, and passing through the CSV Postman gives me my desired outcome.

I have to merge the second part of the process from Postman into Xano and I am struggling converting the binary body into a suitable parameter inside of Xano.

Any ideas on how I can structure my parameters to handle the CSV file. I have tried a few different options but have failed to get that sweet 200.

Any assistance will be greatly appreciated.

Thanks.

Best Answer

Answers

  • Michael Cafra
    Options

    Hey Michael,

    I was able to crack the code with your assistance. I was close but finally found the solution that worked was passing the file resource by itself exclusive of its key-value pair parameter.


    Thanks for your support.

  • Michael Udinski
    Michael Udinski Administrator

    ADMIN

    Options

    Great! Yeah - each API can be different so it's good to read the provider's docs to see how they require a parameter to be sent

  • vnihoul77
    vnihoul77 Member
    Options

    Hi, I have the exact use case and I would need this feature too.

    We need to pass the binary body into the body, which works in Postman but not in Xano.

    In the meantime, we used Make to achieve the upload part, but it's frustrating to use and pay for another tool just for a workflow action.

  • Michael Udinski
    Michael Udinski Administrator

    ADMIN

    Options

    Hi @vnihoul77 - did you try the method that worked above for the other member?

  • endrefyl
    endrefyl Member
    Options

    Did anyone manage to find a workaround for this?