Creating Applications and Tiers
Operations for Networks provides APIs to create Applications and Tiers.
A Tier definition is based on membership criteria that can either be search based or IP address/subnet based. These applications and tiers can be used to fetch the recommended rules based on the traffic flow recorded by VMware Aria Operations for Networks from the environment.
Create an Application
Prerequisite
Ensure that you have the name of the application. Name must be unique and must not conflict with an existing application in the system.
Procedure
To create the application, make a POST request. For example:
Request POST https://operations-for-networks.example.com/api/ni/groups/applications Request Body { "name" : "App-1", } Response Body { "entity_id": "18230:561:271275765", "name": "App-1", "entity_type": "Application", "create_time": 1509410056733, "created_by": "admin@local", "last_modified_time": 0, "last_modified_by": "" }
Create a Tier Using Search Membership Criteria
Prerequisite
Ensure that you have the entity ID of the application. Name of the tier must be unique.
Procedure
To create the tier, make a POST request. For example:
Request POST https://operations-for-networks.example.com/api/ni/groups/applications/18230:561:271275765/tiers Request Body { "name": "tier-1", "group_membership_criteria" : [ { "membership_type": "SearchMembershipCriteria", "search_membership_criteria": { "entity_type" : "VirtualMachine", "filter": "security_groups.entity_id = '18230:82:604573173'" } } ] } Response Body { "entity_id": "18230:562:1266458745", "name": "tier-1", "entity_type": "Tier", "group_membership_criteria": [ { "membership_type": "SearchMembershipCriteria", "search_membership_criteria": { "entity_type": "VirtualMachine", "filter": "security_groups.entity_id = '18230:82:604573173'" } } ], "application": { "entity_id": "18230:561:271275765", "entity_type": "Application" } }
Create a Tier Using IP Address Membership Criteria
Prerequisite
Ensure that you have the entity ID of the application. Name of the tier must be unique.
Procedure
To create the tier, make a POST request. For example:
Request POST https://operations-for-networks.example.com/api/ni/groups/applications/18230:561:271275765/tiers Request Body { "name": "app-1-tier-2", "group_membership_criteria": [ { "membership_type": "IPAddressMembershipCriteria", "ip_address_membership_criteria": { "ip_addresses": [ "11.122.2.212", "11.122.1.0/24" ] } } ] } Response Body { "name": "app-1-tier-2", "group_membership_criteria": [ { "membership_type": "IPAddressMembershipCriteria", "ip_address_membership_criteria": { "ip_addresses": [ "11.122.2.212", "11.122.1.0/24" ] } } ], "application": { "entity_id": "18230:561:271275765", "entity_type": "Application" } }