I want list name of rooms created. I got an error at FindingRooms
method, IUserRequestBuilder
does not contain a definition for FindRooms
. How to solve it?
IPublicClientApplication publicClientApplication = PublicClientApplicationBuilder
.Create("****-8d12-45ce-99dc-ee97478abc48")
.WithTenantId("****-0c15-41f2-9858-b64924a83a6c").WithRedirectUri("http://localhost")
.Build();
var password = new SecureString();
password.AppendChar('<');
password.AppendChar('T');
password.AppendChar('N');
password.AppendChar('>');
password.AppendChar('7');
UsernamePasswordProvider authProvider = new UsernamePasswordProvider(publicClientApplication, scopes);
GraphServiceClient graphClient = new GraphServiceClient(authProvider);
Microsoft.Graph.User me = graphClient.Me.Request()
.WithUsernamePassword("[email protected]", password)
.GetAsync().Result;
var findRooms = await graphClient.Me
.FindRooms("[email protected]")
.Request()
.GetAsync();
Currently, the findRooms
API is in Graph beta version. So, you need to add Microsoft.Graph.Beta
package.