Export card data using Python, PyDomo
Good afternoon, I would like to download card data in csv directly from python using PyDomo, would it be possible?
The function I was trying to use is
domo.page_get_collections
But I didn't have much success, could someone explain to me how I can export this data from the card to python? I want to send to aws automatically
Answers
-
Hi @JR_Iron, have a look through this article [https://developer.domo.com/docs/dataset/import-and-export-data], including sample request codes in Python, to see if you can export your data that way.
10 -
Are you wanting the data exported after it's been processed by the card? You could attempt to mimmic the logic the card is doing using the DataSetClient.query method and query the dataset. You may need to inspect the network traffic to get the exact logic it's using to filter your dataset. Alternatively you could hack the backend APIs using the requests module and call the render endpoint to generate the data and pull it out of the resulting JSON. Depends on how technical you want to get with it. As a warning these APIs are unsupported and can change at any time if you're attempting a direct API connection. the CLI and pydomo packages are supported.
**Was this post helpful? Click Agree or Like below**
**Did this solve your problem? Accept it as a solution!**1 -
So it's not as simple as I thought, I would have to get the complete dataset, set the necessary filters and set the necessary fields to get the desired formatting.
I know there is a way to get the page and page collection, but I don't see any option to retrieve the data directly from the card, with its specific formatting and filters.
0 -
The data is returned when you call the render endpoint. You can pass in your filters / query overrides as part of the PUT request. Inspect the network traffic for the render endpoint when you go to a card and that'll show you the request it's making and the data points from the card in the returning JSON.
**Was this post helpful? Click Agree or Like below**
**Did this solve your problem? Accept it as a solution!**0
Categories
- All Categories
- 1.8K Product Ideas
- 1.8K Ideas Exchange
- 1.5K Connect
- 1.2K Connectors
- 297 Workbench
- 6 Cloud Amplifier
- 8 Federated
- 2.9K Transform
- 100 SQL DataFlows
- 616 Datasets
- 2.2K Magic ETL
- 3.8K Visualize
- 2.5K Charting
- 729 Beast Mode
- 54 App Studio
- 40 Variables
- 678 Automate
- 173 Apps
- 451 APIs & Domo Developer
- 46 Workflows
- 8 DomoAI
- 34 Predict
- 14 Jupyter Workspaces
- 20 R & Python Tiles
- 394 Distribute
- 113 Domo Everywhere
- 275 Scheduled Reports
- 6 Software Integrations
- 121 Manage
- 118 Governance & Security
- Domo Community Gallery
- 32 Product Releases
- 10 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 108 Community Announcements
- 4.8K Archive