Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update OAuth Token operations to new APIs #2116

Merged
merged 2 commits into from
Mar 2, 2020

Commits on Mar 2, 2020

  1. Update OAuth Token operations to new APIs

    Per ['Deprecating OAuth Application API'](https://developer.github.com/changes/2020-02-14-deprecating-oauth-app-endpoint/)
    the HTTP API endpoints called by CheckApplicationAuthentication,
    ResetApplicationAuthentication and RevokeApplicationAuthentication are
    being deprecated.
    
    This PR updates those APIs to call the new HTTP API endpoints as
    documented at the above link.
    
    * Details
    
    Amend CheckApplicationAuthentication, ResetApplicationAuthentication and
    RevokeApplicationAuthentication to create an object containing the OAuth
    access token and to call the single arg version of
    ApiUrls.ApplicationAuthorization. The object is used as the request
    body.
    
    Amend CheckApplicationAuthentication to use POST.
    
    Amend ResetApplicationAuthentication to use PATCH.
    
    Remove the two arg version of ApiUrls.ApplicationAuthorization as it is
    no longer called. Amend the single arg version to use the new API path.
    
    Amend unit tests to account for the above changes.
    MGudgin committed Mar 2, 2020
    Configuration menu
    Copy the full SHA
    9d1fd13 View commit details
    Browse the repository at this point in the history
  2. Update unit tests to check request payload

    Add a check to the unit tests to verify that the request payload
    contains an access_token field with the expected value.
    MGudgin committed Mar 2, 2020
    Configuration menu
    Copy the full SHA
    6c039cd View commit details
    Browse the repository at this point in the history