Plesk 11.5.30 - Trouble creating Mailbox with cp-access via RPC API
Hello,
im using Plesk 11.5.30 and tring to create a mailbox via RPC API, which has cp-access.
In the online-documentation you can read you to do this with the optional parameter
<cp-access> (type boolean), which have to stand between <name> and <mailbox>.
I've tried, but won't work.
Next step:
In plesk_mailname.xsd is mentioned an element <cp_access> (also between <name>
and <mailbox>), but this is a complexType and not a simple boolean.
--- snip ---
<?xml version="1.0" encoding="UTF-8"?>
<packet version="1.6.3.5">'
<mail>
<create>
<filter>
<site-id>$DomID</site-id>
<mailname>
<name>$user</name>
<cp_access>
<enabled>true</enabled>
<access>
<locale>de-DE</locale>
</access>
</cp_access>
<mailbox>
<enabled>$enable</enabled>
<quota>$quota</quota>
</mailbox>
<password>
<value>$passwd</value>
<type>crypt</type>
</password>
<antivir>$antivir</antivir>
</mailname>
</filter>
</create>
</mail>
</packet>
--- snip ---
Returns:
--- snip ---
<status>error</status>
<errcode>1014</errcode>
<errtext>Parser error: Request is invalid. Error in line 9: Element 'cp-access': This element is not expected. Expected is one of ( mailbox, forwarding, alias, autoresponder, password, antivir ).</errtext>
--- snip ---
Hello,
im using Plesk 11.5.30 and tring to create a mailbox via RPC API, which has cp-access.
In the online-documentation you can read you to do this with the optional parameter
<cp-access> (type boolean), which have to stand between <name> and <mailbox>.
I've tried, but won't work.
Next step:
In plesk_mailname.xsd is mentioned an element <cp_access> (also between <name>
and <mailbox>), but this is a complexType and not a simple boolean.
--- snip ---
<?xml version="1.0" encoding="UTF-8"?>
<packet version="1.6.3.5">'
<mail>
<create>
<filter>
<site-id>$DomID</site-id>
<mailname>
<name>$user</name>
<cp_access>
<enabled>true</enabled>
<access>
<locale>de-DE</locale>
</access>
</cp_access>
<mailbox>
<enabled>$enable</enabled>
<quota>$quota</quota>
</mailbox>
<password>
<value>$passwd</value>
<type>crypt</type>
</password>
<antivir>$antivir</antivir>
</mailname>
</filter>
</create>
</mail>
</packet>
--- snip ---
Returns:
--- snip ---
<status>error</status>
<errcode>1014</errcode>
<errtext>Parser error: Request is invalid. Error in line 9: Element 'cp-access': This element is not expected. Expected is one of ( mailbox, forwarding, alias, autoresponder, password, antivir ).</errtext>
--- snip ---
Last edited: