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.6K Connect
- 1.2K Connectors
- 300 Workbench
- 6 Cloud Amplifier
- 9 Federated
- 2.9K Transform
- 102 SQL DataFlows
- 626 Datasets
- 2.2K Magic ETL
- 3.9K Visualize
- 2.5K Charting
- 753 Beast Mode
- 61 App Studio
- 41 Variables
- 692 Automate
- 177 Apps
- 456 APIs & Domo Developer
- 49 Workflows
- 10 DomoAI
- 38 Predict
- 16 Jupyter Workspaces
- 22 R & Python Tiles
- 398 Distribute
- 115 Domo Everywhere
- 276 Scheduled Reports
- 7 Software Integrations
- 130 Manage
- 127 Governance & Security
- 8 Domo Community Gallery
- 38 Product Releases
- 11 Domo University
- 5.4K Community Forums
- 40 Getting Started
- 30 Community Member Introductions
- 110 Community Announcements
- 4.8K Archive