Infoblox’s global team of threat hunters uncovers a DNS operation with the ability to bypass traditional security measures and control the Great Firewall of China. Read about “Muddling Meerkat” and the many other threat actors discovered by Infoblox Threat Intel here.

API & Integration, DevOps,NetOps,SecOps

Reply

How do you remove an Aliase from a Host record using the WAPI?

Techie
Posts: 3
2499     0

I am trying to remove a Aliase from a host record and am having a very difficult time - Idealy I would use the Ansible plug in but it seems to only allow you at add aliases so I am now trying direcly via WAPI

 

I am using the following curl command:

 

curl -k1 -u <uid> -X POST https://<hostname>/wapi/v2.10.5/record:host/ZG5zLmhvc3QkLjQuZWR1LmNvbHVtYmlhLmN1aXQudGVzdC50ZXN0ZXIwMQ:tester01.test.com/External%20DNS -H "Content-Type: application/json" -d '{"name": "tester01.test.com", "ipv4addrs":[{"ipv4addr":"172.16.1.33"}], "view" : "External DNS", "aliases": []}'

I get the error:

{ "Error": "AdmConDataError: None (IBDataConflictError: IB.Data.Conflict:The record 'tester01.test.com' already exists.)", 
  "code": "Client.Ibap.Data.Conflict", 
  "text": "The record 'tester01.test.com' already exists."
}%    

Re: How do you remove an Aliase from a Host record using the WAPI?

Techie
Posts: 3
2500     0

I think I figured it out - needed to use PUT and not POST

Showing results for 
Search instead for 
Did you mean: 

Recommended for You