Difference between revisions of "Rackspace Mailbox (Rest API)"
m (fix rs mailbox name.) |
(09/01/2010 update) |
||
Line 12: | Line 12: | ||
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. | ||
Line 75: | Line 80: | ||
<pre> | <pre> | ||
+ | <?xml version="1.0" encoding="utf-8"?> | ||
<?xml version="1.0" encoding="utf-8"?> | <?xml version="1.0" encoding="utf-8"?> | ||
<rsMailbox xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:rsMailbox"> | <rsMailbox xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:rsMailbox"> | ||
<name>apirsmailbox37</name> | <name>apirsmailbox37</name> | ||
<size>10240</size> | <size>10240</size> | ||
+ | <currentUsage>1024</currentUsage> | ||
<vacationMessage>My Test Vacation Message</vacationMessage> | <vacationMessage>My Test Vacation Message</vacationMessage> | ||
<enableVacationMessage>true</enableVacationMessage> | <enableVacationMessage>true</enableVacationMessage> | ||
Line 86: | Line 93: | ||
</emailForwardingAddressList> | </emailForwardingAddressList> | ||
<saveForwardedEmail>false</saveForwardedEmail> | <saveForwardedEmail>false</saveForwardedEmail> | ||
+ | <lastLogin>2/12/2009 1:00:00 AM</lastLogin> | ||
+ | <createdDate>4/10/2006 7:47:34 PM</createdDate> | ||
+ | <visibleInRackspaceEmailCompanyDirectory>false</visibleInRackspaceEmailCompanyDirectory> | ||
+ | <visibleInExchangeGAL>false</visibleInExchangeGAL> | ||
<contactInfo> | <contactInfo> | ||
<lastName>Testlast</lastName> | <lastName>Testlast</lastName> | ||
Line 114: | Line 125: | ||
<employeeType>Full-Time</employeeType> | <employeeType>Full-Time</employeeType> | ||
</contactInfo> | </contactInfo> | ||
+ | <enabled>true</enabled> | ||
</rsMailbox> | </rsMailbox> | ||
</pre> | </pre> | ||
Line 120: | Line 132: | ||
''Json Result Example'': | ''Json Result Example'': | ||
− | ''{"emailForwardingAddressList":["test@resellerallservices.net"],"enableVacationMessage":true,"contactInfo":{"businessNumber":"555.123.0001" ,"faxNumber":"555.123.0005" ,"firstName":"Jimmy" ,"homeNumber":"555.123.0003" ,"lastName":"TestLaste" ,"mobileNumber":"555.123.0004" ,"notes":"This is my note about my mailbox." ,"pagerNumber":"555.123.0002" ,"businessCity":"" ,"businessCountry":"" ,"businessPostalCode":"" ,"businessState":"" ,"businessStreet":"" ,"employeeType":"DoesNotExist" ,"generationQualifier":"Jr" ,"homeCity":"" ,"homeCountry":"" ,"homeFaxNumber":"555.123.0006" ,"homePostalCode":"" ,"homeState":"" ,"homeStreet":"" ,"initials":"A" ,"organizationUnit":"IT" ,"organizationalStatus":"gainfully employed" ,"title":"My Title" ,"userID":"J.Test"},"name":"unittestexist" ,"saveForwardedEmail":false,"size":10240,"vacationMessage":"Test Vacation Message"}'' | + | ''{"emailForwardingAddressList":["test@resellerallservices.net"],"enableVacationMessage":true,"enabled":true,"contactInfo":{"businessNumber":"555.123.0001" ,"faxNumber":"555.123.0005" ,"firstName":"Jimmy" ,"homeNumber":"555.123.0003" ,"lastName":"TestLaste" ,"mobileNumber":"555.123.0004" ,"notes":"This is my note about my mailbox." ,"pagerNumber":"555.123.0002" ,"businessCity":"" ,"businessCountry":"" ,"businessPostalCode":"" ,"businessState":"" ,"businessStreet":"" ,"employeeType":"DoesNotExist" ,"generationQualifier":"Jr" ,"homeCity":"" ,"homeCountry":"" ,"homeFaxNumber":"555.123.0006" ,"homePostalCode":"" ,"homeState":"" ,"homeStreet":"" ,"initials":"A" ,"organizationUnit":"IT" ,"organizationalStatus":"gainfully employed" ,"title":"My Title" ,"userID":"J.Test"},"name":"unittestexist" ,"saveForwardedEmail":false,"size":10240,"vacationMessage":"Test Vacation Message", "createdDate":"4\/10\/2006 7:47:34 PM", "currentUsage":1024, "visibleInExchangeGAL":false, "visibleInRackspaceEmailCompanyDirectory":false}'' |
== Add/Edit == | == Add/Edit == | ||
Line 266: | Line 278: | ||
| string | | string | ||
| A contact's employee type | | A contact's employee type | ||
+ | |- | ||
+ | | enabled | ||
+ | | boolean | ||
+ | | Status of the mailbox: true = enabled, false = disabled. | ||
+ | |- | ||
+ | | visibleInRackspaceEmailCompanyDirectory | ||
+ | | boolean | ||
+ | | Flag indicating whether the mailbox is visible in the company directory | ||
+ | |- | ||
+ | | visibleInExchangeGAL | ||
+ | | boolean | ||
+ | | Flag indicating whether the mailbox is visible in the Exchange Global Address List | ||
+ | |- | ||
+ | | currentUsage '''''(read only)''''' | ||
+ | | positive integer | ||
+ | | Current space used in mailbox (in MB) | ||
+ | |- | ||
+ | | createdDate '''''(read only)''''' | ||
+ | | string | ||
+ | | Date of mailbox creation, EST Time (in string format) | ||
+ | |- | ||
+ | | lastLogin '''''(read only)''''' | ||
+ | | string | ||
+ | | Date of last login, EST Time (in string format) | ||
|} | |} | ||
Line 298: | Line 334: | ||
'organizationalStatus' => 'OrgStatus', | 'organizationalStatus' => 'OrgStatus', | ||
'employeeType' => 'Full-Time' | 'employeeType' => 'Full-Time' | ||
+ | 'visibleInExchangeGAL'=>'true', | ||
+ | 'visibleInRackspaceEmailCompanyDirectory' => 'false' | ||
} | } |
Revision as of 16:12, 1 September 2010
Contents
Index
URL:
[GET] http://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/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. For .xml format refer to the following schema document: RSMailboxList.xsd
Example:
get '/customers/12345678/domains/example.com/rs/mailboxes', 'text/xml'
XML Result Example:
<?xml version="1.0" encoding="utf-8"?> <rsMailboxList xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:rsMailboxList"> <offset>0</offset> <size>50</size> <total>2</total> <rsMailboxes> <rsMailbox> <name>apirsmailbox37</name> </rsMailbox> <rsMailbox> <name>apirsmailbox91</name> </rsMailbox> </rsMailboxes> </rsMailboxList>
Json Result Example:
{"offset":0,"size":50,"total":2,"rsMailboxes":[{"name":"apirsmailbox37"},{"name":"apirsmailbox91"}]}
Show
URL:
[GET] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/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. For .xml format refer to the following schema document: RSMailbox.xsd
Example:
get '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith', 'text/xml'
XML Result Example:
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?> <rsMailbox xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="urn:xml:rsMailbox"> <name>apirsmailbox37</name> <size>10240</size> <currentUsage>1024</currentUsage> <vacationMessage>My Test Vacation Message</vacationMessage> <enableVacationMessage>true</enableVacationMessage> <emailForwardingAddressList> <emailAddress>notreal0@apidomain.net</emailAddress> <emailAddress>notreal1@apidomain.net</emailAddress> </emailForwardingAddressList> <saveForwardedEmail>false</saveForwardedEmail> <lastLogin>2/12/2009 1:00:00 AM</lastLogin> <createdDate>4/10/2006 7:47:34 PM</createdDate> <visibleInRackspaceEmailCompanyDirectory>false</visibleInRackspaceEmailCompanyDirectory> <visibleInExchangeGAL>false</visibleInExchangeGAL> <contactInfo> <lastName>Testlast</lastName> <firstName>Jayfirst</firstName> <generationQualifier>Jr</generationQualifier> <initials>A</initials> <organizationUnit>IT</organizationUnit> <businessStreet>123 Biz St</businessStreet> <businessCity>Blacksburg</businessCity> <businessState>VA</businessState> <businessPostalCode>24060</businessPostalCode> <businessCountry>USA</businessCountry> <homeStreet>456 Home St</homeStreet> <homeCity>Charlotte</homeCity> <homeState>NC</homeState> <homePostalCode>28210</homePostalCode> <homeCountry>USA</homeCountry> <businessNumber>555.123.0001</businessNumber> <homeNumber>555.123.0003</homeNumber> <mobileNumber>555.123.0004</mobileNumber> <faxNumber>555.123.0005</faxNumber> <homeFaxNumber>555.123.0006</homeFaxNumber> <pagerNumber>555.123.0002</pagerNumber> <notes>This is my note about my mailbox.</notes> <title>My Title</title> <userID>J.Test</userID> <organizationalStatus>OrgStatus</organizationalStatus> <employeeType>Full-Time</employeeType> </contactInfo> <enabled>true</enabled> </rsMailbox>
Json Result Example:
{"emailForwardingAddressList":["test@resellerallservices.net"],"enableVacationMessage":true,"enabled":true,"contactInfo":{"businessNumber":"555.123.0001" ,"faxNumber":"555.123.0005" ,"firstName":"Jimmy" ,"homeNumber":"555.123.0003" ,"lastName":"TestLaste" ,"mobileNumber":"555.123.0004" ,"notes":"This is my note about my mailbox." ,"pagerNumber":"555.123.0002" ,"businessCity":"" ,"businessCountry":"" ,"businessPostalCode":"" ,"businessState":"" ,"businessStreet":"" ,"employeeType":"DoesNotExist" ,"generationQualifier":"Jr" ,"homeCity":"" ,"homeCountry":"" ,"homeFaxNumber":"555.123.0006" ,"homePostalCode":"" ,"homeState":"" ,"homeStreet":"" ,"initials":"A" ,"organizationUnit":"IT" ,"organizationalStatus":"gainfully employed" ,"title":"My Title" ,"userID":"J.Test"},"name":"unittestexist" ,"saveForwardedEmail":false,"size":10240,"vacationMessage":"Test Vacation Message", "createdDate":"4\/10\/2006 7:47:34 PM", "currentUsage":1024, "visibleInExchangeGAL":false, "visibleInRackspaceEmailCompanyDirectory":false}
Add/Edit
URL:
Add: [POST] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/mailboxes/(mailbox name) Edit: [PUT] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/mailboxes/(mailbox name)
Description:
Adds/Edits a Rackspace Email mailbox using the following form fields.
Field Name | Data Type | Description |
---|---|---|
password | string | Password (Required for Add) |
size | positive integer | Mailbox size in megabytes (Required for Add) |
enableVacationMessage | boolean | indicates whether vacation message has been enabled |
vacationMessage | string | A mailbox's vacation message |
emailForwardingAddresses | string | A comma delimited list, Maximum 15 addresses, 4 of which can be outside of this domain |
saveForwardedEmail | string | Indicates whether to save a copy of any forwarded email |
lastName | string | A last name |
firstName | string | A first name |
generationQualifier | string | A person's generation (ex. Jr., Sr., III) |
initials | string | A person's middle initial |
organizationUnit | string | A person's organization unit (ex. Marketing) |
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 |
homeFaxNumber | string | Home Fax phone number |
businessStreet | string | The business street address for a contact |
businessCity | string | The business city for a contact |
businessState | string | The business state for a contact |
businessPostalCode | string | The business postal code/zip code for a contact |
businessCountry | string | The business country for a contact |
homeStreet | string | The home street address for a contact |
homeCity | string | The home city for a contact |
homeState | string | The home state for a contact |
homePostalCode | string | The home postal code/zip code for a contact |
homeCountry | string | The home country for a contact |
notes | string | Any notes for the mailbox |
title | string | A contact's title |
userID | string | A user ID for a contact |
organizationalStatus | string | A contact's organization status |
employeeType | string | A contact's employee type |
enabled | boolean | Status of the mailbox: true = enabled, false = disabled. |
visibleInRackspaceEmailCompanyDirectory | boolean | Flag indicating whether the mailbox is visible in the company directory |
visibleInExchangeGAL | boolean | Flag indicating whether the mailbox is visible in the Exchange Global Address List |
currentUsage (read only) | positive integer | Current space used in mailbox (in MB) |
createdDate (read only) | string | Date of mailbox creation, EST Time (in string format) |
lastLogin (read only) | string | Date of last login, EST Time (in string format) |
Example:
post '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith', 'text/xml', { 'password' => 'Secret13!@#', 'size' => '2048', 'enableVacationMessage' => 'true', 'vacationMessage' => 'My Vacation Message', 'emailForwardingAddresses' => 'sampletest@example.com,sampletest2@example.com', 'saveForwardedEmail' => 'false' 'lastName' => 'Testlastname', 'firstName' => 'Jay', 'generationQualifier' => 'III', 'initials' => 'A', 'organizationUnit' => 'IT', 'businessStreet' => '123 Biz St.', 'businessCity' => 'Blacksburg', 'businessState' => 'VA', 'businessPostalCode' => '24060', 'businessCountry' => 'USA', 'homeStreet' => '456 Home St.', 'homeCity' => 'Charlotte', 'homeState' => 'NC', 'homePostalCode' => '28210', 'homeCountry' => 'USA', 'notes' => 'This is my note about my mailbox.', 'title' => 'My Title', 'userID' => 'J.Test', 'organizationalStatus' => 'OrgStatus', 'employeeType' => 'Full-Time' 'visibleInExchangeGAL'=>'true', 'visibleInRackspaceEmailCompanyDirectory' => 'false' }
Delete
URL:
[DELETE] https://api.emailsrvr.com/v0/customers/(customer account number)/domains/(domain name) /rs/mailboxes/(mailbox name)
Description:
Deletes the mailbox.
Remarks:
The mailbox and mailbox contents are deleted permanently.
Example:
delete '/customers/12345678/domains/example.com/rs/mailboxes/alex.smith', 'text/xml'