http://api-wiki.apps.rackspace.com/api-wiki/api.php?action=feedcontributions&user=APIAdmin&feedformat=atomRackspace Email & Apps API - User contributions [en]2024-03-29T05:31:17ZUser contributionsMediaWiki 1.29.1http://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Domain_Webmail_Settings_(Rest_API)&diff=786Domain Webmail Settings (Rest API)2021-07-20T08:22:42Z<p>APIAdmin: /* Update */</p>
<hr />
<div>== v1 - Current==<br />
<br />
This resource supports reading and setting various Webmail Settings on a specified domain.<br />
<br />
'''These settings are only used for domains that have Rackspace Email services'''. Changing these values will have no effect on Exchange only domains.<br />
<br />
=== Data Model ===<br />
<br />
==== Webmail Settings ====<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Verbs''<br />
!''Description''<br />
|-<br />
| ChatEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Webmail Chat feature is enabled for the domain and shows up in Webmail<br />
|-<br />
| DropboxEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Dropbox feature is enabled for the domain and shows up in Webmail <br />
|-<br />
| PasswordResetEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether users are allowed to set up their own reset scheme. Regardless of setting, account admins may always reset their password through the Control Panel or API.<br />
|-<br />
| User24HourTime<br />
| Bool<br />
| GET, PUT<br />
| Whether to show time in 24 hour time. Setting this to false results in 12 hour time being shown in Webmail.<br />
|-<br />
| MultiFactorSetting<br />
| String<br />
| GET, PUT<br />
| Determines whether users are allowed to or are forced to set up Multi-Factor Authentication for their mailbox. Valid options are "optional", "off", or "forced".<br />
|-<br />
| DropboxEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Dropbox feature is enabled for the domain and shows up in Webmail <br />
|-<br />
| Language<br />
| String<br />
| GET, PUT<br />
| Determines the default language of the Webmail interface for mailboxes. The supported list of language codes is appended below this table.<br />
|-<br />
| DateFormat<br />
| String<br />
| GET, PUT<br />
| Determines the formatting of dates in Webmail. Valid options are "1" for mm/dd/yy or "2" for dd/mm/yy.<br />
|-<br />
| TimeZone<br />
| String<br />
| GET, PUT<br />
| Determines the default timezone of the Webmail interface for mailboxes. The supported list of timezone strings is appended below this table.<br />
|}<br />
<br />
Supported languages for Webmail are:<br />
{| class="wikitable"<br />
!''Language''<br />
!''Language Code''<br />
|-<br />
| English<br />
| en_US<br />
|-<br />
| Spanish<br />
| es_ES<br />
|-<br />
| French<br />
| fr_FR<br />
|-<br />
| Chinese<br />
| zh_CN<br />
|-<br />
| German<br />
| de_DE<br />
|-<br />
| Greek<br />
| de_DE<br />
|-<br />
| Italian<br />
| it_IT<br />
|-<br />
| Japanese<br />
| ja_JP<br />
|-<br />
| Polish<br />
| pl_PL<br />
|-<br />
| Portuguese<br />
| pt_BR<br />
|-<br />
| Thai<br />
| th_TH<br />
|}<br />
<br />
Supported timezones for Webmail are any valid PHP timezones: https://www.php.net/manual/en/timezones.php<br />
<br />
PHP supports various formats, some examples include<br />
<br />
<pre><br />
Etc/GMT+10<br />
Etc/UTC<br />
US/Eastern<br />
EST<br />
America/Buenos_Aires<br />
</pre><br />
<br />
----<br />
<br />
=== Read ===<br />
<br />
{| class="wikitable"<br />
! Verb<br />
| GET<br />
|-<br />
! URL Format<br />
| /v1/customers/{customer account number}/domains/{domain name}/webmailSettings/<br />
|-<br />
! Description<br />
| Returns Webmail Settings for the specified domain.<br />
|-<br />
! Model<br />
| [[#Webmail_Settings|Webmail Settings]]<br />
|}<br />
<br />
HTTP Codes<br />
<br />
{| class="wikitable"<br />
! Code<br />
! Condition<br />
|-<br />
| 200 OK<br />
| The information was successfully retrieved.<br />
|-<br />
| 404 Not Found<br />
| The domain does not exist.<br />
|}<br />
<br />
<pre><br />
Request:<br />
GET https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
<br />
Response:<br />
200 OK<br />
{<br />
"ChatEnabled": true,<br />
"DropboxEnabled": true,<br />
"PasswordResetEnabled": false,<br />
"Use24HourTime": true,<br />
"MultiFactorSetting": "forced",<br />
"Language": "en_US",<br />
"DateFormat": "1",<br />
"TimeZone": "US/Eastern"<br />
}<br />
</pre><br />
<br />
----<br />
<br />
=== Update ===<br />
<br />
{| class="wikitable"<br />
! Verb<br />
| PUT<br />
|-<br />
! URL Format<br />
| /v1/customers/{customer account number}/domains/{domain name}/webmailSettings<br />
|-<br />
! Description<br />
| Updates the webmail settings for a particular domain<br />
|-<br />
! Model<br />
| [[#Webmail_Settings|Webmail Settings]]<br />
|}<br />
<br />
HTTP Codes<br />
<br />
{| class="wikitable"<br />
! Code<br />
! Condition<br />
|-<br />
| 204 No Content<br />
| The request has been accepted and will be processed.<br />
|-<br />
| 404 Not Found<br />
| The domain does not exist.<br />
|}<br />
<br />
<pre><br />
Request:<br />
PUT https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
{<br />
"ChatEnabled": true,<br />
"DropboxEnabled": true,<br />
"PasswordResetEnabled": false,<br />
"Use24HourTime": true,<br />
"MultiFactorSetting": "forced",<br />
"Language": "es_ES",<br />
"DateFormat": "1",<br />
"TimeZone": "US/Eastern"<br />
}<br />
<br />
Response:<br />
204 No Content<br />
</pre><br />
<br />
It also supports partial payloads, for example, just changing the Multi-Factor Authentication setting:<br />
<br />
<pre><br />
Request:<br />
PUT https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
{<br />
"MultiFactorSetting": "optional"<br />
}<br />
<br />
Response:<br />
204 No Content<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Domain_Webmail_Settings_(Rest_API)&diff=785Domain Webmail Settings (Rest API)2021-07-20T08:21:54Z<p>APIAdmin: /* Webmail Settings */</p>
<hr />
<div>== v1 - Current==<br />
<br />
This resource supports reading and setting various Webmail Settings on a specified domain.<br />
<br />
'''These settings are only used for domains that have Rackspace Email services'''. Changing these values will have no effect on Exchange only domains.<br />
<br />
=== Data Model ===<br />
<br />
==== Webmail Settings ====<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Verbs''<br />
!''Description''<br />
|-<br />
| ChatEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Webmail Chat feature is enabled for the domain and shows up in Webmail<br />
|-<br />
| DropboxEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Dropbox feature is enabled for the domain and shows up in Webmail <br />
|-<br />
| PasswordResetEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether users are allowed to set up their own reset scheme. Regardless of setting, account admins may always reset their password through the Control Panel or API.<br />
|-<br />
| User24HourTime<br />
| Bool<br />
| GET, PUT<br />
| Whether to show time in 24 hour time. Setting this to false results in 12 hour time being shown in Webmail.<br />
|-<br />
| MultiFactorSetting<br />
| String<br />
| GET, PUT<br />
| Determines whether users are allowed to or are forced to set up Multi-Factor Authentication for their mailbox. Valid options are "optional", "off", or "forced".<br />
|-<br />
| DropboxEnabled<br />
| Bool<br />
| GET, PUT<br />
| Whether the Dropbox feature is enabled for the domain and shows up in Webmail <br />
|-<br />
| Language<br />
| String<br />
| GET, PUT<br />
| Determines the default language of the Webmail interface for mailboxes. The supported list of language codes is appended below this table.<br />
|-<br />
| DateFormat<br />
| String<br />
| GET, PUT<br />
| Determines the formatting of dates in Webmail. Valid options are "1" for mm/dd/yy or "2" for dd/mm/yy.<br />
|-<br />
| TimeZone<br />
| String<br />
| GET, PUT<br />
| Determines the default timezone of the Webmail interface for mailboxes. The supported list of timezone strings is appended below this table.<br />
|}<br />
<br />
Supported languages for Webmail are:<br />
{| class="wikitable"<br />
!''Language''<br />
!''Language Code''<br />
|-<br />
| English<br />
| en_US<br />
|-<br />
| Spanish<br />
| es_ES<br />
|-<br />
| French<br />
| fr_FR<br />
|-<br />
| Chinese<br />
| zh_CN<br />
|-<br />
| German<br />
| de_DE<br />
|-<br />
| Greek<br />
| de_DE<br />
|-<br />
| Italian<br />
| it_IT<br />
|-<br />
| Japanese<br />
| ja_JP<br />
|-<br />
| Polish<br />
| pl_PL<br />
|-<br />
| Portuguese<br />
| pt_BR<br />
|-<br />
| Thai<br />
| th_TH<br />
|}<br />
<br />
Supported timezones for Webmail are any valid PHP timezones: https://www.php.net/manual/en/timezones.php<br />
<br />
PHP supports various formats, some examples include<br />
<br />
<pre><br />
Etc/GMT+10<br />
Etc/UTC<br />
US/Eastern<br />
EST<br />
America/Buenos_Aires<br />
</pre><br />
<br />
----<br />
<br />
=== Read ===<br />
<br />
{| class="wikitable"<br />
! Verb<br />
| GET<br />
|-<br />
! URL Format<br />
| /v1/customers/{customer account number}/domains/{domain name}/webmailSettings/<br />
|-<br />
! Description<br />
| Returns Webmail Settings for the specified domain.<br />
|-<br />
! Model<br />
| [[#Webmail_Settings|Webmail Settings]]<br />
|}<br />
<br />
HTTP Codes<br />
<br />
{| class="wikitable"<br />
! Code<br />
! Condition<br />
|-<br />
| 200 OK<br />
| The information was successfully retrieved.<br />
|-<br />
| 404 Not Found<br />
| The domain does not exist.<br />
|}<br />
<br />
<pre><br />
Request:<br />
GET https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
<br />
Response:<br />
200 OK<br />
{<br />
"ChatEnabled": true,<br />
"DropboxEnabled": true,<br />
"PasswordResetEnabled": false,<br />
"Use24HourTime": true,<br />
"MultiFactorSetting": "forced",<br />
"Language": "en_US",<br />
"DateFormat": "1",<br />
"TimeZone": "US/Eastern"<br />
}<br />
</pre><br />
<br />
----<br />
<br />
=== Update ===<br />
<br />
{| class="wikitable"<br />
! Verb<br />
| PUT<br />
|-<br />
! URL Format<br />
| /v1/customers/{customer account number}/domains/{domain name}/webmailSettings<br />
|-<br />
! Description<br />
| Updates the webmail settings for a particular domain<br />
|-<br />
! Model<br />
| [[#Webmail_Settings|Webmail Settings]]<br />
|}<br />
<br />
HTTP Codes<br />
<br />
{| class="wikitable"<br />
! Code<br />
! Condition<br />
|-<br />
| 204 No Content<br />
| The request has been accepted and will be processed.<br />
|-<br />
| 404 Not Found<br />
| The domain does not exist.<br />
|}<br />
<br />
<pre><br />
Request:<br />
PUT https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
{<br />
"ChatEnabled": true,<br />
"DropboxEnabled": true,<br />
"PasswordResetEnabled": false,<br />
"Use24HourTime": true,<br />
"MultiFactorSetting": "forced",<br />
"Language": "es_ES",<br />
"DateFormat": "1",<br />
"TimeZone": "US/Eastern"<br />
}<br />
<br />
Response:<br />
204 No Content<br />
</pre><br />
<br />
It also supports partial payloads, for example, just changing the Multi-Factor Authentication setting:<br />
<br />
<pre><br />
Request:<br />
PUT https://api.emailsrvr.com/v1/domains/example.com/webmailSettings<br />
{<br />
"MultiFactorSetting": "on"<br />
}<br />
<br />
Response:<br />
204 No Content<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Exchange_Mailbox_(Rest_API)&diff=774Exchange Mailbox (Rest API)2020-01-28T15:51:12Z<p>APIAdmin: /* v1 - Current */</p>
<hr />
<div>__TOC__<br />
<br />
== v1 - Current ==<br />
<br />
=== Index ===<br />
<br />
''URL'': <br />
<br />
<nowiki>[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Shows a list of mailboxes under the domain<br />
<br />
<br />
''Filter/Search'':<br />
<br />
Mailbox searches may be filtered by the 'enabled' flag using query methods ?enabled=true and ?enabled=false.<br />
<br />
<br />
''Remarks'':<br />
<br />
The show operation only supports the GET HTTP verb.<br />
<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/12345678/domains/example.com/ex/mailboxes'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<mailboxList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:mailboxList"><br />
<offset>0</offset><br />
<size>50</size><br />
<total>3</total><br />
<mailboxes><br />
<mailbox><br />
<name>apiexmailbox55</name><br />
<displayName>API Test</displayName><br />
</mailbox><br />
<mailbox><br />
<name>apiexmailbox6</name><br />
<displayName>API Test</displayName><br />
</mailbox><br />
<mailbox><br />
<name>apiexmailbox90</name><br />
<displayName>API Test</displayName><br />
</mailbox><br />
</mailboxes><br />
</mailboxList><br />
</pre><br />
<br />
<br />
''Json Result Example'':<br />
<br />
{"offset":0,"size":50,"total":3,"mailboxes":[{"name":"apiexmailbox55","displayName":"API Test"},{"name":"apiexmailbox6","displayName":"API Test"},{"name":"apiexmailbox90","displayName":"API Test"}]}<br />
<br />
<br />
''Custom Fields'':<br />
<br />
The result displays each mailbox's 'name' and 'displayName' as default. There is a query string 'fields' that allows the result to display more mailbox properties. The additional properties are: 'size', 'currentUsage', 'hasBlackBerryMobileService', 'hasActiveSyncMobileService'.<br />
<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/12345678/domains/example.com/ex/mailboxes?fields=size,currentUsage'<br />
</pre><br />
<br />
=== Show ===<br />
<br />
''URL'':<br />
<nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
The show operation will return detailed information about the specified mailbox.<br />
<br />
<br />
''Remarks'':<br />
<br />
The show operation only supports the GET HTTP verb.<br />
<br />
The "samAccountName" is the logon name used to support clients and servers running older versions of the operating system.<br />
<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<mailbox xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:mailbox"><br />
<name>apiexmailbox90</name><br />
<displayName>API Test</displayName><br />
<size>2048</size><br />
<currentUsage>0</currentUsage><br />
<isHidden>false</isHidden><br />
<visibleInRackspaceEmailCompanyDirectory>false</visibleInRackspaceEmailCompanyDirectory><br />
<isPublicFolderAdmin>true</isPublicFolderAdmin><br />
<enabled>true</enabled><br />
<lastLogin>2/12/2010 1:00:00 AM</lastLogin><br />
<contactInfo><br />
<firstName>API</firstName><br />
<lastName>Test</lastName><br />
<jobTitle>Dev</jobTitle><br />
<company>My Company</company><br />
<department>R&amp;D</department><br />
<businessNumber>111-1111</businessNumber><br />
<homeNumber>222-2222</homeNumber><br />
<mobileNumber>333-3333</mobileNumber><br />
<faxNumber>444-4444</faxNumber><br />
<pagerNumber>1234</pagerNumber><br />
<addressLine1>123 Main Street</addressLine1><br />
<city>Blacksburg</city><br />
<state>VA</state><br />
<zip>24060</zip><br />
<country>USA</country><br />
<notes>My Notes</notes><br />
<customID>0123456789</customID><br />
</contactInfo><br />
<emailForwardingAddress>apiexmailbox8@apidomain24.com</emailForwardingAddress><br />
<saveForwardedEmail>false</saveForwardedEmail><br />
<emailAddressList><br />
<emailAddress><br />
<address>apiexmailbox90@apidomain92.com</address><br />
<replyTo>true</replyTo><br />
</emailAddress><br />
</emailAddressList><br />
<hasBlackBerryMobileService>false</hasBlackBerryMobileService><br />
<hasActiveSyncMobileService>false</hasActiveSyncMobileService><br />
<samAccountName>apiexmailbox90_53B5B</samAccountName><br />
</mailbox><br />
</pre><br />
<br />
<br />
''Json Result Example'':<br />
<br />
{"name":"apiexmailbox90", "displayName":"API Test", "size":2048, "currentUsage":0, "isHidden":false, "isPublicFolderAdmin":true, "enabled":true, "lastLogin":"2\/12\/2006 1:00:00 AM", "contactInfo":{"firstName":"API", "lastName":"Test", "jobTitle":"Dev", "company":"My Company", "department":"R&D", "businessNumber":"111-1111", "homeNumber":"222-2222", "mobileNumber":"333-3333", "faxNumber":"444-4444", "pagerNumber":"1234", "addressLine1":"123 Main Street", "city":"Blacksburg", "state":"VA", "zip":"24060", "country":"USA", "notes":"My Notes", "customID":"0123456789"}, "emailForwardingAddress":"apiexmailbox8@apidomain24.com", "saveForwardedEmail":false, "emailAddressList":[{"address":"apiexmailbox90@apidomain92.com", "replyTo":true}], "hasBlackBerryMobileService":false, "hasActiveSyncMobileService":false, "samAccountName":"apiexmailbox90_53B5B", "visibleInRackspaceEmailCompanyDirectory":false}<br />
<br />
=== Add/Edit ===<br />
<br />
''URL'':<br />
<nowiki>Add: [POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)<br />
Edit: [PUT] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Adds/edits a mailbox using the specified form fields. All required fields must be supplied when adding. Other fields may be omitted.<br />
<br />
{{RouteRequiresFormEncoded}}<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Description''<br />
|-<br />
| displayName<br />
| string<br />
| Display name (Required for Add)<br />
|-<br />
| password<br />
| string<br />
| Password (Required for Add)<br />
|-<br />
| size<br />
| positive integer<br />
| Mailbox size in megabytes (Required for Add)<br />
|-<br />
| isHidden<br />
| boolean<br />
| Indicates whether or not the mailbox is hidden from the Global Address List<br />
|-<br />
| isPublicFolderAdmin<br />
| boolean<br />
| Indicates whether or not the account is a public folder administrator<br />
|-<br />
| firstName<br />
| string<br />
| First name<br />
|-<br />
| lastName<br />
| string<br />
| Last name<br />
|-<br />
| company<br />
| string<br />
| Company<br />
|-<br />
| department<br />
| string<br />
| Department<br />
|-<br />
| jobTitle<br />
| string<br />
| Job title<br />
|-<br />
| addressLine1<br />
| string<br />
| Street address<br />
|-<br />
| city<br />
| string<br />
| City<br />
|-<br />
| state<br />
| string<br />
| State<br />
|-<br />
| zip<br />
| string<br />
| Zip or postal code<br />
|-<br />
| country<br />
| string<br />
| Country<br />
|-<br />
| businessNumber<br />
| string<br />
| Business phone number<br />
|-<br />
| pagerNumber<br />
| string<br />
| Pager phone number<br />
|-<br />
| homeNumber<br />
| string<br />
| Home phone number<br />
|-<br />
| mobileNumber<br />
| string<br />
| Mobile phone number<br />
|-<br />
| faxNumber<br />
| string<br />
| Fax phone number<br />
|-<br />
| notes<br />
| string<br />
| Notes field<br />
|-<br />
| customID<br />
| string<br />
| A custom field that can be used to tie user mailboxes to external user systems<br />
|-<br />
| emailForwardingAddress<br />
| string<br />
| Forwarding email address (If this field is assigned an email address, then email forwarding will be turned on. If this field is not assigned or assigned an empty string, then email forwarding will be disabled.)<br />
|-<br />
| saveForwardedEmail<br />
| boolean<br />
| When true, copies of forwarded email are saved in this mailbox. When false, email is forwarded but not saved.<br />
|-<br />
| visibleInRackspaceEmailCompanyDirectory<br />
| boolean<br />
| Flag indicating whether the mailbox is visible in the company directory<br />
|-<br />
| enabled<br />
| boolean<br />
| Enable/Disable mailbox, input must be "true" or "false"<br />
|- <br />
| lastLogin '''''(read only)'''''<br />
| string<br />
| Date of last login, EST Time (in string format)<br />
|}<br />
<br />
<br />
''Example'':<br />
<pre><br />
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', <br />
{ <br />
'displayName' => 'Alex Smith',<br />
'password' => 'Secret123!@#',<br />
'size' => '2048'<br />
} <br />
</pre><br />
<br />
<pre><br />
put '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith',<br />
{ <br />
'homeNumber' => '8005551234'<br />
} <br />
</pre><br />
<br />
<br />
''Errors'':<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| New mailbox name (user name) doesn't meet the naming requirements<br />
| 400<br />
| Invalid user name<br />
|-<br />
| New mailbox display name doesn't meet the naming requirements<br />
| 400<br />
| Invalid display name<br />
|-<br />
| New mailbox password doesn't meet the password pattern requirements<br />
| 400<br />
| Password must be at least 8 characters long<br />
|-<br />
| New mailbox name (user name) already exists<br />
| 400<br />
| The email address john.doe@abc.com is already in use<br />
|}<br />
<br />
=== Delete ===<br />
<br />
''URL'':<br />
<nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Deletes the mailbox. <br />
<br />
<br />
''Remarks'':<br />
<br />
The mailbox and mailbox contents are deleted permanently.<br />
<br />
<br />
''Example'':<br />
<pre><br />
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'<br />
</pre><br />
<br />
<br />
=== Add Email Address ===<br />
<br />
''URL'':<br />
<nowiki>[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Adds a mailbox's email address.<br />
<br />
<br />
''Example'':<br />
<pre><br />
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com', {}<br />
</pre><br />
<br />
=== Delete Email Address ===<br />
<br />
''URL'':<br />
<nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Deletes the email address. <br />
<br />
<br />
''Remarks'':<br />
<br />
The operation will fail if the email address does not exist.<br />
<br />
<br />
''Example'':<br />
<pre><br />
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com'<br />
</pre><br />
<br />
<br />
=== Spam Settings ===<br />
<br />
See [[Mailbox_Spam_(Rest_API)| Exchange Mailbox Spam Settings]].<br />
<br />
<br />
=== Mailbox Permissions ===<br />
<br />
Exchange mailboxes can be given permissions. A permission is defined as a tuple (mailbox, permissionType).<br />
<br />
permissionType:= (SendAs | FullAccess | Both)<br />
<br />
==== Index Permissions ====<br />
''URL'':<br />
<br />
<nowiki>[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(user)/permissions</nowiki><br />
<br />
''Description'':<br />
<br />
Shows the current set of permissions granted on a user's mailbox.<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions'<br />
</pre><br />
<br />
''XML Result Example'':<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<permissionList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" <br />
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:permissionList"><br />
<offset>0</offset><br />
<size>50</size><br />
<total>0</total><br />
<permissions><br />
<permission><br />
<emailAddress>joe.schmoe@enterpriseallservices.net</emailAddress><br />
<permissionType>fullAccess</permissionType><br />
</permission><br />
</permissions><br />
</permissionList><br />
</pre><br />
<br />
''Json Result Example'':<br />
<br />
{"offset":0,"size":50,"total":0,"permissions":[{"emailAddress":"joe.schmoe@enterpriseallservices.net","permissionType":"fullAccess"}]}<br />
<br />
''Comments'':<br />
The above result shows the permission list for user Jane Doe's mailbox. The list contains one entry corresponding to <br />
that of user Joe Schmoe with permission type of "FullAccess".<br />
<br />
==== Adding Permission ====<br />
<br />
''URL'':<br />
<br />
<nowiki>[POST] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(user1)/permissions/(user2)</nowiki><br />
<br />
''Description'':<br />
<br />
Grants user2 the specified permission on mailbox of user1.<br />
<br />
{{RouteRequiresFormEncoded}}<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Description''<br />
|-<br />
| permission<br />
| string<br />
| permissionType (Required)<br />
|}<br />
<br />
''Example'':<br />
<pre><br />
post '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe', {'permission' => 'fullAccess'}<br />
</pre><br />
<br />
''Comments'':<br />
The above result shows that on the mailbox of user Jane Doe, the user John Doe has been granted the permission of type "fullAccess".<br />
<br />
==== Editing Permission ====<br />
<br />
''URL'':<br />
<br />
<nowiki>[PUT] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(user1)/permissions/(user2)</nowiki><br />
<br />
''Description'':<br />
<br />
Modifies permission granted to user2 on the mailbox of user1.<br />
<br />
{{RouteRequiresFormEncoded}}<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Description''<br />
|-<br />
| permission<br />
| string<br />
| permissionType (Required)<br />
|}<br />
<br />
''Example'':<br />
<pre><br />
put '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe', <br />
{'permission' => 'both'}<br />
</pre><br />
<br />
''Comments'':<br />
The permission granted to user John Doe on the mailbox of Jane Doe is modified to "both".<br />
<br />
==== Deleting Permission ====<br />
<br />
''URL'':<br />
<br />
<nowiki>[DELETE] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(user1)/permissions/(user2)</nowiki><br />
<br />
''Description'':<br />
<br />
Deletes permission granted to user2 on the mailbox of user1.<br />
<br />
''Example'':<br />
<pre><br />
delete '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe'<br />
</pre><br />
<br />
''Comments'':<br />
The permission granted to user John Doe on the mailbox of Jane Doe is deleted.<br />
<br />
<br />
=== ActiveSync Mobile Service ===<br />
<br />
==== Index ====<br />
<br />
''URL'':<br />
<nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/activesyncmobileservices</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Returns a list of mailboxes that have ActiveSync mobile service enabled.<br />
<br />
<br />
''Remarks'':<br />
<br />
The index operation only supports the GET HTTP verb.<br />
<br />
<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/12345678/domains/example.com/ex/activesyncmobileservices'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<activeSyncMobileServiceList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" <br />
xmlns="urn:xml:activeSyncMobileServiceList"><br />
<offset>0</offset><br />
<size>50</size><br />
<total>3</total><br />
<mailboxes><br />
<mailbox>apiexmailbox36</mailbox><br />
<mailbox>apiexmailbox66</mailbox><br />
<mailbox>apiexmailbox85</mailbox><br />
</mailboxes><br />
</activeSyncMobileServiceList><br />
</pre><br />
<br />
<br />
''Json Result Example'':<br />
<br />
{"offset":0,"size":50,"total":3,"mailboxes":["apiexmailbox36","apiexmailbox66","apiexmailbox85"]}<br />
<br />
==== Show ====<br />
<br />
''URL'':<br />
<nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Returns the mailbox ActiveSync mobile service setup information to access Hosted Exchange 2007.<br />
<br />
<br />
''Remarks'':<br />
<br />
The index operation only supports the GET HTTP verb.<br />
<br />
<br />
''Example'':<br />
<pre><br />
get '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<activeSyncMobileService xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:activeSyncMobileService"><br />
<emailAddress>john.smith@example.com</emailAddress><br />
<serverAddress>mex07A.emailsrvr.com</serverAddress><br />
<userName>johnsmith1234</userName><br />
<domainAddress>mex07A.mlsrvr.com</domainAddress><br />
</activeSyncMobileService><br />
</pre><br />
<br />
<br />
''Json Result Example'':<br />
<br />
{"emailAddress":"john.smith@example.com","serverAddress":"mex07A.emailsrvr.com","userName":"johnsmith1234","domainAddress":"mex07A.mlsrvr.com"}<br />
<br />
<br />
''Errors'':<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| Mailbox has no ActiveSync service<br />
| 404<br />
| User john.smith@example.com has no active ActiveSync Mobile Service.<br />
|}<br />
<br />
==== Add ====<br />
<br />
''URL'':<br />
<nowiki>[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Attaches a ActiveSync service to the mailbox.<br />
<br />
<br />
''Example'':<br />
<pre><br />
post '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', {}<br />
</pre><br />
<br />
<br />
''Errors'':<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| Mailbox already has ActiveSync Service<br />
| 400<br />
| User john.smith@example.com has ActiveSync Mobile Service already<br />
|}<br />
<br />
<br />
==== Delete ====<br />
<br />
''URL'':<br />
<nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)<br />
/ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Detaches a ActiveSync mobile service from a mailbox.<br />
<br />
<br />
''Example'':<br />
<pre><br />
delete '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Customer_(Rest_API)&diff=769Customer (Rest API)2019-06-05T21:24:29Z<p>APIAdmin: /* Company contacts */</p>
<hr />
<div>__TOC__<br />
<br />
== v1 - Current ==<br />
<br />
=== Index (Reseller Only) ===<br />
<br />
<br />
''URL'': <br />
<br />
[GET] <nowiki>https://api.emailsrvr.com/v1/customers</nowiki><br />
<br />
<br />
<br />
''Description'':<br />
<br />
This operation returns the list of customers that the authenticated user has access to.<br />
<br />
<br />
''Filter/Search'':<br />
<br />
Search parameter 'startswith' and 'contains' will try to find the result in customer name, account number and reference number. We also provide a separate query method ?referenceNumber=123456 that will return a Show on the exact customer whose reference number is as specified. This query method only returns details for sub-accounts.<br />
<br />
<br />
''Example'':<br />
<br />
<pre><br />
get '/customers?size=100&offset=10'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<customerList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"<br />
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:customerList"><br />
<offset>0</offset><br />
<size>50</size><br />
<total>3</total><br />
<customers><br />
<customer><br />
<name>API Customer 17</name><br />
<accountNumber>460182</accountNumber><br />
<referenceNumber>49</referenceNumber><br />
</customer><br />
<customer><br />
<name>API Customer 39</name><br />
<accountNumber>460181</accountNumber><br />
<referenceNumber>23</referenceNumber><br />
</customer><br />
<customer><br />
<name>API Customer 50</name><br />
<accountNumber>460183</accountNumber><br />
<referenceNumber>10</referenceNumber><br />
</customer><br />
</customers><br />
</customerList><br />
</pre><br />
<br />
<br />
''JSON Result Example'':<br />
<br />
<pre><br />
{"offset":0,"size":50,"total":3,"customers":<br />
[{"name":"API Customer 17","accountNumber":"460182","referenceNumber":"49"},<br />
{"name":"API Customer 39","accountNumber":"460181","referenceNumber":"23"},<br />
{"name":"API Customer 50","accountNumber":"460183","referenceNumber":"10"}]}<br />
</pre><br />
<br />
=== Show (Reseller Only) ===<br />
<br />
''URL'': <br />
<br />
[GET] <nowiki>https://api.emailsrvr.com/v1/customers/(customer account number)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
The show operation will return detailed information about the specified account.<br />
<br />
<br />
''Remarks'':<br />
<br />
To do the show operation on the account that is logged in instead of a customer's account, use "me" in the place of the customer account number i.e. <nowiki>'https://api.emailsrvr.com/v1/customers/me'</nowiki>.<br />
<br />
The show operation only supports the GET HTTP verb.<br />
<br />
<br />
''Reference Number''<br />
<br />
The query string "referenceNumber=xx" searches for a customer with an exact reference number.<br />
<br />
<br />
''Examples'':<br />
<br />
<pre><br />
get '/customers/me'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<customer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"<br />
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:customer"><br />
<name>API Customer 17</name><br />
<accountNumber>460182</accountNumber><br />
<referenceNumber>49</referenceNumber><br />
<addressLine1>555 Address</addressLine1><br />
<addressLine2>Suite 555</addressLine2><br />
<city>Austin</city><br />
<state>TX</state><br />
<zip>78703</zip><br />
<country>US</country><br />
<phone>1-555-555-5555</phone><br />
<email>user@example.com</email><br />
</customer><br />
</pre><br />
<br />
<br />
''JSON Result Example'':<br />
<br />
<pre><br />
{<br />
"name":"API Customer 17",<br />
"accountNumber":"460182",<br />
"referenceNumber":"49",<br />
"addressLine1":"555 Address",<br />
"addressLine2":"Suite 555",<br />
"city":"Austin",<br />
"state":"Texas",<br />
"zip":"78703",<br />
"country":"USA",<br />
"phone":"1-555-555-5555",<br />
"email":"user@example.com"<br />
}<br />
</pre><br />
<br />
''Example of querying with Reference Number''<br />
<br />
<pre><br />
get '/customers?referenceNumber=49'<br />
</pre><br />
<br />
<br />
''XML Result Example'':<br />
<br />
<pre><br />
<?xml version="1.0" encoding="utf-8"?><br />
<customer xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"<br />
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:customer"><br />
<name>API Customer 17</name><br />
<accountNumber>460182</accountNumber><br />
<referenceNumber>49</referenceNumber><br />
<addressLine1>555 Address</addressLine1><br />
<addressLine2>Suite 555</addressLine2><br />
<city>Austin</city><br />
<state>TX</state><br />
<zip>78703</zip><br />
<country>US</country><br />
<phone>1-555-555-5555</phone><br />
<email>user@example.com</email><br />
</customer><br />
</pre><br />
<br />
=== Add/Edit (Reseller Only)===<br />
<br />
''URL'': <br />
<br />
Add: [POST] <nowiki>https://api.emailsrvr.com/v1/customers</nowiki><br />
Edit: [PUT] <nowiki>https://api.emailsrvr.com/v1/customers/(customer account number)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Add or edit a new sub-account. Note that customer number is not known until the customer is added.<br />
<br />
The <code>name</code> field must contain 100 characters or fewer. The <code>name</code> field cannot be null or empty and cannot begin or end with whitespace.<br />
<br />
The <code>referenceNumber</code> must contain 20 characters or fewer.<br />
<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Description''<br />
|-<br />
| name<br />
| string<br />
| The customer's display name (required for Add)<br />
|-<br />
| referenceNumber<br />
| string<br />
| The reference number of this account<br />
|-<br />
| addressLine1<br />
| string<br />
| Street address for the account<br />
|-<br />
| addressLine2<br />
| string<br />
| Additional address information (building, suite, etc.)<br />
|-<br />
| city<br />
| string<br />
| Account city<br />
|-<br />
| state<br />
| string<br />
| Account state<br />
|-<br />
| zip<br />
| string<br />
| Account ZIP code<br />
|- <br />
| country<br />
| string<br />
| Account country<br />
|-<br />
| phone<br />
| string<br />
| Account phone number<br />
|-<br />
| email<br />
| string<br />
| Account email address<br />
|}<br />
<br />
<br />
''Example'':<br />
<br />
<pre><br />
post '/customers',<br />
{<br />
'name' => 'Name'<br />
}<br />
</pre><br />
<br />
<pre><br />
put '/customers/999999',<br />
{<br />
'name' => 'NewName',<br />
'referenceNumber' => '12345'<br />
'addressLine1':'555 Address',<br />
'addressLine2':'Suite 555',<br />
'city':'Austin',<br />
'state':'Texas',<br />
'zip':'78703',<br />
'country':'USA',<br />
'phone':'1-555-555-5555',<br />
'email':'user@example.com'<br />
}<br />
</pre><br />
<br />
<br />
''Errors'':<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| The name field was not specified<br />
| 400 Bad Request<br />
| Missing required field: name<br />
|-<br />
| The name field cannot be blank<br />
| 400 Bad Request<br />
| Required field name cannot be empty<br />
|-<br />
| Name cannot begin or end with whitespace<br />
| 400 Bad Request<br />
| Improper Customer Name: cannot begin or end with a space<br />
|-<br />
| Name must contain <= 100 characters<br />
| 400 Bad Request<br />
| Name too long: 100 characters or fewer<br />
|-<br />
| Reference number must contain <= 20 characters<br />
| 400 Bad Request<br />
| Reference number too long: 20 characters or fewer<br />
|}<br />
<br />
<br />
=== Enable/Disable (Reseller Only)===<br />
<br />
''URL'': <br />
<br />
<pre><br />
[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/enable<br />
[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/disable<br />
</pre><br />
<br />
<br />
''Description'':<br />
<br />
Enables or disables the account and all services (mailboxes, sharepoint sites, etc).<br />
<br />
<br />
''Example'':<br />
<br />
<pre><br />
post '/customers/999999/disable'<br />
</pre><br />
<br />
<br />
''Errors'':<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| You are either trying to enable/disable an account which does not belong to you or the admin associated with your api key does not have the correct role(s) to perform this action.<br />
| 403<br />
| Not authorized<br />
|-<br />
| You have made too many recent requests to perform this action. You are allowed to perform this action only one time in a 5 minute sliding window.<br />
| 403<br />
| Exceeded request limits<br />
|}<br />
<br />
<br />
=== Delete (Reseller Only) ===<br />
<br />
''URL'': <br />
<br />
[DELETE] <nowiki>https://api.emailsrvr.com/v1/customers/(customer account number)</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Deletes the account.<br />
<br />
<br />
''Example'':<br />
<br />
<pre><br />
delete '/customers/999999'<br />
</pre><br />
<br />
<br />
=== Create Login Tokens ===<br />
<br />
''URL'': <br />
<br />
[POST] <nowiki>https://api.emailsrvr.com/v1/customers/(customer account number)/loginToken</nowiki><br />
<br />
<br />
''Description'':<br />
<br />
Generate a login token using which a customer can use to SSO into the Control Panel.<br />
<br />
Login tokens can be generated for two kinds of users: virtual and non-virtual. The distinction between<br />
the two users is that a virtual user gets the administrator's privileges when SSOed into the Control Panel.<br />
On the other hand, the non-virtual user gets only as much privileges as are given to him/her when<br />
his/her account was created.<br />
<br />
{| class="wikitable"<br />
!''Field Name''<br />
!''Data Type''<br />
!''Description''<br />
|-<br />
| userName<br />
| string<br />
| The name for which login token needs to be created. <br />
|-<br />
| virtualUser<br />
| string<br />
| A flag indicating whether the user for whom the login token needs to be generated is virtual or non-virtual. Valid values: true/false. When set to true, the userName is treated as a virtual user. When set to false, the userName is treated as a non-virtual user. A non-virtual user must be an existing admin user.<br />
|}<br />
<br />
<br />
''Example'':<br />
<br />
<pre><br />
post '/customers/460896/loginToken', {'userName' => 'dev_cust_limitedadmin', 'virtualUser' => 'true'}<br />
<br />
</pre><br />
<br />
Create login token for virtual user 'dev_cust_limitedadmin'.<br />
<br />
<pre><br />
<br />
<?xml version="1.0" encoding="utf-8"?><br />
<br />
<loginToken xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" <br />
<br />
xmlns="urn:xml:loginToken"><br />
<br />
<user>dev_cust_limitedadmin_460896_vu</user><br />
<br />
<token>EEB0012D8DBC2CAC26E28365D44B537FFF0D79350</token><br />
<br />
<dateCreated>6/11/2010 10:53:46 AM</dateCreated><br />
<br />
</loginToken><br />
</pre><br />
<br />
<br />
The login token is valid for ten minutes after its creation. The "dateCreated" field indicates the time when the login token<br />
is created. <br />
<br />
Using the above created login token the customer with account number 460896 can SSO into the Control Panel using<br />
the following URL: <br />
<br />
<pre><br />
http://ControlPanelURL/TokenLogin.aspx?loginToken=EEB0012D8DBC2CAC26E28365D44B537FFF0D79350<br />
</pre><br />
<br />
A customer can also use the login token to login on their private label control panel (E.g.: cp.mydomain.com/logintokens.aspx).<br />
<br />
== v2 - Current ==<br />
<br />
=== Company Invoices ===<br />
<br />
The paths in this section allow you to view a list of invoices, and download a CSV of the line items of a particular invoice.<br />
<br />
==== View Invoices ====<br />
<br />
''Description'':<br />
<br />
View a list of invoices for an account in reverse chronological order (most recent first).<br />
<br />
<br />
''Request'':<br />
<br />
<pre><br />
GET '/v2/customers/999999/invoices', 'application/json'<br />
</pre><br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
{<br />
"Size": 50,<br />
"Offset": 0,<br />
"Total": 1,<br />
"Items": [{<br />
"InvoiceId": "123",<br />
"InvoiceDate": "2017-12-07T00:00:00",<br />
"InvoiceType": "Billing",<br />
"TotalDue": "1122.55",<br />
"IsPaid": true,<br />
"CsvAvailable": true<br />
}]<br />
}<br />
</pre><br />
<br />
===== Request parameters =====<br />
<br />
- ''Size'': The number of invoices returned to GET requests. The default value is 50. <br />
<br />
- ''Offset'': Indicates an offset at which to return invoices to GET requests. The default value is 0.<br />
<br />
- ''Total'': Indicates the total number of invoices for the account.<br />
<br />
===== CsvAvailable =====<br />
<br />
If CsvAvailable is true, then you can use the CSV path (see just below) to retrieve a CSV of line items for this invoice.<br />
<br />
==== Invoice Line Items ====<br />
<br />
''Description'':<br />
<br />
Download a CSV of line items for a specific invoice. You must pass a valid invoice ID in the path.<br />
<br />
<br />
''Request'':<br />
<br />
<pre><br />
GET '/v2/customers/999999/invoices/123123', 'application/json'<br />
</pre><br />
Where 123123 is the invoice ID.<br />
<br />
NOTE! The content-type returned for this route will always be 'text/csv'.<br />
<br />
NOTE! CSV files are only available for invoices starting around July 2017. If a CSV is not available, this route will return a 404.<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
Account No,Reference No,Domain,Product,Type,Service Start,Service End,Term Committed Usage,Current Usage,Usage Change,Months,Rate,Charge<br />
1371592,"","MyDomain.com","Outlook",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,20,20,20,1,0,0<br />
1371592,"","MyDomain.com","Hosted Exchange",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,20,20,20,1,7,140<br />
1371592,"","MyDomain.com","Hosted Exchange ActiveSync",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,20,20,20,1,0,0<br />
1371592,"","MyDomain.com","Hosted Exchange Extra Storage",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,150,150,150,1,0,0<br />
1386010,"","MyOtherDomain","Office 365 Business Essentials",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,31,31,31,1,7,217<br />
1386010,"","MyOtherDomain","Office 365 Business Essentials",Upgrade,11/6/2017 7:54:44 PM,11/30/2017 11:59:59 PM,29,31,2,0.81,7,11.34<br />
1386010,"","MyOtherDomain","Office 365 Business Premium",Renewal,12/1/2017 12:00:00 AM,12/31/2017 11:59:59 PM,39,39,39,1,14,546<br />
</pre><br />
<br />
<br />
<br />
=== Company contacts ===<br />
<br />
The paths in this section allow you to manage company contacts. Company contacts have authorization to contact Support with questions about this account. <br />
<br />
<br />
==== View contacts (Reseller Only) ====<br />
<br />
''Description'':<br />
<br />
View all contacts for an account.<br />
<br />
<br />
''Request'':<br />
<br />
<pre><br />
GET '/v2/customers/999999/contacts', 'application/json'<br />
</pre><br />
<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
{<br />
"Size": 50,<br />
"Offset": 0,<br />
"Total": 1,<br />
"Items": [{<br />
"CustomerNumber": "999999",<br />
"Email": "user@example.com",<br />
"Id": "1",<br />
"Name": "Contact first - Ellie",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": true,<br />
"ReceivesBilling": true,<br />
"ReceivesUpdates": true,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
}]<br />
}<br />
</pre><br />
<br />
===== Request parameters (Reseller Only) =====<br />
<br />
- ''Size'': The number of contacts returned to GET requests. The default value is 50. <br />
<br />
- ''Offset'': Indicates an offset at which to return contacts to GET requests. The default value is 0.<br />
<br />
- ''Total'': Indicates the total number of contacts for the account.<br />
<br />
<br />
===== Alerts, Billing, and Updates (Reseller Only) =====<br />
<br />
- ''ReceivesAlerts'': Indicates whether a contact receives account alerts.<br />
<br />
- ''ReceivesBilling'': Authorizes a contact to receive billing information and inquiries. An account must have at least one billing contact.<br />
<br />
- ''ReceivesUpdates'': Indicates whether a contact receives account update notifications.<br />
<br />
<br />
===== View a specific contact (Reseller Only) =====<br />
<br />
''Description'': <br />
<br />
View a specific contact by adding a contact's <code>ID</code> to the request path.<br />
<br />
Locate a contact's <code>ID</code> in its <code>Items</code> array when [[view all contacts|viewing all contacts]].<br />
<br />
<br />
''Request'':<br />
<br />
<pre><br />
GET '/v2/customers/999999/contacts/4', 'application/json'<br />
</pre><br />
<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
{<br />
"CustomerNumber": "999999",<br />
"Email": "user@example.com",<br />
"Id": "4",<br />
"Name": "Contact first - Ellie",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": true,<br />
"ReceivesBilling": true,<br />
"ReceivesUpdates": true,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
}<br />
</pre><br />
<br />
<br />
===== View a range of contacts at an offset (Reseller Only) =====<br />
<br />
''Description'':<br />
<br />
Include ''Size'' and ''Offset'' in the URL of GET requests to view a range of contacts at an offset.<br />
<br />
<br />
''Request'':<br />
<br />
<pre><br />
GET '/v2/customers/999999/contacts?size=2&offset=2', 'application/json'<br />
</pre><br />
<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
{<br />
"Size": 2,<br />
"Offset": 2,<br />
"Total": 4,<br />
"Items": [{<br />
"CustomerNumber": "999999",<br />
"Email": "user3@example.com",<br />
"Id": "3",<br />
"Name": "Contact first - Ellie",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": true,<br />
"ReceivesBilling": true,<br />
"ReceivesUpdates": true,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
},<br />
{<br />
"CustomerNumber": "999999",<br />
"Email": "user4@example.com",<br />
"Id": "4",<br />
"Name": "Contact after hours - Samir",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": false,<br />
"ReceivesBilling": false,<br />
"ReceivesUpdates": false,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
}]<br />
}<br />
</pre><br />
<br />
<br />
==== Add a contact (Reseller Only) ====<br />
<br />
''Description'':<br />
<br />
Create a new contact.<br />
<br />
Creating a new contact requires all contact fields to be populated. See the following request body for a complete list.<br />
<br />
''Request'':<br />
<br />
<pre><br />
POST /v2/customers/9999/contacts/<br />
{<br />
"Email": "user@example.com",<br />
"Name": "Best Contact",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": false,<br />
"ReceivesBilling": false,<br />
"ReceivesUpdates": false,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
}<br />
</pre><br />
<br />
<br />
==== Update a contact (Reseller Only) ====<br />
<br />
''Description'':<br />
<br />
Update information for the contact you specify.<br />
<br />
''Request'':<br />
<br />
<pre><br />
PUT /v2/customers/999999/contacts/4<br />
{<br />
"Email": "user@example.com",<br />
"Name": "Best Contact",<br />
"Phone": "1235555555",<br />
"ReceivesAlerts": false,<br />
"ReceivesBilling": false,<br />
"ReceivesUpdates": false,<br />
"SecurityAnswer": "A",<br />
"SecurityQuestion": "Q"<br />
}<br />
</pre><br />
<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
</pre><br />
<br />
<br />
==== Delete a contact (Reseller Only) ====<br />
<br />
''Description'':<br />
<br />
Remove a contact from the account.<br />
<br />
An account must include at least one contact for billing. Set <code>"ReceivesBilling" : "true"</code> for any contacts permitted to handle billing-related inquiries.<br />
<br />
''Request'':<br />
<br />
<pre><br />
DELETE /v2/customers/999999/contacts/4<br />
</pre><br />
<br />
<br />
''Response'':<br />
<br />
<pre><br />
200 OK<br />
</pre><br />
<br />
<br />
==== Errors for GET requests ====<br />
<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| Invalid method<br />
| 404 Not Found<br />
| Make sure the URL is correct.<br />
|}<br />
<br />
<br />
==== Errors for DELETE requests ====<br />
<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| Attempting to delete the last primary or billing contact<br />
| 400 Bad Request<br />
| There must be at least one billing contact and one primary contact. (A single contact can be both.)<br />
|}<br />
<br />
<br />
==== Errors for PUT and POST requests ====<br />
<br />
<br />
{| class="wikitable"<br />
!''Description''<br />
!''HTTP Response Code''<br />
!''Sample Message''<br />
|-<br />
| POST body is empty<br />
| 400 Bad Request<br />
| Payload must be a valid JSON object. Make sure the POST body contains content.<br />
|-<br />
| Wrong content type<br />
| 400 Bad Request<br />
| Payload must be a valid JSON object. Verify that the content type is <code>application/json</code>.<br />
|-<br />
| Unable to add a new contact or administrator.<br />
| 400 Bad Request<br />
| Contact/Administrator limit reached.<br />
|-<br />
| Missing contact name<br />
| 400 Bad Request<br />
| Contact name cannot be empty.<br />
|-<br />
| Missing or invalid email address<br />
| 400 Bad Request<br />
| Please enter a valid email address.<br />
|-<br />
| No security question specified<br />
| 400 Bad Request<br />
| Security question cannot be empty.<br />
|-<br />
| No security answer specified<br />
| 400 Bad Request<br />
| Security answer cannot be empty.<br />
|-<br />
| Admin does not have permission to add, change, or remove contacts<br />
| 403 Not Authorized<br />
| Unauthorized.<br />
|}</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=AddDomain()&diff=221AddDomain()2008-10-21T16:53:54Z<p>APIAdmin: </p>
<hr />
<div>This function will add a new sub-account and place a new domain inside that subaccount. If you need to add a new domain to an existing account, use [[Subaccount_AddDomain()]].<br />
<br />
===Parameters===<br />
<br />
Four strings, three integers, two more strings, and a string array:<br />
Administrative username,<br />
Administrative password,<br />
Name of account/domain to be added,<br />
Aliases to the domain (e.g. example.net might be an alias to example.com, emptry string if no domain aliases),<br />
Max mailbox size (integer, MB, default max size for mailboxes when created for this domain),<br />
Max number of users (integer),<br />
Placeholder (integer, set it to 1),<br />
New admin username (username of first admin for the subaccount),<br />
New admin password (password of first admin for the subaccount),<br />
Placeholder (array of strings, set it to empty)<br />
===Return Values===<br />
If successful, the return value of the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=AddDomain()&diff=220AddDomain()2008-10-21T16:53:20Z<p>APIAdmin: </p>
<hr />
<div>This function will add a new sub-account and place a new domain inside that subaccount. If you need to add a new domain to an existing account, use [[Subaccount_AddDomain()]].<br />
<br />
===Parameters===<br />
<br />
Four strings, three integers, three more strings:<br />
Administrative username,<br />
Administrative password,<br />
Name of account/domain to be added,<br />
Aliases to the domain (e.g. example.net might be an alias to example.com, emptry string if no domain aliases),<br />
Max mailbox size (integer, MB, default max size for mailboxes when created for this domain),<br />
Max number of users (integer),<br />
Placeholder (integer, set it to 1),<br />
New admin username (username of first admin for the subaccount),<br />
New admin password (password of first admin for the subaccount),<br />
Placeholder (array of strings, set it to empty)<br />
===Return Values===<br />
If successful, the return value of the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Webmail&diff=219Webmail2008-09-19T20:55:02Z<p>APIAdmin: </p>
<hr />
<div>== SOAP Access ==<br />
<br />
Functions for the Webmail API should be accessed using these paramenters:<br />
<br />
* WSDL URI: https://secure.webmail.us/mail4/soap/soap_server.php?wsdl<br />
<br />
(Old URI:&nbsp;&nbsp;https://secure.webmail.us/mail31/soap/soap_server.php?wsdl -- deprecated)<br />
<br />
Please note that the URI may instead use the path to a private label webmail site configured at Webmail.us. Replace the 'secure.webmail.us' with the hostname of the private label site.<br />
<br />
* Service Name: &nbsp;&nbsp;Webmail<br />
<br />
* Service Port: &nbsp;&nbsp;WebmailPort<br />
<br />
== Function List ==<br />
<br />
[[ping()]]<br><br />
[[LoginUserWebmail()]]<br><br />
[[GetUserNumMessages()]]<br><br />
[[GetHelpStatus()]]<br><br />
[[SetHelpStatus()]]<br><br />
[[GetUserContactsSimple()]]<br><br />
[[GetUserContactsSimpleStr()]]<br><br />
[[GetUserIdentities()]]<br><br />
[[GetUserIdentitiesStr()]]<br><br />
[[GetDisplayPreferences()]]<br><br />
[[GetTimeZoneVals()]]<br><br />
[[SetUserTimeZone()]]<br><br />
[[AddUserContacts()]]<br><br />
[[AddUserContactsStr()]]<br><br />
[[GetUserContactsFull()]]<br><br />
[[GetUserContactsFullStr()]]<br><br />
[[DeleteUserContacts()]]<br><br />
[[DeleteUserContactsStr()]]<br><br />
[[DeleteAllUserContacts()]]<br><br />
[[ModifyUserContacts()]]<br><br />
[[ModifyUsercontactsStr()]]<br><br />
[[AddUserGroups()]]<br><br />
[[AddUserGroupsStr()]]<br><br />
[[GetUserGroups()]]<br><br />
[[GetUserGroupsStr()]]<br><br />
[[DeleteUserGroups()]]<br><br />
[[DeleteAllUserGroups()]]<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Ruby&diff=218Ruby2008-09-19T20:54:22Z<p>APIAdmin: </p>
<hr />
<div>Running the following command:<br />
<br />
<blockquote><code><br />
wsdl2ruby.rb --wsdl https://admin.mailtrust.com/mailaccounts/mailaccounts.wsdl --type client<br />
</code></blockquote><br />
<br />
This will generate the following list of files.<br />
<br />
<blockquote><code><br />
mailaccounts.rb<br/><br />
mailaccountsClient.rb<br/><br />
mailaccountsDriver.rb<br/><br />
mailaccountsMappingRegistry.rb<br/><br />
</code></blockquote><br />
<br />
Here is the sample code for CheckUserAvailable:<br />
<br />
<blockquote><code><br />
require 'rubygems'<br/><br />
gem 'soap4r'<br/><br/><br />
<br />
require 'mailaccountsDriver.rb'<br/><br/><br />
<br />
driver = UtilsSoapPort.new<br/><br />
driver.wiredump_dev = STDOUT<br/><br />
res = driver.CheckUserAvailable('ADMIN_NAME', 'ADMIN_PASSWORD', 'DOMAIN', 'USER')<br/><br />
</code></blockquote></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Ruby&diff=217Ruby2008-09-19T20:53:53Z<p>APIAdmin: New page: Running the following command: <blockquote><code> wsdl2ruby.rb --wsdl https://admin.webmail.us/mailaccounts/mailaccounts.wsdl --type client </code></blockquote> This will generate the fo...</p>
<hr />
<div>Running the following command:<br />
<br />
<blockquote><code><br />
wsdl2ruby.rb --wsdl https://admin.webmail.us/mailaccounts/mailaccounts.wsdl --type client<br />
</code></blockquote><br />
<br />
This will generate the following list of files.<br />
<br />
<blockquote><code><br />
mailaccounts.rb<br/><br />
mailaccountsClient.rb<br/><br />
mailaccountsDriver.rb<br/><br />
mailaccountsMappingRegistry.rb<br/><br />
</code></blockquote><br />
<br />
Here is the sample code for CheckUserAvailable:<br />
<br />
<blockquote><code><br />
require 'rubygems'<br/><br />
gem 'soap4r'<br/><br/><br />
<br />
require 'mailaccountsDriver.rb'<br/><br/><br />
<br />
driver = UtilsSoapPort.new<br/><br />
driver.wiredump_dev = STDOUT<br/><br />
res = driver.CheckUserAvailable('ADMIN_NAME', 'ADMIN_PASSWORD', 'DOMAIN', 'USER')<br/><br />
</code></blockquote></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Main_Page&diff=216Main Page2008-09-19T20:48:03Z<p>APIAdmin: </p>
<hr />
<div>__NOTOC__<br />
== The Mailtrust API ==<br />
<br />
The Mailtrust [http://en.wikipedia.org/wiki/Api API] comprises a robust set of web services designed to allow businesses to fully integrate administrative email functions into their own applications. Based on [http://en.wikipedia.org/wiki/SOAP SOAP], functions in the API allow programs written in many different languages to perform operations such as [[AddUser()|adding mailboxes]] and changing settings. The API can also be used to provide [[LoginUserWebmail()|single sign on]] functionality in concert with other web applications. The Webmail API runs on the same robust server platform that supports our high-availability [http://www.mailtrust.com webmail] and email services.<br />
<br />
<br />
----------------<br />
=== NEW! Screencast ===<br />
[http://www.mailtrust.com/api-wiki/screencasts/api-pings.htm Screencast] of accessing two of our SOAP API's from PHP using Ubuntu linux.<br />
<br />
=== Mailtrust API ===<br />
* [[webmail|Webmail User API]] - provides a short list of webmail user functions<br />
<br />
* [[business|Business API]] - provides a list of functions designed for single business/domain usage<br />
<br />
* [[reseller|Reseller API]] - provides a complete list of functions for multiple domains and sub-accounts<br />
<br />
* [[beta|Beta API]] - a list of functions in public beta testing<br />
<br />
=== Code Examples ===<br />
<br />
{|<br />
|<br />
*[[Perl]]<br />
|<br />
*[[PHP]]<br />
|-<br />
|<br />
*[[ASP]]<br />
|<br />
*[[C#]]<br />
|-<br />
|<br />
*[[ColdFusion]]<br />
|<br />
*[[Ruby]]<br />
|-<br />
|<br />
* [[HTML]] (not part of the API, strictly speaking)<br />
|}<br />
<br />
=== Result Codes ===<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Beta&diff=215Beta2008-09-19T20:42:49Z<p>APIAdmin: </p>
<hr />
<div>Watch this space for new API functions as they become available!</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=MediaWiki:Sidebar&diff=214MediaWiki:Sidebar2008-09-15T00:37:49Z<p>APIAdmin: </p>
<hr />
<div>* navigation<br />
** mainpage|mainpage-description<br />
** Webmail|Webmail API<br />
** Business|Business API<br />
** Reseller|Reseller API<br />
** Beta|Beta API<br />
** helppage|help<br />
* SEARCH<br />
* TOOLBOX<br />
* LANGUAGES</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=MediaWiki:Sidebar&diff=213MediaWiki:Sidebar2008-09-15T00:37:07Z<p>APIAdmin: New page: * navigation ** mainpage|mainpage-description ** Webmail|Webmail API ** currentevents-url|currentevents ** recentchanges-url|recentchanges ** randompage-url|randompage ** helppage|help * S...</p>
<hr />
<div>* navigation<br />
** mainpage|mainpage-description<br />
** Webmail|Webmail API<br />
** currentevents-url|currentevents<br />
** recentchanges-url|recentchanges<br />
** randompage-url|randompage<br />
** helppage|help<br />
* SEARCH<br />
* TOOLBOX<br />
* LANGUAGES</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPAddSubaccounts&diff=212PHPAddSubaccounts2008-08-25T23:58:57Z<p>APIAdmin: New page: Copy and paste this script into an empty file, then make it executable (*nix). It works with PHP that has compiled SOAP support.<br><br> <pre> <?php ####################################...</p>
<hr />
<div>Copy and paste this script into an empty file, then make it executable (*nix). It works with PHP that has compiled SOAP support.<br><br><br />
<br />
<pre><br />
<?php<br />
<br />
#################################################################<br />
# #<br />
# This script will create subaccounts from a list #<br />
# #<br />
#################################################################<br />
<br />
$debug=false;<br />
<br />
if(($argv[1]=="-h")||($argv[1]=="--help")||(count($argv)<4)||(count($argv)>5)) {<br />
echo "PHP script to create a list of accounts for a Webmail.us reseller\n";<br />
echo "Created April 2007 by Kirk Averett\n";<br />
echo "\n";<br />
echo "Usage:\n";<br />
echo "php ".$argv[0]." filename username password [optional separator value] \n";<br />
echo "\n";<br />
echo "The username and password should be for an admin login to a reseller account\n";<br />
echo "The filename should be the file with the list of account names to be created\n";<br />
echo "'\\n' is the default separator, meaning that each account appears on a separate line\n";<br />
echo "\n";<br />
exit;<br />
}<br />
<br />
array_shift($argv);<br />
$file=array_shift($argv);<br />
$ruser=array_shift($argv);<br />
$rpass=array_shift($argv);<br />
if(count($argv)==1) {<br />
$sep = $argv[0];<br />
}<br />
else {<br />
$sep = "\n";<br />
}<br />
$wsdl="https://admin.webmail.us/excedentsoap/excedentsoap.wsdl";<br />
$client = new SoapClient($wsdl, array('trace' => true, 'exceptions' => true));<br />
<br />
$accounts_string=trim(file_get_contents($file));<br />
$accounts_array = explode($sep,$accounts_string); <br />
<br />
$num = count($accounts_array);<br />
for ($i=0; $i<$num; $i++) {<br />
$currentaccount = trim($accounts_array[$i]);<br />
if($currentaccount=="") { continue; }<br />
$res = $client->__soapCall('SearchSubaccounts',<br />
array('ResellerUsername' => $ruser,<br />
'ResellerPassword' => $rpass,<br />
'SubaccountName' => $currentaccount,<br />
'accountList' => ""));<br />
if ($res[Result] == 1) { }<br />
else { echo "Couldn't search for account ".$currentaccount." with error:\n"; print_r($res); echo "\n"; }<br />
$subfound = true;<br />
if ($res[accountList] == "") { $subfound = false; }<br />
else {<br />
$subacclistarr = explode("\n",$res[accountList]);<br />
list($subnum,$subname) = explode(",",$subacclistarr[0]);<br />
if(!(trim($subname) == $currentaccount)) { $subfound = false; }<br />
}<br />
if($subfound == false) { // Add subaccount<br />
$res = $client->__soapCall('AddSubaccount',<br />
array('ResellerUsername' => $ruser,<br />
'ResellerPassword' => $rpass,<br />
'SubaccountName' => $currentaccount,<br />
'accountNumber' => ""));<br />
if ($res[Result] == 1) { echo "New account $currentaccount added to system and identified as #".$res[accountNumber]."\n"; }<br />
elseif ($res[Result] == -200) { echo "Account exists\n"; }<br />
else { echo "Could not add ".$currentaccount." as a new account with error:\n"; print_r($res); echo "\n";}<br />
}<br />
else { echo "Account $currentaccount already in system\n"; }<br />
}<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPProperSizeAllUsers&diff=211PHPProperSizeAllUsers2008-08-25T23:58:53Z<p>APIAdmin: New page: <pre> <?php $domain = 'somedomain.com'; $ruser = 'someuser'; $rpass = 'somepass'; $newdomainsize = 100; //Default mailbox size in MB $proximitymultiplier = 1.12; ...</p>
<hr />
<div><pre><br />
<br />
<?php<br />
<br />
$domain = 'somedomain.com';<br />
$ruser = 'someuser';<br />
$rpass = 'somepass';<br />
$newdomainsize = 100; //Default mailbox size in MB<br />
$proximitymultiplier = 1.12; //This allows about 10% padding; 5% = 1.06, 20% = 1.26<br />
$steps = array(250,500,1024,2048,5000); //For tiered pricing; use values from Webmail contract<br />
<br />
$client = new SoapClient('https://admin.webmail.us/excedentsoap/excedentsoap.wsdl');<br />
<br />
$userlist = array("");<br />
<br />
$res = $client->__soapCall('GetDomainAllUserCurrentSize',<br />
array('ResellerUsername' => $ruser,<br />
'ResellerPassword' => $rpass,<br />
'HostName' => $domain,<br />
'UserStatArray' => $userlist));<br />
<br />
$num = count($res[UserStatArray]);<br />
<br />
$userarray=$res[UserStatArray];<br />
<br />
$usernames=array("");<br />
$userPos=0;<br />
<br />
$usernewsizes=array(0);<br />
<br />
for ($count=0; $count<$num; $count ) {<br />
$thisuserdata = trim($userarray[$count]);<br />
$thisuserdataArray = explode(',',$thisuserdata);<br />
$user = $thisuserdataArray[0];<br />
$usage = $thisuserdataArray[1];<br />
$approximatesize = $usage * $proximitymultiplier;<br />
if ($approximatesize < $newdomainsize) {<br />
print $user . " is fine at " . $usage . "/" . $newdomainsize . "\n";<br />
}<br />
else {<br />
$currentstep = 0;<br />
while ($approximatesize > $steps[$currentstep]) {<br />
$currentstep ;<br />
}<br />
$usernames[$userPos]=$user;<br />
$usernewsizes[$userPos]=$steps[$currentstep];<br />
$userPos ;<br />
}<br />
}<br />
<br />
$res = $client->__soapCall('ModifyDomainMaxMailboxSize',<br />
array('ResellerUsername' => $ruser,<br />
'ResellerPassword' => $rpass,<br />
'HostName' => $domain,<br />
'MaxMbxSize' => $newdomainsize));<br />
<br />
if ($res == 1) {<br />
print "Successfully set " . $domain . " to have a mailbox size of " . $newdomainsize . "MB\n";<br />
}<br />
else {<br />
print "Couldn\'t set " . $domain . " to have a mailbox size of " . $newdomainsize . "MB with error " . $res . "\n";<br />
}<br />
<br />
$num = count($usernames);<br />
<br />
for ($count=0; $count<$num; $count ) {<br />
$res = $client->__soapCall('SetUserMailboxMaxSize',<br />
array('ResellerUsername' => $ruser,<br />
'ResellerPassword' => $rpass,<br />
'HostName' => $domain,<br />
'UserID' => $usernames[$count],<br />
'MaxMbxSize' => $usernewsizes[$count]));<br />
if ($res == 1) {<br />
print "Set " . $usernames[$count] . " to " . $usernewsizes[$count] . "\n";<br />
}<br />
else {<br />
print "Couldn\'t set " . $usernames[$count] . " to " . $usernewsizes[$count] . " with error " . $res . "\n";<br />
}<br />
}<br />
<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPDeleteUser&diff=210PHPDeleteUser2008-08-25T23:58:47Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true)); $res = $client->__soapCall('CheckUserExists...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true));<br />
<br />
$res = $client->__soapCall('CheckUserExists',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail'));<br />
<br />
if ($res == 1) {<br />
$res = $client->__soapCall('DeleteUser',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail'));<br />
echo "Deleted the user\n";<br />
}<br />
else {<br />
echo "No such user to delete\n";<br />
}<br />
<br />
?><br />
<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPModifyUser&diff=209PHPModifyUser2008-08-25T23:58:44Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true)); $res = $client->__soapCall('CheckUserExists...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true));<br />
<br />
$res = $client->__soapCall('CheckUserExists',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail'));<br />
<br />
if ($res == 1) {<br />
$res = $client->__soapCall('AddUser',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail',<br />
'Password' => '22222',<br />
'Active' => '1',<br />
'FirstName' => 'first',<br />
'LastName' => 'newlast',<br />
'StreetAddress' => '1234 Some Street',<br />
'City' => 'SomeCity',<br />
'State' => 'SomeState',<br />
'Country' => 'SomeCountry',<br />
'PostalCode' => '00000',<br />
'Telephone' => '800-555-1212',<br />
'Organization' => 'SomeCompany',<br />
'Department' => 'Development'));<br />
echo "Modified the user\n";<br />
}<br />
else {<br />
echo "No such user to modify\n";<br />
}<br />
?><br />
<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPCreateUser&diff=208PHPCreateUser2008-08-25T23:58:40Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true)); $res = $client->__soapCall('CheckUserExists...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://admin.webmail.us/mailaccounts/mailaccounts.wsdl', array('trace' => true, 'exceptions' => true));<br />
<br />
$res = $client->__soapCall('CheckUserExists',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail'));<br />
<br />
if ($res == 1) {<br />
echo "User already exists\n";<br />
}<br />
else {<br />
$res = $client->__soapCall('AddUser',<br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'somepass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'madeupemail',<br />
'Password' => '12121',<br />
'SetActive' => '1',<br />
'FirstName' => 'first',<br />
'LastName' => 'last',<br />
'StreetAddress' => '1234 Some Street',<br />
'City' => 'SomeCity',<br />
'State' => 'SomeState',<br />
'Country' => 'SomeCountry',<br />
'PostalCode' => '00000',<br />
'Telephone' => '800-555-1212',<br />
'Organization' => 'SomeCompany',<br />
'Department' => 'Development'));<br />
echo "Created the user\n";<br />
}<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPGetDisplayPreferences&diff=207PHPGetDisplayPreferences2008-08-25T23:58:37Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl'); $res = $client->__soapCall('GetDisplayPreferences', array('Reselle...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl');<br />
<br />
$res = $client->__soapCall('GetDisplayPreferences',<br />
array('ResellerUsername' => 'adminuser',<br />
'ResellerPassword' => 'adminpass',<br />
'HostName' => 'somedomain.com',<br />
'UserID' => 'someuser',<br />
$resultarray));<br />
<br />
print_r($res);<br />
print_r($resultarray);<br />
<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPGetUserIdentitiesExample&diff=206PHPGetUserIdentitiesExample2008-08-25T23:58:34Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl'); $res = $client->__soapCall('GetUserIdentities', array('ResellerUse...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl');<br />
<br />
$res = $client->__soapCall('GetUserIdentities',<br />
array('ResellerUsername' => 'reselleruser',<br />
'ResellerPassword' => 'resellerpass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'someuserID',<br />
$contactarray));<br />
<br />
print_r($res);<br />
print_r($contactarray);<br />
<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPGetUserContactsFullExample&diff=205PHPGetUserContactsFullExample2008-08-25T23:58:31Z<p>APIAdmin: New page: <pre> <?php $client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl'); $res = $client->__soapCall('GetUserContactsFull', array('ResellerU...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
$client = new SoapClient('https://secure.webmail.us/mail4/soap/soap_server.php?wsdl');<br />
<br />
$res = $client->__soapCall('GetUserContactsFull',<br />
array('ResellerUsername' => 'reselleruser',<br />
'ResellerPassword' => 'resellerpass',<br />
'HostName' => 'somedomain',<br />
'UserID' => 'someuserID',<br />
$contactarray));<br />
<br />
print_r($res);<br />
print_r($contactarray);<br />
<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPLoginAsExample&diff=204PHPLoginAsExample2008-08-25T23:58:28Z<p>APIAdmin: New page: This is a PHP script that can be used by administrators to login to the webmail client as a user, without using the user's passwword.. This is often useful when troubleshooting. Please n...</p>
<hr />
<div>This is a PHP script that can be used by administrators to login to the webmail client as a user, without using the user's passwword.. This is often useful when troubleshooting. Please note: replace the admin username included in the code with the username of a real admin account-- preferably a limited admin with no rights to do anything in the control panel.<br />
<br />
Put the PHP script on a PHP-aware web server, and navigate to the page using your browser. Enter the email address of the person whose email account needs to be viewed, then put in the password of the administrative account you configured for use with this script. Please note that this script does not rely on nusoap, but instead assumes that PHP has been compiled for SOAP support-- but it should be easy to write this script to use nusoap instead.<br />
<br><br />
----------------<br />
<br><br />
<nowiki><?</nowiki><br><br />
<nowiki>function show_form($username="", $detail="") {</nowiki><br><br />
<nowiki>?></nowiki><br><br />
<nowiki><html></nowiki><br><br />
<nowiki><head><title>Login tool</title></head><body></nowiki><br><br />
<nowiki><form action="myself.php" method="post"></nowiki><br><br />
<nowiki><br></nowiki><br><br />
<nowiki>Email address: <input type=text name=email value="<?echo $email?>"><br><br></nowiki><br><br />
<nowiki>Admin password: <input type=password name=detail value="<?echo $detail?>"><br></nowiki><br><br />
<nowiki><input type=submit></nowiki><br><br />
<nowiki></form></nowiki><br><br />
<nowiki></body></nowiki><br><br />
<nowiki></html></nowiki><br><br />
<nowiki><? }</nowiki><br><br />
<br><br />
<nowiki>$email = $_POST['email'];</nowiki><br><br />
<nowiki>$detail = $_POST['detail'];</nowiki><br><br />
<br><br />
<nowiki>if(isset($email)) {</nowiki><br><br />
<nowiki>&nbsp;&nbsp;if(isset($detail)) {</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;$splitaddress = explode("@", $email);</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;$client = new SoapClient('https://secure.webmail.us/mail31/soap/soap_server.php?wsdl', array('trace' => true, 'exceptions' => true));</nowiki><br><br />
<br><br />
<nowiki>&nbsp;&nbsp;$res = $client->__soapCall('LoginUserWebmail',</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;array('ResellerUsername' => 'LoginAsAdminUser',</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;'ResellerPassword' => $detail,</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;'HostName' => $splitaddress[1],</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;'UserID' => $splitaddress[0],''));</nowiki><br><br />
<nowiki>&nbsp;&nbsp;if ($client->fault) {</nowiki><br><br />
<nowiki>&nbsp;&nbsp;&nbsp;&nbsp;echo "FAULT: ";</nowiki><br><br />
<nowiki>&nbsp;&nbsp;print_r($res);</nowiki><br><br />
<nowiki>&nbsp;&nbsp;exit;</nowiki><br><br />
<nowiki>&nbsp;&nbsp;}</nowiki><br><br />
<br><br />
<nowiki>&nbsp;&nbsp;header("Location: https://secure.webmail.us/mail/src/redirect.php?user_name=$email&emailaddress=$email&sessionID=$res[SessionID]");</nowiki><br><br />
<nowiki>&nbsp;}&nbsp;</nowiki><br><br />
<nowiki>&nbsp;&nbsp;else { show_form($email,detail); }</nowiki><br><br />
<nowiki>}</nowiki><br><br />
<nowiki>else { show_form($email,$detail); }</nowiki><br><br />
<nowiki>?></nowiki><br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPCheckNumMessagesExample&diff=203PHPCheckNumMessagesExample2008-08-25T23:58:25Z<p>APIAdmin: New page: <pre> <?php require_once('nusoap.php'); $client = new soapclient('https://secure.webmail.us/soap/soap_server.php?wsdl', true); $err = $client->getError(); if ($err) { die("ERROR: $...</p>
<hr />
<div><pre><br />
<?php<br />
<br />
require_once('nusoap.php');<br />
<br />
$client = new soapclient('https://secure.webmail.us/soap/soap_server.php?wsdl', true);<br />
$err = $client->getError();<br />
<br />
if ($err)<br />
{<br />
die("ERROR: $err");<br />
}<br />
<br />
$res = $client->call('GetUserNumMessages', <br />
array('ResellerUsername' => 'someadmin',<br />
'ResellerPassword' => 'adminpassword',<br />
'HostName' => 'webmail.us',<br />
'UserID' => 'someperson'));<br />
<br />
if ($client->fault)<br />
{<br />
echo "FAULT: ";<br />
print_r($res);<br />
exit;<br />
}<br />
<br />
$err = $client->getError();<br />
if ($err)<br />
{<br />
die("ERROR2: $err");<br />
}<br />
<br />
print_r($res);<br />
<br />
?><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHPCommandLineSoap&diff=202PHPCommandLineSoap2008-08-25T23:58:22Z<p>APIAdmin: New page: This will work with pre-compiled SOAP and has been tested with PHP 5.2.1. Setting the $debug variable to true and running the commandline tool will display the request headers and message...</p>
<hr />
<div>This will work with pre-compiled SOAP and has been tested with PHP 5.2.1. Setting the $debug variable to true and running the commandline tool will display the request headers and message body.<br />
<br />
<pre><br />
<?php<br />
<br />
$debug = false;<br />
<br />
if ((count($argv)==1)||($argv[1]=="-h")||($arg[1]=="--help")) {<br />
echo "Written by Kirk Averett for Webmail.us in 2007\n";<br />
echo "\n";<br />
echo "Usage: php soapinterface.php wsdl function param1 param2 param3 ...\n";<br />
echo "\n";<br />
echo "For example:\n";<br />
echo " php soapinterface.php https://secure.webmail.us/mail4/soap/soap_server.php?wsdl ping Hello\n";<br />
echo "\n";<br />
echo "Produces:\n";<br />
echo "Hello\n";<br />
echo "\n";<br />
echo "Another example:\n";<br />
echo " php soapinterface.php https://admin.webmail.us/excedentsoap/excedentsoap.wsdl GetUserMailForward /\n";<br />
echo " admin password somedomain someuser '' 0\n";<br />
echo "\n";<br />
echo "Produces:\n";<br />
echo "Array\n";<br />
echo "(\n";<br />
echo " [Result] => 1\n";<br />
echo " [ForwardEmailString] => someforward\n";<br />
echo " [SaveCopy] => 0\n";<br />
echo ")\n";<br />
echo "\n";<br />
exit;<br />
}<br />
<br />
array_shift($argv);<br />
$wsdl = array_shift($argv);<br />
$client = new SoapClient($wsdl, array('trace' => true, 'exceptions' => true))<br />
or die('Counldn\'t initilize SOAP client\n');<br />
$func = array_shift($argv);<br />
$res = $client->__soapCall($func,$argv);<br />
print_r($res);<br />
echo "\n";<br />
if ($debug) {<br />
$headers = $client->__getLastRequestHeaders();<br />
echo "---------- Headers from the request:\n";<br />
print_r($headers);<br />
echo "\n";<br />
$request = $client->__getLastRequest();<br />
echo "---------- Body of the request:\n";<br />
print_r($request);<br />
echo "\n";<br />
}<br />
?><br />
<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl_GetDisplayPreferences&diff=201Perl GetDisplayPreferences2008-08-25T23:57:30Z<p>APIAdmin: New page: <pre> #!/usr/bin/perl -w use strict; use SOAP::Lite; use Data::Dumper; my $service = "https://secure.webmail.us/mail4/soap/soap_server.php?wsdl"; my $resellerUsername = "someadmin"; my ...</p>
<hr />
<div><pre><br />
#!/usr/bin/perl -w<br />
<br />
use strict;<br />
use SOAP::Lite;<br />
use Data::Dumper;<br />
<br />
my $service = "https://secure.webmail.us/mail4/soap/soap_server.php?wsdl";<br />
<br />
my $resellerUsername = "someadmin";<br />
my $resellerPassword = "adminpass";<br />
my $domain = "somedomain.com";<br />
my $userid = "someuser";<br />
<br />
my @result = SOAP::Lite<br />
-> service($service)<br />
-> GetDisplayPreferences($resellerUsername, $resellerPassword, $domain, $userid);<br />
print Dumper @result;<br />
print "\n";<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl_ModifyUser&diff=200Perl ModifyUser2008-08-25T23:57:27Z<p>APIAdmin: New page: <nowiki>#!/usr/bin/perl -w</nowiki><br> <br> use strict;<br> use SOAP::Lite;<br> <br> my $service = "<nowiki>https://admin.webmail.us/mailaccounts/mailaccounts.wsdl</nowiki>";<br> <br> my ...</p>
<hr />
<div><nowiki>#!/usr/bin/perl -w</nowiki><br><br />
<br><br />
use strict;<br><br />
use SOAP::Lite;<br><br />
<br><br />
my $service = "<nowiki>https://admin.webmail.us/mailaccounts/mailaccounts.wsdl</nowiki>";<br><br />
<br><br />
my $resellerUsername = "someadmin";<br><br />
my $resellerPassword = "somepasswd";<br><br />
<br><br />
my $hostName = "mydomain.com";<br><br />
my $userID = "myuser";<br><br />
my $newpasswd = "mynewpasswd";<br><br />
<br><br />
my @result = SOAP::Lite<br><br />
<nowiki> -> service($service)</nowiki><br><br />
<nowiki> -> ModifyUser($resellerUsername, $resellerPassword, $hostName, $userID, $newpasswd, 1,"","","","","","","","","","");</nowiki><br><br />
<br><br />
print $result[0]."\n\n";<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl_SessionID&diff=199Perl SessionID2008-08-25T23:57:21Z<p>APIAdmin: New page: == Getting a SessionID == <nowiki> #!/usr/bin/perl -w</nowiki><br> <br> use strict "vars";<br> use warnings;<br> use SOAP::Lite;<br> <br> <nowiki>my $service = "https://secure.webmail.us/s...</p>
<hr />
<div>== Getting a SessionID ==<br />
<nowiki><br />
#!/usr/bin/perl -w</nowiki><br><br />
<br><br />
use strict "vars";<br><br />
use warnings;<br><br />
use SOAP::Lite;<br><br />
<br><br />
<nowiki>my $service = "https://secure.webmail.us/soap/soap_server.php?wsdl";</nowiki><br><br />
<br><br />
my $resellerUsername = "myadminuser";<br><br />
my $resellerPassword = "somepassword";<br><br />
<br><br />
my $hostName = "mydomain.com";<br><br />
my $userID = "someperson";<br><br />
my $sessionID = "";<br><br />
<br />
my @results = SOAP::Lite<br><br />
&nbsp;&nbsp;<nowiki>-> service($service)</nowiki><br><br />
&nbsp;&nbsp;<nowiki>-> LoginUserWebmail($resellerUsername, $resellerPassword, $hostName, $userID, $sessionID);</nowiki><br><br />
<br><br />
print $results[0]." is the result code\n";<br><br />
print "\n";<br><br />
print $results[1]." is the SessionID\n";<br><br />
print "\n";<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl_Commandline&diff=198Perl Commandline2008-08-25T23:57:18Z<p>APIAdmin: New page: To use this tool, you'll need a recent version of Perl (5.8.0 or better), and two Perl modules: SOAP::Lite Data::Dumper To install the modules from a *nix commandline, try the follow...</p>
<hr />
<div>To use this tool, you'll need a recent version of Perl (5.8.0 or better), and two Perl modules:<br />
<br />
SOAP::Lite<br />
Data::Dumper<br />
<br />
To install the modules from a *nix commandline, try the following:<br />
<br />
perl -MCPAN -e shell<br />
install SOAP::Lite (say "yes" to any questions about dependencies)<br />
install Data::Dumper (again, "yes" to dependencies)<br />
<br />
To use the tool, make a new file on your system with the contents of the code below, save it as executable (Mac & *nix only). Remember that Perl expects placeholder variables to be passed in as well. So if you had named your copy of the script "liteinterface.pl", you would call the [[AddUser()]] function like this from a commandline:<br />
<br />
$ ./liteinterface.pl liteinterface.pl https://admin.webmail.us/excedentsoap/excedentsoap.wsdl \<br />
AddUser myadmin mypass somedomain.com kaverett 1 "" "" "" "" "" "" "" "" "" ""<br />
<br />
<pre><br />
#!/usr/bin/perl -w<br />
use strict;<br />
use SOAP::Lite;<br />
use Data::Dumper;<br />
my $wsdl = shift(@ARGV);<br />
my $func = shift(@ARGV);<br />
print Dumper(SOAP::Lite->service($wsdl)->$func(@ARGV));<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl_GetCurrentUserMailboxSize&diff=197Perl GetCurrentUserMailboxSize2008-08-25T23:57:15Z<p>APIAdmin: New page: == GetCurrentUserMailboxSize == This function has been updated to reflect changes to SOAP::Lite 0.69. For more information about using the SOM objects, please check here:<br> http://sear...</p>
<hr />
<div>== GetCurrentUserMailboxSize ==<br />
<br />
This function has been updated to reflect changes to SOAP::Lite 0.69. For more information about using the SOM objects, please check here:<br><br />
http://search.cpan.org/dist/SOAP-Lite/lib/SOAP/SOM.pm<br><br><br />
-----------------------------------<br />
<pre><br />
#!/usr/bin/perl<br />
<br />
use strict;<br />
#use SOAP::Lite +trace => "all";<br />
use SOAP::Lite;<br />
use Data::Dumper;<br />
<br />
my $uri_prefix = "http://admin.excedent.com/excedentsoap/";<br />
my $uri = $uri_prefix."message/";<br />
my $proxy = "https://admin.excedent.com/excedentsoap/excedentsoap.ASP";<br />
my $xmlschema = "http://www.w3.org/1999/XMLSchema";<br />
my $ns = "namesp1";<br />
my $service = "https://admin.webmail.us/excedentsoap/excedentsoap.wsdl";<br />
my $act_prefix = "Utils.";<br />
my $function = "GetCurrentUserMailboxSize";<br />
<br />
my $resellerUsername = "someadmin";<br />
my $resellerPassword = "somepassword";<br />
<br />
my $hostName = "somedomain.com";<br />
my $userID = "someuser";<br />
<br />
my $mailboxsize = 0;<br />
<br />
my $client = SOAP::Lite<br />
-> uri($uri)<br />
-> on_action( sub { return $uri_prefix."action/".$act_prefix.$function })<br />
-> proxy($proxy)<br />
-> xmlschema($xmlschema)<br />
-> ns($uri_prefix."message/",$ns);<br />
<br />
my @params = (<br />
SOAP::Data->name('ResellerUsername')->value($resellerUsername),<br />
SOAP::Data->name('ResellerPassword')->value($resellerPassword),<br />
SOAP::Data->name('HostName')->value($hostName),<br />
SOAP::Data->name('UserID')->value($userID),<br />
SOAP::Data->name('CurrentMbxSize')->value($mailboxsize)<br />
);<br />
<br />
my $som = $client->call($function => @params);<br />
<br />
print $som->paramsout;<br />
print "\n";<br />
<br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=HTML&diff=196HTML2008-08-25T23:56:33Z<p>APIAdmin: New page: == Login Redirect == This code shows a form asking for a username and password to a mailbox; clicking submit logs the person into the webmail client.<br> <br> <nowiki><form method=post act...</p>
<hr />
<div>== Login Redirect ==<br />
This code shows a form asking for a username and password to a mailbox; clicking submit logs the person into the webmail client.<br><br />
<br><br />
<nowiki><form method=post action="http://reseller1.webmail.us/mail/src/redirect.php"></nowiki><br><br />
<br><br />
<nowiki>username: <input type=text name=user_name><br></nowiki><br><br />
<nowiki>password: <input type=text name=password><br></nowiki><br><br />
<nowiki><input type=hidden name=hostname value="webmail.us"></nowiki><br><br />
<br><br />
<nowiki><input type=submit></nowiki><br><br />
<nowiki></form></nowiki></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=ColdFusion&diff=195ColdFusion2008-08-25T23:56:29Z<p>APIAdmin: New page: This is a very simple ColdFusion script that adds a new user & sets the "uid" LDAP attribute for that user. Notice that the last variable passed to the function is passed as a reference i...</p>
<hr />
<div>This is a very simple ColdFusion script that adds a new user & sets the "uid" LDAP attribute for that user.<br />
<br />
Notice that the last variable passed to the function is passed as a reference instead of passing the contents of the variable. This is because the SOAP server expects a reference in some cases. When looking at the WSDL file for the function you'd like to use, if one parameter name appears in both the function call and in the response to the function call, that variable is supposed to be passed by reference.<br />
<br />
<pre><br />
<cfset member_id = "123456"><br />
<cfset admin_user = "someadmin"><br />
<cfset admin_pw = "somepasswd"><br />
<cfset host_name = "somedomain.com"><br />
<cfset username = "myuser"><br />
<cfset last_name = "smith"><br />
<cfset password = "somepassword"><br />
<br />
<cfset myStr = "uid#Chr(9)##member_id#"> <br />
<br />
<!--- Add new user account ---><br />
<cfinvoke webservice="http://admin.webmail.us/excedentsoap/excedentsoap.wsdl"<br />
method="AddUserWithLdapAttributesString"<br />
returnvariable="rspAddUser"><br />
<cfinvokeargument name="ResellerUsername" value="#admin_user#"/><br />
<cfinvokeargument name="ResellerPassword" value="#admin_pw#"/><br />
<cfinvokeargument name="HostName" value="#host_name#"/><br />
<cfinvokeargument name="UserID" value="#username#"/><br />
<cfinvokeargument name="Surname" value="#last_name#" /><br />
<cfinvokeargument name="Password" value="#password#" /> <br />
<cfinvokeargument name="SetActive" value="1" /><br />
<cfinvokeargument name="AttributesArrayStr" value="myStr" /> <br />
</cfinvoke><br />
<br />
<cfoutput>#rspAddUser#</cfoutput><br />
<cfoutput>#myStr#</cfoutput><br />
</pre></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=C&diff=194C2008-08-25T23:56:26Z<p>APIAdmin: New page: public string LoginUserWebmail(string domain,string user)<br> {<br> string s="";<br> int r;<br> <br> try {<br> // This calls your SOAP method<br> r=obj.LoginUserWebmail(reseller_username,r...</p>
<hr />
<div>public string LoginUserWebmail(string domain,string user)<br><br />
{<br><br />
string s="";<br><br />
int r;<br><br />
<br><br />
try {<br><br />
// This calls your SOAP method<br><br />
r=obj.LoginUserWebmail(reseller_username,reseller_password,domain,user,refs);<br><br />
&nbsp;&nbsp;if (r == 1)<br><br />
&nbsp;&nbsp;&nbsp;&nbsp;return s;<br><br />
&nbsp;&nbsp;else<br><br />
&nbsp;&nbsp;&nbsp;&nbsp;return String.Empty;<br><br />
&nbsp;&nbsp;} // End of try<br><br />
<br><br />
catch(Exception ex)<br><br />
{<br><br />
&nbsp;&nbsp;throw new Exception("Biz.EmailService.LoginUserWebmail." + ex.Message);<br><br />
}<br><br />
}<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=ASP&diff=193ASP2008-08-25T23:56:23Z<p>APIAdmin: New page: A Webmail.us customer recommended the following article as being helpful for System.Net.WebException errors: http://geekswithblogs.net/Denis/archive/2005/08/16/50365.aspx<br /> <br /> <%<...</p>
<hr />
<div>A Webmail.us customer recommended the following article as being helpful for System.Net.WebException errors: http://geekswithblogs.net/Denis/archive/2005/08/16/50365.aspx<br /><br />
<br /><br />
<br />
<%<br><br />
Option Explicit<br><br />
<br><br />
Dim soapClient<br><br />
set soapclient = CreateObject("MSSOAP.SoapClient")<br><br />
<br><br />
soapclient.ClientProperty("ServerHTTPRequest") = True<br><br />
soapclient.mssoapinit "<nowiki>https://admin.webmail.us/excedentsoap/excedentsoap.wsdl</nowiki>", <br> "excedentsoap", "UtilsSoapPort"<br><br />
<br><br />
'*********************Initializing*************************<br><br />
Dim retval<br><br />
<br><br />
'this is the username and password you use to log in to our admin.webmail.us site<br><br />
Dim AdminUsername, AdminPassword<br><br />
<br><br />
AdminUsername = "adminUser"<br><br />
AdminPassword = "adminPassword"<br><br />
<br><br />
Dim emailAddr<br><br />
Dim HostName 'the hostname of the email domain<br><br />
Dim UserID 'userid (id before the @ symbol in the email address)<br><br />
Dim sesID<br><br />
<br><br />
HostName = "webmail.us"<br><br />
UserID = "someguy"<br><br />
<br><br />
'*************function call checkuserexists****************<br><br />
retval = soapclient.LoginUserWebMail(AdminUsername, AdminPassword, HostName, UserID, sesID)<br><br />
<br><br />
Response.Write retval<br><br />
Response.Write "<BR>" & sesID<br><br />
Response.Redirect "<nowiki>http://reseller1.webmail.us/mail/src/redirect.php?</nowiki><br><br />
&nbsp;&nbsp;user_name=someguy@webmail.us&emailaddress=someguy@webmail.us&sessionID="&SesID<br><br />
<br><br />
Set soapclient = nothing<br><br />
<br><br />
%></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=PHP&diff=192PHP2008-08-25T23:56:20Z<p>APIAdmin: New page: Simple PHP script to call a SOAP function via the command line<br> Check for new & total Inbox messages<br> [[PHPLoginAsExample|Create...</p>
<hr />
<div>[[PHPCommandLineSoap|Simple PHP script to call a SOAP function via the command line]]<br><br />
[[PHPCheckNumMessagesExample|Check for new & total Inbox messages]]<br><br />
[[PHPLoginAsExample|Create a PHP webpage to allow an admin password access webmail as a user]]<br><br />
[[PHPGetUserContactsFullExample|Get all information about a user's address book contacts]]<br><br />
[[PHPGetUserIdentitiesExample|Get all information about a user's configured identities]]<br><br />
[[PHPGetDisplayPreferences|Get a list of display settings for a user's webmail client]]<br><br />
[[PHPCreateUser|Create a user]]<br><br />
[[PHPModifyUser|Modify a user]]<br><br />
[[PHPDeleteUser|Delete a user]]<br><br />
[[PHPProperSizeAllUsers|Resize a domain and allocate storage to users who need it]]<br><br />
<br><br />
Special provisioning scripts:<br><br />
[[PHPAddSubaccounts|Add a list of accounts to a reseller account]]<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Perl&diff=191Perl2008-08-25T23:56:17Z<p>APIAdmin: New page: Please note that with the release of SOAP::Lite version 0.69, simple access to ASP-based SOAP API's was broken and somewhat more complex steps are needed. So far, only the [[Perl_GetCurre...</p>
<hr />
<div>Please note that with the release of SOAP::Lite version 0.69, simple access to ASP-based SOAP API's was broken and somewhat more complex steps are needed. So far, only the [[Perl_GetCurrentUserMailboxSize|GetCurrentUserMailboxSize]] documentation has been updated to demonstrate how to use the API with current versions of SOAP::Lite.<br />
<br />
See these:<br />
<br />
[[Perl_Commandline|Commandline Perl tool]]<br><br />
[[Perl_SessionID|SessionID]]<br><br />
[[Perl_GetCurrentUserMailboxSize|GetCurrentUserMailboxSize]] - updated for SOAP::Lite 0.69<br><br />
[[Perl_ModifyUser|ModifyUser]]<br><br />
[[Perl_GetDisplayPreferences|GetDisplayPreferences]]<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Beta&diff=190Beta2008-08-25T23:55:31Z<p>APIAdmin: New page: The address book and related functions have moved out of beta as of May 2006. They are now a part of the Webmail API. Watch this space for new API functions as they become av...</p>
<hr />
<div>The address book and related functions have moved out of beta as of May 2006. They are now a part of the [[Webmail|Webmail API]].<br />
<br />
Watch this space for new API functions as they become available!</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=GetRetCodeDesc()&diff=189GetRetCodeDesc()2008-08-25T23:55:01Z<p>APIAdmin: New page: This function accepts as a parameter an error code number generated by one of the API functions. It returns a string description with the meaning of the error code. ===Parameters=== One...</p>
<hr />
<div>This function accepts as a parameter an error code number generated by one of the API functions. It returns a string description with the meaning of the error code.<br />
<br />
===Parameters===<br />
<br />
One integer input, one string output:<br />
"RetCode" (integer of the return code),<br />
<br />
"Result" (the string with the description of the meaning of the return code)<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning. Which is ironic in the case of this function!</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_SetLimitedAdminPermissions()&diff=188Subaccount SetLimitedAdminPermissions()2008-08-25T23:54:58Z<p>APIAdmin: New page: This function will set the specific permissions granted to a particular limited administrator. "Limited" admins are limited to working with certain portions of the control panel. The com...</p>
<hr />
<div>This function will set the specific permissions granted to a particular limited administrator. "Limited" admins are limited to working with certain portions of the control panel. The complete list of possible permissions is:<br />
<pre><br />
Email Accounts section of the control panel--<br />
EA:Mailboxes<br />
EA:Aliases<br />
EA:Filtering<br />
EA:Settings<br />
EA:Tools<br />
EA:RSSFeeds<br />
EA:UserData<br />
EA:MailingLists<br />
EA:GroupLists<br />
EA:Archiving<br />
EA:DataRestores<br />
<br />
Email Marketing section--<br />
EM:Subscribers<br />
EM:Lists<br />
EM:Emails<br />
EM:Preferences<br />
EM:Resources<br />
EM:Upgrade<br />
EM:SubAccounts<br />
<br />
Reseller Tools section--<br />
RT:Administrators<br />
RT:SubAccounts<br />
RT:WebmailSites<br />
<br />
Email Reports section--<br />
ER:MailboxCount<br />
ER:MailboxStorage<br />
ER:MailForwarding<br />
ER:AdministratorLogs<br />
ER:LastLoginDates<br />
ER:MailboxAliases<br />
ER:Statistics<br />
<br />
Webmail Sites section--<br />
WS:InterfaceDesign<br />
WS:LoginLogoutPages<br />
WS:Images<br />
WS:EmailTaglines<br />
WS:FreeSignups<br />
<br />
Control Panel section--<br />
CP:LoginPage<br />
CP:MainPage<br />
CP:Header<br />
CP:Footer<br />
CP:ColorStyles<br />
CP:SupportPages<br />
<br />
<br />
Collaboration section--<br />
Col:CompanyDirectory<br />
Col:SharedCalendar<br />
<br />
My Account section--<br />
MA:BillingInformation<br />
MA:CompanyContacts<br />
MA:UpgradeServices<br />
MA:InvoiceHistory<br />
<br />
Customer Care section--<br />
CC:Support<br />
CC:Feedback<br />
CC:APIWiki<br />
CC:IdeaCentral<br />
CC:Ticketing<br />
<br />
Custom Tools section--<br />
CT:Tools<br />
<br />
Domain Names section--<br />
DN:Renewal<br />
DN:Registration<br />
DN:DNS<br />
<br />
Troubleshooting section--<br />
TR:DomainDetails<br />
TR:MailboxDetails<br />
TR:DNSCheck<br />
TR:RemoteMailCheck<br />
TR:HeaderAnalyzer<br />
TR:LookupSpamRules<br />
</pre><br />
<br />
===Parameters===<br />
<br />
Five strings of input:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"AdminUsername" (the limited admin about which you are retrieving information),<br />
"DomainList" (the list of domains for which the admin should have rights, or simply "ALL"),<br />
"PermissionsList" (a CRLF separated list of control panel areas for this admin to access)<br />
<br />
===Return Values===<br />
If successful, the return value of the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_GetLimitedAdminPermissions()&diff=187Subaccount GetLimitedAdminPermissions()2008-08-25T23:54:55Z<p>APIAdmin: New page: This function will return the set of specific permissions granted to a particular limited administrator. "Limited" admins are limited to working with certain portions of the control panel...</p>
<hr />
<div>This function will return the set of specific permissions granted to a particular limited administrator. "Limited" admins are limited to working with certain portions of the control panel. The complete list of possible permissions is:<br />
<pre><br />
Email Accounts section of the control panel--<br />
EA:Mailboxes<br />
EA:Aliases<br />
EA:Filtering<br />
EA:Settings<br />
EA:Tools<br />
EA:RSSFeeds<br />
EA:UserData<br />
EA:MailingLists<br />
EA:GroupLists<br />
EA:Archiving<br />
EA:DataRestores<br />
<br />
Email Marketing section--<br />
EM:Subscribers<br />
EM:Lists<br />
EM:Emails<br />
EM:Preferences<br />
EM:Resources<br />
EM:Upgrade<br />
EM:SubAccounts<br />
<br />
Reseller Tools section--<br />
RT:Administrators<br />
RT:SubAccounts<br />
RT:WebmailSites<br />
<br />
Email Reports section--<br />
ER:MailboxCount<br />
ER:MailboxStorage<br />
ER:MailForwarding<br />
ER:AdministratorLogs<br />
ER:LastLoginDates<br />
ER:MailboxAliases<br />
ER:Statistics<br />
<br />
Webmail Sites section--<br />
WS:InterfaceDesign<br />
WS:LoginLogoutPages<br />
WS:Images<br />
WS:EmailTaglines<br />
WS:FreeSignups<br />
<br />
Control Panel section--<br />
CP:LoginPage<br />
CP:MainPage<br />
CP:Header<br />
CP:Footer<br />
CP:ColorStyles<br />
CP:SupportPages<br />
<br />
<br />
Collaboration section--<br />
Col:CompanyDirectory<br />
Col:SharedCalendar<br />
<br />
My Account section--<br />
MA:BillingInformation<br />
MA:CompanyContacts<br />
MA:UpgradeServices<br />
MA:InvoiceHistory<br />
<br />
Customer Care section--<br />
CC:Support<br />
CC:Feedback<br />
CC:APIWiki<br />
CC:IdeaCentral<br />
CC:Ticketing<br />
<br />
Custom Tools section--<br />
CT:Tools<br />
<br />
Domain Names section--<br />
DN:Renewal<br />
DN:Registration<br />
DN:DNS<br />
<br />
Troubleshooting section--<br />
TR:DomainDetails<br />
TR:MailboxDetails<br />
TR:DNSCheck<br />
TR:RemoteMailCheck<br />
TR:HeaderAnalyzer<br />
TR:LookupSpamRules<br />
</pre><br />
<br />
===Parameters===<br />
<br />
Three strings of input, two of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"AdminUsername" (the limited admin about which you are retrieving information),<br />
<br />
"DomainList" (the list of domains for which the admin has rights, or simply "ALL"),<br />
"PermissionsList" (a CRLF separated list of control panel areas that this admin can access)<br />
<br />
===Return Values===<br />
If successful, the return value of the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_GetAllocatedStorage()&diff=186Subaccount GetAllocatedStorage()2008-08-25T23:54:52Z<p>APIAdmin: New page: This function will return the current figures for allocated (assigned to a mailbox) storage and available storage for all domains on a subaccount. Integer results are in MB. ===Parameter...</p>
<hr />
<div>This function will return the current figures for allocated (assigned to a mailbox) storage and available storage for all domains on a subaccount. Integer results are in MB.<br />
<br />
===Parameters===<br />
<br />
Three strings of input, three integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"SubaccountNumber",<br />
<br />
"Result",<br />
"allocatedExtraStorage" (how much extra storage has been assigned to mailboxes),<br />
"allotedExtraStorage" (upper limit on permitted storage; will always be >= than allocated storage)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_GetNumMailboxes()&diff=185Subaccount GetNumMailboxes()2008-08-25T23:54:50Z<p>APIAdmin: New page: This function will return the current number of mailboxes that have been created across all domains on a subaccount. ===Parameters=== Three strings of input, two integers of output: ...</p>
<hr />
<div>This function will return the current number of mailboxes that have been created across all domains on a subaccount.<br />
<br />
===Parameters===<br />
<br />
Three strings of input, two integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"SubaccountNumber",<br />
<br />
"Result",<br />
"numMailboxes" (number of unique email mailboxes)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_GetNumDomains()&diff=184Subaccount GetNumDomains()2008-08-25T23:54:47Z<p>APIAdmin: New page: This function will return the current number of domains associated with a subaccount. This number does not include domain aliases. ===Parameters=== Three strings of input, two integers ...</p>
<hr />
<div>This function will return the current number of domains associated with a subaccount. This number does not include domain aliases.<br />
<br />
===Parameters===<br />
<br />
Three strings of input, two integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"SubaccountNumber",<br />
<br />
"Result",<br />
"numDomains" (number of domains on the subaccount)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=Subaccount_GetNumBcc()&diff=183Subaccount GetNumBcc()2008-08-25T23:54:45Z<p>APIAdmin: New page: This function will return the current number of email addresses being archived with BCC Archiving associated with a subaccount. ===Parameters=== Three strings of input, two integers of o...</p>
<hr />
<div>This function will return the current number of email addresses being archived with BCC Archiving associated with a subaccount.<br />
<br />
===Parameters===<br />
<br />
Three strings of input, two integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"SubaccountNumber",<br />
<br />
"Result",<br />
"numBcc" (total number of BCC archived mailboxes across all domains on the subaccount)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=GetEMSubscriberLimit()&diff=182GetEMSubscriberLimit()2008-08-25T23:54:42Z<p>APIAdmin: New page: This function will return the current number of subscriber email addresses and the maximum number of subscriber email addresses associated with a subaccount for the Email Marketing / Outre...</p>
<hr />
<div>This function will return the current number of subscriber email addresses and the maximum number of subscriber email addresses associated with a subaccount for the Email Marketing / Outreach product.<br />
<br />
===Parameters===<br />
<br />
Three strings of input, three integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"SubaccountNumber",<br />
<br />
"Result",<br />
"numSubscribers" (number of unique email addresses),<br />
"maxNumSubscribers" (upper limit of permitted subscribers for this subaccount)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=GetDomainNumBcc()&diff=181GetDomainNumBcc()2008-08-25T23:54:39Z<p>APIAdmin: New page: This function will return the number of BCC archived mailboxes ===Parameters=== Three strings of input, two integers of output: "ResellerUsername" (the administrative user for the AP...</p>
<hr />
<div>This function will return the number of BCC archived mailboxes<br />
<br />
===Parameters===<br />
<br />
Three strings of input, two integers of output:<br />
"ResellerUsername" (the administrative user for the API),<br />
"ResellerPassword",<br />
"HostName" (domain name),<br />
<br />
"Result",<br />
"numBcc" (number of mailboxes being archived via BCC)<br />
<br />
===Return Values===<br />
If successful, the return value of "Result" from the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=AliasIndividual&diff=180AliasIndividual2008-08-25T23:53:38Z<p>APIAdmin: New page: CheckAliasExists()<br> GetUserAliasesString()<br> AddAlias()<br> ModifyAlias()<br> DeleteAlias()<br> GetAlias()<br></p>
<hr />
<div>[[CheckAliasExists()]]<br><br />
[[GetUserAliasesString()]]<br><br />
[[AddAlias()]]<br><br />
[[ModifyAlias()]]<br><br />
[[DeleteAlias()]]<br><br />
[[GetAlias()]]<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=AliasDomain&diff=179AliasDomain2008-08-25T23:53:27Z<p>APIAdmin: New page: ModifyDomainAliases()<br> SetNobodyAlias()<br> RemoveNobodyAlias()<br> GetUserAliasesBulk()<br> AddUserAliasesBulk()<br> DeleteUserAliasesBulk()<br></p>
<hr />
<div>[[ModifyDomainAliases()]]<br><br />
[[SetNobodyAlias()]]<br><br />
[[RemoveNobodyAlias()]]<br><br />
[[GetUserAliasesBulk()]]<br><br />
[[AddUserAliasesBulk()]]<br><br />
[[DeleteUserAliasesBulk()]]<br></div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=GetCurrentUserMailboxSize()&diff=178GetCurrentUserMailboxSize()2008-08-25T23:13:36Z<p>APIAdmin: New page: This function will report the amount of space used in a given mailbox. This information is updated nightly. Size is given in megabytes. ===Input Parameters=== Four strings, one result i...</p>
<hr />
<div>This function will report the amount of space used in a given mailbox. This information is updated nightly. Size is given in megabytes.<br />
<br />
===Input Parameters===<br />
Four strings, one result integer:<br />
Administrative username,<br />
Administrative password,<br />
Domain name,<br />
User name,<br />
<br />
Size in MB<br />
===Return Values===<br />
If successful, the return value of the function will be 1.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=GetUserStatus()&diff=177GetUserStatus()2008-08-25T23:13:31Z<p>APIAdmin: New page: This function will report whether a user is valid on the system. ===Input Parameters=== Four strings: Administrative username, Administrative password, Domain name, User n...</p>
<hr />
<div>This function will report whether a user is valid on the system.<br />
<br />
===Input Parameters===<br />
Four strings:<br />
Administrative username,<br />
Administrative password,<br />
Domain name,<br />
User name<br />
===Return Values===<br />
If successful, the return value of the function will be 1: User Exists & is Active, 0: User Exists & is Inactive,-5: User does not exist/Invalid,-4: Domain does not exist/Invalid.<br />
<br />
Consult the [[resultcodes|Result Code Table]] for a list of result codes and their meaning.</div>APIAdminhttp://api-wiki.apps.rackspace.com/api-wiki/index.php?title=UsersIndividual&diff=176UsersIndividual2008-08-25T23:13:13Z<p>APIAdmin: New page: CheckUserExists()<br> AddUser()<br> DeleteUser()<br> ModifyUser()<br> GetUserMailForward()<br> SetUserMailForward()<br> RemoveUserMailForward()<br> [[GetUserMai...</p>
<hr />
<div>[[CheckUserExists()]]<br><br />
[[AddUser()]]<br><br />
[[DeleteUser()]]<br><br />
[[ModifyUser()]]<br><br />
[[GetUserMailForward()]]<br><br />
[[SetUserMailForward()]]<br><br />
[[RemoveUserMailForward()]]<br><br />
[[GetUserMailVacation()]]<br><br />
[[SetUserMailVacation()]]<br><br />
[[SetUserMailboxMaxSize()]]<br><br />
[[GetUserMailboxMaxSize()]]<br><br />
[[GetUserLastLogin()]]<br><br />
[[GetUserActiveStatus()]]<br><br />
[[GetUserStatus()]]<br><br />
[[GetCurrentUserMailboxSize()]]<br><br />
[[CheckUserAvailable()]]<br><br />
[[GetUserAliasesString()]]<br><br />
[[AddUserWithLdapAttributes()]]<br><br />
[[AddUserWithLdapAttributesString()]]<br><br />
[[ModifyUserWithLdapAttributes()]]<br><br />
[[ModifyUserWithLdapAttributesString()]]<br><br />
[[AddUserSpam()]]<br><br />
[[DeleteUserSpam()]]<br><br />
[[GetUserSpam()]]<br><br />
[[SetUserSpamCleaner()]]<br><br />
[[GetUserSpamCleaner()]]<br><br />
[[SetUserSpamSafeList()]]<br><br />
[[GetUserSpamSafeList()]]<br><br />
[[SetUserSpamBlackList()]]<br><br />
[[GetUserSpamBlackList()]]<br><br />
[[GetMailAllotStorage()]]<br><br />
[[AddMailAllotStorage()]]<br><br />
[[GetUserNumMessages()]]<br></div>APIAdmin