algolia 3.5.0 → 3.5.1
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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +8 -0
- data/Gemfile.lock +1 -1
- data/lib/algolia/api/abtesting_client.rb +0 -7
- data/lib/algolia/api/analytics_client.rb +0 -168
- data/lib/algolia/api/ingestion_client.rb +2 -170
- data/lib/algolia/api/insights_client.rb +0 -22
- data/lib/algolia/api/monitoring_client.rb +11 -11
- data/lib/algolia/api/search_client.rb +3 -58
- data/lib/algolia/models/abtesting/ab_tests_variant.rb +0 -18
- data/lib/algolia/models/abtesting/ab_tests_variant_search_params.rb +0 -18
- data/lib/algolia/models/abtesting/add_ab_tests_request.rb +0 -18
- data/lib/algolia/models/abtesting/minimum_detectable_effect.rb +0 -18
- data/lib/algolia/models/abtesting/schedule_ab_tests_request.rb +0 -18
- data/lib/algolia/models/abtesting/variant.rb +0 -18
- data/lib/algolia/models/analytics/click_position.rb +0 -32
- data/lib/algolia/models/analytics/daily_add_to_cart_rates.rb +0 -28
- data/lib/algolia/models/analytics/daily_average_clicks.rb +0 -24
- data/lib/algolia/models/analytics/daily_click_through_rates.rb +0 -28
- data/lib/algolia/models/analytics/daily_conversion_rates.rb +0 -28
- data/lib/algolia/models/analytics/daily_no_click_rates.rb +0 -32
- data/lib/algolia/models/analytics/daily_no_results_rates.rb +0 -18
- data/lib/algolia/models/analytics/daily_purchase_rates.rb +0 -14
- data/lib/algolia/models/analytics/daily_searches_no_clicks.rb +0 -14
- data/lib/algolia/models/analytics/daily_searches_no_results.rb +0 -14
- data/lib/algolia/models/analytics/get_add_to_cart_rate_response.rb +0 -28
- data/lib/algolia/models/analytics/get_average_click_position_response.rb +0 -24
- data/lib/algolia/models/analytics/get_click_positions_response.rb +0 -18
- data/lib/algolia/models/analytics/get_click_through_rate_response.rb +0 -28
- data/lib/algolia/models/analytics/get_conversion_rate_response.rb +0 -28
- data/lib/algolia/models/analytics/get_no_click_rate_response.rb +0 -32
- data/lib/algolia/models/analytics/get_no_results_rate_response.rb +0 -18
- data/lib/algolia/models/analytics/get_purchase_rate_response.rb +0 -14
- data/lib/algolia/models/analytics/top_hit_with_analytics.rb +0 -56
- data/lib/algolia/models/analytics/top_hit_with_revenue_analytics.rb +0 -98
- data/lib/algolia/models/analytics/top_search_with_analytics.rb +0 -90
- data/lib/algolia/models/analytics/top_search_with_revenue_analytics.rb +0 -132
- data/lib/algolia/models/ingestion/event.rb +0 -14
- data/lib/algolia/models/ingestion/pagination.rb +0 -60
- data/lib/algolia/models/ingestion/run.rb +0 -18
- data/lib/algolia/models/ingestion/source_csv.rb +0 -21
- data/lib/algolia/models/ingestion/task.rb +0 -18
- data/lib/algolia/models/ingestion/task_create.rb +0 -18
- data/lib/algolia/models/ingestion/task_create_v1.rb +0 -18
- data/lib/algolia/models/ingestion/task_update.rb +0 -18
- data/lib/algolia/models/ingestion/task_update_v1.rb +0 -18
- data/lib/algolia/models/ingestion/task_v1.rb +0 -18
- data/lib/algolia/models/ingestion/transformation.rb +1 -1
- data/lib/algolia/models/ingestion/transformation_create.rb +1 -1
- data/lib/algolia/models/insights/added_to_cart_object_ids.rb +0 -123
- data/lib/algolia/models/insights/added_to_cart_object_ids_after_search.rb +0 -149
- data/lib/algolia/models/insights/clicked_filters.rb +0 -105
- data/lib/algolia/models/insights/clicked_object_ids.rb +0 -105
- data/lib/algolia/models/insights/clicked_object_ids_after_search.rb +0 -149
- data/lib/algolia/models/insights/converted_filters.rb +0 -105
- data/lib/algolia/models/insights/converted_object_ids.rb +0 -105
- data/lib/algolia/models/insights/converted_object_ids_after_search.rb +0 -131
- data/lib/algolia/models/insights/insights_events.rb +0 -18
- data/lib/algolia/models/insights/object_data_after_search.rb +0 -26
- data/lib/algolia/models/insights/purchased_object_ids.rb +0 -123
- data/lib/algolia/models/insights/purchased_object_ids_after_search.rb +0 -123
- data/lib/algolia/models/insights/viewed_filters.rb +0 -105
- data/lib/algolia/models/insights/viewed_object_ids.rb +0 -105
- data/lib/algolia/models/personalization/personalization_strategy_params.rb +0 -18
- data/lib/algolia/models/query-suggestions/configuration.rb +0 -17
- data/lib/algolia/models/query-suggestions/configuration_response.rb +0 -17
- data/lib/algolia/models/query-suggestions/configuration_with_index.rb +0 -17
- data/lib/algolia/models/query-suggestions/source_index.rb +0 -28
- data/lib/algolia/models/recommend/banner_image.rb +4 -2
- data/lib/algolia/models/recommend/bought_together_query.rb +0 -36
- data/lib/algolia/models/recommend/condition.rb +0 -15
- data/lib/algolia/models/recommend/consequence.rb +0 -28
- data/lib/algolia/models/recommend/fallback_params.rb +0 -92
- data/lib/algolia/models/recommend/looking_similar_query.rb +0 -36
- data/lib/algolia/models/recommend/promote_consequence_object.rb +0 -14
- data/lib/algolia/models/recommend/ranking_info.rb +0 -112
- data/lib/algolia/models/recommend/recommend_hit.rb +0 -18
- data/lib/algolia/models/recommend/recommend_search_params.rb +0 -92
- data/lib/algolia/models/recommend/recommendations_results.rb +0 -61
- data/lib/algolia/models/recommend/recommended_for_you_query.rb +0 -36
- data/lib/algolia/models/recommend/related_query.rb +0 -36
- data/lib/algolia/models/recommend/search_recommend_rules_params.rb +0 -50
- data/lib/algolia/models/recommend/search_recommend_rules_response.rb +0 -14
- data/lib/algolia/models/recommend/trending_facet_hit.rb +0 -18
- data/lib/algolia/models/recommend/trending_facets_query.rb +0 -36
- data/lib/algolia/models/recommend/trending_items_query.rb +0 -36
- data/lib/algolia/models/recommend/widgets.rb +5 -2
- data/lib/algolia/models/search/banner_image.rb +4 -2
- data/lib/algolia/models/search/browse_params_object.rb +0 -128
- data/lib/algolia/models/search/browse_response.rb +0 -61
- data/lib/algolia/models/search/condition.rb +0 -15
- data/lib/algolia/models/search/consequence.rb +0 -28
- data/lib/algolia/models/search/consequence_params.rb +0 -128
- data/lib/algolia/models/search/index_settings.rb +0 -78
- data/lib/algolia/models/search/log.rb +0 -34
- data/lib/algolia/models/search/promote_object_ids.rb +0 -14
- data/lib/algolia/models/search/ranking_info.rb +0 -112
- data/lib/algolia/models/search/rule.rb +0 -18
- data/lib/algolia/models/search/search_dictionary_entries_params.rb +0 -32
- data/lib/algolia/models/search/search_dictionary_entries_response.rb +0 -14
- data/lib/algolia/models/search/search_for_facet_values_request.rb +0 -14
- data/lib/algolia/models/search/search_for_facets.rb +0 -128
- data/lib/algolia/models/search/search_for_hits.rb +0 -128
- data/lib/algolia/models/search/search_params_object.rb +0 -128
- data/lib/algolia/models/search/search_response.rb +0 -61
- data/lib/algolia/models/search/search_rules_params.rb +0 -32
- data/lib/algolia/models/search/search_synonyms_params.rb +0 -32
- data/lib/algolia/models/search/search_user_ids_params.rb +0 -32
- data/lib/algolia/models/search/search_user_ids_response.rb +0 -32
- data/lib/algolia/models/search/settings_response.rb +0 -78
- data/lib/algolia/models/search/user_hit.rb +0 -15
- data/lib/algolia/models/search/user_id.rb +0 -15
- data/lib/algolia/models/search/widgets.rb +5 -2
- data/lib/algolia/version.rb +1 -1
- metadata +2 -11
- data/lib/algolia/models/query-suggestions/base_query_suggestions_configuration_response.rb +0 -230
- data/lib/algolia/models/query-suggestions/base_query_suggestions_configuration_with_index.rb +0 -212
- data/lib/algolia/models/query-suggestions/get_config_status200_response.rb +0 -252
- data/lib/algolia/models/query-suggestions/get_log_file200_response.rb +0 -263
- data/lib/algolia/models/query-suggestions/query_suggestions_configuration.rb +0 -276
- data/lib/algolia/models/query-suggestions/query_suggestions_configuration_response.rb +0 -316
- data/lib/algolia/models/query-suggestions/query_suggestions_configuration_with_index.rb +0 -295
- data/lib/algolia/models/recommend/banners.rb +0 -209
- data/lib/algolia/models/search/banners.rb +0 -209
|
@@ -355,67 +355,6 @@ module Algolia
|
|
|
355
355
|
self.additional_properties.merge!(attributes.reject { |k, _| self.class.attribute_map.key?(k.to_sym) })
|
|
356
356
|
end
|
|
357
357
|
|
|
358
|
-
# Custom attribute writer method with validation
|
|
359
|
-
# @param [Object] ab_test_variant_id Value to be assigned
|
|
360
|
-
def ab_test_variant_id=(ab_test_variant_id)
|
|
361
|
-
if ab_test_variant_id.nil?
|
|
362
|
-
raise ArgumentError, "ab_test_variant_id cannot be nil"
|
|
363
|
-
end
|
|
364
|
-
|
|
365
|
-
if ab_test_variant_id < 1
|
|
366
|
-
raise ArgumentError, "invalid value for \"ab_test_variant_id\", must be greater than or equal to 1."
|
|
367
|
-
end
|
|
368
|
-
|
|
369
|
-
@ab_test_variant_id = ab_test_variant_id
|
|
370
|
-
end
|
|
371
|
-
|
|
372
|
-
# Custom attribute writer method with validation
|
|
373
|
-
# @param [Object] around_lat_lng Value to be assigned
|
|
374
|
-
def around_lat_lng=(around_lat_lng)
|
|
375
|
-
if around_lat_lng.nil?
|
|
376
|
-
raise ArgumentError, "around_lat_lng cannot be nil"
|
|
377
|
-
end
|
|
378
|
-
|
|
379
|
-
pattern = /^(-?\d+(\.\d+)?),\s*(-?\d+(\.\d+)?)$/
|
|
380
|
-
if around_lat_lng !~ pattern
|
|
381
|
-
raise ArgumentError, "invalid value for \"around_lat_lng\", must conform to the pattern #{pattern}."
|
|
382
|
-
end
|
|
383
|
-
|
|
384
|
-
@around_lat_lng = around_lat_lng
|
|
385
|
-
end
|
|
386
|
-
|
|
387
|
-
# Custom attribute writer method with validation
|
|
388
|
-
# @param [Object] page Value to be assigned
|
|
389
|
-
def page=(page)
|
|
390
|
-
if page.nil?
|
|
391
|
-
raise ArgumentError, "page cannot be nil"
|
|
392
|
-
end
|
|
393
|
-
|
|
394
|
-
if page < 0
|
|
395
|
-
raise ArgumentError, "invalid value for \"page\", must be greater than or equal to 0."
|
|
396
|
-
end
|
|
397
|
-
|
|
398
|
-
@page = page
|
|
399
|
-
end
|
|
400
|
-
|
|
401
|
-
# Custom attribute writer method with validation
|
|
402
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
403
|
-
def hits_per_page=(hits_per_page)
|
|
404
|
-
if hits_per_page.nil?
|
|
405
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
406
|
-
end
|
|
407
|
-
|
|
408
|
-
if hits_per_page > 1000
|
|
409
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
410
|
-
end
|
|
411
|
-
|
|
412
|
-
if hits_per_page < 1
|
|
413
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
414
|
-
end
|
|
415
|
-
|
|
416
|
-
@hits_per_page = hits_per_page
|
|
417
|
-
end
|
|
418
|
-
|
|
419
358
|
# Checks equality by comparing each attribute.
|
|
420
359
|
# @param [Object] Object to be compared
|
|
421
360
|
def ==(other)
|
|
@@ -110,38 +110,6 @@ module Algolia
|
|
|
110
110
|
end
|
|
111
111
|
end
|
|
112
112
|
|
|
113
|
-
# Custom attribute writer method with validation
|
|
114
|
-
# @param [Object] page Value to be assigned
|
|
115
|
-
def page=(page)
|
|
116
|
-
if page.nil?
|
|
117
|
-
raise ArgumentError, "page cannot be nil"
|
|
118
|
-
end
|
|
119
|
-
|
|
120
|
-
if page < 0
|
|
121
|
-
raise ArgumentError, "invalid value for \"page\", must be greater than or equal to 0."
|
|
122
|
-
end
|
|
123
|
-
|
|
124
|
-
@page = page
|
|
125
|
-
end
|
|
126
|
-
|
|
127
|
-
# Custom attribute writer method with validation
|
|
128
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
129
|
-
def hits_per_page=(hits_per_page)
|
|
130
|
-
if hits_per_page.nil?
|
|
131
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
132
|
-
end
|
|
133
|
-
|
|
134
|
-
if hits_per_page > 1000
|
|
135
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
136
|
-
end
|
|
137
|
-
|
|
138
|
-
if hits_per_page < 1
|
|
139
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
140
|
-
end
|
|
141
|
-
|
|
142
|
-
@hits_per_page = hits_per_page
|
|
143
|
-
end
|
|
144
|
-
|
|
145
113
|
# Checks equality by comparing each attribute.
|
|
146
114
|
# @param [Object] Object to be compared
|
|
147
115
|
def ==(other)
|
|
@@ -89,38 +89,6 @@ module Algolia
|
|
|
89
89
|
end
|
|
90
90
|
end
|
|
91
91
|
|
|
92
|
-
# Custom attribute writer method with validation
|
|
93
|
-
# @param [Object] page Value to be assigned
|
|
94
|
-
def page=(page)
|
|
95
|
-
if page.nil?
|
|
96
|
-
raise ArgumentError, "page cannot be nil"
|
|
97
|
-
end
|
|
98
|
-
|
|
99
|
-
if page < 0
|
|
100
|
-
raise ArgumentError, "invalid value for \"page\", must be greater than or equal to 0."
|
|
101
|
-
end
|
|
102
|
-
|
|
103
|
-
@page = page
|
|
104
|
-
end
|
|
105
|
-
|
|
106
|
-
# Custom attribute writer method with validation
|
|
107
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
108
|
-
def hits_per_page=(hits_per_page)
|
|
109
|
-
if hits_per_page.nil?
|
|
110
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
111
|
-
end
|
|
112
|
-
|
|
113
|
-
if hits_per_page > 1000
|
|
114
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
115
|
-
end
|
|
116
|
-
|
|
117
|
-
if hits_per_page < 1
|
|
118
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
119
|
-
end
|
|
120
|
-
|
|
121
|
-
@hits_per_page = hits_per_page
|
|
122
|
-
end
|
|
123
|
-
|
|
124
92
|
# Checks equality by comparing each attribute.
|
|
125
93
|
# @param [Object] Object to be compared
|
|
126
94
|
def ==(other)
|
|
@@ -93,38 +93,6 @@ module Algolia
|
|
|
93
93
|
end
|
|
94
94
|
end
|
|
95
95
|
|
|
96
|
-
# Custom attribute writer method with validation
|
|
97
|
-
# @param [Object] page Value to be assigned
|
|
98
|
-
def page=(page)
|
|
99
|
-
if page.nil?
|
|
100
|
-
raise ArgumentError, "page cannot be nil"
|
|
101
|
-
end
|
|
102
|
-
|
|
103
|
-
if page < 0
|
|
104
|
-
raise ArgumentError, "invalid value for \"page\", must be greater than or equal to 0."
|
|
105
|
-
end
|
|
106
|
-
|
|
107
|
-
@page = page
|
|
108
|
-
end
|
|
109
|
-
|
|
110
|
-
# Custom attribute writer method with validation
|
|
111
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
112
|
-
def hits_per_page=(hits_per_page)
|
|
113
|
-
if hits_per_page.nil?
|
|
114
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
115
|
-
end
|
|
116
|
-
|
|
117
|
-
if hits_per_page > 1000
|
|
118
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
119
|
-
end
|
|
120
|
-
|
|
121
|
-
if hits_per_page < 1
|
|
122
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
123
|
-
end
|
|
124
|
-
|
|
125
|
-
@hits_per_page = hits_per_page
|
|
126
|
-
end
|
|
127
|
-
|
|
128
96
|
# Checks equality by comparing each attribute.
|
|
129
97
|
# @param [Object] Object to be compared
|
|
130
98
|
def ==(other)
|
|
@@ -112,38 +112,6 @@ module Algolia
|
|
|
112
112
|
end
|
|
113
113
|
end
|
|
114
114
|
|
|
115
|
-
# Custom attribute writer method with validation
|
|
116
|
-
# @param [Object] page Value to be assigned
|
|
117
|
-
def page=(page)
|
|
118
|
-
if page.nil?
|
|
119
|
-
raise ArgumentError, "page cannot be nil"
|
|
120
|
-
end
|
|
121
|
-
|
|
122
|
-
if page < 0
|
|
123
|
-
raise ArgumentError, "invalid value for \"page\", must be greater than or equal to 0."
|
|
124
|
-
end
|
|
125
|
-
|
|
126
|
-
@page = page
|
|
127
|
-
end
|
|
128
|
-
|
|
129
|
-
# Custom attribute writer method with validation
|
|
130
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
131
|
-
def hits_per_page=(hits_per_page)
|
|
132
|
-
if hits_per_page.nil?
|
|
133
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
134
|
-
end
|
|
135
|
-
|
|
136
|
-
if hits_per_page > 1000
|
|
137
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
138
|
-
end
|
|
139
|
-
|
|
140
|
-
if hits_per_page < 1
|
|
141
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
142
|
-
end
|
|
143
|
-
|
|
144
|
-
@hits_per_page = hits_per_page
|
|
145
|
-
end
|
|
146
|
-
|
|
147
115
|
# Checks equality by comparing each attribute.
|
|
148
116
|
# @param [Object] Object to be compared
|
|
149
117
|
def ==(other)
|
|
@@ -655,84 +655,6 @@ module Algolia
|
|
|
655
655
|
end
|
|
656
656
|
end
|
|
657
657
|
|
|
658
|
-
# Custom attribute writer method with validation
|
|
659
|
-
# @param [Object] pagination_limited_to Value to be assigned
|
|
660
|
-
def pagination_limited_to=(pagination_limited_to)
|
|
661
|
-
if pagination_limited_to.nil?
|
|
662
|
-
raise ArgumentError, "pagination_limited_to cannot be nil"
|
|
663
|
-
end
|
|
664
|
-
|
|
665
|
-
if pagination_limited_to > 20000
|
|
666
|
-
raise ArgumentError, "invalid value for \"pagination_limited_to\", must be smaller than or equal to 20000."
|
|
667
|
-
end
|
|
668
|
-
|
|
669
|
-
@pagination_limited_to = pagination_limited_to
|
|
670
|
-
end
|
|
671
|
-
|
|
672
|
-
# Custom attribute writer method with validation
|
|
673
|
-
# @param [Object] hits_per_page Value to be assigned
|
|
674
|
-
def hits_per_page=(hits_per_page)
|
|
675
|
-
if hits_per_page.nil?
|
|
676
|
-
raise ArgumentError, "hits_per_page cannot be nil"
|
|
677
|
-
end
|
|
678
|
-
|
|
679
|
-
if hits_per_page > 1000
|
|
680
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be smaller than or equal to 1000."
|
|
681
|
-
end
|
|
682
|
-
|
|
683
|
-
if hits_per_page < 1
|
|
684
|
-
raise ArgumentError, "invalid value for \"hits_per_page\", must be greater than or equal to 1."
|
|
685
|
-
end
|
|
686
|
-
|
|
687
|
-
@hits_per_page = hits_per_page
|
|
688
|
-
end
|
|
689
|
-
|
|
690
|
-
# Custom attribute writer method with validation
|
|
691
|
-
# @param [Object] min_proximity Value to be assigned
|
|
692
|
-
def min_proximity=(min_proximity)
|
|
693
|
-
if min_proximity.nil?
|
|
694
|
-
raise ArgumentError, "min_proximity cannot be nil"
|
|
695
|
-
end
|
|
696
|
-
|
|
697
|
-
if min_proximity > 7
|
|
698
|
-
raise ArgumentError, "invalid value for \"min_proximity\", must be smaller than or equal to 7."
|
|
699
|
-
end
|
|
700
|
-
|
|
701
|
-
if min_proximity < 1
|
|
702
|
-
raise ArgumentError, "invalid value for \"min_proximity\", must be greater than or equal to 1."
|
|
703
|
-
end
|
|
704
|
-
|
|
705
|
-
@min_proximity = min_proximity
|
|
706
|
-
end
|
|
707
|
-
|
|
708
|
-
# Custom attribute writer method with validation
|
|
709
|
-
# @param [Object] max_facet_hits Value to be assigned
|
|
710
|
-
def max_facet_hits=(max_facet_hits)
|
|
711
|
-
if max_facet_hits.nil?
|
|
712
|
-
raise ArgumentError, "max_facet_hits cannot be nil"
|
|
713
|
-
end
|
|
714
|
-
|
|
715
|
-
if max_facet_hits > 100
|
|
716
|
-
raise ArgumentError, "invalid value for \"max_facet_hits\", must be smaller than or equal to 100."
|
|
717
|
-
end
|
|
718
|
-
|
|
719
|
-
@max_facet_hits = max_facet_hits
|
|
720
|
-
end
|
|
721
|
-
|
|
722
|
-
# Custom attribute writer method with validation
|
|
723
|
-
# @param [Object] max_values_per_facet Value to be assigned
|
|
724
|
-
def max_values_per_facet=(max_values_per_facet)
|
|
725
|
-
if max_values_per_facet.nil?
|
|
726
|
-
raise ArgumentError, "max_values_per_facet cannot be nil"
|
|
727
|
-
end
|
|
728
|
-
|
|
729
|
-
if max_values_per_facet > 1000
|
|
730
|
-
raise ArgumentError, "invalid value for \"max_values_per_facet\", must be smaller than or equal to 1000."
|
|
731
|
-
end
|
|
732
|
-
|
|
733
|
-
@max_values_per_facet = max_values_per_facet
|
|
734
|
-
end
|
|
735
|
-
|
|
736
658
|
# Checks equality by comparing each attribute.
|
|
737
659
|
# @param [Object] Object to be compared
|
|
738
660
|
def ==(other)
|
|
@@ -116,21 +116,6 @@ module Algolia
|
|
|
116
116
|
end
|
|
117
117
|
end
|
|
118
118
|
|
|
119
|
-
# Custom attribute writer method with validation
|
|
120
|
-
# @param [Object] user_id Value to be assigned
|
|
121
|
-
def user_id=(user_id)
|
|
122
|
-
if user_id.nil?
|
|
123
|
-
raise ArgumentError, "user_id cannot be nil"
|
|
124
|
-
end
|
|
125
|
-
|
|
126
|
-
pattern = /^[a-zA-Z0-9 \-*.]+$/
|
|
127
|
-
if user_id !~ pattern
|
|
128
|
-
raise ArgumentError, "invalid value for \"user_id\", must conform to the pattern #{pattern}."
|
|
129
|
-
end
|
|
130
|
-
|
|
131
|
-
@user_id = user_id
|
|
132
|
-
end
|
|
133
|
-
|
|
134
119
|
# Checks equality by comparing each attribute.
|
|
135
120
|
# @param [Object] Object to be compared
|
|
136
121
|
def ==(other)
|
|
@@ -96,21 +96,6 @@ module Algolia
|
|
|
96
96
|
end
|
|
97
97
|
end
|
|
98
98
|
|
|
99
|
-
# Custom attribute writer method with validation
|
|
100
|
-
# @param [Object] user_id Value to be assigned
|
|
101
|
-
def user_id=(user_id)
|
|
102
|
-
if user_id.nil?
|
|
103
|
-
raise ArgumentError, "user_id cannot be nil"
|
|
104
|
-
end
|
|
105
|
-
|
|
106
|
-
pattern = /^[a-zA-Z0-9 \-*.]+$/
|
|
107
|
-
if user_id !~ pattern
|
|
108
|
-
raise ArgumentError, "invalid value for \"user_id\", must conform to the pattern #{pattern}."
|
|
109
|
-
end
|
|
110
|
-
|
|
111
|
-
@user_id = user_id
|
|
112
|
-
end
|
|
113
|
-
|
|
114
99
|
# Checks equality by comparing each attribute.
|
|
115
100
|
# @param [Object] Object to be compared
|
|
116
101
|
def ==(other)
|
|
@@ -7,6 +7,7 @@ module Algolia
|
|
|
7
7
|
module Search
|
|
8
8
|
# widgets returned from any rules that are applied to the current search.
|
|
9
9
|
class Widgets
|
|
10
|
+
# banners defined in the merchandising studio for the given search.
|
|
10
11
|
attr_accessor :banners
|
|
11
12
|
|
|
12
13
|
# Attribute mapping from ruby-style variable name to JSON key.
|
|
@@ -24,7 +25,7 @@ module Algolia
|
|
|
24
25
|
# Attribute type mapping.
|
|
25
26
|
def self.types_mapping
|
|
26
27
|
{
|
|
27
|
-
:banners => :"
|
|
28
|
+
:banners => :"Array<Banner>"
|
|
28
29
|
}
|
|
29
30
|
end
|
|
30
31
|
|
|
@@ -56,7 +57,9 @@ module Algolia
|
|
|
56
57
|
}
|
|
57
58
|
|
|
58
59
|
if attributes.key?(:banners)
|
|
59
|
-
|
|
60
|
+
if (value = attributes[:banners]).is_a?(Array)
|
|
61
|
+
self.banners = value
|
|
62
|
+
end
|
|
60
63
|
end
|
|
61
64
|
end
|
|
62
65
|
|
data/lib/algolia/version.rb
CHANGED
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.5.
|
|
4
|
+
version: 3.5.1
|
|
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-10-
|
|
11
|
+
date: 2024-10-10 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: faraday
|
|
@@ -419,8 +419,6 @@ files:
|
|
|
419
419
|
- lib/algolia/models/personalization/get_user_token_response.rb
|
|
420
420
|
- lib/algolia/models/personalization/personalization_strategy_params.rb
|
|
421
421
|
- lib/algolia/models/personalization/set_personalization_strategy_response.rb
|
|
422
|
-
- lib/algolia/models/query-suggestions/base_query_suggestions_configuration_response.rb
|
|
423
|
-
- lib/algolia/models/query-suggestions/base_query_suggestions_configuration_with_index.rb
|
|
424
422
|
- lib/algolia/models/query-suggestions/base_response.rb
|
|
425
423
|
- lib/algolia/models/query-suggestions/config_status.rb
|
|
426
424
|
- lib/algolia/models/query-suggestions/configuration.rb
|
|
@@ -428,14 +426,9 @@ files:
|
|
|
428
426
|
- lib/algolia/models/query-suggestions/configuration_with_index.rb
|
|
429
427
|
- lib/algolia/models/query-suggestions/error_base.rb
|
|
430
428
|
- lib/algolia/models/query-suggestions/facet.rb
|
|
431
|
-
- lib/algolia/models/query-suggestions/get_config_status200_response.rb
|
|
432
|
-
- lib/algolia/models/query-suggestions/get_log_file200_response.rb
|
|
433
429
|
- lib/algolia/models/query-suggestions/languages.rb
|
|
434
430
|
- lib/algolia/models/query-suggestions/log_file.rb
|
|
435
431
|
- lib/algolia/models/query-suggestions/log_level.rb
|
|
436
|
-
- lib/algolia/models/query-suggestions/query_suggestions_configuration.rb
|
|
437
|
-
- lib/algolia/models/query-suggestions/query_suggestions_configuration_response.rb
|
|
438
|
-
- lib/algolia/models/query-suggestions/query_suggestions_configuration_with_index.rb
|
|
439
432
|
- lib/algolia/models/query-suggestions/source_index.rb
|
|
440
433
|
- lib/algolia/models/recommend/advanced_syntax_features.rb
|
|
441
434
|
- lib/algolia/models/recommend/alternatives_as_exact.rb
|
|
@@ -447,7 +440,6 @@ files:
|
|
|
447
440
|
- lib/algolia/models/recommend/banner_image.rb
|
|
448
441
|
- lib/algolia/models/recommend/banner_image_url.rb
|
|
449
442
|
- lib/algolia/models/recommend/banner_link.rb
|
|
450
|
-
- lib/algolia/models/recommend/banners.rb
|
|
451
443
|
- lib/algolia/models/recommend/boolean_string.rb
|
|
452
444
|
- lib/algolia/models/recommend/bought_together_query.rb
|
|
453
445
|
- lib/algolia/models/recommend/condition.rb
|
|
@@ -540,7 +532,6 @@ files:
|
|
|
540
532
|
- lib/algolia/models/search/banner_image.rb
|
|
541
533
|
- lib/algolia/models/search/banner_image_url.rb
|
|
542
534
|
- lib/algolia/models/search/banner_link.rb
|
|
543
|
-
- lib/algolia/models/search/banners.rb
|
|
544
535
|
- lib/algolia/models/search/batch_assign_user_ids_params.rb
|
|
545
536
|
- lib/algolia/models/search/batch_dictionary_entries_params.rb
|
|
546
537
|
- lib/algolia/models/search/batch_dictionary_entries_request.rb
|
|
@@ -1,230 +0,0 @@
|
|
|
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
|
-
|
|
3
|
-
require "date"
|
|
4
|
-
require "time"
|
|
5
|
-
|
|
6
|
-
module Algolia
|
|
7
|
-
module QuerySuggestions
|
|
8
|
-
class BaseQuerySuggestionsConfigurationResponse
|
|
9
|
-
# API key used to read from your source index.
|
|
10
|
-
attr_accessor :source_indices_api_key
|
|
11
|
-
|
|
12
|
-
# API key used to write and configure your Query Suggestions index.
|
|
13
|
-
attr_accessor :suggestions_indices_api_key
|
|
14
|
-
|
|
15
|
-
# API key used to read from external Algolia indices.
|
|
16
|
-
attr_accessor :external_indices_api_key
|
|
17
|
-
|
|
18
|
-
# Attribute mapping from ruby-style variable name to JSON key.
|
|
19
|
-
def self.attribute_map
|
|
20
|
-
{
|
|
21
|
-
:source_indices_api_key => :sourceIndicesAPIKey,
|
|
22
|
-
:suggestions_indices_api_key => :suggestionsIndicesAPIKey,
|
|
23
|
-
:external_indices_api_key => :externalIndicesAPIKey
|
|
24
|
-
}
|
|
25
|
-
end
|
|
26
|
-
|
|
27
|
-
# Returns all the JSON keys this model knows about
|
|
28
|
-
def self.acceptable_attributes
|
|
29
|
-
attribute_map.values
|
|
30
|
-
end
|
|
31
|
-
|
|
32
|
-
# Attribute type mapping.
|
|
33
|
-
def self.types_mapping
|
|
34
|
-
{
|
|
35
|
-
:source_indices_api_key => :String,
|
|
36
|
-
:suggestions_indices_api_key => :String,
|
|
37
|
-
:external_indices_api_key => :String
|
|
38
|
-
}
|
|
39
|
-
end
|
|
40
|
-
|
|
41
|
-
# List of attributes with nullable: true
|
|
42
|
-
def self.openapi_nullable
|
|
43
|
-
Set.new([])
|
|
44
|
-
end
|
|
45
|
-
|
|
46
|
-
# Initializes the object
|
|
47
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
|
48
|
-
def initialize(attributes = {})
|
|
49
|
-
unless attributes.is_a?(Hash)
|
|
50
|
-
raise(
|
|
51
|
-
ArgumentError,
|
|
52
|
-
"The input argument (attributes) must be a hash in `Algolia::BaseQuerySuggestionsConfigurationResponse` initialize method"
|
|
53
|
-
)
|
|
54
|
-
end
|
|
55
|
-
|
|
56
|
-
# check to see if the attribute exists and convert string to symbol for hash key
|
|
57
|
-
attributes = attributes.each_with_object({}) do |(k, v), h|
|
|
58
|
-
unless self.class.attribute_map.key?(k.to_sym)
|
|
59
|
-
raise(
|
|
60
|
-
ArgumentError,
|
|
61
|
-
"`#{k}` is not a valid attribute in `Algolia::BaseQuerySuggestionsConfigurationResponse`. Please check the name to make sure it's valid. List of attributes: " +
|
|
62
|
-
self.class.attribute_map.keys.inspect
|
|
63
|
-
)
|
|
64
|
-
end
|
|
65
|
-
|
|
66
|
-
h[k.to_sym] = v
|
|
67
|
-
end
|
|
68
|
-
|
|
69
|
-
if attributes.key?(:source_indices_api_key)
|
|
70
|
-
self.source_indices_api_key = attributes[:source_indices_api_key]
|
|
71
|
-
end
|
|
72
|
-
|
|
73
|
-
if attributes.key?(:suggestions_indices_api_key)
|
|
74
|
-
self.suggestions_indices_api_key = attributes[:suggestions_indices_api_key]
|
|
75
|
-
end
|
|
76
|
-
|
|
77
|
-
if attributes.key?(:external_indices_api_key)
|
|
78
|
-
self.external_indices_api_key = attributes[:external_indices_api_key]
|
|
79
|
-
end
|
|
80
|
-
end
|
|
81
|
-
|
|
82
|
-
# Checks equality by comparing each attribute.
|
|
83
|
-
# @param [Object] Object to be compared
|
|
84
|
-
def ==(other)
|
|
85
|
-
return true if equal?(other)
|
|
86
|
-
|
|
87
|
-
self.class == other.class &&
|
|
88
|
-
source_indices_api_key == other.source_indices_api_key &&
|
|
89
|
-
suggestions_indices_api_key == other.suggestions_indices_api_key &&
|
|
90
|
-
external_indices_api_key == other.external_indices_api_key
|
|
91
|
-
end
|
|
92
|
-
|
|
93
|
-
# @see the `==` method
|
|
94
|
-
# @param [Object] Object to be compared
|
|
95
|
-
def eql?(other)
|
|
96
|
-
self == other
|
|
97
|
-
end
|
|
98
|
-
|
|
99
|
-
# Calculates hash code according to all attributes.
|
|
100
|
-
# @return [Integer] Hash code
|
|
101
|
-
def hash
|
|
102
|
-
[source_indices_api_key, suggestions_indices_api_key, external_indices_api_key].hash
|
|
103
|
-
end
|
|
104
|
-
|
|
105
|
-
# Builds the object from hash
|
|
106
|
-
# @param [Hash] attributes Model attributes in the form of hash
|
|
107
|
-
# @return [Object] Returns the model itself
|
|
108
|
-
def self.build_from_hash(attributes)
|
|
109
|
-
return nil unless attributes.is_a?(Hash)
|
|
110
|
-
|
|
111
|
-
attributes = attributes.transform_keys(&:to_sym)
|
|
112
|
-
transformed_hash = {}
|
|
113
|
-
types_mapping.each_pair do |key, type|
|
|
114
|
-
if attributes.key?(attribute_map[key]) && attributes[attribute_map[key]].nil?
|
|
115
|
-
transformed_hash[key.to_sym] = nil
|
|
116
|
-
elsif type =~ /\AArray<(.*)>/i
|
|
117
|
-
# check to ensure the input is an array given that the attribute
|
|
118
|
-
# is documented as an array but the input is not
|
|
119
|
-
if attributes[attribute_map[key]].is_a?(Array)
|
|
120
|
-
transformed_hash[key.to_sym] = attributes[attribute_map[key]].map { |v|
|
|
121
|
-
_deserialize(::Regexp.last_match(1), v)
|
|
122
|
-
}
|
|
123
|
-
end
|
|
124
|
-
elsif !attributes[attribute_map[key]].nil?
|
|
125
|
-
transformed_hash[key.to_sym] = _deserialize(type, attributes[attribute_map[key]])
|
|
126
|
-
end
|
|
127
|
-
end
|
|
128
|
-
|
|
129
|
-
new(transformed_hash)
|
|
130
|
-
end
|
|
131
|
-
|
|
132
|
-
# Deserializes the data based on type
|
|
133
|
-
# @param string type Data type
|
|
134
|
-
# @param string value Value to be deserialized
|
|
135
|
-
# @return [Object] Deserialized data
|
|
136
|
-
def self._deserialize(type, value)
|
|
137
|
-
case type.to_sym
|
|
138
|
-
when :Time
|
|
139
|
-
Time.parse(value)
|
|
140
|
-
when :Date
|
|
141
|
-
Date.parse(value)
|
|
142
|
-
when :String
|
|
143
|
-
value.to_s
|
|
144
|
-
when :Integer
|
|
145
|
-
value.to_i
|
|
146
|
-
when :Float
|
|
147
|
-
value.to_f
|
|
148
|
-
when :Boolean
|
|
149
|
-
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
150
|
-
true
|
|
151
|
-
else
|
|
152
|
-
false
|
|
153
|
-
end
|
|
154
|
-
|
|
155
|
-
when :Object
|
|
156
|
-
# generic object (usually a Hash), return directly
|
|
157
|
-
value
|
|
158
|
-
when /\AArray<(?<inner_type>.+)>\z/
|
|
159
|
-
inner_type = Regexp.last_match[:inner_type]
|
|
160
|
-
value.map { |v| _deserialize(inner_type, v) }
|
|
161
|
-
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
162
|
-
k_type = Regexp.last_match[:k_type]
|
|
163
|
-
v_type = Regexp.last_match[:v_type]
|
|
164
|
-
{}.tap do |hash|
|
|
165
|
-
value.each do |k, v|
|
|
166
|
-
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
167
|
-
end
|
|
168
|
-
end
|
|
169
|
-
# model
|
|
170
|
-
else
|
|
171
|
-
# models (e.g. Pet) or oneOf
|
|
172
|
-
klass = Algolia::QuerySuggestions.const_get(type)
|
|
173
|
-
klass.respond_to?(:openapi_any_of) || klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass
|
|
174
|
-
.build_from_hash(value)
|
|
175
|
-
end
|
|
176
|
-
end
|
|
177
|
-
|
|
178
|
-
# Returns the string representation of the object
|
|
179
|
-
# @return [String] String presentation of the object
|
|
180
|
-
def to_s
|
|
181
|
-
to_hash.to_s
|
|
182
|
-
end
|
|
183
|
-
|
|
184
|
-
# to_body is an alias to to_hash (backward compatibility)
|
|
185
|
-
# @return [Hash] Returns the object in the form of hash
|
|
186
|
-
def to_body
|
|
187
|
-
to_hash
|
|
188
|
-
end
|
|
189
|
-
|
|
190
|
-
def to_json(*_args)
|
|
191
|
-
to_hash.to_json
|
|
192
|
-
end
|
|
193
|
-
|
|
194
|
-
# Returns the object in the form of hash
|
|
195
|
-
# @return [Hash] Returns the object in the form of hash
|
|
196
|
-
def to_hash
|
|
197
|
-
hash = {}
|
|
198
|
-
self.class.attribute_map.each_pair do |attr, param|
|
|
199
|
-
value = send(attr)
|
|
200
|
-
if value.nil?
|
|
201
|
-
is_nullable = self.class.openapi_nullable.include?(attr)
|
|
202
|
-
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
|
203
|
-
end
|
|
204
|
-
|
|
205
|
-
hash[param] = _to_hash(value)
|
|
206
|
-
end
|
|
207
|
-
|
|
208
|
-
hash
|
|
209
|
-
end
|
|
210
|
-
|
|
211
|
-
# Outputs non-array value in the form of hash
|
|
212
|
-
# For object, use to_hash. Otherwise, just return the value
|
|
213
|
-
# @param [Object] value Any valid value
|
|
214
|
-
# @return [Hash] Returns the value in the form of hash
|
|
215
|
-
def _to_hash(value)
|
|
216
|
-
if value.is_a?(Array)
|
|
217
|
-
value.compact.map { |v| _to_hash(v) }
|
|
218
|
-
elsif value.is_a?(Hash)
|
|
219
|
-
{}.tap do |hash|
|
|
220
|
-
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
221
|
-
end
|
|
222
|
-
elsif value.respond_to?(:to_hash)
|
|
223
|
-
value.to_hash
|
|
224
|
-
else
|
|
225
|
-
value
|
|
226
|
-
end
|
|
227
|
-
end
|
|
228
|
-
end
|
|
229
|
-
end
|
|
230
|
-
end
|