Deprecate Index::add_api_key for Client::add_api_key#284
Closed
julienbourdeau wants to merge 1 commit intomasterfrom
Closed
Deprecate Index::add_api_key for Client::add_api_key#284julienbourdeau wants to merge 1 commit intomasterfrom
julienbourdeau wants to merge 1 commit intomasterfrom
Conversation
1 similar comment
|
@julienbourdeau the goal here is just to mark it as deprecated in the doc right? We could also add deprecation warnings whenever the method is called, WDYT? |
Author
|
Yes, I checked the lib and it seems like the only thing we do so far for deprecation is to write it in the comment. Also, we're reconsidering, and we'll probably depredcated all other method (like update, delete, get,...). |
raphi
approved these changes
Apr 12, 2018
|
Closed in favor of #286 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Same as algolia/algoliasearch-client-php#378
All keys should be managed using the Client class.
If you use the Index class, you'll attached the key to the index internally. They are not displayed in the dashboard and cannot be retrieve with client::list_api_keys. This is a deprecated feature, that shouldn't be used anymore.
Instead, you can create a key using client::add_api_key that will be attached to the Application internally. You can add restriction on the index to achieve the same behavior.
Other methods like get, update, delete, list are still required to access your existing keys.