Update APITokenResource for API Tokens v2
Review Request #12474 — Created July 15, 2022 and submitted — Latest diff uploaded
This change updates the
APITokenResource
according to the newWebAPIToken
fields addded as part of our move to API Tokens v2. The API now creates tokens
in the vendor checksum format rather than the legacy SHA1 format. Users can also
invalidate tokens via the API.This change also corrects some PUT, POST and DELETE tests for for the
APITokenResource
. These tests were all callingself.api_get
instead of the
appropriate HTTP method.It also updates test utilities that are related to
WebAPITokens
.
Ran unit tests in
reviewboard/webapi/tests
.