DomainZoneCreate

From NETIM
(Difference between revisions)
Jump to: navigation, search
(Pushed from Centre de support - FranceDNS.)
 
m (Text replace - "API Version 1 (Recommended)" to "API Version 1 (Deprecated)")
 
(10 intermediate revisions by 2 users not shown)
Line 1: Line 1:
[[Category:Fonctions]]
+
[[Category:Functions]]
 +
 
 +
 
 +
<tabs>
 +
<tab name="API Version 2 (Recommended)">
 +
 
 +
{| class="wikitable" style="width: 200px;"
 +
! Release
 +
! Runtime
 +
|-
 +
|API >= 2.0|| Synchronous
 +
|}
 +
 
 +
 
 +
'''Description'''
 +
 
 +
Creates a DNS record into the domain zonefile
 +
 
 +
[[StructOperationResponse]] domainZoneCreate(string idSession, string domain, string subdomain, string type, string value, [[StructOptionsZone]] options)
 +
 
 +
 
 +
 
 +
'''Parameters'''
 +
{| class="wikitable" style="width: 700px;"
 +
! Format
 +
! Variable
 +
! Description
 +
! Notes
 +
|-
 +
|style="width: 100px;" | string (32)|| style="width: 100px;" | idSession || style="width: 200px" | Session ID  || style="width: 300px" |
 +
|-
 +
|string (255)|| domain|| Domain name ||
 +
|-
 +
|string (255) ||subdomain || Sub domain  ||
 +
|-
 +
|string ||type|| Type of DNS record || ''A / AAAA / MX / CNAME / TXT / NS / SRV''
 +
|-
 +
|string (150) ||value|| Value of the new DNS record ||
 +
|-
 +
|[[StructOptionsZone]] ||options|| Settings of the new DNS record||
 +
|}
 +
 
 +
List of DNS record types and acceptable values
 +
 
 +
{| class="wikitable" style="width: 700px;"
 +
! Type
 +
! Value
 +
|-
 +
|style="width: 100px;" | A || style="width: 150px" | IPv4 Address
 +
|-
 +
|AAAA|| IPv6  Address
 +
|-
 +
|MX || fully qualified domain name of the mailserver
 +
|-
 +
|CNAME || fully qualified domain name
 +
|-
 +
|NS|| fully qualified domain name of the DNS server
 +
|}
 +
 
 +
 
 +
'''Return'''
 +
 
 +
A structure [[StructOperationResponse]]
 +
 
 +
 
 +
'''Notes'''
 +
 
 +
none
 +
 
 +
 
 +
== Examples ==
 +
 
 +
''' PHP '''
 +
<source lang="php">
 +
<?php
 +
$clientSOAP = new SoapClient("http://URL.wsdl");
 +
$structOptionsZone = array('service' => '', 'protocol' => '', 'ttl' => '', 'priority' => '', 'weight' => '', 'port' => '');
 +
 
 +
try
 +
{
 +
      $idSession = $clientSOAP->sessionOpen("XXXX", "XXXX", "EN");     
 +
      $StructOperationResponse = $clientSOAP->domainZoneCreate($idSession, "netim.com", "www", "A", "192.168.0.1", $structOptionsZone);
 +
     
 +
      print_r($StructOperationResponse);
 +
}
 +
catch(SoapFault $fault)
 +
{
 +
      echo "Exception : " .$fault->getMessage(). "\n";
 +
}
 +
 
 +
if (isset($idSession))
 +
{
 +
      $clientSOAP->sessionClose($idSession);
 +
}
 +
?>
 +
</source >
 +
 
 +
 
 +
</tab>
 +
<tab name="API Version 1 (Deprecated)">
 +
 
 
{| class="wikitable" style="width: 200px;"
 
{| class="wikitable" style="width: 200px;"
! Version
+
! Release
! Exécution
+
! Runtime
 
|-
 
|-
|API > 1.0|| Synchrone
+
|API > 1.0|| Synchronous
 
|}
 
|}
  
Line 10: Line 110:
 
'''Description'''
 
'''Description'''
  
Créé un enregistrement DNS pour le domaine
+
Creates a DNS record into the domain zonefile
  
 
  int domainZoneCreate(string idSession, string domain, string subdomain, string type, string value, [[StructOptionsZone]] options)  
 
  int domainZoneCreate(string idSession, string domain, string subdomain, string type, string value, [[StructOptionsZone]] options)  
Line 16: Line 116:
  
  
'''Liste des paramètres'''
+
'''Parameters'''
 
{| class="wikitable" style="width: 700px;"
 
{| class="wikitable" style="width: 700px;"
 
! Format
 
! Format
Line 23: Line 123:
 
! Notes
 
! Notes
 
|-
 
|-
|style="width: 100px;" | string (32)|| style="width: 100px;" | idSession || style="width: 200px" | Identifiant de la session || style="width: 300px" |
+
|style="width: 100px;" | string (32)|| style="width: 100px;" | idSession || style="width: 200px" | Session ID || style="width: 300px" |
 
|-
 
|-
|string (255)|| domain|| Nom de domaine ||  
+
|string (255)|| domain|| Domain name ||  
 
|-
 
|-
|string (255) ||subdomain || Sous domaine ||
+
|string (255) ||subdomain || Sub domain ||
 
|-
 
|-
|string ||type|| Type d'enregistrement || ''A / AAAA / MX / CNAME / TXT / NS / SRV''
+
|string ||type|| Type of DNS record || ''A / AAAA / MX / CNAME / TXT / NS / SRV''
 
|-
 
|-
|string (150) ||value|| Valeur de l'enregistrement ||
+
|string (150) ||value|| Value of the new DNS record ||
 
|-
 
|-
|[[StructOptionsZone]] ||options|| Paramètres de l'enregistrement||
+
|[[StructOptionsZone]] ||options|| Settings of the new DNS record||
 
|}
 
|}
  
Liste des types d'enregistrement et des valeurs
+
List of DNS record types and acceptable values
  
 
{| class="wikitable" style="width: 700px;"
 
{| class="wikitable" style="width: 700px;"
 
! Type
 
! Type
! Destination cible
+
! Value
 
|-
 
|-
|style="width: 100px;" | A || style="width: 150px" | Adresse IPv4
+
|style="width: 100px;" | A || style="width: 150px" | IPv4 Address
 
|-
 
|-
|AAAA|| Adresse IPv6  
+
|AAAA|| IPv6 Address
 
|-
 
|-
|MX || Nom de domaine qualifié (fqdn) du serveur MX
+
|MX || fully qualified domain name of the mailserver
 
|-
 
|-
|CNAME || Nom de domaine qualifié (fqdn)
+
|CNAME || fully qualified domain name
 
|-
 
|-
|NS|| Nom de domaine qualifié (fqdn) du serveur DNS
+
|NS|| fully qualified domain name of the DNS server
 
|}
 
|}
  
  
'''Valeurs de retour'''
+
'''Return'''
  
  Un numéro d'opération
+
  A tracking number
  
  
 
'''Notes'''
 
'''Notes'''
  
  Aucune
+
  none
  
== Exemples ==
 
  
''' Langage PHP '''
+
== Examples ==
 +
 
 +
''' PHP '''
 
<source lang="php">
 
<source lang="php">
 
<?php
 
<?php
$clientSOAP = new SoapClient("http://drs.netim.com/1.4/DRS.wsdl");
+
$clientSOAP = new SoapClient("http://URL.wsdl");
$structOptionsZone = array();
+
$structOptionsZone = array('service' => '', 'protocol' => '', 'ttl' => '', 'priority' => '', 'weight' => '', 'port' => '');  
  
 
try
 
try
 
{
 
{
       $idSession = $clientSOAP−>login("XXXX", "XXXX", "EN");       
+
       $idSession = $clientSOAP->login("XXXX", "XXXX", "EN");       
       $trackingID = $clientSOAP−>domainZoneCreate($idSession, "netim.com", "www", "A", "192.168.0.1", $structOptionsZone);
+
       $trackingID = $clientSOAP->domainZoneCreate($idSession, "netim.com", "www", "A", "192.168.0.1", $structOptionsZone);
 
        
 
        
 
       echo($trackingID);
 
       echo($trackingID);
Line 80: Line 181:
 
catch(SoapFault $fault)
 
catch(SoapFault $fault)
 
{
 
{
       echo "Exception : " .$fault−>getMessage(). "\n";
+
       echo "Exception : " .$fault->getMessage(). "\n";
 
}
 
}
  
 
if (isset($idSession))
 
if (isset($idSession))
 
{
 
{
       $clientSOAP−>logout($idSession);
+
       $clientSOAP->logout($idSession);
 
}
 
}
 
?>
 
?>
Line 91: Line 192:
  
  
''' Langage JAVA'''
+
''' JAVA'''
 
<source lang="java">
 
<source lang="java">
 
DRSServiceLocator service = new DRSServiceLocator();
 
DRSServiceLocator service = new DRSServiceLocator();
Line 117: Line 218:
 
}  
 
}  
 
</source>
 
</source>
 +
 +
</tab>
 +
</tabs>

Latest revision as of 14:52, 2 August 2017


Release Runtime
API >= 2.0 Synchronous


Description

Creates a DNS record into the domain zonefile

StructOperationResponse domainZoneCreate(string idSession, string domain, string subdomain, string type, string value, StructOptionsZone options) 


Parameters

Format Variable Description Notes
string (32) idSession Session ID
string (255) domain Domain name
string (255) subdomain Sub domain
string type Type of DNS record A / AAAA / MX / CNAME / TXT / NS / SRV
string (150) value Value of the new DNS record
StructOptionsZone options Settings of the new DNS record

List of DNS record types and acceptable values

Type Value
A IPv4 Address
AAAA IPv6 Address
MX fully qualified domain name of the mailserver
CNAME fully qualified domain name
NS fully qualified domain name of the DNS server


Return

A structure StructOperationResponse


Notes

none


[edit] Examples

PHP

<?php
$clientSOAP = new SoapClient("http://URL.wsdl");
$structOptionsZone = array('service' => '', 'protocol' => '', 'ttl' => '', 'priority' => '', 'weight' => '', 'port' => ''); 
 
try
{
      $idSession = $clientSOAP->sessionOpen("XXXX", "XXXX", "EN");      
      $StructOperationResponse = $clientSOAP->domainZoneCreate($idSession, "netim.com", "www", "A", "192.168.0.1", $structOptionsZone);
 
      print_r($StructOperationResponse);
}
catch(SoapFault $fault)
{
      echo "Exception : " .$fault->getMessage(). "\n";
}
 
if (isset($idSession))
{
      $clientSOAP->sessionClose($idSession);
}
?>


Release Runtime
API > 1.0 Synchronous


Description

Creates a DNS record into the domain zonefile

int domainZoneCreate(string idSession, string domain, string subdomain, string type, string value, StructOptionsZone options) 


Parameters

Format Variable Description Notes
string (32) idSession Session ID
string (255) domain Domain name
string (255) subdomain Sub domain
string type Type of DNS record A / AAAA / MX / CNAME / TXT / NS / SRV
string (150) value Value of the new DNS record
StructOptionsZone options Settings of the new DNS record

List of DNS record types and acceptable values

Type Value
A IPv4 Address
AAAA IPv6 Address
MX fully qualified domain name of the mailserver
CNAME fully qualified domain name
NS fully qualified domain name of the DNS server


Return

A tracking number


Notes

none


[edit] Examples

PHP

<?php
$clientSOAP = new SoapClient("http://URL.wsdl");
$structOptionsZone = array('service' => '', 'protocol' => '', 'ttl' => '', 'priority' => '', 'weight' => '', 'port' => ''); 
 
try
{
      $idSession = $clientSOAP->login("XXXX", "XXXX", "EN");      
      $trackingID = $clientSOAP->domainZoneCreate($idSession, "netim.com", "www", "A", "192.168.0.1", $structOptionsZone);
 
      echo($trackingID);
}
catch(SoapFault $fault)
{
      echo "Exception : " .$fault->getMessage(). "\n";
}
 
if (isset($idSession))
{
      $clientSOAP->logout($idSession);
}
?>


JAVA

DRSServiceLocator service = new DRSServiceLocator();
String idSession;
int trackingID;
StructOptionsZone structOptionsZone = new StructOptionsZone();
 
try
{
      DRSPortType port = service.getDRSPort();
      idSession = port.login("XXXX", "XXXX", "EN");
 
      trackingID = port.domainZoneCreate(idSession, "netim.com", "www", "A", "192.168.0.1", structOptionsZone);
      System.out.println(trackingID);
 
      port.logout(idSession);
}
catch (RemoteException re)
{
      System.out.println(re.getMessage());
}
catch (ServiceException se)
{
      se.printStackTrace();
}
Personal tools
Namespaces

Variants
Actions
Your account
Domain names
Shared Hosting
Old Hosting offers
SSL Certificates
Resellers
Affiliates
Contact Us
Miscellaneous