I've experienced some issues with NSX-T and how can we automate everything with it.
I had a working fabric that I created manually and now the goal is to automate the entire deployment.
I've been able to automate the deployment of the NSX-T Managers and create some objects but I think the documentation has some serious errors and it's not usable in his current shape. I may be wrong and therefore I would please ask you to accept my apologies in that case. What I am trying to do here is to help in order to make NSX a better product than it is right now (and it is already pretty good as far as I think).
What I wanted to do was to just create an uplink profile using a dead-simple REST API call using Python.
According to the VMware API Doc for 2.5 :https://code.vmware.com/apis/696/nsx-t Here is what I need to do:
Per the documentation, Creates a hostswitch profile. The resource_type is required.
I was lazy and literally did a copy paste of the documentation example but the NSX-T manager wasn't happy about it. I tried to change the value to true/false/null/True/False without any luck
I decided to sniff the API call from the GUI as you guys mentioned that the GUI was just an API consuming tool in order to create the desired state (Quote for Tech Field Day March 2019). To my surprise the API call made using the GUI is clearly different from what the docs mentions (with the URL being different as well).
"https://srv-nsx-manager.vpackets.lab/nsxapi/rpc/call/BaseHostSwitchProfileFacade" instead of https://<nsx-mgr>/api/v1/host-switch-profiles in the documentation
Can you guys tell me how can we troubleshoot that? I logged into the NSX-T Manager using the root account and manage to find the API logs but it has the same error message than what you can see above (resource_type require either true/false/null).
I believe this is a documentation inconsistency and I would like to know how can we move forward automating an NSX-T fabric. What's VMware recommended way?
Also, there is a KB for Postman and NSX-T 2.5 API collection compatibility, can we expect to have it natively accepted into postman in a later release or will we have to deal with this KB again?
This is not the first time this is happening to me and again, I may be wrong and in this case please accept my apologies.
Thanks for letting me and the community know about this, please!