-
Notifications
You must be signed in to change notification settings - Fork 11.8k
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
API keys: Add deprecation to api keys #65948
Conversation
@@ -17,7 +17,7 @@ An API key is a randomly generated string that external systems use to interact | |||
|
|||
When you create an API key, you specify a **Role** that determines the permissions associated with the API key. Role permissions control that actions the API key can perform on Grafana resources. | |||
|
|||
> **Note:** If you use Grafana v8.5 or newer, use service accounts instead of API keys. For more information, refer to [Grafana service accounts]({{< relref "../service-accounts/" >}}). | |||
> **Note:** If you use Grafana v9.1 or newer, use service accounts instead of API keys. For more information, refer to [Grafana service accounts]({{< relref "../service-accounts/" >}}). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not part of deprecation, fix for wrong version in docs
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good 👍
pkg/api/apikey.go
Outdated
@@ -20,6 +20,11 @@ import ( | |||
// | |||
// Will return auth keys. | |||
// | |||
// Deprecated: true. | |||
// | |||
// Deprecated please use GET /api/serviceaccounts and GET /api/serviceaccounts/{id}/tokens instead |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
super nit: I'd add a punctuation mark after deprecated
. Something like Deprecated: please use...
or Deprecated. Please use...
.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i do not think it's nit. this is about clear communication on this. and should be reviewed as such
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm!
* add: deprecation to api keys write path * boolean w. meessage * add read and delete endpoints * better description of deprecation * updated with puncutations
What is this feature?
Adds deprecation notice for the create path of API keys w. a link to the new documentation outlining how to migrate your API calls to service accounts.
linking to page -https://grafana.com/docs/grafana/next/administration/api-keys/#migrate-api-keys-to-grafana-service-accounts-using-the-api
notes
Part of a bigger sunsetting of API keys - #53567