REST API Not working
Hi Experts,
We are working on a quick POC to integrate InfoBlox in our project to fetch free IP and DNS records using InfoBlox REST APIs. However we are getting as
{ "Error": "AdmConProtoError: Invalid reference: network/Tkpd4kdvgmsPneJQZ5INXl1gnEZpd0Wvoe4:192.167.20.0/24/default",
"code": "Client.Ibap.Proto",
"text": "Invalid reference: network/Tkpd4kdvgmsPneJQZ5INXl1gnEZpd0Wvoe4:192.167.20.0/24/default"
}
What i did was as per API doc executed
https://192.168.x.70/wapi/v2.0/networkview?_return_type=json-pretty&name=default
This gives something like
{
"_ref": "networkview/ZG5zLm5ldHdvcmtfdmlldyQw:default/true",
"is_default": true,
"name": "default"
}
It is interesting to see we are getting EXACTLY same response as mentioned in API doc even the "ZG5zLm5ldHdvcmtfdmlldyQw" so seems this code in hardwired for a particular kind of object
Now i have so many objects how would i know what this code is and how would i get it?
Am i trying something completely wrong?
I have no clue about API just doing some POC
We are working on a quick POC to integrate InfoBlox in our project to fetch free IP and DNS records using InfoBlox REST APIs. However we are getting as
{ "Error": "AdmConProtoError: Invalid reference: network/Tkpd4kdvgmsPneJQZ5INXl1gnEZpd0Wvoe4:192.167.20.0/24/default",
"code": "Client.Ibap.Proto",
"text": "Invalid reference: network/Tkpd4kdvgmsPneJQZ5INXl1gnEZpd0Wvoe4:192.167.20.0/24/default"
}
What i did was as per API doc executed
https://192.168.x.70/wapi/v2.0/networkview?_return_type=json-pretty&name=default
This gives something like
{
"_ref": "networkview/ZG5zLm5ldHdvcmtfdmlldyQw:default/true",
"is_default": true,
"name": "default"
}
It is interesting to see we are getting EXACTLY same response as mentioned in API doc even the "ZG5zLm5ldHdvcmtfdmlldyQw" so seems this code in hardwired for a particular kind of object
Now i have so many objects how would i know what this code is and how would i get it?
Am i trying something completely wrong?
I have no clue about API just doing some POC
0
Best Answer
-
I guess i got it. the API docs says
"The way API works in InfoBlox every object type has a reference object so as per InfoBlox document states “WAPI Objects are referenced using their Object References. WAPI returns this reference when an object is created,modified, deleted or read. This reference is used to identify the object for the same operations.”
So we have to refer to particular object with object reference now we are good0
Answers
-
Great Prateek, glad you got it resolved. Please let us know if you have any additional questions? We are updating the community site in about a month with new categories, content, etc., so you'll see a dramatic change!
Best,
Eric
0
Categories
- All Categories
- 5.1K Forums
- 4.6K Critical Network Services
- 463 Security
- Visibility and Insights
- Ideas Portal
- Webinars & Events
- 266 Resources
- 266 News & Announcements
- Knowledge Base Articles
- Infoblox Documentation Portal
- Infoblox Blog
- Support Portal
- 4 Members Hub
- 4 Getting Started with Community
- Community Support