Files
elasticsearch-js/docs/reference-transform-preview_transform.asciidoc
2024-12-05 14:46:52 -06:00

85 lines
4.7 KiB
Plaintext

[[reference-transform-preview_transform]]
////////
===========================================================================================================================
|| ||
|| ||
|| ||
|| ██████╗ ███████╗ █████╗ ██████╗ ███╗ ███╗███████╗ ||
|| ██╔══██╗██╔════╝██╔══██╗██╔══██╗████╗ ████║██╔════╝ ||
|| ██████╔╝█████╗ ███████║██║ ██║██╔████╔██║█████╗ ||
|| ██╔══██╗██╔══╝ ██╔══██║██║ ██║██║╚██╔╝██║██╔══╝ ||
|| ██║ ██║███████╗██║ ██║██████╔╝██║ ╚═╝ ██║███████╗ ||
|| ╚═╝ ╚═╝╚══════╝╚═╝ ╚═╝╚═════╝ ╚═╝ ╚═╝╚══════╝ ||
|| ||
|| ||
|| This file is autogenerated, DO NOT send pull requests that changes this file directly. ||
|| You should update the script that does the generation, which can be found in: ||
|| https://github.com/elastic/elastic-client-generator-js ||
|| ||
|| You can run the script with the following command: ||
|| npm run elasticsearch -- --version <version> ||
|| ||
|| ||
|| ||
===========================================================================================================================
////////
[discrete]
[[client.transform.previewTransform]]
=== client.transform.previewTransform
Preview a transform. Generates a preview of the results that you will get when you create a transform with the same configuration. It returns a maximum of 100 results. The calculations are based on all the current data in the source index. It also generates a list of mappings and settings for the destination index. These values are determined based on the field types of the source index and the transform aggregations.
{ref}/preview-transform.html[{es} documentation]
[discrete]
==== Function signature
[source,ts]
----
(TransformPreviewTransformRequest, options?): Promise<TransformPreviewTransformResponse>
----
[discrete]
==== TransformPreviewTransformRequest
[pass]
++++
<pre>
++++
interface TransformPreviewTransformRequest extends <<RequestBase>> {
transform_id?: <<Id>>
timeout?: <<Duration>>
dest?: TransformDestination
description?: string
frequency?: <<Duration>>
pivot?: TransformPivot
source?: TransformSource
settings?: TransformSettings
sync?: TransformSyncContainer
retention_policy?: TransformRetentionPolicyContainer
latest?: TransformLatest
}
[pass]
++++
</pre>
++++
[discrete]
==== TransformPreviewTransformResponse
[pass]
++++
<pre>
++++
interface TransformPreviewTransformResponse<TTransform = unknown> {
generated_dest_index: IndicesIndexState
preview: TTransform[]
}
[pass]
++++
</pre>
++++