From eabf3eb5f15a57d560e74b94e0c0921377af0ea9 Mon Sep 17 00:00:00 2001 From: tv Date: Mon, 22 Aug 2011 15:21:13 +0200 Subject: ovh soapi zoneEntry{Add,Del}: initial commit --- ovh/soapi/zoneEntryAdd | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100755 ovh/soapi/zoneEntryAdd (limited to 'ovh/soapi/zoneEntryAdd') diff --git a/ovh/soapi/zoneEntryAdd b/ovh/soapi/zoneEntryAdd new file mode 100755 index 00000000..68a0b8e3 --- /dev/null +++ b/ovh/soapi/zoneEntryAdd @@ -0,0 +1,25 @@ +#!/usr/bin/python + +from os import environ +from SOAPpy import WSDL + +soap = WSDL.Proxy('https://www.ovh.com/soapi/soapi-re-1.24.wsdl') + +username = environ['KREBS_OVH_USER'] +password = environ['KREBS_OVH_PASS'] +domain = argv[2] +subdomain = argv[3] +fieldtype = argv[4] +target = argv[5] + +#login +session = soap.login(username, password, 'de', 0) +print "login successfull" + +#zoneEntryAdd +soap.zoneEntryAdd(session, domain, subdomain, fieldtype, target) +print "zoneEntryAdd successfull" + +#logout +soap.logout(session) +print "logout successfull" -- cgit v1.2.3