Registering the unique identity of an application's users is nearly ubiquitous among all software today. A formalized method of allowing an application’s user to register their identity with an existing set of data, stored outside of your application, is known as OAuth (open standard for authorization). This method allows an application to gain access to the user’s data from a third-party server, providing the unique identification without requiring the user to step through a registration process to provide such. To algorithm of the OAuth method one must consider the three steps it requires: fetching the request, user authorization, and fetching the access .
Fetching an ...view middle of the document...
Whether the login prompt is necessary or not, the callback provided to the authorize function will be called. 
Fetching the Access token
Now that the user has authorized the request, the application may sign an HTTP GET or HTTP POST to the third-party server in order to retrieve the data the user has authorized to be shared. This could include access to items such as email addresses, phone numbers, and even electronic documents. This particular method utilizes the sendSignedRequest function which takes three arguments. The application will need to pass a URI, a callback function, and it can include a parameter object. The callback itself takes two arguments. The application will need to provide the callback with a response text string and the XMLHttpRequest object that was used to originally make the request. 
This three step algorithm appears to be as simple as can be, considering the following: the application never needs to gain any type of registration or authorization from the...