8

How would i go about linking someones gamer-tag? Basically, i am wanting to make sure a user actually owns that account. MLG Game battles does the same thing, where you click a link, then you are redirected to Microsoft's Xbox Live website. Once i login, i am redirected back to MLG Game battles, and my account is then Linked. After that, i would save the gamer-tag into a Database for latter reference. How would i do this?

enter image description here

Hunter Mitchell
  • 7,063
  • 18
  • 69
  • 116
  • No @DaveChen but is there something in there that allows for this? – Hunter Mitchell Dec 06 '13 at 04:39
  • @DaveChen AWESOME! can you submit your answer with some sample code, and ill accept your answer! thanks! – Hunter Mitchell Dec 06 '13 at 04:50
  • 2
    OP, did you ever figure out how to do this? It seems that Dave Chen's links are now outdated. – Chris Fremgen Feb 05 '15 at 21:46
  • Tagging @DaveChen in case he can provide updated links or some context by which we can search for ourselves. – weberc2 Nov 23 '15 at 16:19
  • The process is called OAuth. And @DaveChen link to register an application works for me. – Martin Bean Nov 23 '15 at 17:14
  • @weberc2 The API doesn't provide anything to XBL. The only way (at the moment), is to tell the user to change their bio to include a code so that you can verify their account. I'll look more into this, see if there's a workaround but it looks like this is what the majority of websites are doing. – Dave Chen Nov 24 '15 at 18:48
  • 1
    If they havent got an API, why not use CURL? you can then scrape the page for information using DOMDocument and DOMXPath... – John Hudson Nov 24 '15 at 22:21
  • 1
    Here is Microsoft's OAuth documentation. https://msdn.microsoft.com/en-us/library/hh243647.aspx – James Jan 31 '16 at 21:32

1 Answers1

0

With Reference to James Comment:

*OAuth 2.0

Live Connect implements the OAuth 2.0 protocol to authenticate users. This topic describes both the authorization flows that Live Connect uses and the supported extension parameters. In this topic, we assume that you are familiar with OAuth 2.0 and OAuth terminology. If you're new to OAuth, we recommend that you check out the OAuth 2.0 spec first, or refer to it when you come across a term or idea that's unfamiliar to you.
Source https://msdn.microsoft.com/en-us/library/hh243647.aspx (correct as of 13th September 2016)

If you read through their documentation I'm sure you can get the finer details and work it into you project

ben jay hutton
  • 402
  • 5
  • 15