Thursday, June 9, 2016

How access NSX through APIs


When talking about automation,  the capability of receiving remote calls is the success factor of any plataform, might be via command line or API calls.
VMware NSX is not an exception, providing APIs functionality you can monitor, manager and troubleshoot it remotely.

This post is more a personal reference, so I can always come back and check  how to access it, but it can also help others starting on this field .

First of all, you need a API client to issue commands to your remote system. There are a lot of them out them, personally I’m using the RestClient.

To start issuing commands you need to provide the proper credentials to access NSX.
-       On the upper bar Click on Authorization and then on Basic Authentication;


-       Provide the username and password with the required privileges;
-       Click OK;


Now we need to set up the header
-       On the upper back, click on Headers and then on Custom Header;


-       For Name, type: Content-Type;
-       For Value, type: application/xml;
-       Click OK;


Before running any command make sure the Authentication and Header are always present.


Let’s make a test to guarantee  everything is configured properly.
-       For method, select: GET;
-       For URL, type: https://"nsx_manager"/api/1.0/appliance-management/global/info
-       Click Send;


If you see the version of your NSX Manager as the example above, everything is set up correctly.

Pretty cool right ?!?! So why don’t you download NSX vSphere API Guide and create some amazing stuff  ?!?!?
 

1 comment:

Suseela Susiee said...

Great and useful article. Creating content regularly is very tough. Your points are motivated me to move on.


SEO Company in Chennai

Post a Comment

Who am I

My photo
I’m and IT specialist with over 15 years of experience, working from IT infraestructure to management products, troubleshooting and project management skills from medium to large environments. Nowadays I'm working for VMware as a Senior Consultant, helping customers to embrace the Cloud Era and make them succefully on this journay. Despite the fact I'm a VMware employee these postings reflect my own opnion and do not represents VMware's position, strategies or opinios.

Most Viewed Posts

Blog Archive