

def authorize_request_token(request_token, url):
    "Adds information to request token to allow it to become an access token.\n\n  Modifies the request_token object passed in by setting and unsetting the\n  necessary fields to allow this token to form a valid upgrade request.\n\n  Args:\n    request_token: The OAuth request token which has been authorized by the\n        user. In order for this token to be upgraded to an access token,\n        certain fields must be extracted from the URL and added to the token\n        so that they can be passed in an upgrade-token request.\n    url: The URL of the current page which the user's browser was redirected\n        to after they authorized access for the app. This function extracts\n        information from the URL which is needed to upgraded the token from\n        a request token to an access token.\n\n  Returns:\n    The same token object which was passed in.\n  "
    (token, verifier) = oauth_token_info_from_url(url)
    request_token.token = token
    request_token.verifier = verifier
    request_token.auth_state = AUTHORIZED_REQUEST_TOKEN
    return request_token

dataset/ETHPy150Open acil-bwh/SlicerCIP/Scripted/attic/PicasaSnap/gdata/gauth.py authorize_request_token/original