-
Notifications
You must be signed in to change notification settings - Fork 128
Description
Also, if you are a maintainer, feel free to add any clarification and instruction about this issue.
Sorry if this is already partially/completely implemented, feel free to let me know about the state of this issue in the repo.
Related to meilisearch/integration-guides#261
This issue is divided in two sections, first you need to make the implementation, second you must update the code-samples (no one likes a outdated docs, right?).
New implementation
Related to:
- issue: Delete and get documents by filter meilisearch#3477
- spec: Specify the new fetch documents route specifications#234
Gives the user the possibility to use a filter expression to retrieve documents, like in search.
Implement in the getDocuments method an internal conditional allowing the user to query the documents with the same method but using a new filter method.
When the user calls the get documents method with a filter argument, request POST /indexes/{index_uid}/documents/fetch using a JSON body containing an int offset, int limit, String[] fields and now String filter or String[] filter.
filter it should still call the previous implementation.
Code samples:
Inside of this file: .code-samples.meilisearch.yml:
-
Update
get_documents_1:
Refer to this curl example: https://github.com/meilisearch/documentation/blob/e4fdc3d485c22e31a045b8a71bacf18b6a7d50e0/.code-samples.meilisearch.yaml#L30C1-L30C16 -
Create a new entry with this key
get_documents_post_1:
Refer to this curl example: https://github.com/meilisearch/documentation/blob/e4fdc3d485c22e31a045b8a71bacf18b6a7d50e0/.code-samples.meilisearch.yaml#L1043
Todo:
- Implement the
getDocumentsnew behavior keeping the old behavior when possible. - Update the code-samples according to this issue.