The FusionExport SDK in Python
Project description
Language SDK for FusionExport which enables exporting of charts and dashboards through Python.
Installation
To install this Python package, use pip:
pip install fusionexport
Usage
To use the SDK in your project:
from fusionexport import ExportManager, ExportConfig
Getting Started
Start with a simple chart export. For exporting a single chart just pass the chart configuration as you would have passed it to the FusionCharts constructor.
from fusionexport import ExportManager, ExportConfig # Import sdk # Instantiate the ExportConfig class and add the required configurations export_config = ExportConfig() export_config["chartConfig"] = [{ "type": "column2d", "renderAt": "chart-container", "width": "600", "height": "400", "dataFormat": "json", "dataSource": { "chart": { "caption": "Number of visitors last week", "subCaption": "Bakersfield Central vs Los Angeles Topanga" }, "data": [{ "label": "Mon", "value": "15123" },{ "label": "Tue", "value": "14233" },{ "label": "Wed", "value": "25507" } ] } }] # Instantiate the ExportManager class em = ExportManager() # Call the export() method with the export config and the output location exported_files = em.export(export_config, "./exported-charts", True) # print list of exported files print(exported_files)
Now run this file, then the exported chart files will be saved in ./exported-charts folder.
API Reference
You can find the full reference here
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size fusionexport-1.2.0-py2.py3-none-any.whl (10.2 kB) | File type Wheel | Python version py2.py3 | Upload date | Hashes View |
Filename, size fusionexport-1.2.0.tar.gz (8.3 kB) | File type Source | Python version None | Upload date | Hashes View |
Close
Hashes for fusionexport-1.2.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 43cd0d23b4b2454679f159914d2a29f3c530e1bb6fdfc035b5779c9d2ffce291 |
|
MD5 | aecc6a1d9f63915a4a61e7687b576ed0 |
|
BLAKE2-256 | 73fbb204e9497444b0417408ff394dbb7252402c0c9decc7116ab46553916f04 |