forked from microsoftgraph/microsoft-graph-comms-samples
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Sync with latest SDKs, and refresh of documentation. (microsoftgraph#118
- Loading branch information
Showing
36 changed files
with
2,410 additions
and
2,157 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
82 changes: 82 additions & 0 deletions
82
Samples/BetaSamples/StatelessSamples/OnlineMeetingSamples/OnlineMeetingMeRequest.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,82 @@ | ||
// <copyright file="OnlineMeetingMeRequest.cs" company="Microsoft Corporation"> | ||
// Copyright (c) Microsoft Corporation. All rights reserved. | ||
// Licensed under the MIT license. | ||
// </copyright> | ||
|
||
// THIS CODE HAS NOT BEEN TESTED RIGOROUSLY.USING THIS CODE IN PRODUCTION ENVIRONMENT IS STRICTLY NOT RECOMMENDED. | ||
// THIS SAMPLE IS PURELY FOR DEMONSTRATION PURPOSES ONLY. | ||
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY KIND. | ||
// | ||
#pragma warning disable SA1100 // Do not prefix calls with base | ||
#pragma warning disable SA1402 // File may contain only single type. | ||
#pragma warning disable SA1121 // Use built-int type alias. | ||
#pragma warning disable SA1649 // Filename should match first type. | ||
|
||
namespace Microsoft.Graph | ||
{ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.Threading.Tasks; | ||
|
||
/// <summary> | ||
/// IUserRequestBuilder with OnlineMeetings request collection property. | ||
/// </summary> | ||
public interface IUserRequestBuilderEx : IUserRequestBuilder | ||
{ | ||
/// <summary> | ||
/// Gets. | ||
/// </summary> | ||
IUserOnlineMeetingsCollectionRequestBuilder OnlineMeetings | ||
{ | ||
get; | ||
} | ||
} | ||
|
||
/// <summary> | ||
/// UserRequestBuilderEx with support for creating onlinemeetings request collection. | ||
/// </summary> | ||
public class UserRequestBuilderEx : UserRequestBuilder, IUserRequestBuilderEx | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="UserRequestBuilderEx"/> class. | ||
/// </summary> | ||
/// <param name="requestUrl">The URL for the built request.</param> | ||
/// <param name="client">The Microsoft.Graph.IBaseClient for handling requests.</param> | ||
public UserRequestBuilderEx(String requestUrl, IBaseClient client) | ||
: base(requestUrl, client) | ||
{ | ||
} | ||
|
||
/// <summary> | ||
/// Gets. | ||
/// </summary> | ||
public IUserOnlineMeetingsCollectionRequestBuilder OnlineMeetings => new UserOnlineMeetingsCollectionRequestBuilder(this.AppendSegmentToRequestUrl("onlinemeetings"), base.Client); | ||
} | ||
|
||
/// <summary> | ||
/// CallsGraphServiceClientEx adding suport for me with onlinemeetings request collection. | ||
/// </summary> | ||
public class CallsGraphServiceClientEx : CallsGraphServiceClient | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the <see cref="CallsGraphServiceClientEx"/> class. | ||
/// </summary> | ||
/// <param name="baseUrl">a.</param> | ||
/// <param name="authenticationProvider">b.</param> | ||
/// <param name="httpProvider">c.</param> | ||
public CallsGraphServiceClientEx(string baseUrl, IAuthenticationProvider authenticationProvider, IHttpProvider httpProvider = null) | ||
: base(baseUrl, authenticationProvider, httpProvider) | ||
{ | ||
} | ||
|
||
/// <summary> | ||
/// Gets. | ||
/// </summary> | ||
public new IUserRequestBuilderEx Me => new UserRequestBuilderEx(base.BaseUrl + "/me", this); | ||
} | ||
} | ||
|
||
#pragma warning restore SA1100 // Do not prefix calls with base | ||
#pragma warning restore SA1402 // File may contain only single type. | ||
#pragma warning restore SA1121 // Use built-int type alias. | ||
#pragma warning restore SA1649 // Filename should match first type. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 19 additions & 11 deletions
30
Samples/BetaSamples/StatelessSamples/OnlineMeetingSamples/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,28 +1,36 @@ | ||
# Introduction | ||
# THE SAMPLE PROVIDED IS PURELY FOR DEMONSTRATION PURPOSES ONLY.THIS CODE AND INFORMATION IS PROVIDED "AS IS" | ||
# WITHOUT WARRANTY OF ANY KIND. | ||
|
||
# Introduction | ||
|
||
## About | ||
The online meeting stateless sample demonstrates how one can consume Microsoft.Skype.Graph.CoreSDK in thier bot application to | ||
1. Get an online meeting based on meetingid (current support is only for [vtcid](https://docs.microsoft.com/en-us/microsoftteams/cloud-video-interop)). | ||
1. Create a adhoc online meeting on behalf of an organizer in your tenant. | ||
The online meeting stateless sample demonstrates how one can consume Microsoft.Graph.Communications.Client in bot application to | ||
1. Get an online meeting based on on [vtcid](https://docs.microsoft.com/en-us/microsoftteams/cloud-video-interop)). | ||
2. Create a online meeting on behalf a user (delegated auth) in your tenant. | ||
|
||
## Getting Started | ||
### Prerequisites | ||
1. [Permissions](https://developer.microsoft.com/en-us/graph/docs/concepts/permissions_reference#online-meetings-permissions) - The following persmissions are needed by the bot application to successfully authenticate against the online meeting service. | ||
* OnlineMeetings.Read.All OR OnlineMeetings.ReadWrite.All for getting meeting details | ||
* OnlineMeetings.ReadWrite.All for creating a meeting. | ||
* OnlineMeetings.ReadWrite for creating a meeting. | ||
|
||
1. Tools. | ||
* [Visual Studio 2017](https://visualstudio.microsoft.com/downloads/) | ||
* [Visual Studio 2017 or above](https://visualstudio.microsoft.com/downloads/) | ||
|
||
|
||
## Build and Test | ||
|
||
1. Open OnlineMeetingsSample.sln in Visual Studio 2017 and update the values of the following in `program.cs` | ||
1. Open OnlineMeetingsSample.sln in Visual Studio and update the values of the following in `program.cs` | ||
* `appId, appSecret` : AppId, Appsecret of your bot application | ||
* `tenantId` : Tenant against which to fetch/create the online meeting. | ||
* `meetingId (Only needed for GET)` : The VTC conference id. | ||
* `organizerId (Only needed for Create)` : oid of the user on behalf of whom the adhoc meeting is to be created. | ||
* Note - The organizerId should belong to the same tenant as specified by teanantid | ||
* `vtcid (Only needed for GET)` : The VTC conference id. | ||
* `userName, password (Only needed for Create)` : Username, Password of the user. | ||
* Note - The user should belong to the same tenant as specified by teanantId | ||
|
||
2. Build, Run the application. | ||
|
||
|
||
|
||
# References | ||
Please refer following links on various ways to get access tokens. Please use the appropriate mechanism which meets with the requirements of your organization. | ||
* https://docs.microsoft.com/en-us/graph/auth-v2-user | ||
* https://github.com/microsoftgraph/msgraph-sdk-dotnet-auth |
Oops, something went wrong.