Difference between revisions of "Exchange Mailbox (Rest API)"

From Rackspace Email & Apps API
Jump to: navigation, search
(Update to latest live version.)
(v1 - Current)
 
(22 intermediate revisions by 4 users not shown)
Line 1: Line 1:
 
__TOC__
 
__TOC__
  
 +
== v1 - Current ==
  
== Index ==
+
=== Index ===
  
 
''URL'':  
 
''URL'':  
  
  <nowiki>[GET] http://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes</nowiki>
 
         /ex/mailboxes</nowiki>
  
Line 13: Line 14:
  
 
Shows a list of mailboxes under the domain
 
Shows a list of mailboxes under the domain
 +
 +
 +
''Filter/Search'':
 +
 +
Mailbox searches may be filtered by the 'enabled' flag using query methods ?enabled=true and ?enabled=false.
  
  
 
''Remarks'':
 
''Remarks'':
  
The show operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/MailboxList.xsd MailboxList.xsd]
+
The show operation only supports the GET HTTP verb.
  
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/mailboxes', 'text/xml'
+
get '/customers/12345678/domains/example.com/ex/mailboxes'
 
</pre>
 
</pre>
  
Line 56: Line 62:
  
  
== Show ==
+
''Custom Fields'':
 +
 
 +
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'.
 +
 
 +
 
 +
''Example'':
 +
<pre>
 +
get '/customers/12345678/domains/example.com/ex/mailboxes?fields=size,currentUsage'
 +
</pre>
 +
 
 +
=== Show ===
  
 
''URL'':
 
''URL'':
  <nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)</nowiki>
 
         /ex/mailboxes/(mailbox name)</nowiki>
  
Line 70: Line 86:
 
''Remarks'':
 
''Remarks'':
  
The show operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/Mailbox.xsd Mailbox.xsd]
+
The show operation only supports the GET HTTP verb.
  
 
The "samAccountName" is the logon name used to support clients and servers running older versions of the operating system.
 
The "samAccountName" is the logon name used to support clients and servers running older versions of the operating system.
Line 77: Line 93:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', 'text/xml'
+
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'
 
</pre>
 
</pre>
  
Line 91: Line 107:
 
   <currentUsage>0</currentUsage>
 
   <currentUsage>0</currentUsage>
 
   <isHidden>false</isHidden>
 
   <isHidden>false</isHidden>
 +
  <visibleInRackspaceEmailCompanyDirectory>false</visibleInRackspaceEmailCompanyDirectory>
 
   <isPublicFolderAdmin>true</isPublicFolderAdmin>
 
   <isPublicFolderAdmin>true</isPublicFolderAdmin>
 
   <enabled>true</enabled>
 
   <enabled>true</enabled>
 +
  <lastLogin>2/12/2010 1:00:00 AM</lastLogin>
 
   <contactInfo>
 
   <contactInfo>
 
     <firstName>API</firstName>
 
     <firstName>API</firstName>
Line 110: Line 128:
 
     <country>USA</country>
 
     <country>USA</country>
 
     <notes>My Notes</notes>
 
     <notes>My Notes</notes>
 +
    <customID>0123456789</customID>
 
   </contactInfo>
 
   </contactInfo>
   <emailForwardingAddress />
+
   <emailForwardingAddress>apiexmailbox8@apidomain24.com</emailForwardingAddress>
 +
  <saveForwardedEmail>false</saveForwardedEmail>
 
   <emailAddressList>
 
   <emailAddressList>
 
     <emailAddress>
 
     <emailAddress>
Line 127: Line 147:
 
''Json Result Example'':
 
''Json Result Example'':
  
{"name":"apiexmailbox90","displayName":"API Test","size":2048,"currentUsage":0,"isHidden":false,"isPublicFolderAdmin":true,"enabled":true,"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"},"emailForwardingAddress":"","emailAddressList":[{"address":"apiexmailbox90@apidomain92.com","replyTo":true}],"hasBlackBerryMobileService":false,"hasActiveSyncMobileService":false,"samAccountName":"apiexmailbox90_53B5B"}
+
{"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}
 
 
  
== Add/Edit ==
+
=== Add/Edit ===
  
 
''URL'':
 
''URL'':
  <nowiki>Add: [POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>Add: [POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)
 
         /ex/mailboxes/(mailbox name)
Edit: [PUT] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
Edit: [PUT] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)</nowiki>
 
         /ex/mailboxes/(mailbox name)</nowiki>
  
Line 143: Line 162:
 
Adds/edits a mailbox using the specified form fields. All required fields must be supplied when adding. Other fields may be omitted.
 
Adds/edits a mailbox using the specified form fields. All required fields must be supplied when adding. Other fields may be omitted.
  
 +
{{RouteRequiresFormEncoded}}
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 232: Line 252:
 
| string
 
| string
 
| Notes field
 
| Notes field
 +
|-
 +
| customID
 +
| string
 +
| A custom field that can be used to tie user mailboxes to external user systems
 
|-
 
|-
 
| emailForwardingAddress
 
| emailForwardingAddress
 
| string
 
| string
 
| 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.)
 
| 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.)
 +
|-
 +
| saveForwardedEmail
 +
| boolean
 +
| When true, copies of forwarded email are saved in this mailbox. When false, email is forwarded but not saved.
 +
|-
 +
| visibleInRackspaceEmailCompanyDirectory
 +
| boolean
 +
| Flag indicating whether the mailbox is visible in the company directory
 
|-
 
|-
 
| enabled
 
| enabled
 +
| boolean
 +
| Enable/Disable mailbox, input must be "true" or "false"
 +
|-
 +
| lastLogin '''''(read only)'''''
 
| string
 
| string
| Enable/Disable mailbox, input must be "true" or "false"
+
| Date of last login, EST Time (in string format)
 
|}
 
|}
  
Line 245: Line 281:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', 'text/xml',  
+
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith',  
 
{  
 
{  
 
   'displayName' => 'Alex Smith',
 
   'displayName' => 'Alex Smith',
Line 254: Line 290:
  
 
<pre>
 
<pre>
put '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', 'text/xml',
+
put '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith',
 
{  
 
{  
   'homenumber' => '8005551234'
+
   'homeNumber' => '8005551234'
 
}   
 
}   
 
</pre>
 
</pre>
Line 285: Line 321:
 
|}
 
|}
  
 
+
=== Delete ===
== Delete ==
 
  
 
''URL'':
 
''URL'':
  <nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
             /ex/mailboxes/(mailbox name)</nowiki>
 
             /ex/mailboxes/(mailbox name)</nowiki>
  
Line 305: Line 340:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', 'text/xml'
+
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'
 
</pre>
 
</pre>
  
  
== Add Email Address ==
+
=== Add Email Address ===
  
 
''URL'':
 
''URL'':
  <nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki>
 
         /ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki>
  
Line 323: Line 358:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com', 'text/xml'
+
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com', {}
 
</pre>
 
</pre>
  
 
+
=== Delete Email Address ===
== Delete Email Address ==
 
  
 
''URL'':
 
''URL'':
  <nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
             /ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki>
 
             /ex/mailboxes/(mailbox name)/emailaddresses/(email address)</nowiki>
  
Line 346: Line 380:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com', 'text/xml'
+
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com'
 
</pre>
 
</pre>
  
  
== Spam ==
+
=== Spam Settings ===
  
=== Index Blacklist ===
+
See [[Mailbox_Spam_(Rest_API)| Exchange Mailbox Spam Settings]].
  
''URL'':
 
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/blacklist</nowiki>
 
  
 +
=== Mailbox Permissions ===
  
''Description'':
+
Exchange mailboxes can be given permissions. A permission is defined as a tuple (mailbox, permissionType).
 
 
This operation returns email address blacklist associated with the mailbox.  
 
 
 
  
''Remarks'':
+
permissionType:= (SendAs | FullAccess | Both)
 
 
The Index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/Blacklist.xsd Blacklist.xsd]
 
 
 
 
 
''Example'':
 
<pre>
 
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/blacklist', 'text/xml'
 
</pre>
 
 
 
 
 
''XML Result Example'':
 
 
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<blacklist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:blacklist">
 
  <addresses>
 
    <address>name1@spam.com</address>
 
    <address>name2@spam.com</address>
 
  </addresses>
 
</blacklist>
 
</pre>
 
 
 
 
 
''Json Result Example'':
 
 
 
{"addresses":["name1@spam.com","name2@spam.com"]}
 
 
 
 
 
=== Index IP Blacklist ===
 
  
 +
==== Index Permissions ====
 
''URL'':
 
''URL'':
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/ipblacklist</nowiki>
 
  
 +
<nowiki>[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 +
        /ex/mailboxes/(user)/permissions</nowiki>
  
 
''Description'':
 
''Description'':
  
This operation returns IP blacklist associated with the mailbox.
+
Shows the current set of permissions granted on a user's mailbox.
 
 
 
 
''Remarks'':
 
 
 
The Index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/IpBlacklist.xsd IpBlacklist.xsd]
 
 
 
 
 
''Example'':
 
<pre>
 
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/ipblacklist', 'text/xml'
 
</pre>
 
 
 
''XML Result Example':
 
 
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<ipBlacklist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:ipBlacklist">
 
  <addresses>
 
    <ip>216.12.34.1</ip>
 
    <ip>216.12.34.2</ip>
 
  </addresses>
 
</ipBlacklist>
 
</pre>
 
 
 
 
 
''Json Result Example'':
 
 
 
{"addresses":["216.12.34.1","216.12.34.2"]}
 
 
 
 
 
=== Index Safelist ===
 
 
 
''URL'':
 
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/safelist</nowiki>
 
 
 
 
 
''Description'':
 
 
 
This operation returns email address safelist associated with the mailbox.
 
 
 
 
 
''Remarks'':
 
 
 
The Index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/Safelist.xsd Safelist.xsd]
 
 
 
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/safelist', 'text/xml'
+
get '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions'
 
</pre>
 
</pre>
 
  
 
''XML Result Example'':
 
''XML Result Example'':
 
 
<pre>
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<?xml version="1.0" encoding="utf-8"?>
<safelist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:safelist">
+
<permissionList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"  
   <addresses>
+
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:permissionList">
     <address>name1@notspam.com</address>
+
   <offset>0</offset>
    <address>name2@notspam.com</address>
+
  <size>50</size>
   </addresses>
+
  <total>0</total>
</safelist>
+
  <permissions>
 +
     <permission>
 +
      <emailAddress>joe.schmoe@enterpriseallservices.net</emailAddress>
 +
      <permissionType>fullAccess</permissionType>
 +
    </permission>
 +
   </permissions>
 +
</permissionList>
 
</pre>
 
</pre>
 
  
 
''Json Result Example'':
 
''Json Result Example'':
  
{"addresses":["name1@notspam.com","name2@notspam.com"]}
+
{"offset":0,"size":50,"total":0,"permissions":[{"emailAddress":"joe.schmoe@enterpriseallservices.net","permissionType":"fullAccess"}]}
 
 
  
 +
''Comments'':
 +
The above result shows the permission list for user Jane Doe's mailbox. The list contains one entry corresponding to
 +
that of user Joe Schmoe with permission type of "FullAccess".
  
=== Index IP Safelist ===
+
==== Adding Permission ====
  
 
''URL'':
 
''URL'':
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/ipsafelist</nowiki>
 
  
 +
<nowiki>[POST] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 +
        /ex/mailboxes/(user1)/permissions/(user2)</nowiki>
  
 
''Description'':
 
''Description'':
  
This operation returns IP safelist associated with the mailbox.
+
Grants user2 the specified permission on mailbox of user1.
 
 
 
 
''Remarks'':
 
 
 
The Index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/IpSafelist.xsd IpSafelist.xsd]
 
 
 
 
 
''Example'':
 
<pre>
 
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/ipsafelist', 'text/xml'
 
</pre>
 
 
 
 
 
''XML Result Example'':
 
 
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<ipSafelist xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:ipSafelist">
 
  <addresses>
 
    <ip>192.168.0.1</ip>
 
    <ip>192.168.0.2</ip>
 
  </addresses>
 
</ipSafelist>
 
</pre>
 
 
 
 
 
''Json Result Example'':
 
 
 
{"addresses":["192.168.0.1","192.168.0.2"]}
 
 
 
 
 
=== Add Blacklist ===
 
 
 
''URL'':
 
<nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/blacklist/(email address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Adds an email address or domain to the blacklist.
 
 
 
 
 
''Example'':
 
<pre>
 
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/blacklist/anyone@spam.com', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered invalid email or domain
 
| 400
 
| invalid email address: abc
 
|-
 
| Entered current domain
 
| 400
 
| Adding example.com would blacklist the current domain
 
|}
 
 
 
 
 
=== Add IP Blacklist ===
 
 
 
''URL'':
 
<nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/ipblacklist/(ip address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Adds an IP to the blacklist.
 
 
 
 
 
''Example'':
 
<pre>
 
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/blacklist/216.12.34.1', 'text/xml'
 
</pre>
 
 
 
 
 
=== Add Safelist ===
 
 
 
''URL'':
 
<nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/safelist/(email address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Adds an email address or domain to the safelist.
 
 
 
 
 
''Example'':
 
<pre>
 
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/safelist/anyone@yahoo.com', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered invalid email or domain
 
| 400
 
| invalid email address: abc
 
|}
 
 
 
 
 
=== Add IP Safelist ===
 
 
 
''URL'':
 
<nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/safelist/(ip address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Adds an IP to the safelist.
 
 
 
 
 
''Example'':
 
<pre>
 
post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/safelist/216.12.34.1', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered invalid IP address
 
| 400
 
| invalid ip address: 123
 
|}
 
 
 
 
 
=== Delete Blacklist ===
 
 
 
''URL'':
 
<nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
            /ex/mailboxes/(mailbox name)/spam/blacklist/(email address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Removes an email address or domain from the blacklist.
 
 
 
 
 
''Example'':
 
<pre>
 
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/blacklist/anyone@yahoo.com', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered invalid email or domain
 
| 400
 
| invalid email address: abc
 
|-
 
| Entered email or domain is not on the current blacklist
 
| 400
 
| abc@junkmail.com is not found on the blacklist
 
|}
 
 
 
 
 
=== Delete IP Blacklist ===
 
 
 
''URL'':
 
<nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
            /ex/mailboxes/(mailbox name)/spam/ipblacklist/(ip address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Removes an IP from the blacklist.
 
 
 
 
 
''Example'':
 
<pre>
 
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/ipblacklist/216.12.34.1', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered IP is not on the current blacklist
 
| 400
 
| 216.12.34.1 is not found on the blacklist
 
|}
 
 
 
 
 
=== Delete Safelist ===
 
 
 
''URL'':
 
<nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
            /ex/mailboxes/(mailbox name)/spam/safelist/(email address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Removes an email address or domain from the safelist.
 
 
 
 
 
''Example'':
 
<pre>
 
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/safelist/anyone@yahoo.com', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered invalid email or domain
 
| 400
 
| invalid email address: abc
 
|-
 
| Entered email or domain is not on the current safelist
 
| 400
 
| anyone@yahoo.com is not found on the safelist
 
|}
 
 
 
 
 
=== Delete IP Safelist ===
 
 
 
''URL'':
 
<nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
            /ex/mailboxes/(mailbox name)/spam/ipsafelist/(email address)</nowiki>
 
 
 
 
 
''Description'':
 
 
 
Removes an IP from the safelist.
 
 
 
 
 
''Example'':
 
<pre>
 
delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/ipsafelist/216.12.34.1', 'text/xml'
 
</pre>
 
 
 
 
 
''Errors'':
 
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Entered IP is not on the current safelist
 
| 400
 
| 216.12.34.1 is not found on the safelist
 
|}
 
 
 
 
 
=== Show Spam Setting ===
 
 
 
''URL'':
 
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/settings</nowiki>
 
 
 
 
 
''Description'':
 
 
 
This operation returns the spam settings associated with the mailbox.
 
 
 
 
 
''Remarks'':
 
 
 
The Show operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/MailboxSpamSetting.xsd MailboxSpamSetting.xsd]
 
 
 
 
 
''Example'':
 
<pre>
 
get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/settings', 'text/xml'
 
</pre>
 
 
 
 
 
''XML Result Example'':
 
 
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<MailboxSpamSettings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:MailboxSpamSettings">
 
  <filterLevel>on</filterLevel>
 
  <sendToDomainQuarantine>false</sendToDomainQuarantine>
 
  <quarantineOwner />
 
</MailboxSpamSettings>
 
</pre>
 
 
 
 
 
''Json Result Example'':
 
 
 
{"filterLevel":"on","sendToDomainQuarantine":false,"quarantineOwner":""}
 
 
 
 
 
=== Edit Spam Setting ===
 
 
 
''URL'':
 
<nowiki>[PUT] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/spam/settings</nowiki>
 
 
 
 
 
''Description'':
 
 
 
This operation will modify the mailbox spam setting. Only 'filterlevel' is the required form field.
 
  
 +
{{RouteRequiresFormEncoded}}
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 820: Line 453:
 
!''Description''
 
!''Description''
 
|-
 
|-
| filterlevel
+
| permission
| string
 
| Spam filter status, must be 'on' or 'off' or 'exclusive' (Required)
 
|-
 
| sendtodomainquarantine
 
| boolean
 
| Indicates whether or not send spam to domain quarantine
 
|-
 
| quarantineowner
 
 
| string
 
| string
| The email address that quarantine notifications be sent to
+
| permissionType (Required)
 
|}
 
|}
 
 
''Remarks'':
 
 
Form field "filterlevel" is always required. <br>
 
When "filterlevel" is "on", spam will be sent to mailbox quarantine as default, unless "sendtodomainquarantine" is set to "true". <br>
 
Changing "filterlevel" to "off" will force "sendtodomainquarantine" to be "false". <br>
 
When "filterlevel" is "exclusive", spam will be sent to mailbox quarantine as default, unless "sendtodomainquarantine" is set to "true". In addition, mailbox will only receive email from addresses and IPs on its safelist.
 
 
 
''Example'':
 
<pre>
 
put '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/spam/settings', 'text/xml',
 
{
 
  'filterlevel' => 'off'
 
 
</pre>
 
 
 
''Errors'':
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Invalid input for form field 'filterlevel'
 
| 400
 
| Invalid filterLevel, input must be: on/off/exclusive
 
|}
 
 
 
== BlackBerry Mobile Service ==
 
 
=== Index ===
 
 
''URL'':
 
<nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/blackberrymobileservices</nowiki>
 
 
 
''Description'':
 
 
Returns a list of mailboxes that has BlackBerry mobile service enabled.
 
 
 
''Remarks'':
 
 
The index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/BlackberryMobileServiceList.xsd BlackberryMobileServiceList.xsd]
 
 
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/blackberrymobileservices', 'text/xml'
+
post '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe', {'permission' => 'fullAccess'}
</pre>
 
 
 
 
 
''XML Result Example'':
 
 
 
<pre>
 
<?xml version="1.0" encoding="utf-8"?>
 
<blackBerryMobileServiceList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"
 
xmlns="urn:xml:blackBerryMobileServiceList">
 
  <offset>0</offset>
 
  <size>50</size>
 
  <total>3</total>
 
  <mailboxes>
 
    <mailbox>apiexmailbox36</mailbox>
 
    <mailbox>apiexmailbox66</mailbox>
 
    <mailbox>apiexmailbox85</mailbox>
 
  </mailboxes>
 
</blackBerryMobileServiceList>
 
 
</pre>
 
</pre>
  
 +
''Comments'':
 +
The above result shows that on the mailbox of user Jane Doe, the user John Doe has been granted the permission of type "fullAccess".
  
''Json Result Example'':
+
==== Editing Permission ====
 
 
{"offset":0,"size":50,"total":3,"mailboxes":["apiexmailbox36","apiexmailbox66","apiexmailbox85"]}
 
 
 
 
 
=== Add ===
 
  
 
''URL'':
 
''URL'':
<nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
        /ex/mailboxes/(mailbox name)/blackberrymobileservice</nowiki>
 
  
 +
<nowiki>[PUT] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 +
        /ex/mailboxes/(user1)/permissions/(user2)</nowiki>
  
 
''Description'':
 
''Description'':
  
Attaches a BlackBerry mobile service to the mailbox.
+
Modifies permission granted to user2 on the mailbox of user1.
  
 +
{{RouteRequiresFormEncoded}}
  
 
{| class="wikitable"
 
{| class="wikitable"
Line 929: Line 484:
 
!''Description''
 
!''Description''
 
|-
 
|-
| activationPassword
+
| permission
 
| string
 
| string
| Activation password (Required)
+
| permissionType (Required)
 
|}
 
|}
 
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
post '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/blackberrymobileservice', 'text/xml',
+
put '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe',  
{
+
{'permission' => 'both'}
  'activationPassword' => '12345'
 
}
 
 
</pre>
 
</pre>
  
 +
''Comments'':
 +
The permission granted to user John Doe on the mailbox of Jane Doe is modified to "both".
  
''Errors'':
+
==== Deleting Permission ====
 
 
{| class="wikitable"
 
!''Description''
 
!''HTTP Response Code''
 
!''Sample Message''
 
|-
 
| Mailbox already has BlackBerry Service
 
| 400
 
| User john.smith@example.com has BlackBerry Mobile Service already
 
|}
 
 
 
 
 
=== Delete ===
 
  
 
''URL'':
 
''URL'':
<nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
 
            /ex/mailboxes/(mailbox name)/blackberrymobileservice</nowiki>
 
  
 +
<nowiki>[DELETE] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 +
        /ex/mailboxes/(user1)/permissions/(user2)</nowiki>
  
 
''Description'':
 
''Description'':
  
Detaches a BlackBerry mobile service from a mailbox.
+
Deletes permission granted to user2 on the mailbox of user1.
 
 
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
delete '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/blackberrymobileservice', 'text/xml'
+
delete '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe'
 
</pre>
 
</pre>
  
 +
''Comments'':
 +
The permission granted to user John Doe on the mailbox of Jane Doe is deleted.
  
== ActiveSync Mobile Service ==
 
  
=== Index ===
+
=== ActiveSync Mobile Service ===
 +
 
 +
==== Index ====
  
 
''URL'':
 
''URL'':
  <nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/activesyncmobileservices</nowiki>
 
         /ex/activesyncmobileservices</nowiki>
  
Line 991: Line 534:
 
''Remarks'':
 
''Remarks'':
  
The index operation only supports the GET HTTP verb. For .xml format refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/ActiveSyncMobileServiceList.xsd ActiveSyncMobileServiceList.xsd]
+
The index operation only supports the GET HTTP verb.
  
  
Line 997: Line 540:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/activesyncmobileservices', 'text/xml'
+
get '/customers/12345678/domains/example.com/ex/activesyncmobileservices'
 
</pre>
 
</pre>
  
Line 1,023: Line 566:
 
{"offset":0,"size":50,"total":3,"mailboxes":["apiexmailbox36","apiexmailbox66","apiexmailbox85"]}
 
{"offset":0,"size":50,"total":3,"mailboxes":["apiexmailbox36","apiexmailbox66","apiexmailbox85"]}
  
 
+
==== Show ====
=== Show ===
 
  
 
''URL'':
 
''URL'':
  <nowiki>[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
 
         /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
  
Line 1,038: Line 580:
 
''Remarks'':
 
''Remarks'':
  
The index operation only supports the GET HTTP verb. For .xml format, refer to the following schema document: [http://api.emailsrvr.com/v0/Schemas/ActiveSyncMobileService.xsd ActiveSyncMobileService.xsd]
+
The index operation only supports the GET HTTP verb.
  
  
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
get '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', 'text/xml'
+
get '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'
 
</pre>
 
</pre>
  
Line 1,077: Line 619:
 
|}
 
|}
  
=== Add ===
+
==== Add ====
  
 
''URL'':
 
''URL'':
  <nowiki>[POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
         /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
 
         /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
  
Line 1,091: Line 633:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
post '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', 'text/xml', {}
+
post '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', {}
 
</pre>
 
</pre>
  
Line 1,108: Line 650:
  
  
=== Delete ===
+
==== Delete ====
  
 
''URL'':
 
''URL'':
  <nowiki>[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name)
+
  <nowiki>[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
 
             /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
 
             /ex/mailboxes/(mailbox name)/activesyncmobileservice</nowiki>
  
Line 1,122: Line 664:
 
''Example'':
 
''Example'':
 
<pre>
 
<pre>
delete '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', 'text/xml'
+
delete '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'
 
</pre>
 
</pre>

Latest revision as of 07:51, 28 January 2020

v1 - Current

Index

URL:

[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes


Description:

Shows a list of mailboxes under the domain


Filter/Search:

Mailbox searches may be filtered by the 'enabled' flag using query methods ?enabled=true and ?enabled=false.


Remarks:

The show operation only supports the GET HTTP verb.


Example:

get '/customers/12345678/domains/example.com/ex/mailboxes'


XML Result Example:

<?xml version="1.0" encoding="utf-8"?>
<mailboxList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:mailboxList">
  <offset>0</offset>
  <size>50</size>
  <total>3</total>
  <mailboxes>
    <mailbox>
      <name>apiexmailbox55</name>
      <displayName>API Test</displayName>
    </mailbox>
    <mailbox>
      <name>apiexmailbox6</name>
      <displayName>API Test</displayName>
    </mailbox>
    <mailbox>
      <name>apiexmailbox90</name>
      <displayName>API Test</displayName>
    </mailbox>
  </mailboxes>
</mailboxList>


Json Result Example:

{"offset":0,"size":50,"total":3,"mailboxes":[{"name":"apiexmailbox55","displayName":"API Test"},{"name":"apiexmailbox6","displayName":"API Test"},{"name":"apiexmailbox90","displayName":"API Test"}]}


Custom Fields:

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'.


Example:

get '/customers/12345678/domains/example.com/ex/mailboxes?fields=size,currentUsage'

Show

URL:

[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)


Description:

The show operation will return detailed information about the specified mailbox.


Remarks:

The show operation only supports the GET HTTP verb.

The "samAccountName" is the logon name used to support clients and servers running older versions of the operating system.


Example:

get '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'


XML Result Example:

<?xml version="1.0" encoding="utf-8"?>
<mailbox xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:mailbox">
  <name>apiexmailbox90</name>
  <displayName>API Test</displayName>
  <size>2048</size>
  <currentUsage>0</currentUsage>
  <isHidden>false</isHidden>
  <visibleInRackspaceEmailCompanyDirectory>false</visibleInRackspaceEmailCompanyDirectory>
  <isPublicFolderAdmin>true</isPublicFolderAdmin>
  <enabled>true</enabled>
  <lastLogin>2/12/2010 1:00:00 AM</lastLogin>
  <contactInfo>
    <firstName>API</firstName>
    <lastName>Test</lastName>
    <jobTitle>Dev</jobTitle>
    <company>My Company</company>
    <department>R&D</department>
    <businessNumber>111-1111</businessNumber>
    <homeNumber>222-2222</homeNumber>
    <mobileNumber>333-3333</mobileNumber>
    <faxNumber>444-4444</faxNumber>
    <pagerNumber>1234</pagerNumber>
    <addressLine1>123 Main Street</addressLine1>
    <city>Blacksburg</city>
    <state>VA</state>
    <zip>24060</zip>
    <country>USA</country>
    <notes>My Notes</notes>
    <customID>0123456789</customID>
  </contactInfo>
  <emailForwardingAddress>apiexmailbox8@apidomain24.com</emailForwardingAddress>
  <saveForwardedEmail>false</saveForwardedEmail>
  <emailAddressList>
    <emailAddress>
      <address>apiexmailbox90@apidomain92.com</address>
      <replyTo>true</replyTo>
    </emailAddress>
  </emailAddressList>
  <hasBlackBerryMobileService>false</hasBlackBerryMobileService>
  <hasActiveSyncMobileService>false</hasActiveSyncMobileService>
  <samAccountName>apiexmailbox90_53B5B</samAccountName>
</mailbox>


Json Result Example:

{"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}

Add/Edit

URL:

Add: [POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)
Edit: [PUT] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)


Description:

Adds/edits a mailbox using the specified form fields. All required fields must be supplied when adding. Other fields may be omitted.

Note: this route requires that you submit the request body in Content-Type: application/x-www-form-urlencoded format

Field Name Data Type Description
displayName string Display name (Required for Add)
password string Password (Required for Add)
size positive integer Mailbox size in megabytes (Required for Add)
isHidden boolean Indicates whether or not the mailbox is hidden from the Global Address List
isPublicFolderAdmin boolean Indicates whether or not the account is a public folder administrator
firstName string First name
lastName string Last name
company string Company
department string Department
jobTitle string Job title
addressLine1 string Street address
city string City
state string State
zip string Zip or postal code
country string Country
businessNumber string Business phone number
pagerNumber string Pager phone number
homeNumber string Home phone number
mobileNumber string Mobile phone number
faxNumber string Fax phone number
notes string Notes field
customID string A custom field that can be used to tie user mailboxes to external user systems
emailForwardingAddress string 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.)
saveForwardedEmail boolean When true, copies of forwarded email are saved in this mailbox. When false, email is forwarded but not saved.
visibleInRackspaceEmailCompanyDirectory boolean Flag indicating whether the mailbox is visible in the company directory
enabled boolean Enable/Disable mailbox, input must be "true" or "false"
lastLogin (read only) string Date of last login, EST Time (in string format)


Example:

post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith', 
{ 
  'displayName' => 'Alex Smith',
  'password' => 'Secret123!@#',
  'size' => '2048'
} 
put '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith',
{ 
  'homeNumber' => '8005551234'
}  


Errors:

Description HTTP Response Code Sample Message
New mailbox name (user name) doesn't meet the naming requirements 400 Invalid user name
New mailbox display name doesn't meet the naming requirements 400 Invalid display name
New mailbox password doesn't meet the password pattern requirements 400 Password must be at least 8 characters long
New mailbox name (user name) already exists 400 The email address john.doe@abc.com is already in use

Delete

URL:

[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
            /ex/mailboxes/(mailbox name)


Description:

Deletes the mailbox.


Remarks:

The mailbox and mailbox contents are deleted permanently.


Example:

delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith'


Add Email Address

URL:

[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)/emailaddresses/(email address)


Description:

Adds a mailbox's email address.


Example:

post '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com', {}

Delete Email Address

URL:

[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
            /ex/mailboxes/(mailbox name)/emailaddresses/(email address)


Description:

Deletes the email address.


Remarks:

The operation will fail if the email address does not exist.


Example:

delete '/customers/12345678/domains/example.com/ex/mailboxes/alex.smith/emailaddresses/alex@example.com'


Spam Settings

See Exchange Mailbox Spam Settings.


Mailbox Permissions

Exchange mailboxes can be given permissions. A permission is defined as a tuple (mailbox, permissionType).

permissionType:= (SendAs | FullAccess | Both)

Index Permissions

URL:

[GET] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(user)/permissions

Description:

Shows the current set of permissions granted on a user's mailbox.

Example:

get '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions'

XML Result Example:

<?xml version="1.0" encoding="utf-8"?>
<permissionList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:permissionList">
  <offset>0</offset>
  <size>50</size>
  <total>0</total>
  <permissions>
    <permission>
      <emailAddress>joe.schmoe@enterpriseallservices.net</emailAddress>
      <permissionType>fullAccess</permissionType>
    </permission>
  </permissions>
</permissionList>

Json Result Example:

{"offset":0,"size":50,"total":0,"permissions":[{"emailAddress":"joe.schmoe@enterpriseallservices.net","permissionType":"fullAccess"}]}

Comments: The above result shows the permission list for user Jane Doe's mailbox. The list contains one entry corresponding to that of user Joe Schmoe with permission type of "FullAccess".

Adding Permission

URL:

[POST] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(user1)/permissions/(user2)

Description:

Grants user2 the specified permission on mailbox of user1.

Note: this route requires that you submit the request body in Content-Type: application/x-www-form-urlencoded format

Field Name Data Type Description
permission string permissionType (Required)

Example:

post '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe', {'permission' => 'fullAccess'}

Comments: The above result shows that on the mailbox of user Jane Doe, the user John Doe has been granted the permission of type "fullAccess".

Editing Permission

URL:

[PUT] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(user1)/permissions/(user2)

Description:

Modifies permission granted to user2 on the mailbox of user1.

Note: this route requires that you submit the request body in Content-Type: application/x-www-form-urlencoded format

Field Name Data Type Description
permission string permissionType (Required)

Example:

put '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe', 
{'permission' => 'both'}

Comments: The permission granted to user John Doe on the mailbox of Jane Doe is modified to "both".

Deleting Permission

URL:

[DELETE] http://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(user1)/permissions/(user2)

Description:

Deletes permission granted to user2 on the mailbox of user1.

Example:

delete '/customers/100012/domains/enterpriseallservices.net/ex/mailboxes/jane.doe/permissions/john.doe'

Comments: The permission granted to user John Doe on the mailbox of Jane Doe is deleted.


ActiveSync Mobile Service

Index

URL:

[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/activesyncmobileservices


Description:

Returns a list of mailboxes that have ActiveSync mobile service enabled.


Remarks:

The index operation only supports the GET HTTP verb.


Example:

get '/customers/12345678/domains/example.com/ex/activesyncmobileservices'


XML Result Example:

<?xml version="1.0" encoding="utf-8"?>
<activeSyncMobileServiceList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
xmlns="urn:xml:activeSyncMobileServiceList">
  <offset>0</offset>
  <size>50</size>
  <total>3</total>
  <mailboxes>
    <mailbox>apiexmailbox36</mailbox>
    <mailbox>apiexmailbox66</mailbox>
    <mailbox>apiexmailbox85</mailbox>
  </mailboxes>
</activeSyncMobileServiceList>


Json Result Example:

{"offset":0,"size":50,"total":3,"mailboxes":["apiexmailbox36","apiexmailbox66","apiexmailbox85"]}

Show

URL:

[GET] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)/activesyncmobileservice


Description:

Returns the mailbox ActiveSync mobile service setup information to access Hosted Exchange 2007.


Remarks:

The index operation only supports the GET HTTP verb.


Example:

get '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'


XML Result Example:

<?xml version="1.0" encoding="utf-8"?>
<activeSyncMobileService xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:activeSyncMobileService">
  <emailAddress>john.smith@example.com</emailAddress>
  <serverAddress>mex07A.emailsrvr.com</serverAddress>
  <userName>johnsmith1234</userName>
  <domainAddress>mex07A.mlsrvr.com</domainAddress>
</activeSyncMobileService>


Json Result Example:

{"emailAddress":"john.smith@example.com","serverAddress":"mex07A.emailsrvr.com","userName":"johnsmith1234","domainAddress":"mex07A.mlsrvr.com"}


Errors:

Description HTTP Response Code Sample Message
Mailbox has no ActiveSync service 404 User john.smith@example.com has no active ActiveSync Mobile Service.

Add

URL:

[POST] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
        /ex/mailboxes/(mailbox name)/activesyncmobileservice


Description:

Attaches a ActiveSync service to the mailbox.


Example:

post '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice', {}


Errors:

Description HTTP Response Code Sample Message
Mailbox already has ActiveSync Service 400 User john.smith@example.com has ActiveSync Mobile Service already


Delete

URL:

[DELETE] https://api.emailsrvr.com/v1/customers/(customer account number)/domains/(domain name)
            /ex/mailboxes/(mailbox name)/activesyncmobileservice


Description:

Detaches a ActiveSync mobile service from a mailbox.


Example:

delete '/customers/12345678/domains/example.com/ex/mailboxes/john.smith/activesyncmobileservice'