Skip to content

Commit 250b0aa

Browse files
algolia-botmillotpshortcuts
committed
fix(specs): correct query params for ingestion [skip-bc] (generated)
algolia/api-clients-automation#3830 Co-authored-by: algolia-bot <[email protected]> Co-authored-by: Pierre Millot <[email protected]> Co-authored-by: shortcuts <[email protected]>
1 parent 30546cf commit 250b0aa

File tree

3 files changed

+20
-15
lines changed

3 files changed

+20
-15
lines changed

lib/algolia/api/ingestion_client.rb

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1372,8 +1372,8 @@ def get_transformation(transformation_id, request_options = {})
13721372
# @param items_per_page [Integer] Number of items per page. (default to 10)
13731373
# @param page [Integer] Page number of the paginated API response.
13741374
# @param type [Array<AuthenticationType>] Type of authentication resource to retrieve.
1375-
# @param platform [Array<PlatformWithNone>] Ecommerce platform for which to retrieve authentication resources.
1376-
# @param sort [AuthenticationSortKeys] Property by which to sort the list of authentication resources. (default to 'createdAt')
1375+
# @param platform [Array<PlatformWithNone>] Ecommerce platform for which to retrieve authentications.
1376+
# @param sort [AuthenticationSortKeys] Property by which to sort the list of authentications. (default to 'createdAt')
13771377
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
13781378
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
13791379
# @return [Http::Response] the response
@@ -1441,8 +1441,8 @@ def list_authentications_with_http_info(
14411441
# @param items_per_page [Integer] Number of items per page. (default to 10)
14421442
# @param page [Integer] Page number of the paginated API response.
14431443
# @param type [Array<AuthenticationType>] Type of authentication resource to retrieve.
1444-
# @param platform [Array<PlatformWithNone>] Ecommerce platform for which to retrieve authentication resources.
1445-
# @param sort [AuthenticationSortKeys] Property by which to sort the list of authentication resources. (default to 'createdAt')
1444+
# @param platform [Array<PlatformWithNone>] Ecommerce platform for which to retrieve authentications.
1445+
# @param sort [AuthenticationSortKeys] Property by which to sort the list of authentications. (default to 'createdAt')
14461446
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
14471447
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
14481448
# @return [ListAuthenticationsResponse]
@@ -1472,6 +1472,7 @@ def list_authentications(
14721472
# @param page [Integer] Page number of the paginated API response.
14731473
# @param type [Array<DestinationType>] Destination type.
14741474
# @param authentication_id [Array<String>] Authentication ID used by destinations.
1475+
# @param transformation_id [String] Get the list of destinations used by a transformation.
14751476
# @param sort [DestinationSortKeys] Property by which to sort the destinations. (default to 'createdAt')
14761477
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
14771478
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
@@ -1481,6 +1482,7 @@ def list_destinations_with_http_info(
14811482
page = nil,
14821483
type = nil,
14831484
authentication_id = nil,
1485+
transformation_id = nil,
14841486
sort = nil,
14851487
order = nil,
14861488
request_options = {}
@@ -1515,6 +1517,7 @@ def list_destinations_with_http_info(
15151517
query_params[:authenticationID] = @api_client.build_collection_param(authentication_id, :csv)
15161518
end
15171519

1520+
query_params[:transformationID] = transformation_id unless transformation_id.nil?
15181521
query_params[:sort] = sort unless sort.nil?
15191522
query_params[:order] = order unless order.nil?
15201523
query_params = query_params.merge(request_options[:query_params]) unless request_options[:query_params].nil?
@@ -1544,6 +1547,7 @@ def list_destinations_with_http_info(
15441547
# @param page [Integer] Page number of the paginated API response.
15451548
# @param type [Array<DestinationType>] Destination type.
15461549
# @param authentication_id [Array<String>] Authentication ID used by destinations.
1550+
# @param transformation_id [String] Get the list of destinations used by a transformation.
15471551
# @param sort [DestinationSortKeys] Property by which to sort the destinations. (default to 'createdAt')
15481552
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
15491553
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
@@ -1553,6 +1557,7 @@ def list_destinations(
15531557
page = nil,
15541558
type = nil,
15551559
authentication_id = nil,
1560+
transformation_id = nil,
15561561
sort = nil,
15571562
order = nil,
15581563
request_options = {}
@@ -1562,6 +1567,7 @@ def list_destinations(
15621567
page,
15631568
type,
15641569
authentication_id,
1570+
transformation_id,
15651571
sort,
15661572
order,
15671573
request_options
@@ -1829,7 +1835,7 @@ def list_runs(
18291835
# @param items_per_page [Integer] Number of items per page. (default to 10)
18301836
# @param page [Integer] Page number of the paginated API response.
18311837
# @param type [Array<SourceType>] Source type. Some sources require authentication.
1832-
# @param authentication_id [Array<String>] Authentication IDs of the sources to retrieve. &#39;none&#39; returns sources that doesn&#39;t have an authentication resource.
1838+
# @param authentication_id [Array<String>] Authentication IDs of the sources to retrieve. &#39;none&#39; returns sources that doesn&#39;t have an authentication.
18331839
# @param sort [SourceSortKeys] Property by which to sort the list of sources. (default to 'createdAt')
18341840
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
18351841
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
@@ -1901,7 +1907,7 @@ def list_sources_with_http_info(
19011907
# @param items_per_page [Integer] Number of items per page. (default to 10)
19021908
# @param page [Integer] Page number of the paginated API response.
19031909
# @param type [Array<SourceType>] Source type. Some sources require authentication.
1904-
# @param authentication_id [Array<String>] Authentication IDs of the sources to retrieve. &#39;none&#39; returns sources that doesn&#39;t have an authentication resource.
1910+
# @param authentication_id [Array<String>] Authentication IDs of the sources to retrieve. &#39;none&#39; returns sources that doesn&#39;t have an authentication.
19051911
# @param sort [SourceSortKeys] Property by which to sort the list of sources. (default to 'createdAt')
19061912
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
19071913
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
@@ -2185,7 +2191,7 @@ def list_tasks_v1(
21852191
# - editSettings
21862192
# @param items_per_page [Integer] Number of items per page. (default to 10)
21872193
# @param page [Integer] Page number of the paginated API response.
2188-
# @param sort [SortKeys] Property by which to sort the list. (default to 'desc')
2194+
# @param sort [TransformationSortKeys] Property by which to sort the list of transformations. (default to 'createdAt')
21892195
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
21902196
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
21912197
# @return [Http::Response] the response
@@ -2248,7 +2254,7 @@ def list_transformations_with_http_info(
22482254
# - editSettings
22492255
# @param items_per_page [Integer] Number of items per page. (default to 10)
22502256
# @param page [Integer] Page number of the paginated API response.
2251-
# @param sort [SortKeys] Property by which to sort the list. (default to 'desc')
2257+
# @param sort [TransformationSortKeys] Property by which to sort the list of transformations. (default to 'createdAt')
22522258
# @param order [OrderKeys] Sort order of the response, ascending or descending. (default to 'desc')
22532259
# @param request_options: The request options to send along with the query, they will be merged with the transporter base parameters (headers, query params, timeouts, etc.). (optional)
22542260
# @return [ListTransformationsResponse]

lib/algolia/models/ingestion/authentication_sort_keys.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ module Algolia
77
module Ingestion
88
class AuthenticationSortKeys
99
NAME = "name".freeze
10-
AUTH_TYPE = "auth_type".freeze
10+
TYPE = "type".freeze
1111
PLATFORM = "platform".freeze
1212
UPDATED_AT = "updatedAt".freeze
1313
CREATED_AT = "createdAt".freeze
1414

1515
def self.all_vars
16-
@all_vars ||= [NAME, AUTH_TYPE, PLATFORM, UPDATED_AT, CREATED_AT].freeze
16+
@all_vars ||= [NAME, TYPE, PLATFORM, UPDATED_AT, CREATED_AT].freeze
1717
end
1818

1919
# Builds the enum from string

lib/algolia/models/ingestion/sort_keys.rb renamed to lib/algolia/models/ingestion/transformation_sort_keys.rb

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,14 +5,13 @@
55

66
module Algolia
77
module Ingestion
8-
class SortKeys
8+
class TransformationSortKeys
99
NAME = "name".freeze
10-
TYPE = "type".freeze
1110
UPDATED_AT = "updatedAt".freeze
1211
CREATED_AT = "createdAt".freeze
1312

1413
def self.all_vars
15-
@all_vars ||= [NAME, TYPE, UPDATED_AT, CREATED_AT].freeze
14+
@all_vars ||= [NAME, UPDATED_AT, CREATED_AT].freeze
1615
end
1716

1817
# Builds the enum from string
@@ -26,8 +25,8 @@ def self.build_from_hash(value)
2625
# @param [String] The enum value in the form of the string
2726
# @return [String] The enum value
2827
def build_from_hash(value)
29-
return value if SortKeys.all_vars.include?(value)
30-
raise "Invalid ENUM value #{value} for class #SortKeys"
28+
return value if TransformationSortKeys.all_vars.include?(value)
29+
raise "Invalid ENUM value #{value} for class #TransformationSortKeys"
3130
end
3231
end
3332
end

0 commit comments

Comments
 (0)