From 59b3d1f840e3b9d4d79690cdb305c04130d5e3f3 Mon Sep 17 00:00:00 2001 From: algolia-bot Date: Wed, 22 Jan 2025 09:52:39 +0000 Subject: [PATCH] docs: lot of guides (generated) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit https://github.com/algolia/api-clients-automation/pull/4355 Co-authored-by: algolia-bot Co-authored-by: Clément Vannicatte Co-authored-by: Morgan Leroi Co-authored-by: Pierre Millot Co-authored-by: Thomas Raffray --- algolia/search/api_search.go | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/algolia/search/api_search.go b/algolia/search/api_search.go index 4018c9301..ac4b5abf8 100644 --- a/algolia/search/api_search.go +++ b/algolia/search/api_search.go @@ -8664,7 +8664,8 @@ func (c *APIClient) UpdateApiKey(r ApiUpdateApiKeyRequest, opts ...RequestOption func CreateIterable[T any](execute func(*T, error) (*T, error), validate func(*T, error) (bool, error), opts ...IterableOption) (*T, error) { conf := config{ - maxRetries: -1, + headerParams: map[string]string{}, + maxRetries: -1, timeout: func(count int) time.Duration { return 0 * time.Millisecond }, @@ -8868,7 +8869,7 @@ func (c *APIClient) WaitForApiKey( operation ApiKeyOperation, opts ...WaitForApiKeyOption, ) (*GetApiKeyResponse, error) { - conf := config{} + conf := config{headerParams: map[string]string{}} for _, opt := range opts { opt.apply(&conf) @@ -9233,6 +9234,7 @@ Helper: Replaces object content of all the given objects according to their resp */ func (c *APIClient) PartialUpdateObjects(indexName string, objects []map[string]any, opts ...PartialUpdateObjectsOption) ([]BatchResponse, error) { conf := config{ + headerParams: map[string]string{}, createIfNotExists: true, } @@ -9263,6 +9265,7 @@ ChunkedBatch chunks the given `objects` list in subset of 1000 elements max in o */ func (c *APIClient) ChunkedBatch(indexName string, objects []map[string]any, action Action, opts ...ChunkedBatchOption) ([]BatchResponse, error) { conf := config{ + headerParams: map[string]string{}, waitForTasks: false, batchSize: 1000, } @@ -9314,7 +9317,8 @@ func (c *APIClient) ReplaceAllObjects(indexName string, objects []map[string]any tmpIndexName := fmt.Sprintf("%s_tmp_%d", indexName, time.Now().UnixNano()) conf := config{ - scopes: []ScopeType{SCOPE_TYPE_SETTINGS, SCOPE_TYPE_RULES, SCOPE_TYPE_SYNONYMS}, + headerParams: map[string]string{}, + scopes: []ScopeType{SCOPE_TYPE_SETTINGS, SCOPE_TYPE_RULES, SCOPE_TYPE_SYNONYMS}, } for _, opt := range opts {