Skip to content

Instantly share code, notes, and snippets.

@rpunt
Created March 16, 2013 14:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save rpunt/5176583 to your computer and use it in GitHub Desktop.
Save rpunt/5176583 to your computer and use it in GitHub Desktop.
A SOAP message that will retrieve a list of rooms in a roomlist from Exchange 2010.
// given the e-mail address of a roomlist, this SOAP message will retrieve the member rooms.
NSString *roomlist = @"roomlist1@domain.tld" // this is the e-mail address of the room list you're querying
NSLog(@"querying roomlist %@", roomlist);
NSString *soapMessage = [NSString stringWithFormat:@""
@"<?xml version=\"1.0\" encoding=\"utf-8\"?>"
@"<soap:Envelope xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\" xmlns:t=\"http://schemas.microsoft.com/exchange/services/2006/types\" xmlns:m=\"http://schemas.microsoft.com/exchange/services/2006/messages\">"
@"<soap:Header>"
@"<t:RequestServerVersion Version =\"Exchange2010_SP2\"/>"
@"</soap:Header>"
@"<soap:Body>"
@"<m:GetRooms>"
@"<m:RoomList>"
@"<t:EmailAddress>%@</t:EmailAddress>"
@"</m:RoomList>"
@"</m:GetRooms>"
@"</soap:Body>"
@"</soap:Envelope>"
@"", roomlist];
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment