Page tree
Skip to end of metadata
Go to start of metadata

To create a DNS record:

POST /dns_zones/:dns_zone_id/records.xml
POST /dns_zones/:dns_zone_id/records.json

XML Request example

curl -i-X POST http://onapp.test/dns_zones/:dns_zone_id/records.xml -d "<dns_record><name>test</name><ttl>111</ttl><type>A</type><ip></ip></dns_record>" -u user:userpass -H 'Accept: application/xml' -H 'Content-type: application/xml' 

JSON Request example

curl -i -X POST http://onapp.test/dns_zones/:dns_zone_id/records.json -d '{"dns_record":{"name":"TEST_NAME","ttl":"111","type":"A","ip":""}}' -u user:userpass -H 'Accept: application/json' -H 'Content-type: application/json' 


name* - DNS record name

ttl* - the time to live value

type* - the record type

ip* - host IP ( for A and AAAA records)

XML Response example

<?xml version="1.0" encoding="UTF-8"?>
<id type="integer">2696</id>

Starting from the 3.0.6 version of the OnApp Cloud it is possible to use underscore character in the CNAME records.

#trackbackRdf ($trackbackUtils.getContentIdentifier($page) $page.title $trackbackUtils.getPingUrl($page))
  • No labels