Check out our Github repo for sample code and examples for creating PNG and VSDX diagrams and connecting cloud environments up with Hyperglance programmatically.
We also have a set of older sample scripts that you can download for appending new attributes onto resources in Hyperglance:
- Augment application tags when the node_UID is known.
- Augment attribute when the node_UID is known.
- Augment attribute when the node_UID is unknown but attribute is known.
- Augment Dependencies when the node_UID of the dependant and the supporter is known.
- Create a topology.
- Delete a topology.
- Get a list of all the nodes, links and endpoints and their corresponding attributes in the Hyperglance server and output it in JSON.
- Get a list of all the topologies in the Hyperglance server and output it in JSON.
To use these older example scripts:
- Generate an API key
- Open config.py in a text editor
- Set the DATASOURCE and API_KEY values to match the values for the API key you generated earlier.
- Set the HGS_URL to point to your running Hyperglance instance.