Add SCIM token reset to admin token API

What does this MR do and why?

SCIM tokens can now be reset (replaced with a new value) using the admin token API.

🛠️ with ❤️ at Siemens

References

How to set up and validate locally

How to set up and validate locally

  1. Follow the instructions on how to test SCIM tokens.
  2. Create instance and group scim tokens as described above.
  3. Create a personal access token with admin_mode and api capabilities. Preferences > Access Tokens > Add a new token to query the token information api.
  4. Query the API:
curl -k --request POST \
--url 'https://gdk.test:3443/api/v4/admin/token' \
--header 'Authorization: Bearer <Admin Token>' \
--header 'Content-Type: application/json' \
--data '{"token": "glsoat-from-above"}'
  1. Now reset the token:
curl -k --request DELETE \
--url 'https://gdk.test:3443/api/v4/admin/token' \
--header 'Authorization: Bearer <Admin Token>' \
--header 'Content-Type: application/json' \
--data '{"token": "glsoat-from-above"}'
  1. Query it again like in step 4 with a POST - you should now get a NOT FOUND.

MR acceptance checklist

MR Checklist ( @nwittstruck)

Related to &15777

Edited by Nicholas Wittstruck

Merge request reports

Loading