---
isPublished: true
knowledgeIndex: false
hidden: true
noindex: true
template: "page.peb"
title: "AI Embedding Action Flow Reference"
description: "Inputs, outputs, transaction effects and troubleshooting for AI Embedding Action in Salesforce Flow."
contentType: "reference"
audience: "admin,developer"
---

# AI Embedding Action

Identify the compatibility fields of AI Embedding Action.
The namespaced Apex action name is `rooms__AIEmbeddingAction`.

**Reference status: Limited.** Review the supported behavior and limitations below.

## Transaction summary

| Effect | Behavior |
| --- | --- |
| API callout | Yes. The action waits for an API response. |
| Record writes | The action does not directly change Salesforce records. |
| Background work | No queued work is started. |
| Platform event | The action does not directly publish a platform event. |
| Email | The action does not send email. |

This compatibility action does not provide a complete embedding-result contract for a new Flow. Do not use it when the Flow requires generated vectors. Source Text, AI Agent ID, Chunk Strategy and Return Embeddings in Results do not change the request. The Embeddings output is not populated by this action.

For batch search-index updates, review [Batch AI Vectorize Records Action](/content/build/flows/BatchAIVectorService.md).

## Inputs

Required describes the Flow input setting. Additional conditions are stated in the guidance.

| API name | Flow label | Required | Default or guidance |
| --- | --- | --- | --- |
| `recordId` | Record ID | No | The record used by the supported request. |
| `modelId` | AI Agent ID | No | Retained input. Does not select an agent for this request. |
| `sourceText` | Source Text | No | Retained input. Does not provide text to this request. |
| `chunkStrategy` | Chunk Strategy | No | Declared default: `DEFAULT`. Does not control this request. |
| `returnInResults` | Return Embeddings in Results | No | Declared default: `false`. Does not populate Embeddings. |

## Outputs

| API name | Flow label | Meaning |
| --- | --- | --- |
| `success` | Success | Whether the action reported success. Check this value before continuing. |
| `message` | Error Message | Result details or an error. Read this value with Success. |
| `embeddings` | Embeddings (Results) | Retained output. This action does not populate it. |
| `totalTokens` | Total Tokens | Reported token usage when supplied. |

## Configure the Flow

1. Identify the existing Flow and the installed action fields.
2. Do not require Embeddings or text-input processing from this compatibility action.
3. Use a complete supported indexing workflow for new automation.
4. For an existing Flow, inspect Success, Error Message and the actual business result.

Confirm the Flow user's action access and the required access to the referenced records.
Review the configured Salesforce API connection user's access when the action makes a callout.
Connect the action's Fault path.

## Troubleshooting

**You have uncommitted work pending.** Check earlier record writes, queued work and other actions in the same transaction.
Review the [transaction settings and debugger limits](/content/build/flows/index.md#resolve-uncommitted-work-pending).

**Source Text or returned embeddings have no effect.** Those exposed controls do not provide a text-input or returned-vector contract in this action. Do not build a Flow that requires Embeddings to be populated.

Confirm that the action and its fields exist in the installed package.
See the [Flow action index](/content/build/flows/index.md) for related actions and transaction guidance.
