Exemple #1
0
        private async void btnDoAuth_Click(object sender, EventArgs e)
        {
            var wlidtoken = await WLIDAuthentication.RequestToken(txtEmail.Text, txtPassword.Text);                   UpdateStatus("WLID OAuth Token Generated");

            txtOAuthToken.Text = wlidtoken.AccessToken;

            var spartanToken = await SpartanAuthentication.RequestToken(wlidtoken.AccessToken);                          UpdateStatus("Spartan Token Generated");

            txtSpartanToken.Text = spartanToken.SpartanToken;

            _dot = new AuntieDotManager(spartanToken.SpartanToken, spartanToken.UserInformation.Gamertag);   UpdateStatus("AuntieDot Initalized");

            await _dot.GetServicesListAsync();

            lbServices.Items.Clear();
            foreach (var service in _dot.ServicesList.ServiceList)
            {
                lbServices.Items.Add(service.Value);
            }
            UpdateStatus("Services List Recieved");

            txtHeaders.Text = string.Format("X-343-Authorization-WLID: v1={0}\r\nX-343-Authorization-Spartan: {1}",
                                            wlidtoken.AccessToken, spartanToken.SpartanToken);
            UpdateStatus("Populated Headers");
        }
Exemple #2
0
        private async void btnGetServicesList_Click(object sender, EventArgs e)
        {
            await _dot.GetServicesListAsync();

            lbServices.Items.Clear();
            foreach (var service in _dot.ServicesList.ServiceList)
            {
                lbServices.Items.Add(service.Value);
            }
            UpdateStatus("Services List Recieved");


            txtHeaders.Text = string.Format("X-343-Authorization-WLID: v1={0}\r\nX-343-Authorization-Spartan: {1}",
                                            txtOAuthToken.Text, txtSpartanToken.Text);
            UpdateStatus("Populated Headers");
        }
Exemple #3
0
        private async void btnDoAuth_Click(object sender, EventArgs e)
        {
            var wlidtoken           = await WLIDAuthentication.RequestToken(txtEmail.Text, txtPassword.Text);                   UpdateStatus("WLID OAuth Token Generated");
            txtOAuthToken.Text      = wlidtoken.AccessToken;

            var spartanToken        = await SpartanAuthentication.RequestToken(wlidtoken.AccessToken);                          UpdateStatus("Spartan Token Generated");
            txtSpartanToken.Text    = spartanToken.SpartanToken;

            _dot                    = new AuntieDotManager(spartanToken.SpartanToken, spartanToken.UserInformation.Gamertag);   UpdateStatus("AuntieDot Initalized");
            
            await _dot.GetServicesListAsync();

            lbServices.Items.Clear();
            foreach (var service in _dot.ServicesList.ServiceList)
                lbServices.Items.Add(service.Value);
            UpdateStatus("Services List Recieved");

            txtHeaders.Text = string.Format("X-343-Authorization-WLID: v1={0}\r\nX-343-Authorization-Spartan: {1}",
                                            wlidtoken.AccessToken, spartanToken.SpartanToken);
            UpdateStatus("Populated Headers");
        }