Creating an APN and an EPG using REST and XML
One of the cool things about using the REST client is that we can run more than one command at a time. We created a tenant and then deleted it. Now we want to create a bridge domain, but need a tenant to go with it. We do not need to create the tenant separately; we can create it at the same time as creating the bridge domain.
How to do it...
- Keep the URL the same as before.
- Enter the following:
<fvTenant name="TenantA"> <fvCtx name="TenantA_VRF"/> <fvBD name="TenantA-BD"> <fvSubnet ip="10.0.0.1/24"/> <fvRsCtx tnFvCtxName="TenantA_VRF"/> </fvBD> </fvTenant>
- Press
Send
.
How it works...
This creates the tenant, the VRF (context), the bridge domain, and the subnet:

The code also associates the VRF to the bridge domain:
