I have raised a Meraki support ticket, but wanted to reach out to the community anyway to see if anyone had used this API / new feature yet.
The first issue I had is when trying to add multiple nameserver addresses, it threw an error saying: "More than one address is in addresses"
import requests
url = "https://api.meraki.com/api/v1/organizations/ORG_ID/appliance/dns/split/profiles"
payload = '''{
"name": "8x8 DNS Profile",
"hostnames": [ "*.8x8.com", "*.packet8.net" ],
"nameservers": { "addresses": [ "8.28.0.9", "192.84.18.11" ] }
}'''
headers = {
"Authorization": "Bearer API_TOKEN",
"Content-Type": "application/json",
"Accept": "application/json"
}
response = requests.request('POST', url, headers=headers, data = payload)
print(response.text.encode('utf8'))
When I added a profile with only one nameserver I was not convinced it was actually redirecting traffic to the specified nameserver, because a packet capture on the Internet port showed the DNS query going to the clients DNS server, which is set to Proxy to upstream DNS rather than the one added in the DNS profile via the API...