THE GAME HAS CHANGED

Introducing Infoblox Universal DDI ManagementTM

Watch the launch to discover the new era of management for critical network services. Watch Now

API & Integration, DevOps,NetOps,SecOps

Reply

Standard REST examples to retrieve networks that contain specific Extensible Attribute information.

New Member
Posts: 1
2330     0

I am a extreme novice when it comes to scripting. I was asked to investigate this. I need to know the REST calls that would be needed to search for a certain extensible attribute and return all associated data.

 

Here is an example question posed to me by one of our network Architects:

 

For instance if I have a request for say NPT rack 1311, and I am trying to obtain the subnet and VLAN ID, here is what the attributes would be under the network:

 

10.88.10.0/24

Country: USA

City: Freeport

LocationName: NPDC

NetworkRegion1: Data Center

NetworkRegion2: Management 

NetworkRegion3: 

VlanTag: 310

ContactGroup: Unix Support

ContactNumber: 412-555-1234

ConactEmail: unix_support@somewhere.com

L3GwRouters: nptpe03,nptpe04

Switches: nptsx301, nptsx302, nptsx304, nptsx205, nptsx401

Redundancy: N+1

Transport: DarkFiber

Carrier: null

 

10.88.11.0/24

Country: USA

City: Freeport

LocationName: NPDC

NetworkRegion1: Data Center

NetworkRegion2: Management 

NetworkRegion3: 

VlanTag: 311

ContactGroup: Unix Support

ContactNumber: 412-555-5555

ConactEmail: unix_support@somewhere.com

L3GwRouters: nptpe03,nptpe04

Switches: nptsx301, nptsx302, nptsx304, nptsx205,  nptsx102, nptsx1023, nptsx455

Redundancy: N+1

Transport: DarkFiber

Carrier: null

 

 

So if a REST call occurred with:

 

Location: NPDC

NetworkRegion1: Data Center

NetworkRegion1: Management

 

 

I would expect to get back those 2 networks with the other associated extensible attributes.

 

What I need from Infoblox support are what REST calls are to make such a query to their API.

Re: Standard REST examples to retrieve networks that contain specific Extensible Attribute informati

Adviser
Posts: 181
2331     0

Hi,

 

Extensible attributes require a special search syntax. Searches for extensible attributes are sent by prefixing the extensible attribute name with an asterisk (*).

 

You can search for networks based on Extensible Attributes like below:

curl -k -u admin:infoblox -X GET "https://grid-master/wapi/v2.11/network?_return_fields%2B=extattrs&*Location%3A=NPDC&*NetworkRegion1%3A=Data%20Center&*NetworkRegion2%3A=Management&_return_as_object=1"

The %3A is URL encoding for ":" which makes the search case insensitive and %20 is URL encoding for a space.

 

Hope this is helpful,

Thanks and regards,

Krishna

Showing results for 
Search instead for 
Did you mean: 

Recommended for You