- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
Trying to set a static IP
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 10:39 AM
Name required
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 11:30 AM
Reading the WAPI 1.2.1 Docs for NIOS 6.8.5 under Support-->Download it indicates that a "name" is required on create. See page 415-416 for CURL examples (make sure the zone and network exists first):
curl -k3 -u admin:testpw -H "Content-Type: application/json" \
-X POST https://192.168.1.2/wapi/v1.2.1/record:host -d \
’{"ipv4addrs":[{"ipv4addr":"10.222.0.12"}],"name":"host.zone.com"}’
WAPI 1.2.1
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 11:33 AM
Ah,
I also see that you are using WAPI 1.0. There are lots of new features in 1.2.1 if you can get your NIOS up to 6.8.4.
Hope this helps,
Brad
No change
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 11:42 AM
Content-type?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 12:26 PM
Are you able to set the content-type in your ASP.net call, it should be set to JSON format: "Content-Type: application/json". Also, make sure you are doing a POST vs. GET. Were you able to run it against V1.2.1 - https://infoblox/wapi/v1.2.1/record:host?
Can you try it from CURL on the command line to verify it works and then we can dig into how to make it work in ASP.net?
Curl errors
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
12-30-2013 01:03 PM
Fixed
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
01-08-2014 09:51 AM
We got it figured out. First, we upgraded to WAPI V1.4. Then, we used the following code:
Dim objHTTP = CreateObject("MSXML2.serverXMLHTTP")
Dim strEnvelope = "ipv4addr=" & TextBox2.Text & "&mac=" & TextBox1.Text & "&comment=" & TextBox3.Text & "&name=" & TextBox4.Text
objHTTP.SetOption(2, 13056)
objHTTP.Open("POST", ("https://infoblox/wapi/v1.4/fixedaddress"), False, strUsername, strPassword)
objHTTP.setRequestHeader("Content-Type", "application/x-www-form-urlencoded; charset=utf-8")
objHTTP.send(strEnvelope)
Label3.Text = objHTTP.responseText
if you want to create a
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
01-16-2014 11:42 AM
if you want to create a static ip, don't create a 'record:host', just create a 'fixedaddress' object.
you can do this with the v1.2 api, you don't need to use v1.4
if you set the mac address to '00:00:00:00:00:00', it will create a reservation.
Re: if you want to create a
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Email to a Friend
- Report Inappropriate Content
01-27-2017 10:50 AM
Thanks, this works great! Do you know how I can set the Unlimited Lease Time field on the reservation? When I retreive the object and try to update the 'never_ends' field I get the following error...
AdmConProtoError: Operation update not allowed for lease