Partager via


Retrieve All Email Addresses in a Microsoft Office 365 Account

 

Applies To: Windows Server 2012 Essentials

Retrieves all email addresses in a Microsoft Office 365 account.

URI Template

GET services/builtin/MailboxManagement.svc/mailbox/getEmailAddresses?username={username}

{username}
The logon name of a user.

Sample Request

GET https://www.contoso.com/services/builtin/MailboxManagement.svc/mailbox/getEmailAddresses?username=user1 HTTP/1.1  
Content-Type: application/xml  
Accept: application/xml  
Cookie: ASP.NET_SessionId=********************  
Canary: *********************  
Host: domainname  
Content-Length: 0  

Sample Response

Microsoft Office 365

HTTP/1.1 200 OK  
<ArrayOfstring  
    xmlns="https://schemas.microsoft.com/2003/10/Serialization/Arrays"  
    xmlns:i="http://www.w3.org/2001/XMLSchema-instance">  
  <string>user1@ttp1.onmicrosoft.com</string>  
</ArrayOfstring>  

Error Codes

Error Code Error Message
400 One or more parameters are not valid.
404 The path does not exist.
500 An internal server error occurred.
501 Not implemented.

See Also

Web Service Methods