algolia 3.1.1 → 3.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (29) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/issue.yml +2 -16
  3. data/CHANGELOG.md +6 -0
  4. data/Gemfile.lock +1 -1
  5. data/lib/algolia/api/ingestion_client.rb +6 -0
  6. data/lib/algolia/models/analytics/{currencies_value.rb → currency_code.rb} +3 -3
  7. data/lib/algolia/models/analytics/daily_revenue.rb +1 -1
  8. data/lib/algolia/models/analytics/get_revenue.rb +1 -1
  9. data/lib/algolia/models/analytics/top_hit_with_revenue_analytics.rb +1 -1
  10. data/lib/algolia/models/analytics/top_search_with_revenue_analytics.rb +1 -1
  11. data/lib/algolia/models/ingestion/run_type.rb +3 -1
  12. data/lib/algolia/models/ingestion/source.rb +0 -2
  13. data/lib/algolia/models/ingestion/source_create.rb +0 -2
  14. data/lib/algolia/models/ingestion/source_type.rb +13 -1
  15. data/lib/algolia/models/recommend/{facets_stats.rb → facet_stats.rb} +3 -3
  16. data/lib/algolia/models/recommend/fallback_params.rb +2 -2
  17. data/lib/algolia/models/recommend/recommendations_results.rb +1 -1
  18. data/lib/algolia/models/recommend/search_params.rb +2 -2
  19. data/lib/algolia/models/recommend/search_params_object.rb +2 -2
  20. data/lib/algolia/models/search/browse_params_object.rb +2 -2
  21. data/lib/algolia/models/search/browse_response.rb +1 -1
  22. data/lib/algolia/models/search/consequence_params.rb +2 -2
  23. data/lib/algolia/models/search/{facets_stats.rb → facet_stats.rb} +3 -3
  24. data/lib/algolia/models/search/search_for_facets.rb +2 -2
  25. data/lib/algolia/models/search/search_for_hits.rb +2 -2
  26. data/lib/algolia/models/search/search_params_object.rb +2 -2
  27. data/lib/algolia/models/search/search_response.rb +1 -1
  28. data/lib/algolia/version.rb +1 -1
  29. metadata +5 -5
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 0e17bb4992fec59b9eadf29c8243f9c10f029dc9af23278a0c51230b7d9ef4bb
4
- data.tar.gz: a4f61aa37084e234676d7d6abe97a9e3febf78b3069b45eb0eeab6cb49979f6c
3
+ metadata.gz: 6c1fcfd0f638527d0a72d2a0c2f22bdb84be0550b3078f18d798c869306b0eab
4
+ data.tar.gz: e884227706bf4aaeb9bea4d5e89082c7703a0b338652f253d1899e4bf5e9f81c
5
5
  SHA512:
6
- metadata.gz: 1c508315e7ff164a28ac8e6631d5ed6036cfe815330c99b8ad08b7f74f613317e7c43354afcda3b1a3989653961758468260ddb7b05f160a51393d67af5f76a6
7
- data.tar.gz: 610361616a11645b18962e5128f39b20ed6fd9c6fec22bc6076ddb7deb84d7e3a13c01353c297d00603068539ec1be9a66f2528cdc02ed411ec50726ad5d7da5
6
+ metadata.gz: 74a3b488c0216925855926fb2e013e7ba7bb82255748f5d596c6b2baf53475cecb9421165ab1825ac8fda55c06a8f223e7a9c8b754fd58f661a5be5c0164bac6
7
+ data.tar.gz: 43f32884d0fef05486fdfb9173ec94e57acd1da2564db04d529e0b836948a84978551a1e88ffc1a5a116051049011ca3e745312643be26bf2d2f7f28ad1e3fa5
@@ -22,7 +22,7 @@ jobs:
22
22
  const title = context.payload.issue.title;
23
23
  const body = context.payload.issue.body;
24
24
 
25
- const res = await fetch('https://algolia.atlassian.net/rest/api/3/issue', {
25
+ const res = await fetch('https://algolia.atlassian.net/rest/api/2/issue', {
26
26
  method: 'POST',
27
27
  headers: {
28
28
  'Accept': 'application/json',
@@ -31,21 +31,7 @@ jobs:
31
31
  },
32
32
  body: JSON.stringify({
33
33
  fields: {
34
- description: {
35
- content: [
36
- {
37
- content: [
38
- {
39
- text: `Issue created by ${context.actor} at ${context.payload.issue.html_url} \n\n${body}`,
40
- type: 'text'
41
- }
42
- ],
43
- type: 'paragraph'
44
- }
45
- ],
46
- type: 'doc',
47
- version: 1
48
- },
34
+ description: `Issue created by ${context.actor} at [${context.payload.issue.html_url}](${context.payload.issue.html_url}) \n\n${body}`,
49
35
  issuetype: {
50
36
  id: '10001'
51
37
  },
data/CHANGELOG.md CHANGED
@@ -1,3 +1,9 @@
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
+
1
7
  ## [3.1.1](https://github.com/algolia/algoliasearch-client-ruby/compare/3.1.0...3.1.1)
2
8
 
3
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/)
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- algolia (3.1.1)
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)
@@ -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,
@@ -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.1".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.1
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-21 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
@@ -165,7 +165,7 @@ files:
165
165
  - lib/algolia/models/abtesting/status.rb
166
166
  - lib/algolia/models/abtesting/variant.rb
167
167
  - lib/algolia/models/analytics/click_position.rb
168
- - lib/algolia/models/analytics/currencies_value.rb
168
+ - lib/algolia/models/analytics/currency_code.rb
169
169
  - lib/algolia/models/analytics/daily_add_to_cart_rates.rb
170
170
  - lib/algolia/models/analytics/daily_average_clicks.rb
171
171
  - lib/algolia/models/analytics/daily_click_through_rates.rb
@@ -448,8 +448,8 @@ files:
448
448
  - lib/algolia/models/recommend/exhaustive.rb
449
449
  - lib/algolia/models/recommend/facet_filters.rb
450
450
  - lib/algolia/models/recommend/facet_ordering.rb
451
+ - lib/algolia/models/recommend/facet_stats.rb
451
452
  - lib/algolia/models/recommend/facets.rb
452
- - lib/algolia/models/recommend/facets_stats.rb
453
453
  - lib/algolia/models/recommend/fallback_params.rb
454
454
  - lib/algolia/models/recommend/fbt_model.rb
455
455
  - lib/algolia/models/recommend/get_recommend_task_response.rb
@@ -564,8 +564,8 @@ files:
564
564
  - lib/algolia/models/search/facet_filters.rb
565
565
  - lib/algolia/models/search/facet_hits.rb
566
566
  - lib/algolia/models/search/facet_ordering.rb
567
+ - lib/algolia/models/search/facet_stats.rb
567
568
  - lib/algolia/models/search/facets.rb
568
- - lib/algolia/models/search/facets_stats.rb
569
569
  - lib/algolia/models/search/fetched_index.rb
570
570
  - lib/algolia/models/search/get_api_key_response.rb
571
571
  - lib/algolia/models/search/get_dictionary_settings_response.rb