Skip to content

Commit 1ed8dad

Browse files
fix(specs): returns an response [skip-bc] (#4107) (generated) [skip ci]
Co-authored-by: Clément Vannicatte <[email protected]>
1 parent ab0b923 commit 1ed8dad

File tree

13 files changed

+38
-38
lines changed

13 files changed

+38
-38
lines changed

clients/algoliasearch-client-csharp/algoliasearch/Clients/SearchClient.cs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -514,8 +514,8 @@ public partial interface ISearchClient
514514
/// <exception cref="ArgumentException">Thrown when arguments are not correct</exception>
515515
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
516516
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
517-
/// <returns>Task of DeletedAtResponse</returns>
518-
Task<DeletedAtResponse> DeleteByAsync(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default);
517+
/// <returns>Task of UpdatedAtResponse</returns>
518+
Task<UpdatedAtResponse> DeleteByAsync(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default);
519519

520520
/// <summary>
521521
/// This operation doesn't accept empty queries or filters. It's more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](#tag/Records/operation/batch). (Synchronous version)
@@ -530,8 +530,8 @@ public partial interface ISearchClient
530530
/// <exception cref="ArgumentException">Thrown when arguments are not correct</exception>
531531
/// <exception cref="Algolia.Search.Exceptions.AlgoliaApiException">Thrown when the API call was rejected by Algolia</exception>
532532
/// <exception cref="Algolia.Search.Exceptions.AlgoliaUnreachableHostException">Thrown when the client failed to call the endpoint</exception>
533-
/// <returns>DeletedAtResponse</returns>
534-
DeletedAtResponse DeleteBy(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default);
533+
/// <returns>UpdatedAtResponse</returns>
534+
UpdatedAtResponse DeleteBy(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default);
535535

536536
/// <summary>
537537
/// Deletes an index and all its settings. - Deleting an index doesn't delete its analytics data. - If you try to delete a non-existing index, the operation is ignored without warning. - If the index you want to delete has replica indices, the replicas become independent indices. - If the index you want to delete is a replica index, you must first unlink it from its primary index before you can delete it. For more information, see [Delete replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/deleting-replicas/).
@@ -2374,7 +2374,7 @@ public DeleteApiKeyResponse DeleteApiKey(string key, RequestOptions options = nu
23742374

23752375

23762376
/// <inheritdoc />
2377-
public async Task<DeletedAtResponse> DeleteByAsync(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default)
2377+
public async Task<UpdatedAtResponse> DeleteByAsync(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default)
23782378
{
23792379

23802380
if (indexName == null)
@@ -2389,12 +2389,12 @@ public async Task<DeletedAtResponse> DeleteByAsync(string indexName, DeleteByPar
23892389
requestOptions.PathParameters.Add("indexName", QueryStringHelper.ParameterToString(indexName));
23902390

23912391
requestOptions.Data = deleteByParams;
2392-
return await _transport.ExecuteRequestAsync<DeletedAtResponse>(new HttpMethod("POST"), "/1/indexes/{indexName}/deleteByQuery", requestOptions, cancellationToken).ConfigureAwait(false);
2392+
return await _transport.ExecuteRequestAsync<UpdatedAtResponse>(new HttpMethod("POST"), "/1/indexes/{indexName}/deleteByQuery", requestOptions, cancellationToken).ConfigureAwait(false);
23932393
}
23942394

23952395

23962396
/// <inheritdoc />
2397-
public DeletedAtResponse DeleteBy(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default) =>
2397+
public UpdatedAtResponse DeleteBy(string indexName, DeleteByParams deleteByParams, RequestOptions options = null, CancellationToken cancellationToken = default) =>
23982398
AsyncHelper.RunSync(() => DeleteByAsync(indexName, deleteByParams, options, cancellationToken));
23992399

24002400

clients/algoliasearch-client-dart/packages/client_search/lib/src/api/search_client.dart

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -673,7 +673,7 @@ final class SearchClient implements ApiClient {
673673
/// * [indexName] Name of the index on which to perform the operation.
674674
/// * [deleteByParams]
675675
/// * [requestOptions] additional request configuration.
676-
Future<DeletedAtResponse> deleteBy({
676+
Future<UpdatedAtResponse> deleteBy({
677677
required String indexName,
678678
required DeleteByParams deleteByParams,
679679
RequestOptions? requestOptions,
@@ -692,9 +692,9 @@ final class SearchClient implements ApiClient {
692692
request: request,
693693
options: requestOptions,
694694
);
695-
return deserialize<DeletedAtResponse, DeletedAtResponse>(
695+
return deserialize<UpdatedAtResponse, UpdatedAtResponse>(
696696
response,
697-
'DeletedAtResponse',
697+
'UpdatedAtResponse',
698698
growable: true,
699699
);
700700
}

clients/algoliasearch-client-go/algolia/search/api_search.go

Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

clients/algoliasearch-client-java/algoliasearch/src/main/java/com/algolia/api/SearchClient.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1490,7 +1490,7 @@ public CompletableFuture<DeleteApiKeyResponse> deleteApiKeyAsync(@Nonnull String
14901490
* the transporter requestOptions.
14911491
* @throws AlgoliaRuntimeException If it fails to process the API call
14921492
*/
1493-
public DeletedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams, RequestOptions requestOptions)
1493+
public UpdatedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams, RequestOptions requestOptions)
14941494
throws AlgoliaRuntimeException {
14951495
return LaunderThrowable.await(deleteByAsync(indexName, deleteByParams, requestOptions));
14961496
}
@@ -1504,7 +1504,7 @@ public DeletedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByPa
15041504
* @param deleteByParams (required)
15051505
* @throws AlgoliaRuntimeException If it fails to process the API call
15061506
*/
1507-
public DeletedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams) throws AlgoliaRuntimeException {
1507+
public UpdatedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams) throws AlgoliaRuntimeException {
15081508
return this.deleteBy(indexName, deleteByParams, null);
15091509
}
15101510

@@ -1519,7 +1519,7 @@ public DeletedAtResponse deleteBy(@Nonnull String indexName, @Nonnull DeleteByPa
15191519
* the transporter requestOptions.
15201520
* @throws AlgoliaRuntimeException If it fails to process the API call
15211521
*/
1522-
public CompletableFuture<DeletedAtResponse> deleteByAsync(
1522+
public CompletableFuture<UpdatedAtResponse> deleteByAsync(
15231523
@Nonnull String indexName,
15241524
@Nonnull DeleteByParams deleteByParams,
15251525
RequestOptions requestOptions
@@ -1533,7 +1533,7 @@ public CompletableFuture<DeletedAtResponse> deleteByAsync(
15331533
.setMethod("POST")
15341534
.setBody(deleteByParams)
15351535
.build();
1536-
return executeAsync(request, requestOptions, new TypeReference<DeletedAtResponse>() {});
1536+
return executeAsync(request, requestOptions, new TypeReference<UpdatedAtResponse>() {});
15371537
}
15381538

15391539
/**
@@ -1545,7 +1545,7 @@ public CompletableFuture<DeletedAtResponse> deleteByAsync(
15451545
* @param deleteByParams (required)
15461546
* @throws AlgoliaRuntimeException If it fails to process the API call
15471547
*/
1548-
public CompletableFuture<DeletedAtResponse> deleteByAsync(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams)
1548+
public CompletableFuture<UpdatedAtResponse> deleteByAsync(@Nonnull String indexName, @Nonnull DeleteByParams deleteByParams)
15491549
throws AlgoliaRuntimeException {
15501550
return this.deleteByAsync(indexName, deleteByParams, null);
15511551
}

clients/algoliasearch-client-javascript/packages/client-search/src/searchClient.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1298,7 +1298,7 @@ export function createSearchClient({
12981298
deleteBy(
12991299
{ indexName, deleteByParams }: DeleteByProps,
13001300
requestOptions?: RequestOptions,
1301-
): Promise<DeletedAtResponse> {
1301+
): Promise<UpdatedAtResponse> {
13021302
if (!indexName) {
13031303
throw new Error('Parameter `indexName` is required when calling `deleteBy`.');
13041304
}

clients/algoliasearch-client-kotlin/client/src/commonMain/kotlin/com/algolia/client/api/SearchClient.kt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -394,7 +394,7 @@ public class SearchClient(
394394
* @param deleteByParams
395395
* @param requestOptions additional request configuration.
396396
*/
397-
public suspend fun deleteBy(indexName: String, deleteByParams: DeleteByParams, requestOptions: RequestOptions? = null): DeletedAtResponse {
397+
public suspend fun deleteBy(indexName: String, deleteByParams: DeleteByParams, requestOptions: RequestOptions? = null): UpdatedAtResponse {
398398
require(indexName.isNotBlank()) { "Parameter `indexName` is required when calling `deleteBy`." }
399399
val requestConfig = RequestConfig(
400400
method = RequestMethod.POST,

clients/algoliasearch-client-php/lib/Api/SearchClient.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -824,7 +824,7 @@ public function deleteApiKey($key, $requestOptions = [])
824824
*
825825
* @param array $requestOptions the requestOptions to send along with the query, they will be merged with the transporter requestOptions
826826
*
827-
* @return \Algolia\AlgoliaSearch\Model\Search\DeletedAtResponse|array<string, mixed>
827+
* @return \Algolia\AlgoliaSearch\Model\Search\UpdatedAtResponse|array<string, mixed>
828828
*/
829829
public function deleteBy($indexName, $deleteByParams, $requestOptions = [])
830830
{

clients/algoliasearch-client-python/algoliasearch/search/client.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1919,7 +1919,7 @@ async def delete_by(
19191919
],
19201920
delete_by_params: Union[DeleteByParams, dict[str, Any]],
19211921
request_options: Optional[Union[dict, RequestOptions]] = None,
1922-
) -> DeletedAtResponse:
1922+
) -> UpdatedAtResponse:
19231923
"""
19241924
This operation doesn't accept empty queries or filters. It's more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](#tag/Records/operation/batch).
19251925
@@ -1931,12 +1931,12 @@ async def delete_by(
19311931
:param delete_by_params: (required)
19321932
:type delete_by_params: DeleteByParams
19331933
: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)
1934-
:return: Returns the deserialized response in a 'DeletedAtResponse' result object.
1934+
:return: Returns the deserialized response in a 'UpdatedAtResponse' result object.
19351935
"""
19361936
resp = await self.delete_by_with_http_info(
19371937
index_name, delete_by_params, request_options
19381938
)
1939-
return resp.deserialize(DeletedAtResponse, resp.raw_data)
1939+
return resp.deserialize(UpdatedAtResponse, resp.raw_data)
19401940

19411941
async def delete_index_with_http_info(
19421942
self,
@@ -6919,7 +6919,7 @@ def delete_by(
69196919
],
69206920
delete_by_params: Union[DeleteByParams, dict[str, Any]],
69216921
request_options: Optional[Union[dict, RequestOptions]] = None,
6922-
) -> DeletedAtResponse:
6922+
) -> UpdatedAtResponse:
69236923
"""
69246924
This operation doesn't accept empty queries or filters. It's more efficient to get a list of object IDs with the [`browse` operation](#tag/Search/operation/browse), and then delete the records using the [`batch` operation](#tag/Records/operation/batch).
69256925
@@ -6931,12 +6931,12 @@ def delete_by(
69316931
:param delete_by_params: (required)
69326932
:type delete_by_params: DeleteByParams
69336933
: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)
6934-
:return: Returns the deserialized response in a 'DeletedAtResponse' result object.
6934+
:return: Returns the deserialized response in a 'UpdatedAtResponse' result object.
69356935
"""
69366936
resp = self.delete_by_with_http_info(
69376937
index_name, delete_by_params, request_options
69386938
)
6939-
return resp.deserialize(DeletedAtResponse, resp.raw_data)
6939+
return resp.deserialize(UpdatedAtResponse, resp.raw_data)
69406940

69416941
def delete_index_with_http_info(
69426942
self,

clients/algoliasearch-client-ruby/lib/algolia/api/search_client.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -860,10 +860,10 @@ def delete_by_with_http_info(index_name, delete_by_params, request_options = {})
860860
# @param index_name [String] Name of the index on which to perform the operation. (required)
861861
# @param delete_by_params [DeleteByParams] (required)
862862
# @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)
863-
# @return [DeletedAtResponse]
863+
# @return [UpdatedAtResponse]
864864
def delete_by(index_name, delete_by_params, request_options = {})
865865
response = delete_by_with_http_info(index_name, delete_by_params, request_options)
866-
@api_client.deserialize(response.body, request_options[:debug_return_type] || "Search::DeletedAtResponse")
866+
@api_client.deserialize(response.body, request_options[:debug_return_type] || "Search::UpdatedAtResponse")
867867
end
868868

869869
# Deletes an index and all its settings. - Deleting an index doesn't delete its analytics data. - If you try to delete a non-existing index, the operation is ignored without warning. - If the index you want to delete has replica indices, the replicas become independent indices. - If the index you want to delete is a replica index, you must first unlink it from its primary index before you can delete it. For more information, see [Delete replica indices](https://www.algolia.com/doc/guides/managing-results/refine-results/sorting/how-to/deleting-replicas/).

clients/algoliasearch-client-scala/src/main/scala/algoliasearch/api/SearchClient.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -546,7 +546,7 @@ class SearchClient(
546546
*/
547547
def deleteBy(indexName: String, deleteByParams: DeleteByParams, requestOptions: Option[RequestOptions] = None)(
548548
implicit ec: ExecutionContext
549-
): Future[DeletedAtResponse] = Future {
549+
): Future[UpdatedAtResponse] = Future {
550550
requireNotNull(indexName, "Parameter `indexName` is required when calling `deleteBy`.")
551551
requireNotNull(deleteByParams, "Parameter `deleteByParams` is required when calling `deleteBy`.")
552552

@@ -556,7 +556,7 @@ class SearchClient(
556556
.withPath(s"/1/indexes/${escape(indexName)}/deleteByQuery")
557557
.withBody(deleteByParams)
558558
.build()
559-
execute[DeletedAtResponse](request, requestOptions)
559+
execute[UpdatedAtResponse](request, requestOptions)
560560
}
561561

562562
/** Deletes an index and all its settings. - Deleting an index doesn't delete its analytics data. - If you try to

clients/algoliasearch-client-swift/Sources/Search/SearchClient.swift

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1027,14 +1027,14 @@ open class SearchClient {
10271027

10281028
/// - parameter indexName: (path) Name of the index on which to perform the operation.
10291029
/// - parameter deleteByParams: (body)
1030-
/// - returns: SearchDeletedAtResponse
1030+
/// - returns: UpdatedAtResponse
10311031
@available(macOS 10.15, iOS 13.0, tvOS 13.0, watchOS 6.0, *)
10321032
open func deleteBy(
10331033
indexName: String,
10341034
deleteByParams: DeleteByParams,
10351035
requestOptions: RequestOptions? = nil
1036-
) async throws -> SearchDeletedAtResponse {
1037-
let response: Response<SearchDeletedAtResponse> = try await deleteByWithHTTPInfo(
1036+
) async throws -> UpdatedAtResponse {
1037+
let response: Response<UpdatedAtResponse> = try await deleteByWithHTTPInfo(
10381038
indexName: indexName,
10391039
deleteByParams: deleteByParams,
10401040
requestOptions: requestOptions
@@ -1056,13 +1056,13 @@ open class SearchClient {
10561056
// - parameter indexName: (path) Name of the index on which to perform the operation.
10571057
//
10581058
// - parameter deleteByParams: (body)
1059-
// - returns: RequestBuilder<SearchDeletedAtResponse>
1059+
// - returns: RequestBuilder<UpdatedAtResponse>
10601060

10611061
open func deleteByWithHTTPInfo(
10621062
indexName: String,
10631063
deleteByParams: DeleteByParams,
10641064
requestOptions userRequestOptions: RequestOptions? = nil
1065-
) async throws -> Response<SearchDeletedAtResponse> {
1065+
) async throws -> Response<UpdatedAtResponse> {
10661066
guard !indexName.isEmpty else {
10671067
throw AlgoliaError.invalidArgument("indexName", "deleteBy")
10681068
}

specs/bundled/search.doc.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3544,7 +3544,7 @@ paths:
35443544
$ref: '#/components/schemas/deleteByParams'
35453545
responses:
35463546
'200':
3547-
$ref: '#/components/responses/DeletedAt'
3547+
$ref: '#/components/responses/UpdatedAt'
35483548
'400':
35493549
$ref: '#/components/responses/BadRequest'
35503550
'402':

specs/bundled/search.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -887,7 +887,7 @@ paths:
887887
$ref: '#/components/schemas/deleteByParams'
888888
responses:
889889
'200':
890-
$ref: '#/components/responses/DeletedAt'
890+
$ref: '#/components/responses/UpdatedAt'
891891
'400':
892892
$ref: '#/components/responses/BadRequest'
893893
'402':

0 commit comments

Comments
 (0)