You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// When provided, a second transporter will be created in order to leverage the `*WithTransformation` methods exposed by the Push connector (https://www.algolia.com/doc/guides/sending-and-managing-data/send-and-update-your-data/connectors/push/).
82
+
transformationOptions?: {
83
+
region: IngestionRegion;
84
+
} & ClientOptions;
85
+
86
+
/** @deprecated Use `transformationOptions` instead. */
82
87
transformation?: {
83
88
// The region of your Algolia application ID, used to target the correct hosts of the transformation service.
84
89
region: IngestionRegion;
@@ -100,26 +105,30 @@ export function algoliasearch(
throw new Error('`transformation.region` must be provided at client instantiation before calling this method.');
119
-
}
120
-
121
-
if (!options?.transformation?.region) {
122
-
throw new Error('`region` must be provided when leveraging the transformation pipeline');
131
+
throw new Error('`transformationOptions` must be set in the client config before calling this method. It defaults to the Ingestion API defaults. See https://www.algolia.com/doc/libraries/sdk/methods/ingestion/');
@@ -130,11 +139,7 @@ export function algoliasearch(
130
139
requestOptions,
131
140
): Promise<Array<WatchResponse>> {
132
141
if (!ingestionTransporter) {
133
-
throw new Error('`transformation.region` must be provided at client instantiation before calling this method.');
134
-
}
135
-
136
-
if (!options?.transformation?.region) {
137
-
throw new Error('`region` must be provided when leveraging the transformation pipeline');
142
+
throw new Error('`transformationOptions` must be set in the client config before calling this method. It defaults to the Ingestion API defaults. See https://www.algolia.com/doc/libraries/sdk/methods/ingestion/');
throw new Error('`transformation.region` must be provided at client instantiation before calling this method.');
149
-
}
150
-
151
-
if (!options?.transformation?.region) {
152
-
throw new Error('`region` must be provided when leveraging the transformation pipeline');
153
+
throw new Error('`transformationOptions` must be set in the client config before calling this method. It defaults to the Ingestion API defaults. See https://www.algolia.com/doc/libraries/sdk/methods/ingestion/');
0 commit comments