# CRM Analytics Lightning Web Components

Use CRM Analytics Lightning Web Components to retrieve data and metadata for CRM Analytics assets, execute queries, and schedule data syncs for recipes, dataflows, and data connectors.

The `lightning/analyticsWaveApi` module provides wire adapters and JavaScript functions built on top of the CRM Analytics REST API. Use these wire adapters and functions to work with CRM Analytics data and metadata.

## Wire Adapters

`getActions`

Retrieves a collection of Salesforce actions available for the specified Analytics user. For more information on syntax and usage, see the [getActions](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-actions.md) reference in the Lightning Web Components Developer Guide.

`getAnalyticsLimits`

Retrieves the Analytics limits for CRM Analytics. For more information on syntax and usage, see the [getAnalyticsLimits](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-analytics-limits.md) reference in the Lightning Web Components Developer Guide.

`getDataConnector`

Retrieves a specific CRM Analytics data connector by ID or developer name. For more information on syntax and usage, see the [getDataConnector](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connector.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectors`

Retrieves a collection of CRM Analytics data connectors. For more information on syntax and usage, see the [getDataConnectors](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connectors.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectorSourceFields`

Retrieves a collection of source fields for a source object used by a CRM Analytics data connector. For more information on syntax and usage, see the [getDataConnectorSourceFields](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connectorsource-fields.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectorSourceObject`

Retrieves a source object used by a CRM Analytics data connector. For more information on syntax and usage, see the [getDataConnectorSourceObject](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connector-source-object.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectorSourceObjectDataPreviewWithFields`

Retrieves the fields for a data preview for a source object used by a CRM Analytics data connector. For more information on syntax and usage, see the [getDataConnectorSourceObjectDataPreviewWithFields](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connector-source-object-data-previewwithfields.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectorStatus`

Retrieves the status for a specific CRM Analytics data connector by ID or developer name. For more information on syntax and usage, see the [getDataConnectorStatus](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connector-status.md) reference in the Lightning Web Components Developer Guide.

`getDataConnectorTypes`

Retrieves the collection of CRM Analytics data connector types. For more information on syntax and usage, see the [getDataConnectorTypes](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-data-connector-types.md) reference in the Lightning Web Components Developer Guide.

`getDataflowJob`

Retrieves a specific CRM Analytics dataflow job. For more information on syntax and usage, see the [getDataflowJob](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataflow-job.md) reference in the Lightning Web Components Developer Guide.

`getDataflowJobs`

Retrieves a collection of CRM Analytics dataflow jobs. For more information on syntax and usage, see the [getDataflowJobs](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataflow-jobs.md) reference in the Lightning Web Components Developer Guide.

`getDataflowJobNode`

Retrieves a specific CRM Analytics dataflow job node for a recipe or dataflow. For more information on syntax and usage, see the [getDataflowJobNode](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataflow-job-node.md) reference in the Lightning Web Components Developer Guide.

`getDataflowJobNodes`

Retrieves a collection of CRM Analytics dataflow job nodes for a recipe or dataflow. For more information on syntax and usage, see the [getDataflowJobNodes](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataflow-job-nodes.md) reference in the Lightning Web Components Developer Guide.

`getDataflows`

Retrieves a collection of CRM Analytics dataflows. For more information on syntax and usage, see the [getDataflows](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataflows.md) reference in the Lightning Web Components Developer Guide.

`getDataset`

Retrieves a specific CRM Analytics dataset by ID or developer name. For more information on syntax and usage, see the [getDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataset.md) reference in the Lightning Web Components Developer Guide.

`getDatasets`

Retrieves a collection of CRM Analytics datasets. For more information on syntax and usage, see the [getDatasets](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-datasets.md) reference in the Lightning Web Components Developer Guide.

`getDatasetVersion`

Retrieves a specific CRM Analytics dataset version by ID or developer name. For more information on syntax and usage, see the [getDatasetVersion](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataset-version.md) reference in the Lightning Web Components Developer Guide.

`getDatasetVersions`

Retrieves a collection of versions for a CRM Analytics dataset. For more information on syntax and usage, see the [getDatasetVersions](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dataset-versions.md) reference in the Lightning Web Components Developer Guide.

`getDependencies`

Retrieves a collection of dependencies for a CRM Analytics asset. For more information on syntax and usage, see the [getDependencies](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-dependencies.md) reference in the Lightning Web Components Developer Guide.

`getRecipe`

Retrieves a specific CRM Analytics recipe by ID. For more information on syntax and usage, see the [getRecipe](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-recipe.md) reference in the Lightning Web Components Developer Guide.

`getRecipes`

Retrieves a collection of CRM Analytics recipes. For more information on syntax and usage, see the [getRecipes](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-recipes.md) reference in the Lightning Web Components Developer Guide.

`getReplicatedDataset`

Retrieves a specific CRM Analytics replicated dataset by ID, also known as a connected object. For more information on syntax and usage, see the [getReplicatedDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-replicated-dataset.md) reference in the Lightning Web Components Developer Guide.

`getReplicatedDatasets`

Retrieves a collection of CRM Analytics replicated datasets, also known as connected objects. For more information on syntax and usage, see the [getReplicatedDatasets](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-replicated-datasets.md) reference in the Lightning Web Components Developer Guide.

`getReplicatedFields`

Retrieves a collection of fields belonging to a CRM Analytics replicated dataset, also known as connected object. For more information on syntax and usage, see the [getReplicatedFields](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-replicated-fields.md) reference in the Lightning Web Components Developer Guide.

`getSchedule`

Retrieves a schedule for a CRM Analytics recipe, dataflow, or data sync. For more information on syntax and usage, see the [getSchedule](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-schedule.md) reference in the Lightning Web Components Developer Guide.

`getSecurityCoverageDatasetVersion`

Retrieves the security coverage for a specific CRM Analytics dataset version by ID or developer name. For more information on syntax and usage, see the [getSecurityCoverageDatasetVersion](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-security-coverage-dataset-version.md) reference in the Lightning Web Components Developer Guide.

`getStories`

Retrieves a collection of Einstein Discovery stories. For more information on syntax and usage, see the [getStories](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-stories.md) reference in the Lightning Web Components Developer Guide.

`getWaveFolder`

Retrieves a specific CRM Analytics app or folder. For more information on syntax and usage, see the [getWaveFolder](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-folder.md) reference in the Lightning Web Components Developer Guide.

`getWaveFolders`

Retrieves a collection of CRM Analytics apps or folders. For more information on syntax and usage, see the [getWaveFolders](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-folders.md) reference in the Lightning Web Components Developer Guide.

`getWaveTemplate`

Retrieves a CRM Analytics template by ID or API name. For more information on syntax and usage, see the [getWaveTemplate](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-template.md) reference in the Lightning Web Components Developer Guide.

`getWaveTemplateConfig`

Retrieves the configuration for a CRM Analytics template by ID or API name. For more information on syntax and usage, see the [getWaveTemplateConfig](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-template-config.md) reference in the Lightning Web Components Developer Guide.

`getWaveTemplateReleaseNotes`

Retrieves the release notes for a CRM Analytics template by ID or API name. For more information on syntax and usage, see the [getWaveTemplateReleaseNotes](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-template-release-notes.md) reference in the Lightning Web Components Developer Guide.

`getWaveTemplates`

Retrieves a collection of CRM Analytics templates. For more information on syntax and usage, see the [getWaveTemplates](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-wave-templates.md) reference in the Lightning Web Components Developer Guide.

`getXmd`

Retrieves a specific CRM Analytics extended metadata type (Xmd) for a version of a dataset. For more information on syntax and usage, see the [getXmd](https://developer.salesforce.com/docs/platform/lwc/guide/reference-wire-adapters-get-xmd.md) reference in the Lightning Web Components Developer Guide.

## Functions

`createDataConnector`

Creates an instance of a CRM Analytics connector to connect to data in your Salesforce orgs, apps, data warehouses, and database services. For more information on syntax and usage, see the [createDataConnector](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-create-data-connector.md) reference in the Lightning Web Components Developer Guide.

`createDataflowJob`

Creates a CRM Analytics dataflow job, which is the equivalent of clicking **Run Now** for a data prep recipe, a data sync, or a dataflow in the CRM Analytics Data Manager UI. For more information on syntax and usage, see the [createDataflowJob](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-create-dataflow-job.md) reference in the Lightning Web Components Developer Guide.

`createDataset`

Creates a dataset. For more information on syntax and usage, see the [createDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-create-dataset.md) reference in the Lightning Web Components Developer Guide.

`createDatasetVersion`

Creates a version for a specific CRM Analytics dataset by ID or developer name. For more information on syntax and usage, see the [createDatasetVersion](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-create-dataset-version.md) reference in the Lightning Web Components Developer Guide.

`createReplicatedDataset`

Creates a CRM Analytics replicated dataset, also known as a connected object. For more information on syntax and usage, see the [createReplicatedDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-create-replicated-dataset.md) reference in the Lightning Web Components Developer Guide.

`deleteDataConnector`

Deletes a specific CRM Analytics connector by ID or developer name. For more information on syntax and usage, see the [deleteDataConnector](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-delete-data-connector.md) reference in the Lightning Web Components Developer Guide.

`deleteDataset`

Deletes a specific CRM Analytics dataset by ID or developer name. For more information on syntax and usage, see the [deleteDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-delete-dataset.md) reference in the Lightning Web Components Developer Guide.

`deleteRecipe`

Deletes a specific CRM Analytics recipe by ID. For more information on syntax and usage, see the [deleteRecipe](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-delete-recipe.md) reference in the Lightning Web Components Developer Guide.

`deleteReplicatedDataset`

Deletes a specific CRM Analytics replicated dataset by ID. For more information on syntax and usage, see the [deleteReplicatedDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-delete-replicated-dataset.md) reference in the Lightning Web Components Developer Guide.

`deleteWaveFolder`

Deletes a specific CRM Analytics app or folder by ID. For more information on syntax and usage, see the [deleteWaveFolder](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-delete-wave-folder.md) reference in the Lightning Web Components Developer Guide.

`executeQuery`

Executes a CRM Analytics query written in Salesforce Analytics Query Language (SAQL) or standard SQL. For more information on syntax and usage, see the [executeQuery](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-execute-query.md) reference in the Lightning Web Components Developer Guide.

`ingestDataConnector`

Triggers the CRM Analytics to run a data sync. For more information on syntax and usage, see the [ingestDataConnector](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-ingest-data-connector.md) reference in the Lightning Web Components Developer Guide.

`postWaveFolders`

Creates a CRM Analytics app or folder by ID. For more information on syntax and usage, see the [postWaveFolders](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-post-wave-folders.md) reference in the Lightning Web Components Developer Guide.

`updateDataConnector`

Updates a CRM Analytics data connector. For more information on syntax and usage, see the [updateDataConnector](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-data-connector.md) reference in the Lightning Web Components Developer Guide.

`updateDataflowJob`

Updates a CRM Analytics dataflow job, which is the equivalent of clicking **Stop** for a data prep recipe, a data sync, or a dataflow in the CRM Analytics Data Manager UI. For more information on syntax and usage, see the [updateDataflowJob](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-dataflow-job.md) reference in the Lightning Web Components Developer Guide.

`updateDataset`

Updates a specific CRM Analytics dataset by ID or developer name. For more information on syntax and usage, see the [updateDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-dataset.md) reference in the Lightning Web Components Developer Guide.

`updateDatasetVersion`

Updates a specific CRM Analytics dataset version by ID or developer name. For more information on syntax and usage, see the [updateDatasetVersion](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-dataset-version.md) reference in the Lightning Web Components Developer Guide.

`updatePartialWaveFolder`

Performs a partial update for a CRM Analytics app or folder by ID. For more information on syntax and usage, see the [updatePartialWaveFolder](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-partial-wave-folder.md) reference in the Lightning Web Components Developer Guide.

`updateRecipe`

Updates a CRM Analytics recipe. For more information on syntax and usage, see the [updateRecipe](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-recipe.md) reference in the Lightning Web Components Developer Guide.

`updateReplicatedDataset`

Updates a CRM Analytics replicated dataset by ID. For more information on syntax and usage, see the [updateReplicatedDataset](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-replicated-dataset.md) reference in the Lightning Web Components Developer Guide.

`updateReplicatedFields`

Updates the collection of fields for a CRM Analytics replicated dataset by ID. For more information on syntax and usage, see the [updateReplicatedFields](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-replicated-dataset-fields.md) reference in the Lightning Web Components Developer Guide.

`updateSchedule`

Updates the schedule for a CRM Analytics data prep recipe, data sync, or dataflow. For more information on syntax and usage, see the [updateSchedule](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-schedule.md) reference in the Lightning Web Components Developer Guide.

`updateXmd`

Updates the user Xmd for a CRM Analytics dataset. For more information on syntax and usage, see the [updateXmd](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-xmd.md) reference in the Lightning Web Components Developer Guide.

`updateWaveFolder`

Updates a CRM Analytics app or folder by ID. For more information on syntax and usage, see the [updateWaveFolder](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-update-wave-folder.md) reference in the Lightning Web Components Developer Guide.

`validateWaveTemplate`

Validates a CRM Analytics template for org readiness. For more information on syntax and usage, see the [valildateWaveTemplate](https://developer.salesforce.com/docs/platform/lwc/guide/reference-analytics-validate-wave-template.xmd.md) reference in the Lightning Web Components Developer Guide.
