Product SiteDocumentation Site

2.17. User API key renewal

Users can request to recreate it's authentication token by issuing a GET request to the following URI:
https://hostname/api/v1/users/:user_id/recreate_api_key
Where :user_id should be replaced by the ID of the desired user.
If the request is successful a JSON containing the newly created authentication token will be returned alongside HTTP 200 OK status code. In the following lines you may find an example response to a successful request:
      Request:
        HTTP Verb: PATCH
        URI: https://hostname/api/v1/users/1/recreate_api_key?auth_token=xxxxxx

      Response:
      { query: true,
              auth_token: "abcdabcdabcd" }
If the requested user does not exist HTTP 404 Not Found status code will be returned. If the requesting users does not have privileges over the requested user HTTP 401 The server also might return HTTP 500 Internal Server Error in case of uncaught exceptions.