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 0c0dbf8 commit 1b559b4
Show file tree
Hide file tree
Showing 3 changed files with 31 additions and 34 deletions.
37 changes: 20 additions & 17 deletions algoliasearch/Clients/IngestionClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -900,8 +900,8 @@ public interface IIngestionClient
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Type of authentication resource to retrieve. (optional)</param>
/// <param name="platform">Ecommerce platform for which to retrieve authentication resources. (optional)</param>
/// <param name="sort">Property by which to sort the list of authentication resources. (optional)</param>
/// <param name="platform">Ecommerce platform for which to retrieve authentications. (optional)</param>
/// <param name="sort">Property by which to sort the list of authentications. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
Expand All @@ -922,8 +922,8 @@ public interface IIngestionClient
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Type of authentication resource to retrieve. (optional)</param>
/// <param name="platform">Ecommerce platform for which to retrieve authentication resources. (optional)</param>
/// <param name="sort">Property by which to sort the list of authentication resources. (optional)</param>
/// <param name="platform">Ecommerce platform for which to retrieve authentications. (optional)</param>
/// <param name="sort">Property by which to sort the list of authentications. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
Expand All @@ -945,6 +945,7 @@ public interface IIngestionClient
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Destination type. (optional)</param>
/// <param name="authenticationID">Authentication ID used by destinations. (optional)</param>
/// <param name="transformationID">Get the list of destinations used by a transformation. (optional)</param>
/// <param name="sort">Property by which to sort the destinations. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
Expand All @@ -953,7 +954,7 @@ public interface IIngestionClient
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
/// <returns>Task of ListDestinationsResponse</returns>
Task<ListDestinationsResponse> ListDestinationsAsync(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);
Task<ListDestinationsResponse> ListDestinationsAsync(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, string transformationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);

/// <summary>
/// Retrieves a list of destinations. (Synchronous version)
Expand All @@ -967,6 +968,7 @@ public interface IIngestionClient
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Destination type. (optional)</param>
/// <param name="authenticationID">Authentication ID used by destinations. (optional)</param>
/// <param name="transformationID">Get the list of destinations used by a transformation. (optional)</param>
/// <param name="sort">Property by which to sort the destinations. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
Expand All @@ -975,7 +977,7 @@ public interface IIngestionClient
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
/// <returns>ListDestinationsResponse</returns>
ListDestinationsResponse ListDestinations(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);
ListDestinationsResponse ListDestinations(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, string transformationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);

/// <summary>
/// Retrieves a list of events for a task run, identified by it's ID.
Expand Down Expand Up @@ -1088,7 +1090,7 @@ public interface IIngestionClient
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Source type. Some sources require authentication. (optional)</param>
/// <param name="authenticationID">Authentication IDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication resource. (optional)</param>
/// <param name="authenticationID">Authentication IDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication. (optional)</param>
/// <param name="sort">Property by which to sort the list of sources. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
Expand All @@ -1110,7 +1112,7 @@ public interface IIngestionClient
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="type">Source type. Some sources require authentication. (optional)</param>
/// <param name="authenticationID">Authentication IDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication resource. (optional)</param>
/// <param name="authenticationID">Authentication IDs of the sources to retrieve. 'none' returns sources that doesn't have an authentication. (optional)</param>
/// <param name="sort">Property by which to sort the list of sources. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
Expand Down Expand Up @@ -1231,15 +1233,15 @@ public interface IIngestionClient
/// - editSettings
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="sort">Property by which to sort the list. (optional)</param>
/// <param name="sort">Property by which to sort the list of transformations. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <exception cref="ArgumentException">Thrown when arguments are not correct</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
/// <returns>Task of ListTransformationsResponse</returns>
Task<ListTransformationsResponse> ListTransformationsAsync(int? itemsPerPage = default, int? page = default, SortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);
Task<ListTransformationsResponse> ListTransformationsAsync(int? itemsPerPage = default, int? page = default, TransformationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);

/// <summary>
/// Retrieves a list of transformations. (Synchronous version)
Expand All @@ -1251,15 +1253,15 @@ public interface IIngestionClient
/// - editSettings
/// <param name="itemsPerPage">Number of items per page. (optional, default to 10)</param>
/// <param name="page">Page number of the paginated API response. (optional)</param>
/// <param name="sort">Property by which to sort the list. (optional)</param>
/// <param name="sort">Property by which to sort the list of transformations. (optional)</param>
/// <param name="order">Sort order of the response, ascending or descending. (optional)</param>
/// <param name="options">Add extra http header or query parameters to Algolia.</param>
/// <param name="cancellationToken">Cancellation Token to cancel the request.</param>
/// <exception cref="ArgumentException">Thrown when arguments are not correct</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
/// <returns>ListTransformationsResponse</returns>
ListTransformationsResponse ListTransformations(int? itemsPerPage = default, int? page = default, SortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);
ListTransformationsResponse ListTransformations(int? itemsPerPage = default, int? page = default, TransformationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default);

/// <summary>
/// Push a `batch` request payload through the Pipeline. You can check the status of task pushes with the observability endpoints.
Expand Down Expand Up @@ -2635,7 +2637,7 @@ public ListAuthenticationsResponse ListAuthentications(int? itemsPerPage = defau


/// <inheritdoc />
public async Task<ListDestinationsResponse> ListDestinationsAsync(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default)
public async Task<ListDestinationsResponse> ListDestinationsAsync(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, string transformationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default)
{
var requestOptions = new InternalRequestOptions(options);

Expand All @@ -2644,15 +2646,16 @@ public async Task<ListDestinationsResponse> ListDestinationsAsync(int? itemsPerP
requestOptions.AddQueryParameter("page", page);
requestOptions.AddQueryParameter("type", type);
requestOptions.AddQueryParameter("authenticationID", authenticationID);
requestOptions.AddQueryParameter("transformationID", transformationID);
requestOptions.AddQueryParameter("sort", sort);
requestOptions.AddQueryParameter("order", order);
return await _transport.ExecuteRequestAsync<ListDestinationsResponse>(new HttpMethod("GET"), "/1/destinations", requestOptions, cancellationToken).ConfigureAwait(false);
}


/// <inheritdoc />
public ListDestinationsResponse ListDestinations(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default) =>
AsyncHelper.RunSync(() => ListDestinationsAsync(itemsPerPage, page, type, authenticationID, sort, order, options, cancellationToken));
public ListDestinationsResponse ListDestinations(int? itemsPerPage = default, int? page = default, List<DestinationType> type = default, List<string> authenticationID = default, string transformationID = default, DestinationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default) =>
AsyncHelper.RunSync(() => ListDestinationsAsync(itemsPerPage, page, type, authenticationID, transformationID, sort, order, options, cancellationToken));


/// <inheritdoc />
Expand Down Expand Up @@ -2777,7 +2780,7 @@ public ListTasksResponseV1 ListTasksV1(int? itemsPerPage = default, int? page =


/// <inheritdoc />
public async Task<ListTransformationsResponse> ListTransformationsAsync(int? itemsPerPage = default, int? page = default, SortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default)
public async Task<ListTransformationsResponse> ListTransformationsAsync(int? itemsPerPage = default, int? page = default, TransformationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default)
{
var requestOptions = new InternalRequestOptions(options);

Expand All @@ -2791,7 +2794,7 @@ public async Task<ListTransformationsResponse> ListTransformationsAsync(int? ite


/// <inheritdoc />
public ListTransformationsResponse ListTransformations(int? itemsPerPage = default, int? page = default, SortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default) =>
public ListTransformationsResponse ListTransformations(int? itemsPerPage = default, int? page = default, TransformationSortKeys? sort = default, OrderKeys? order = default, RequestOptions options = null, CancellationToken cancellationToken = default) =>
AsyncHelper.RunSync(() => ListTransformationsAsync(itemsPerPage, page, sort, order, options, cancellationToken));


Expand Down
10 changes: 5 additions & 5 deletions algoliasearch/Models/Ingestion/AuthenticationSortKeys.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,9 +12,9 @@
namespace Algolia.Search.Models.Ingestion;

/// <summary>
/// Property by which to sort the list of authentication resources.
/// Property by which to sort the list of authentications.
/// </summary>
/// <value>Property by which to sort the list of authentication resources.</value>
/// <value>Property by which to sort the list of authentications.</value>
[JsonConverter(typeof(Serializer.JsonStringEnumConverter<AuthenticationSortKeys>))]
public enum AuthenticationSortKeys
{
Expand All @@ -25,10 +25,10 @@ public enum AuthenticationSortKeys
Name = 1,

/// <summary>
/// Enum AuthType for value: auth_type
/// Enum Type for value: type
/// </summary>
[JsonPropertyName("auth_type")]
AuthType = 2,
[JsonPropertyName("type")]
Type = 2,

/// <summary>
/// Enum Platform for value: platform
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,34 +12,28 @@
namespace Algolia.Search.Models.Ingestion;

/// <summary>
/// Property by which to sort the list.
/// Property by which to sort the list of transformations.
/// </summary>
/// <value>Property by which to sort the list.</value>
[JsonConverter(typeof(Serializer.JsonStringEnumConverter<SortKeys>))]
public enum SortKeys
/// <value>Property by which to sort the list of transformations.</value>
[JsonConverter(typeof(Serializer.JsonStringEnumConverter<TransformationSortKeys>))]
public enum TransformationSortKeys
{
/// <summary>
/// Enum Name for value: name
/// </summary>
[JsonPropertyName("name")]
Name = 1,

/// <summary>
/// Enum Type for value: type
/// </summary>
[JsonPropertyName("type")]
Type = 2,

/// <summary>
/// Enum UpdatedAt for value: updatedAt
/// </summary>
[JsonPropertyName("updatedAt")]
UpdatedAt = 3,
UpdatedAt = 2,

/// <summary>
/// Enum CreatedAt for value: createdAt
/// </summary>
[JsonPropertyName("createdAt")]
CreatedAt = 4
CreatedAt = 3
}

0 comments on commit 1b559b4

Please sign in to comment.