Skip to content

Commit

Permalink
fix(specs): correct query params for ingestion [skip-bc] (generated)
Browse files Browse the repository at this point in the history
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]>
  • Loading branch information
3 people committed Sep 25, 2024
1 parent 46bf93d commit c3416d3
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 16 deletions.
27 changes: 17 additions & 10 deletions Sources/Ingestion/IngestionClient.swift
Original file line number Diff line number Diff line change
Expand Up @@ -1634,8 +1634,8 @@ open class IngestionClient {
/// - parameter itemsPerPage: (query) Number of items per page. (optional, default to 10)
/// - parameter page: (query) Page number of the paginated API response. (optional)
/// - parameter type: (query) Type of authentication resource to retrieve. (optional)
/// - parameter platform: (query) Ecommerce platform for which to retrieve authentication resources. (optional)
/// - parameter sort: (query) Property by which to sort the list of authentication resources. (optional)
/// - parameter platform: (query) Ecommerce platform for which to retrieve authentications. (optional)
/// - parameter sort: (query) Property by which to sort the list of authentications. (optional)
/// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
/// - returns: ListAuthenticationsResponse
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
Expand Down Expand Up @@ -1677,9 +1677,9 @@ open class IngestionClient {
//
// - parameter type: (query) Type of authentication resource to retrieve. (optional)
//
// - parameter platform: (query) Ecommerce platform for which to retrieve authentication resources. (optional)
// - parameter platform: (query) Ecommerce platform for which to retrieve authentications. (optional)
//
// - parameter sort: (query) Property by which to sort the list of authentication resources. (optional)
// - parameter sort: (query) Property by which to sort the list of authentications. (optional)
//
// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
// - returns: RequestBuilder<ListAuthenticationsResponse>
Expand Down Expand Up @@ -1720,6 +1720,7 @@ open class IngestionClient {
/// - parameter page: (query) Page number of the paginated API response. (optional)
/// - parameter type: (query) Destination type. (optional)
/// - parameter authenticationID: (query) Authentication ID used by destinations. (optional)
/// - parameter transformationID: (query) Get the list of destinations used by a transformation. (optional)
/// - parameter sort: (query) Property by which to sort the destinations. (optional)
/// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
/// - returns: ListDestinationsResponse
Expand All @@ -1729,6 +1730,7 @@ open class IngestionClient {
page: Int? = nil,
type: [DestinationType]? = nil,
authenticationID: [String]? = nil,
transformationID: String? = nil,
sort: DestinationSortKeys? = nil,
order: OrderKeys? = nil,
requestOptions: RequestOptions? = nil
Expand All @@ -1738,6 +1740,7 @@ open class IngestionClient {
page: page,
type: type,
authenticationID: authenticationID,
transformationID: transformationID,
sort: sort,
order: order,
requestOptions: requestOptions
Expand All @@ -1764,6 +1767,8 @@ open class IngestionClient {
//
// - parameter authenticationID: (query) Authentication ID used by destinations. (optional)
//
// - parameter transformationID: (query) Get the list of destinations used by a transformation. (optional)
//
// - parameter sort: (query) Property by which to sort the destinations. (optional)
//
// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
Expand All @@ -1774,6 +1779,7 @@ open class IngestionClient {
page: Int? = nil,
type: [DestinationType]? = nil,
authenticationID: [String]? = nil,
transformationID: String? = nil,
sort: DestinationSortKeys? = nil,
order: OrderKeys? = nil,
requestOptions userRequestOptions: RequestOptions? = nil
Expand All @@ -1785,6 +1791,7 @@ open class IngestionClient {
"page": page?.encodeToJSON(),
"type": type?.encodeToJSON(),
"authenticationID": authenticationID?.encodeToJSON(),
"transformationID": transformationID?.encodeToJSON(),
"sort": sort?.encodeToJSON(),
"order": order?.encodeToJSON(),
]
Expand Down Expand Up @@ -2036,7 +2043,7 @@ open class IngestionClient {
/// - parameter page: (query) Page number of the paginated API response. (optional)
/// - parameter type: (query) Source type. Some sources require authentication. (optional)
/// - parameter authenticationID: (query) Authentication IDs of the sources to retrieve. 'none' returns sources that
/// doesn't have an authentication resource. (optional)
/// doesn't have an authentication. (optional)
/// - parameter sort: (query) Property by which to sort the list of sources. (optional)
/// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
/// - returns: ListSourcesResponse
Expand Down Expand Up @@ -2080,7 +2087,7 @@ open class IngestionClient {
// - parameter type: (query) Source type. Some sources require authentication. (optional)
//
// - parameter authenticationID: (query) Authentication IDs of the sources to retrieve. 'none' returns sources that
// doesn't have an authentication resource. (optional)
// doesn't have an authentication. (optional)
//
// - parameter sort: (query) Property by which to sort the list of sources. (optional)
//
Expand Down Expand Up @@ -2333,14 +2340,14 @@ open class IngestionClient {

/// - parameter itemsPerPage: (query) Number of items per page. (optional, default to 10)
/// - parameter page: (query) Page number of the paginated API response. (optional)
/// - parameter sort: (query) Property by which to sort the list. (optional)
/// - parameter sort: (query) Property by which to sort the list of transformations. (optional)
/// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
/// - returns: ListTransformationsResponse
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
open func listTransformations(
itemsPerPage: Int? = nil,
page: Int? = nil,
sort: SortKeys? = nil,
sort: TransformationSortKeys? = nil,
order: OrderKeys? = nil,
requestOptions: RequestOptions? = nil
) async throws -> ListTransformationsResponse {
Expand Down Expand Up @@ -2369,15 +2376,15 @@ open class IngestionClient {
//
// - parameter page: (query) Page number of the paginated API response. (optional)
//
// - parameter sort: (query) Property by which to sort the list. (optional)
// - parameter sort: (query) Property by which to sort the list of transformations. (optional)
//
// - parameter order: (query) Sort order of the response, ascending or descending. (optional)
// - returns: RequestBuilder<ListTransformationsResponse>

open func listTransformationsWithHTTPInfo(
itemsPerPage: Int? = nil,
page: Int? = nil,
sort: SortKeys? = nil,
sort: TransformationSortKeys? = nil,
order: OrderKeys? = nil,
requestOptions userRequestOptions: RequestOptions? = nil
) async throws -> Response<ListTransformationsResponse> {
Expand Down
4 changes: 2 additions & 2 deletions Sources/Ingestion/Models/AuthenticationSortKeys.swift
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,10 @@ import Foundation
import Core
#endif

/// Property by which to sort the list of authentication resources.
/// Property by which to sort the list of authentications.
public enum AuthenticationSortKeys: String, Codable, CaseIterable {
case name
case authType = "auth_type"
case type
case platform
case updatedAt
case createdAt
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,11 @@ import Foundation
import Core
#endif

/// Property by which to sort the list.
public enum SortKeys: String, Codable, CaseIterable {
/// Property by which to sort the list of transformations.
public enum TransformationSortKeys: String, Codable, CaseIterable {
case name
case type
case updatedAt
case createdAt
}

extension SortKeys: Hashable {}
extension TransformationSortKeys: Hashable {}

0 comments on commit c3416d3

Please sign in to comment.