This documentation has moved

XML API documentation can now be found at developer.openprovider.com. This page will remain available until September 2026, but will no longer be updated.

The XML API itself is not changing. Your existing integration continues to work.

API Module Nameserver searchZoneRecordDnsRequest

From Openprovider API documentation

Revision as of 08:44, 27 July 2018 by WikiSysop (Talk | contribs)
Jump to: navigation, search

Contents

Module DNS zone > Retrieve

Module DNS zone
Command name searchZoneRecordDnsRequest
Use Retrieves information about an existing DNS zone object
Input
  • name
  • limit - How many records to retrieve (default: 100, max 1000)
  • offset - From which record to retrieve (default: 0)
  • orderBy - Sorting, allowed by fields - type, name, value, ttl, prio (default: type: asc, name: asc)
Output

Examples

Using PHP class

$request = new OP_Request;
$request->setCommand('searchZoneRecordDnsRequest')
  ->setAuth(array('username' => 'username', 'password' => 'password'))
  ->setArgs(array(
    'name' => 'demozone.com',
    'offset' => 5,
    'limit' => 3,
    'orderBy' => 'name',
  ));

Raw XML

Please note that newlines and leading spaces are added only for readability. Those whitespaces should be excluded from your XML command before sending it to Openprovider.

<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <credentials>
    <username>username</username>
    <password>password</password>
  </credentials>
  <searchZoneRecordDnsRequest>
    <name>demozone.com</name>
    <offset>5</offset>
    <limit>3</limit>
    <orderBy>name</orderBy>
  </searchZoneRecordDnsRequest>
</openXML>
<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <reply>
  0
  <desc></desc>
  <data>
   <results>
     <array>
       <item>
         <id>502647110</id>
         <name>demozone.nl</name>
         <type>MX</type>
         <value>123.demozone.nl</value>
         <prio>5</prio>
         <ttl>86400</ttl>
         <creationDate>2017-07-18 05:54:36</creationDate>
         <modificationDate>2017-07-18 05:54:36</modificationDate>
       </item>
       <item>
         <id>529669018</id>
         <name>demozone.nl</name>
         <type>CNAME</type>
         <value>google.com</value>
         <prio>
         </prio>
         <ttl>3600</ttl>
         <creationDate>2017-09-14 10:09:09</creationDate>
         <modificationDate>2017-09-14 10:09:09</modificationDate>
       </item>
       <item>
         <id>516713902</id>
         <name>www.demozone.nl</name>
         <type>A</type>
         <value>8.8.8.8</value>
         <prio>
         </prio>
         <ttl>86400</ttl>
         <creationDate>2017-08-18 08:15:10</creationDate>
         <modificationDate>2017-08-18 08:15:10</modificationDate>
       </item>
     </array>
   </results>
   <total>12</total>
    </data>
  </reply>
</openXML>
Views
Personal tools