Please use the new documentation

This page is still here for now, but it will no longer be available from 31-Dec-2026. All content has moved to the new API documentation, which covers current features and new updates.

Go to the new documentation

API Module Domain modifyDomainForwardingRequest

From Openprovider API documentation

(Difference between revisions)
Jump to: navigation, search
(Created page with '==Module Domain > Modify domain forwarding== {| border="1" cellpadding="4" |- style="background-color:#BBBBBB;" |'''Module''' |domain |- style="background-color:#EEEEEE;" |'''Com…')
(Module Domain > Modify domain forwarding)
 
Line 22: Line 22:
*true
*true
|}
|}
 +
 +
==Examples==
 +
===Using PHP class===
 +
$request = new OP_Request;
 +
$request->setCommand('modifyDomainForwardingRequest')
 +
  ->setAuth(array('username' => 'username', 'password' => 'password'))
 +
  ->setArgs(array(
 +
    'forwardFrom' => 'test.nl',
 +
    'schemeFrom' => 'http',
 +
    'forwardTo' => 'test2.nl',
 +
    'forwardType' => 'permanent',
 +
  ));
 +
 +
===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>
 +
  <modifyDomainForwardingRequest>
 +
    <forwardFrom>test.nl</forwardFrom>
 +
    <schemeFrom>http</forwardFrom>
 +
    <forwardTo>test2.nl</forwardFrom>
 +
    <forwardType>permanent</forwardFrom>
 +
  </modifyDomainForwardingRequest>
 +
</openXML>
 +
 +
<?xml version="1.0" encoding="UTF-8"?>
 +
<openXML>
 +
  <reply>
 +
    <nowiki><code>0</code></nowiki>
 +
    <desc>
 +
    </desc>
 +
    <data>1</data>
 +
  </reply>
 +
</openXML>

Current revision as of 10:44, 3 November 2016

Contents

Module Domain > Modify domain forwarding

Module domain
Command name modifyDomainForwardingRequest
Use Modify domain forwarding rule
Input
  • forwardFrom (hostname)
  • schemeFrom (only 'http' now)
  • forwardTo (hostname)
  • forwardType ('permanent'|'temporary'|'iframe')
output
  • true

Examples

Using PHP class

$request = new OP_Request;
$request->setCommand('modifyDomainForwardingRequest')
 ->setAuth(array('username' => 'username', 'password' => 'password'))
 ->setArgs(array(
   'forwardFrom' => 'test.nl',
   'schemeFrom' => 'http',
   'forwardTo' => 'test2.nl',
   'forwardType' => 'permanent',
 ));

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>
  <modifyDomainForwardingRequest>
    <forwardFrom>test.nl</forwardFrom>
    <schemeFrom>http</forwardFrom>
    <forwardTo>test2.nl</forwardFrom>
    <forwardType>permanent</forwardFrom>
  </modifyDomainForwardingRequest>
</openXML>
<?xml version="1.0" encoding="UTF-8"?>
<openXML>
  <reply>
    <code>0</code>
    <desc>
    </desc>
    <data>1</data>
  </reply>
</openXML>
Views
Personal tools