algolia 3.1.0 → 3.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/issue.yml +55 -0
  3. data/CHANGELOG.md +14 -0
  4. data/Gemfile.lock +1 -1
  5. data/README.md +2 -2
  6. data/lib/algolia/api/ingestion_client.rb +6 -0
  7. data/lib/algolia/api/search_client.rb +4 -4
  8. data/lib/algolia/models/abtesting/ab_test.rb +0 -10
  9. data/lib/algolia/models/abtesting/variant.rb +0 -10
  10. data/lib/algolia/models/analytics/{currencies_value.rb → currency_code.rb} +3 -3
  11. data/lib/algolia/models/analytics/daily_revenue.rb +1 -1
  12. data/lib/algolia/models/analytics/get_revenue.rb +1 -1
  13. data/lib/algolia/models/analytics/top_hit_with_revenue_analytics.rb +1 -1
  14. data/lib/algolia/models/analytics/top_search_with_revenue_analytics.rb +1 -1
  15. data/lib/algolia/models/ingestion/run_type.rb +3 -1
  16. data/lib/algolia/models/ingestion/source.rb +0 -2
  17. data/lib/algolia/models/ingestion/source_create.rb +0 -2
  18. data/lib/algolia/models/ingestion/source_type.rb +13 -1
  19. data/lib/algolia/models/recommend/{facets_stats.rb → facet_stats.rb} +3 -3
  20. data/lib/algolia/models/recommend/fallback_params.rb +2 -2
  21. data/lib/algolia/models/recommend/recommendations_results.rb +1 -1
  22. data/lib/algolia/models/recommend/search_params.rb +2 -2
  23. data/lib/algolia/models/recommend/search_params_object.rb +2 -2
  24. data/lib/algolia/models/search/browse_params_object.rb +2 -2
  25. data/lib/algolia/models/search/browse_response.rb +1 -1
  26. data/lib/algolia/models/search/consequence_params.rb +2 -2
  27. data/lib/algolia/models/search/{facets_stats.rb → facet_stats.rb} +3 -3
  28. data/lib/algolia/models/search/search_for_facets.rb +2 -2
  29. data/lib/algolia/models/search/search_for_hits.rb +2 -2
  30. data/lib/algolia/models/search/search_params_object.rb +2 -2
  31. data/lib/algolia/models/search/search_response.rb +1 -1
  32. data/lib/algolia/version.rb +1 -1
  33. metadata +6 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 4341176aaa1fb5ede3413b4844215ba53d4e51e75f03d1988563d661d8ed4815
4
- data.tar.gz: f9c1da9c1e6d2cf40cf576d6ceea212f947a73c7e8e3868c47436eb205b977bc
3
+ metadata.gz: 6c1fcfd0f638527d0a72d2a0c2f22bdb84be0550b3078f18d798c869306b0eab
4
+ data.tar.gz: e884227706bf4aaeb9bea4d5e89082c7703a0b338652f253d1899e4bf5e9f81c
5
5
  SHA512:
6
- metadata.gz: 8317dae670e222ca42819edab6a46275b8c0b249729a938679fdebcd52211f7e8b43d22b6ddbe6e994a43ec0eabc885b537452c123fc25722e16bfd17c4d9d20
7
- data.tar.gz: b8437399665e10107249c38e6fd0131aaffd0319a4d15d9fe093a1ebd76c9383fb328a656a58d04254427bd91d6cabb95e16a2dd322f83f9104918d470d60956
6
+ metadata.gz: 74a3b488c0216925855926fb2e013e7ba7bb82255748f5d596c6b2baf53475cecb9421165ab1825ac8fda55c06a8f223e7a9c8b754fd58f661a5be5c0164bac6
7
+ data.tar.gz: 43f32884d0fef05486fdfb9173ec94e57acd1da2564db04d529e0b836948a84978551a1e88ffc1a5a116051049011ca3e745312643be26bf2d2f7f28ad1e3fa5
@@ -0,0 +1,55 @@
1
+ name: 'Issue sync with Jira'
2
+ on:
3
+ issues:
4
+ types: [opened]
5
+
6
+ permissions:
7
+ issues: write
8
+ contents: read
9
+
10
+ jobs:
11
+ sync:
12
+ runs-on: ubuntu-latest
13
+ steps:
14
+ - name: Create ticket
15
+ uses: actions/github-script@v7
16
+ with:
17
+ script: |
18
+ const action = context.payload.action;
19
+ if (action !== 'opened') {
20
+ return;
21
+ }
22
+ const title = context.payload.issue.title;
23
+ const body = context.payload.issue.body;
24
+
25
+ const res = await fetch('https://algolia.atlassian.net/rest/api/2/issue', {
26
+ method: 'POST',
27
+ headers: {
28
+ 'Accept': 'application/json',
29
+ 'Content-Type': 'application/json',
30
+ 'Authorization': `Basic ${{ secrets.JIRA_TOKEN }}`
31
+ },
32
+ body: JSON.stringify({
33
+ fields: {
34
+ description: `Issue created by ${context.actor} at [${context.payload.issue.html_url}](${context.payload.issue.html_url}) \n\n${body}`,
35
+ issuetype: {
36
+ id: '10001'
37
+ },
38
+ parent: {
39
+ key: 'DI-2737'
40
+ },
41
+ project: {
42
+ id: '10118'
43
+ },
44
+ summary: `[GH-ISSUE] ${title}`
45
+ },
46
+ update: {}
47
+ })
48
+ });
49
+
50
+ if (!res.ok) {
51
+ throw new Error(`Failed to create ticket: ${res.statusText} (${res.status}) - ${await res.text()}`);
52
+ }
53
+
54
+ const data = await res.json();
55
+ console.log(`Created ticket: ${data.key}`);
data/CHANGELOG.md CHANGED
@@ -1,3 +1,17 @@
1
+ ## [3.2.0](https://github.com/algolia/algoliasearch-client-ruby/compare/3.1.1...3.2.0)
2
+
3
+ - [23a799f0e](https://github.com/algolia/api-clients-automation/commit/23a799f0e) feat(specs): push source type ([#3600](https://github.com/algolia/api-clients-automation/pull/3600)) by [@shortcuts](https://github.com/shortcuts/)
4
+ - [536fdef01](https://github.com/algolia/api-clients-automation/commit/536fdef01) fix(specs): filter run list by type ([#3577](https://github.com/algolia/api-clients-automation/pull/3577)) by [@millotp](https://github.com/millotp/)
5
+ - [9b6dc0b70](https://github.com/algolia/api-clients-automation/commit/9b6dc0b70) docs(specs): update api's length minimum value ([#3574](https://github.com/algolia/api-clients-automation/pull/3574)) by [@Jerska](https://github.com/Jerska/)
6
+
7
+ ## [3.1.1](https://github.com/algolia/algoliasearch-client-ruby/compare/3.1.0...3.1.1)
8
+
9
+ - [4cbbce55c](https://github.com/algolia/api-clients-automation/commit/4cbbce55c) fix(clients): highlight and snippet results e2e ([#3567](https://github.com/algolia/api-clients-automation/pull/3567)) by [@shortcuts](https://github.com/shortcuts/)
10
+ - [7c7de04ab](https://github.com/algolia/api-clients-automation/commit/7c7de04ab) fix(specs): another wrong link ([#3570](https://github.com/algolia/api-clients-automation/pull/3570)) by [@kai687](https://github.com/kai687/)
11
+ - [f38a9ef12](https://github.com/algolia/api-clients-automation/commit/f38a9ef12) chore(specs): breaking change method names mapping table ([#3568](https://github.com/algolia/api-clients-automation/pull/3568)) by [@shortcuts](https://github.com/shortcuts/)
12
+ - [9dedfc90f](https://github.com/algolia/api-clients-automation/commit/9dedfc90f) fix(clients): mention `main` branch instead of `master` ([#3566](https://github.com/algolia/api-clients-automation/pull/3566)) by [@shortcuts](https://github.com/shortcuts/)
13
+ - [0e5ffb1e8](https://github.com/algolia/api-clients-automation/commit/0e5ffb1e8) fix(specs): broken link ([#3559](https://github.com/algolia/api-clients-automation/pull/3559)) by [@kai687](https://github.com/kai687/)
14
+
1
15
  ## [3.1.0](https://github.com/algolia/algoliasearch-client-ruby/compare/3.0.2...3.1.0)
2
16
 
3
17
  - [d53060d96](https://github.com/algolia/api-clients-automation/commit/d53060d96) feat(specs): add /schedule endpoint ([#3350](https://github.com/algolia/api-clients-automation/pull/3350)) by [@febeck](https://github.com/febeck/)
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- algolia (3.1.0)
4
+ algolia (3.2.0)
5
5
  base64 (>= 0.2.0, < 1)
6
6
  faraday (>= 1.0.1, < 3.0)
7
7
  faraday-net_http_persistent (>= 0.15, < 3)
data/README.md CHANGED
@@ -13,7 +13,7 @@
13
13
  </p>
14
14
 
15
15
  <p align="center">
16
- <a href="https://www.algolia.com/doc/api-client/getting-started/install/ruby/" target="_blank">Documentation</a> •
16
+ <a href="https://www.algolia.com/doc/libraries/ruby/" target="_blank">Documentation</a> •
17
17
  <a href="https://github.com/algolia/algoliasearch-rails" target="_blank">Rails</a> •
18
18
  <a href="https://discourse.algolia.com" target="_blank">Community Forum</a> •
19
19
  <a href="http://stackoverflow.com/questions/tagged/algolia" target="_blank">Stack Overflow</a> •
@@ -47,7 +47,7 @@ Finally, you may begin searching a object using the `search` method:
47
47
  objects = client.search_single_index('your_index_name', 'Foo')
48
48
  ```
49
49
 
50
- For full documentation, visit the **[Algolia Ruby API Client](https://www.algolia.com/doc/api-client/getting-started/install/ruby/)**.
50
+ For full documentation, visit the **[Algolia Ruby API Client](https://www.algolia.com/doc/libraries/ruby/)**.
51
51
 
52
52
  ## ❓ Troubleshooting
53
53
 
@@ -1753,6 +1753,7 @@ module Algolia
1753
1753
  # @param items_per_page [Integer] Number of items per page. (default to 10)
1754
1754
  # @param page [Integer] Page number of the paginated API response.
1755
1755
  # @param status [Array<RunStatus>] Run status for filtering the list of task runs.
1756
+ # @param type [Array<RunType>] Run type for filtering the list of task runs.
1756
1757
  # @param task_id [String] Task ID for filtering the list of task runs.
1757
1758
  # @param sort [RunSortKeys] Property by which to sort the list of task runs. (default to 'createdAt')
1758
1759
  # @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
@@ -1764,6 +1765,7 @@ module Algolia
1764
1765
  items_per_page = nil,
1765
1766
  page = nil,
1766
1767
  status = nil,
1768
+ type = nil,
1767
1769
  task_id = nil,
1768
1770
  sort = nil,
1769
1771
  order = nil,
@@ -1797,6 +1799,7 @@ module Algolia
1797
1799
  query_params[:itemsPerPage] = items_per_page unless items_per_page.nil?
1798
1800
  query_params[:page] = page unless page.nil?
1799
1801
  query_params[:status] = @api_client.build_collection_param(status, :multi) unless status.nil?
1802
+ query_params[:type] = @api_client.build_collection_param(type, :multi) unless type.nil?
1800
1803
  query_params[:taskID] = task_id unless task_id.nil?
1801
1804
  query_params[:sort] = sort unless sort.nil?
1802
1805
  query_params[:order] = order unless order.nil?
@@ -1828,6 +1831,7 @@ module Algolia
1828
1831
  # @param items_per_page [Integer] Number of items per page. (default to 10)
1829
1832
  # @param page [Integer] Page number of the paginated API response.
1830
1833
  # @param status [Array<RunStatus>] Run status for filtering the list of task runs.
1834
+ # @param type [Array<RunType>] Run type for filtering the list of task runs.
1831
1835
  # @param task_id [String] Task ID for filtering the list of task runs.
1832
1836
  # @param sort [RunSortKeys] Property by which to sort the list of task runs. (default to 'createdAt')
1833
1837
  # @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
@@ -1839,6 +1843,7 @@ module Algolia
1839
1843
  items_per_page = nil,
1840
1844
  page = nil,
1841
1845
  status = nil,
1846
+ type = nil,
1842
1847
  task_id = nil,
1843
1848
  sort = nil,
1844
1849
  order = nil,
@@ -1850,6 +1855,7 @@ module Algolia
1850
1855
  items_per_page,
1851
1856
  page,
1852
1857
  status,
1858
+ type,
1853
1859
  task_id,
1854
1860
  sort,
1855
1861
  order,
@@ -818,7 +818,7 @@ module Algolia
818
818
  @api_client.deserialize(response.body, request_options[:debug_return_type] || "Search::DeleteApiKeyResponse")
819
819
  end
820
820
 
821
- # This operation doesn&#39;t accept empty queries or filters. It&#39;s more efficient to get a list of object IDs with the [&#x60;browse&#x60; operation](#tag/Search/operation/browse), and then delete the records using the [&#x60;batch&#x60; operation](tag/Records/operation/batch).
821
+ # This operation doesn&#39;t accept empty queries or filters. It&#39;s more efficient to get a list of object IDs with the [&#x60;browse&#x60; operation](#tag/Search/operation/browse), and then delete the records using the [&#x60;batch&#x60; operation](#tag/Records/operation/batch).
822
822
  #
823
823
  # Required API Key ACLs:
824
824
  # - deleteIndex
@@ -855,7 +855,7 @@ module Algolia
855
855
  @api_client.call_api(:POST, path, new_options)
856
856
  end
857
857
 
858
- # This operation doesn't accept empty queries or filters. It's more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](tag/Records/operation/batch).
858
+ # This operation doesn't accept empty queries or filters. It's more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](#tag/Records/operation/batch).
859
859
  #
860
860
  # Required API Key ACLs:
861
861
  # - deleteIndex
@@ -2294,7 +2294,7 @@ module Algolia
2294
2294
  @api_client.deserialize(response.body, request_options[:debug_return_type] || "Search::AddApiKeyResponse")
2295
2295
  end
2296
2296
 
2297
- # Adds a record to an index or replace it. - If the record doesn&#39;t have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn&#39;t exist, a new record is added to your index. - If you add a record to an index that doesn&#39;t exist yet, a new index is created. To update _some_ attributes of a record, use the [&#x60;partial&#x60; operation](#tag/Records/operation/partial). To add, update, or replace multiple records, use the [&#x60;batch&#x60; operation](#tag/Records/operation/batch).
2297
+ # Adds a record to an index or replace it. - If the record doesn&#39;t have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn&#39;t exist, a new record is added to your index. - If you add a record to an index that doesn&#39;t exist yet, a new index is created. To update _some_ attributes of a record, use the [&#x60;partial&#x60; operation](#tag/Records/operation/partialUpdateObject). To add, update, or replace multiple records, use the [&#x60;batch&#x60; operation](#tag/Records/operation/batch).
2298
2298
  #
2299
2299
  # Required API Key ACLs:
2300
2300
  # - addObject
@@ -2331,7 +2331,7 @@ module Algolia
2331
2331
  @api_client.call_api(:POST, path, new_options)
2332
2332
  end
2333
2333
 
2334
- # Adds a record to an index or replace it. - If the record doesn't have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn't exist, a new record is added to your index. - If you add a record to an index that doesn't exist yet, a new index is created. To update _some_ attributes of a record, use the [`partial` operation](#tag/Records/operation/partial). To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
2334
+ # Adds a record to an index or replace it. - If the record doesn't have an object ID, a new record with an auto-generated object ID is added to your index. - If a record with the specified object ID exists, the existing record is replaced. - If a record with the specified object ID doesn't exist, a new record is added to your index. - If you add a record to an index that doesn't exist yet, a new index is created. To update _some_ attributes of a record, use the [`partial` operation](#tag/Records/operation/partialUpdateObject). To add, update, or replace multiple records, use the [`batch` operation](#tag/Records/operation/batch).
2335
2335
  #
2336
2336
  # Required API Key ACLs:
2337
2337
  # - addObject
@@ -144,34 +144,24 @@ module Algolia
144
144
 
145
145
  if attributes.key?(:click_significance)
146
146
  self.click_significance = attributes[:click_significance]
147
- else
148
- self.click_significance = nil
149
147
  end
150
148
 
151
149
  if attributes.key?(:conversion_significance)
152
150
  self.conversion_significance = attributes[:conversion_significance]
153
- else
154
- self.conversion_significance = nil
155
151
  end
156
152
 
157
153
  if attributes.key?(:add_to_cart_significance)
158
154
  self.add_to_cart_significance = attributes[:add_to_cart_significance]
159
- else
160
- self.add_to_cart_significance = nil
161
155
  end
162
156
 
163
157
  if attributes.key?(:purchase_significance)
164
158
  self.purchase_significance = attributes[:purchase_significance]
165
- else
166
- self.purchase_significance = nil
167
159
  end
168
160
 
169
161
  if attributes.key?(:revenue_significance)
170
162
  if (value = attributes[:revenue_significance]).is_a?(Hash)
171
163
  self.revenue_significance = value
172
164
  end
173
- else
174
- self.revenue_significance = nil
175
165
  end
176
166
 
177
167
  if attributes.key?(:updated_at)
@@ -167,14 +167,10 @@ module Algolia
167
167
 
168
168
  if attributes.key?(:add_to_cart_rate)
169
169
  self.add_to_cart_rate = attributes[:add_to_cart_rate]
170
- else
171
- self.add_to_cart_rate = nil
172
170
  end
173
171
 
174
172
  if attributes.key?(:average_click_position)
175
173
  self.average_click_position = attributes[:average_click_position]
176
- else
177
- self.average_click_position = nil
178
174
  end
179
175
 
180
176
  if attributes.key?(:click_count)
@@ -185,8 +181,6 @@ module Algolia
185
181
 
186
182
  if attributes.key?(:click_through_rate)
187
183
  self.click_through_rate = attributes[:click_through_rate]
188
- else
189
- self.click_through_rate = nil
190
184
  end
191
185
 
192
186
  if attributes.key?(:conversion_count)
@@ -197,8 +191,6 @@ module Algolia
197
191
 
198
192
  if attributes.key?(:conversion_rate)
199
193
  self.conversion_rate = attributes[:conversion_rate]
200
- else
201
- self.conversion_rate = nil
202
194
  end
203
195
 
204
196
  if attributes.key?(:currencies)
@@ -241,8 +233,6 @@ module Algolia
241
233
 
242
234
  if attributes.key?(:purchase_rate)
243
235
  self.purchase_rate = attributes[:purchase_rate]
244
- else
245
- self.purchase_rate = nil
246
236
  end
247
237
 
248
238
  if attributes.key?(:search_count)
@@ -6,7 +6,7 @@ require "time"
6
6
  module Algolia
7
7
  module Analytics
8
8
  # Currency code.
9
- class CurrenciesValue
9
+ class CurrencyCode
10
10
  # Currency code.
11
11
  attr_accessor :currency
12
12
 
@@ -47,7 +47,7 @@ module Algolia
47
47
  if (!attributes.is_a?(Hash))
48
48
  raise(
49
49
  ArgumentError,
50
- "The input argument (attributes) must be a hash in `Algolia::CurrenciesValue` initialize method"
50
+ "The input argument (attributes) must be a hash in `Algolia::CurrencyCode` initialize method"
51
51
  )
52
52
  end
53
53
 
@@ -56,7 +56,7 @@ module Algolia
56
56
  if (!self.class.attribute_map.key?(k.to_sym))
57
57
  raise(
58
58
  ArgumentError,
59
- "`#{k}` is not a valid attribute in `Algolia::CurrenciesValue`. Please check the name to make sure it's valid. List of attributes: " +
59
+ "`#{k}` is not a valid attribute in `Algolia::CurrencyCode`. Please check the name to make sure it's valid. List of attributes: " +
60
60
  self.class.attribute_map.keys.inspect
61
61
  )
62
62
  end
@@ -28,7 +28,7 @@ module Algolia
28
28
  # Attribute type mapping.
29
29
  def self.types_mapping
30
30
  {
31
- :currencies => :"Hash<String, CurrenciesValue>",
31
+ :currencies => :"Hash<String, CurrencyCode>",
32
32
  :date => :"String"
33
33
  }
34
34
  end
@@ -28,7 +28,7 @@ module Algolia
28
28
  # Attribute type mapping.
29
29
  def self.types_mapping
30
30
  {
31
- :currencies => :"Hash<String, CurrenciesValue>",
31
+ :currencies => :"Hash<String, CurrencyCode>",
32
32
  :dates => :"Array<DailyRevenue>"
33
33
  }
34
34
  end
@@ -79,7 +79,7 @@ module Algolia
79
79
  :add_to_cart_count => :"Integer",
80
80
  :purchase_rate => :"Float",
81
81
  :purchase_count => :"Integer",
82
- :currencies => :"Hash<String, CurrenciesValue>"
82
+ :currencies => :"Hash<String, CurrencyCode>"
83
83
  }
84
84
  end
85
85
 
@@ -90,7 +90,7 @@ module Algolia
90
90
  :click_count => :"Integer",
91
91
  :conversion_count => :"Integer",
92
92
  :nb_hits => :"Integer",
93
- :currencies => :"Hash<String, CurrenciesValue>",
93
+ :currencies => :"Hash<String, CurrencyCode>",
94
94
  :add_to_cart_rate => :"Float",
95
95
  :add_to_cart_count => :"Integer",
96
96
  :purchase_rate => :"Float",
@@ -9,9 +9,11 @@ module Algolia
9
9
  REINDEX = "reindex".freeze
10
10
  UPDATE = "update".freeze
11
11
  DISCOVER = "discover".freeze
12
+ VALIDATE = "validate".freeze
13
+ PUSH = "push".freeze
12
14
 
13
15
  def self.all_vars
14
- @all_vars ||= [REINDEX, UPDATE, DISCOVER].freeze
16
+ @all_vars ||= [REINDEX, UPDATE, DISCOVER, VALIDATE, PUSH].freeze
15
17
  end
16
18
 
17
19
  # Builds the enum from string
@@ -124,8 +124,6 @@ module Algolia
124
124
 
125
125
  if attributes.key?(:input)
126
126
  self.input = attributes[:input]
127
- else
128
- self.input = nil
129
127
  end
130
128
 
131
129
  if attributes.key?(:authentication_id)
@@ -107,8 +107,6 @@ module Algolia
107
107
 
108
108
  if attributes.key?(:input)
109
109
  self.input = attributes[:input]
110
- else
111
- self.input = nil
112
110
  end
113
111
 
114
112
  if attributes.key?(:authentication_id)
@@ -15,9 +15,21 @@ module Algolia
15
15
  JSON = "json".freeze
16
16
  SHOPIFY = "shopify".freeze
17
17
  SFCC = "sfcc".freeze
18
+ PUSH = "push".freeze
18
19
 
19
20
  def self.all_vars
20
- @all_vars ||= [BIGCOMMERCE, BIGQUERY, COMMERCETOOLS, CSV, DOCKER, GA4_BIGQUERY_EXPORT, JSON, SHOPIFY, SFCC].freeze
21
+ @all_vars ||= [
22
+ BIGCOMMERCE,
23
+ BIGQUERY,
24
+ COMMERCETOOLS,
25
+ CSV,
26
+ DOCKER,
27
+ GA4_BIGQUERY_EXPORT,
28
+ JSON,
29
+ SHOPIFY,
30
+ SFCC,
31
+ PUSH
32
+ ].freeze
21
33
  end
22
34
 
23
35
  # Builds the enum from string
@@ -5,7 +5,7 @@ require "time"
5
5
 
6
6
  module Algolia
7
7
  module Recommend
8
- class FacetsStats
8
+ class FacetStats
9
9
  # Minimum value in the results.
10
10
  attr_accessor :min
11
11
 
@@ -56,7 +56,7 @@ module Algolia
56
56
  if (!attributes.is_a?(Hash))
57
57
  raise(
58
58
  ArgumentError,
59
- "The input argument (attributes) must be a hash in `Algolia::FacetsStats` initialize method"
59
+ "The input argument (attributes) must be a hash in `Algolia::FacetStats` initialize method"
60
60
  )
61
61
  end
62
62
 
@@ -65,7 +65,7 @@ module Algolia
65
65
  if (!self.class.attribute_map.key?(k.to_sym))
66
66
  raise(
67
67
  ArgumentError,
68
- "`#{k}` is not a valid attribute in `Algolia::FacetsStats`. Please check the name to make sure it's valid. List of attributes: " +
68
+ "`#{k}` is not a valid attribute in `Algolia::FacetStats`. Please check the name to make sure it's valid. List of attributes: " +
69
69
  self.class.attribute_map.keys.inspect
70
70
  )
71
71
  end
@@ -813,8 +813,8 @@ module Algolia
813
813
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
814
814
  end
815
815
 
816
- if length < 1
817
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
816
+ if length < 0
817
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
818
818
  end
819
819
 
820
820
  @length = length
@@ -141,7 +141,7 @@ module Algolia
141
141
  :exhaustive_nb_hits => :"Boolean",
142
142
  :exhaustive_typo => :"Boolean",
143
143
  :facets => :"Hash<String, Hash<String, Integer>>",
144
- :facets_stats => :"Hash<String, FacetsStats>",
144
+ :facets_stats => :"Hash<String, FacetStats>",
145
145
  :index => :"String",
146
146
  :index_used => :"String",
147
147
  :message => :"String",
@@ -813,8 +813,8 @@ module Algolia
813
813
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
814
814
  end
815
815
 
816
- if length < 1
817
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
816
+ if length < 0
817
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
818
818
  end
819
819
 
820
820
  @length = length
@@ -815,8 +815,8 @@ module Algolia
815
815
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
816
816
  end
817
817
 
818
- if length < 1
819
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
818
+ if length < 0
819
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
820
820
  end
821
821
 
822
822
  @length = length
@@ -823,8 +823,8 @@ module Algolia
823
823
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
824
824
  end
825
825
 
826
- if length < 1
827
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
826
+ if length < 0
827
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
828
828
  end
829
829
 
830
830
  @length = length
@@ -154,7 +154,7 @@ module Algolia
154
154
  :exhaustive_nb_hits => :"Boolean",
155
155
  :exhaustive_typo => :"Boolean",
156
156
  :facets => :"Hash<String, Hash<String, Integer>>",
157
- :facets_stats => :"Hash<String, FacetsStats>",
157
+ :facets_stats => :"Hash<String, FacetStats>",
158
158
  :index => :"String",
159
159
  :index_used => :"String",
160
160
  :message => :"String",
@@ -830,8 +830,8 @@ module Algolia
830
830
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
831
831
  end
832
832
 
833
- if length < 1
834
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
833
+ if length < 0
834
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
835
835
  end
836
836
 
837
837
  @length = length
@@ -5,7 +5,7 @@ require "time"
5
5
 
6
6
  module Algolia
7
7
  module Search
8
- class FacetsStats
8
+ class FacetStats
9
9
  # Minimum value in the results.
10
10
  attr_accessor :min
11
11
 
@@ -56,7 +56,7 @@ module Algolia
56
56
  if (!attributes.is_a?(Hash))
57
57
  raise(
58
58
  ArgumentError,
59
- "The input argument (attributes) must be a hash in `Algolia::FacetsStats` initialize method"
59
+ "The input argument (attributes) must be a hash in `Algolia::FacetStats` initialize method"
60
60
  )
61
61
  end
62
62
 
@@ -65,7 +65,7 @@ module Algolia
65
65
  if (!self.class.attribute_map.key?(k.to_sym))
66
66
  raise(
67
67
  ArgumentError,
68
- "`#{k}` is not a valid attribute in `Algolia::FacetsStats`. Please check the name to make sure it's valid. List of attributes: " +
68
+ "`#{k}` is not a valid attribute in `Algolia::FacetStats`. Please check the name to make sure it's valid. List of attributes: " +
69
69
  self.class.attribute_map.keys.inspect
70
70
  )
71
71
  end
@@ -864,8 +864,8 @@ module Algolia
864
864
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
865
865
  end
866
866
 
867
- if length < 1
868
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
867
+ if length < 0
868
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
869
869
  end
870
870
 
871
871
  @length = length
@@ -842,8 +842,8 @@ module Algolia
842
842
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
843
843
  end
844
844
 
845
- if length < 1
846
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
845
+ if length < 0
846
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
847
847
  end
848
848
 
849
849
  @length = length
@@ -815,8 +815,8 @@ module Algolia
815
815
  raise ArgumentError, "invalid value for \"length\", must be smaller than or equal to 1000."
816
816
  end
817
817
 
818
- if length < 1
819
- raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 1."
818
+ if length < 0
819
+ raise ArgumentError, "invalid value for \"length\", must be greater than or equal to 0."
820
820
  end
821
821
 
822
822
  @length = length
@@ -152,7 +152,7 @@ module Algolia
152
152
  :exhaustive_nb_hits => :"Boolean",
153
153
  :exhaustive_typo => :"Boolean",
154
154
  :facets => :"Hash<String, Hash<String, Integer>>",
155
- :facets_stats => :"Hash<String, FacetsStats>",
155
+ :facets_stats => :"Hash<String, FacetStats>",
156
156
  :index => :"String",
157
157
  :index_used => :"String",
158
158
  :message => :"String",
@@ -1,5 +1,5 @@
1
1
  # Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT.
2
2
 
3
3
  module Algolia
4
- VERSION = "3.1.0".freeze
4
+ VERSION = "3.2.0".freeze
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: algolia
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.1.0
4
+ version: 3.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - https://alg.li/support
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-08-20 00:00:00.000000000 Z
11
+ date: 2024-08-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -118,6 +118,7 @@ executables: []
118
118
  extensions: []
119
119
  extra_rdoc_files: []
120
120
  files:
121
+ - ".github/workflows/issue.yml"
121
122
  - ".github/workflows/release.yml"
122
123
  - ".gitignore"
123
124
  - CHANGELOG.md
@@ -164,7 +165,7 @@ files:
164
165
  - lib/algolia/models/abtesting/status.rb
165
166
  - lib/algolia/models/abtesting/variant.rb
166
167
  - lib/algolia/models/analytics/click_position.rb
167
- - lib/algolia/models/analytics/currencies_value.rb
168
+ - lib/algolia/models/analytics/currency_code.rb
168
169
  - lib/algolia/models/analytics/daily_add_to_cart_rates.rb
169
170
  - lib/algolia/models/analytics/daily_average_clicks.rb
170
171
  - lib/algolia/models/analytics/daily_click_through_rates.rb
@@ -447,8 +448,8 @@ files:
447
448
  - lib/algolia/models/recommend/exhaustive.rb
448
449
  - lib/algolia/models/recommend/facet_filters.rb
449
450
  - lib/algolia/models/recommend/facet_ordering.rb
451
+ - lib/algolia/models/recommend/facet_stats.rb
450
452
  - lib/algolia/models/recommend/facets.rb
451
- - lib/algolia/models/recommend/facets_stats.rb
452
453
  - lib/algolia/models/recommend/fallback_params.rb
453
454
  - lib/algolia/models/recommend/fbt_model.rb
454
455
  - lib/algolia/models/recommend/get_recommend_task_response.rb
@@ -563,8 +564,8 @@ files:
563
564
  - lib/algolia/models/search/facet_filters.rb
564
565
  - lib/algolia/models/search/facet_hits.rb
565
566
  - lib/algolia/models/search/facet_ordering.rb
567
+ - lib/algolia/models/search/facet_stats.rb
566
568
  - lib/algolia/models/search/facets.rb
567
- - lib/algolia/models/search/facets_stats.rb
568
569
  - lib/algolia/models/search/fetched_index.rb
569
570
  - lib/algolia/models/search/get_api_key_response.rb
570
571
  - lib/algolia/models/search/get_dictionary_settings_response.rb