@@ -11,72 +11,143 @@ delete_an_index_1: |-
1111get_one_document_1 : |-
1212 client.getDocument(1)
1313get_documents_1 : |-
14- index. getDocuments(params: getDocumentsParams )
14+ client.getindex('movie'). getDocuments({ limit: 2 } )
1515add_or_replace_documents_1 : |-
16- index.addDocuments(documents: object[])
16+ client.getindex('movie').addDocuments([{
17+ id: 287947,
18+ title: 'Shazam',
19+ poster: 'https://image.tmdb.org/t/p/w1280/xnopI5Xtky18MPhK40cZAGAOVeV.jpg',
20+ overview: 'A boy is given the ability to become an adult superhero in times of need with a single magic word.',
21+ release_date: '2019-03-23'
22+ }])
1723add_or_update_documents_1 : |-
18- index.updateDocuments(documents: object[]
24+ client.getindex('movie').updateDocuments([{
25+ movieskud: 287947,
26+ title: 'Shazam ⚡️'
27+ }])
1928delete_all_documents_1 : |-
29+ client.getindex('movie').deleteAllDocuments()
2030delete_one_document_1 : |-
21- index. deleteDocument(documentId: string )
31+ client.getindex('movie'). deleteDocument(25684 )
2232delete_documents_1 : |-
23- index. deleteDocuments(documentsIds: string[ ])
33+ client.getindex('movie'). deleteDocuments([23488, 153738, 437035, 363869 ])
2434search_1 : |-
25- client.getIndex('xxx ').search(query: string, options?: SearchParams )
35+ client.getIndex('movie ').search('American ninja' )
2636get_update_1 : |-
27- index. getUpdateStatus(updateId: number )
37+ client.getindex('movie'). getUpdateStatus(1 )
2838get_all_updates_1 : |-
29- index .getAllUpdateStatus()
39+ client.getindex('movie') .getAllUpdateStatus()
3040get_keys : |-
3141 client.getKeys()
3242get_settings_1 : |-
33- index .getSettings()
43+ client.getindex('movie') .getSettings()
3444update_settings_1 : |-
35- index.updateSettings(settings: Settings)
45+ client.getindex('movie').updateSettings({
46+ rankingRules: [
47+ 'typo',
48+ 'words',
49+ 'proximity',
50+ 'attribute',
51+ 'wordsPosition',
52+ 'exactness',
53+ 'desc(release_date)',
54+ 'desc(rank)'
55+ ],
56+ distinctAttribute: 'movie_id',
57+ searchableAttributes: [
58+ 'uid',
59+ 'movie_id',
60+ 'title',
61+ 'description',
62+ 'poster',
63+ 'release_date',
64+ 'rank'
65+ ],
66+ displayedAttributes: [
67+ 'title',
68+ 'description',
69+ 'poster',
70+ 'release_date',
71+ 'rank'
72+ ],
73+ stopWords: [
74+ 'the',
75+ 'a',
76+ 'an'
77+ ],
78+ synonyms: {
79+ 'wolverine': ['xmen', 'logan'],
80+ 'logan': ['wolverine']
81+ },
82+ acceptNewFields: false
83+ })
3684reset_settings_1 : |-
37- index .resetSettings()
85+ client.getindex('movie') .resetSettings()
3886get_synonyms_1 : |-
39- index .getSynonyms()
87+ client.getindex('movie') .getSynonyms()
4088update_synonyms_1 : |-
41- index.updateSynonym(synonyms: object)
89+ client.getindex('movie').updateSynonym({
90+ wolverine: ['xmen', 'logan'],
91+ logan: ['wolverine', 'xmen'],
92+ wow: ['world of warcraft']
93+ })
4294reset_synonyms_1 : |-
43- index .resetSynonym()
95+ client.getindex('movie') .resetSynonym()
4496get_stop_words_1 : |-
45- index .getStopWords()
97+ client.getindex('movie') .getStopWords()
4698update_stop_words_1 : |-
47- index. updateStopWords(string[ ])
99+ client.getindex('movie'). updateStopWords(['of', 'the', 'to' ])
48100reset_stop_words_1 : |-
49- index .resetStopWords()
101+ client.getindex('movie') .resetStopWords()
50102get_ranking_rules_1 : |-
51- index .getRankingRules()
103+ client.getindex('movie') .getRankingRules()
52104update_ranking_rules_1 : |-
53- index.updateRankingRules(rankingRules: string[])
105+ client.getindex('movie').updateRankingRules([
106+ 'typo',
107+ 'words',
108+ 'proximity',
109+ 'attribute',
110+ 'wordsPosition',
111+ 'exactness',
112+ 'asc(release_date)',
113+ 'desc(rank)'
114+ ])
54115reset_ranking_rules_1 : |-
55- index .resetRankingRules()
116+ client.getindex('movie') .resetRankingRules()
56117get_distinct_attribute_1 : |-
57- index .getDistinctAttribute()
118+ client.getindex('movie') .getDistinctAttribute()
58119update_distinct_attribute_1 : |-
59- index. updateDistinctAttribute(distinctAttribute: string )
120+ client.getindex('movie'). updateDistinctAttribute('movie_id' )
60121reset_distinct_attribute_1 : |-
61- index .resetDistinctAttribute()
122+ client.getindex('movie') .resetDistinctAttribute()
62123get_searchable_attributes_1 : |-
63- index .getSearchableAttributes()
124+ client.getindex('movie') .getSearchableAttributes()
64125update_searchable_attributes_1 : |-
65- index.updateSearchableAttributes(searchableAttributes: string[])
126+ client.getindex('movie').updateSearchableAttributes([
127+ 'title',
128+ 'description',
129+ 'uid'
130+ ])
66131reset_searchable_attributes_1 : |-
67- index .resetSearchableAttributes()
132+ client.getindex('movie') .resetSearchableAttributes()
68133get_displayed_attributes_1 : |-
69- index .getDisplayedAttributes()
134+ client.getindex('movie') .getDisplayedAttributes()
70135update_displayed_attributes_1 : |-
71- index.updateDisplayedAttributes(displayedAttributes: string[])
136+ client.getindex('movie').updateDisplayedAttributes([
137+ 'title',
138+ 'description',
139+ 'release_date',
140+ 'rank',
141+ 'poster'
142+ ])
72143reset_displayed_attributes_1 : |-
73- index .resetDisplayedAttributes()
144+ client.getindex('movie') .resetDisplayedAttributes()
74145get_accept_new_fields_1 : |-
75- index .getAcceptNewFields()
146+ client.getindex('movie') .getAcceptNewFields()
76147update_accept_new_fields_1 : |-
77- index. updateAcceptNewFields(acceptNewFields: boolean )
148+ client.getindex('movie'). updateAcceptNewFields(false )
78149get_index_stats_1 : |-
79- index .getStats()
150+ client.getindex('movie') .getStats()
80151get_indexes_stats_1 : |-
81152 client.stats()
82153get_health_1 : |-
0 commit comments