int host_delete(string session, string host)
Delete a host.
The XML-RPC response will contain this operation attributed ID (int) or a fault describing the problem. Possible faults are described in section Error Codes Format.
host = "ns1.example.com" try: opid = proxy.host_delete(session, host) print "deletion of '%s' is Gandi operation #%d" % (host, opid) except xmlrpclib.Fault, e: print "could not delete host '%s' because: %s" % (host, e.faultString)
$host = "example.com"; $msg = new xmlrpcmsg("host_delete", array($session, new xmlrpcval($host))); $reply = $proxy->send($msg); if ($reply->faultCode()) { printf("could not delete host '%s' because: %s\n", $host, $reply->faultString()); } else { $val = $reply->value(); $val = $val->scalarval(); printf("deletion of host '%s' is Gandi operation #%d\n", $host, $val); }
my $host = "example.com"; my $reply = $proxy->call("host_delete", $session, $host); my $opid = $reply->result(); unless (defined $opid) { printf "could not delete host '%s' because: %s\n", $host, $reply->faultstring; } else { printf "deletion of host '%s' is Gandi operation #%d\n", $host, $opid; }
No question on this page and its children.
RSS feed for questions matching this filter (Help)Last modified: 03 Mar 2009 at 15:16 by Ryan A. (Gandi)