API & Code Samples

“I want to try this for myself, but I’m not a developer. Where can I find examples that I can copy & paste?”

>

That's one of the main reasons for this site's existence.  To work with our valuable developer community and make sure you have the resources you need, when developing on or with Nutanix.

What languages will we include?

>

As this list of resources gets built, code samples will be based on Python 3.6, Bash scripting, PowerShell and C#.  Community feedback indicates these choices are the most commonly mentioned languages when script samples are requested, although additional languages may be added over time.

Where can I just browse them all in one place?

>

Because we're focused on making these samples as accessible as possible, all samples below are distributed on the NutanixDev Github.

VM Management

RequirementsDescription
Python 3.6Prism Central, API v3Create a Nutanix VM with basic required spec, using Python 3.6 and the Prism REST API v3.
Python 3.6Prism Central, API v3Create a Nutanix VM with very detailed spec, using Python 3.6 and the Prism REST API v3.
Bash scriptPrism Central, API v3Create a Nutanix VM with very detailed spec, using Bash script and the Prism REST API v3.
PowerShellPrism Central, API v3Create a Nutanix VM with basic required spec, using Microsoft PowerShell and the Prism REST API v3.

Cluster Management

C# Console AppPrism Central, API v3List all VMs on a specified cluster using a Microsoft C# Console App and the Prism REST API v3.

Storage Management

RequirementsDescription
Python 3.6Prism Element, API v2.0Create a Nutanix Image Services image using Python 3.6 and the Prism REST API v2.0.