Automated Data Downloads via Rest API?

  • 1
  • Question
  • Updated 3 years ago
  • Answered
Archived and Closed

This conversation is no longer open for comments or replies and is no longer visible to community members.

I would like to query the Rest API to pull down all of my trip information in an automated fashion, so that I can analyze the data with my own local tools.  I would like do this without having to redirect the information to a web site, but rather directly to my laptop making the request, regardless of where I am in the world. 

Also, when I share my App, I do not want to be the centralized data repository for everyone's data that would like to use it.  They would use their credentials to pull down their own data for analysis with a copy of the framework that I will build.  

It would also be nice to be able to send a flag, where one would only pull down new trips that have not yet been downloaded.

 Can I do this with the Rest API as it is today?
Photo of Jim

Jim

  • 92 Points 75 badge 2x thumb

Posted 3 years ago

  • 1
Photo of Adam Altman

Adam Altman, Alum

  • 3,712 Points 3k badge 2x thumb
Hi Jim, 

You can do this with the rest API, but it may be *much* easier for you to just download them from our web Dashboard @ http://dashboard.automatic.com
There, in the trip list on the right hand column, the very bottom has an export button.  That will give you the ability to download all of your trips into CSV format.  

-Adam
Photo of Jim

Jim

  • 92 Points 75 badge 2x thumb
I am missing how I can do this with the Rest API without the "CODE_FROM_AUTHORIZE_URL", which seems to require a website to confirm authentication.  Can I just change my Redirect URL to your site?

I have a very hard requirement to automate this with zero clicks.  
Photo of Xxxxx

Xxxxx

  • 314 Points 250 badge 2x thumb
Could this be taken off a Support forum and redirected to Suggestions? It does not help me to read about someone's technical issues that th Automatic and the app were not designed for.
Photo of Tom

Tom, Former Employee

  • 41,706 Points 20k badge 2x thumb
Hi there, WeenzWorld! This question was a bit more technical as it was related to our API, but we certainly welcome questions of this nature here in the community. If you're not familiar with what an API is, you may find this article helpful. To learn more about our API specifically, check out this FAQ.
(Edited)
Photo of Xxxxx

Xxxxx

  • 314 Points 250 badge 2x thumb
I guess I can "unfollow" questions, but I would much rather opting in to a developer forum.
Photo of Tom

Tom, Former Employee

  • 41,706 Points 20k badge 2x thumb
If you're interested in unsubscribing for email alerts on new community topics, you can do so by clicking on your name at the top of this page. Then click on "Profile" from the drop down menu that appears:




On the next page, click on the "Email & Notifications" heading: 



On the following page, you can uncheck the boxes next to the alerts you no longer want to receive and click on the "Save Emails & Notifications" and "Save Company Notifications" buttons respectively to confirm. Just note that your profile will state "Automatic" instead of "Apple" (as shown in the screenshot below):
(Edited)
Photo of Brendan Nee

Brendan Nee, Alum

  • 780 Points 500 badge 2x thumb
It can be automated once you get an access token. Just visit your authorize URL, log in once, manually copy the 'code' parameter from the URL you get redirected to (its ok if it doesn't exist, just get it from your browser's address bar) and then do a curl request to get an access token using the preformatted curl request from the developer dashboard. 

After you get the access token, you can automate requesting trips, including requesting only trips that happened after a specific date, using the optional `start` parameter.
Photo of Jim

Jim

  • 92 Points 75 badge 2x thumb
Thank you Brendan, I am able to access the rest API through this method.  I was thrown by the URL, since mine is currently not up.  

Thank you again!

Jim

This conversation is no longer open for comments or replies.