Example #1
0
        private async Task InvokeAppAsync(string accessToken, string scheme)
        {
            try
            {
                using (var graph = new GraphRepository(accessToken))
                {
                    var user = await graph.GetUserAsync();

                    var targetDeviceId = await UserInfoRepository.GetTargetDeviceIdByUserIdAsync(user.Id);

                    await graph.AddLaunchAppRequestAsync(targetDeviceId, scheme);
                }
            }
            catch (Exception ex)
            {
                Trace.WriteLine(ex);
            }
        }