Exporting visual artifacts with REST APIs
This is a sample Python code snippet for authenticating and submitting the
GET
request that exports dashboards with IDs 2115 and 2110, and then
writing the response to the my_app.json file.
export requests headers = {'AUTHORIZATION':'apikey secret_api_key'} payload = {'dashboards': '[2115, 2110]', 'filename': 'apitestmigration', 'dry_run':'False'} r = requests.get('source_arcviz_ip/arc/migration/api/export/', headers=headers, params=payload) with open('my_app.json', 'w') as f: f.write(r.text)