API Call to Download Data using Usertoken

  • 0
  • 1
  • Question
  • Updated 6 months ago
  • Answered
I am having problems with an API call to download a CSV file. The application requires a log in, however I am having problems authenticating when using a user token.

API call:

https://<company.quickbase.com>... <DBID>?a=q&qid=29&dlta=xs%7E&ridlist=29561&usertoken=<usertoken>

When I attempt to use the API call on a browser in which I am already logged in, I have no problem downloading the .csv, so I know the API call is correct, however, when I switch to different browser, Quickbase tells me I need to sign in, despite my inclusion of my usertoken.

How do I fix my API call? (Thanks in advance)
Photo of Noah McBride

Noah McBride

  • 356 Points 250 badge 2x thumb

Posted 6 months ago

  • 0
  • 1
Photo of Charlie

Charlie

  • 294 Points 250 badge 2x thumb

Hi Noah,

 

for this I would suggest using API_GenResultsTable, which has a csv option, and also permits usertoken as a parameter. Here's an example:

 

https://mcftech.quickbase.com/db/<dbid>?a=api_genresultstable&qid=1&options=csv&usertoken=<usertoken>

 

This should immediately force a csv download in your browser. Hope that helps!

 for ref: https://help.quickbase.com/api-guide/index.html#gen_results_table.html%3FTocPath%3DQuick%2520Base%25...

Charlie
(Edited)