API Module Domain createDomainRequest
From Openprovider API documentation
(Difference between revisions)
(→Module Domain > Create) |
(→Module Domain > Create) |
||
| Line 21: | Line 21: | ||
*[[API Format Handle|billingHandle]] (customer unique identifier or [[API Format Handle|handle]]) | *[[API Format Handle|billingHandle]] (customer unique identifier or [[API Format Handle|handle]]) | ||
*[[API Format Handle|resellerHandle]] (customer unique identifier or [[API Format Handle|handle]]) | *[[API Format Handle|resellerHandle]] (customer unique identifier or [[API Format Handle|handle]]) | ||
| - | *'''[[API Format | + | *'''[[API Format nsGroup|nsGroup]]''' ('nameserver group', mandatory field only if nameServers field is empty) |
| - | *[[API Format | + | *[[API Format nsTemplateName|nsTemplateName]] (name of the template to use to automatically create DNS zone on the domain) |
*'''[[API Format Nameservers|nameServers]]''' (mandatory field only if nsGroup field is empty) | *'''[[API Format Nameservers|nameServers]]''' (mandatory field only if nsGroup field is empty) | ||
| - | *[[API Format | + | *[[API Format isDnssecEnabled|isDnssecEnabled]] (''0'' (default) or ''1'' - Only accepted when nameservers of Openprovider are used) |
*[[API Format useDomicile|useDomicile]] (''0'' (default) or ''1'') | *[[API Format useDomicile|useDomicile]] (''0'' (default) or ''1'') | ||
*[[API Format isPrivateWhoisEnabled|isPrivateWhoisEnabled]] (''0'' or ''1'', default value is ''0'') | *[[API Format isPrivateWhoisEnabled|isPrivateWhoisEnabled]] (''0'' or ''1'', default value is ''0'') | ||
Revision as of 07:00, 16 June 2016
Contents |
Module Domain > Create
Fields marked in bold are mandatory
| Module | domain |
| Command name | createDomainRequest |
| Use | Registers a domain name with the attributes provided |
| Input |
|
| Output |
|
Examples
Using PHP class
$request = new OP_Request;
$request->setCommand('createDomainRequest')
->setAuth(array('username' => 'username', 'password' => 'password'))
->setArgs(array(
'ownerHandle' => 'SR003891-NL',
'adminHandle' => 'SR003891-NL',
'techHandle' => 'SR003891-NL',
'billingHandle' => 'SR003891-NL',
'domain' => array(
'name' => 'this-domain-is-registered',
'extension' => 'com'
),
'period' => '1',
'nsGroup' => 'dns-openprovider',
'nsTemplateName' => 'Shared hosting server Apollo',
));
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>
<createDomainRequest>
<ownerHandle>SR003891-NL</ownerHandle>
<adminHandle>SR003891-NL</adminHandle>
<techHandle>SR003891-NL</techHandle>
<billingHandle>SR003891-NL</billingHandle>
<domain>
<name>this-domain-is-registered</name>
<extension>com</extension>
</domain>
<period>1</period>
<nsGroup>dns-openprovider</nsGroup>
<nsTemplateName>Shared hosting server Apollo</nsTemplateName>
</createDomainRequest>
</openXML>
<?xml version="1.0" encoding="UTF-8"?>
<openXML>
<reply>
< code>0</code>
<desc></desc>
<data>
<status>ACT</status>
<activationDate>2011-04-22 14:14:32</activationDate>
<expirationDate>2012-04-22 14:41:32</expirationDate>
<expirationDateOpenprovider>2012-04-22 14:41:32</expirationDateOpenprovider>
<authCode>123456</authCode>
</data>
</reply>
</openXML>