---
isPublished: true
knowledgeIndex: false
hidden: true
noindex: true
template: "page.peb"
title: "Create Experience Flow Action"
description: "Inputs, outputs, callouts, record effects, recipients and invitation-link guidance for the DialogueOne Create Experience Flow action."
contentType: "reference"
audience: "admin,developer"
seoTitle: "Create Experience Flow Action Reference"
seoDescription: "Create an Experience from a generated XP document in Salesforce Flow, check the recipient link and send email as a separate step."
---

# Create Experience

Use **Create Experience** to prepare a generated XP document for one recipient and obtain that recipient's invitation URL.
The namespaced Apex action name is `rooms__CreateExperienceAction`.
The action does not send email.

Use the `contentRecordId` output from
[Generate XP Document](/content/build/flows/GenerateXPDocumentAction.md) as the document input.

## Transaction summary

| Effect | Behavior |
| --- | --- |
| API callout | Yes. The action waits for the creation result. |
| Record writes | Requests creation of Room, Item, Member and review Request records. It also updates their completion state. The action does not directly insert, update or delete records in the calling Flow transaction. |
| Platform event | The action does not directly publish a platform event. |
| Email | No email is sent. The action returns a recipient invitation URL. |
| Background work | A successful result confirms a Room ID and invitation URL. It does not report an email send. |

Each invocation creates a new Experience.
Do not assume that a later Flow fault removes records or revokes an invitation that was already created.

## Inputs

| API name | Flow label | Required | Default or guidance |
| --- | --- | --- | --- |
| `primaryDocumentContentId` | Primary Document Content ID | Yes | The generated document's `rooms__Content__c` ID. Map `contentRecordId` from Generate XP Document. |
| `primaryRecipientId` | Primary Recipient ID | Yes | A Contact, Lead or active internal User with an email address. |
| `experienceTemplateId` | Experience Template ID | No | A published Experience template's `rooms__DocumentRoom__c` ID. Leave blank for document-only sharing. |

The generated document must have a saved PDF with matching File and version references.
Do not supply the template Content ID, XP Document ID or PDF File ID as Primary Document Content ID.

When you select an Experience template, it must be active and published.
It must support Room invitations and contain exactly one unfilled document slot.
Its target object must match the generated document's source object when a target object is set.
Other template items must already be ready for publication.

## Outputs

| API name | Flow label | Meaning |
| --- | --- | --- |
| `success` | Success | `true` confirms a Room ID and primary recipient invitation URL. |
| `message` | Message | Result details or an error. |
| `roomId` | Room ID | The created Experience's Salesforce Room record ID. |
| `primaryRecipientInviteUrl` | Primary Recipient Invite URL | The invitation URL for the selected recipient. Use this value in the later email. |

Store Room ID and Primary Recipient Invite URL.
Do not pass the URL to email until Success equals `true`.
Connect the action's Fault path as well as the false-result Decision path.

## Recipient and signing rules

| Recipient | Behavior |
| --- | --- |
| Contact | Can receive the document. For an eligible signing document, the action assigns this Contact to Signer 1. |
| Active internal User | Can receive the document. For an eligible signing document, the action assigns this User to Signer 1. |
| Lead | Receives view-only access. This action does not assign a Lead to a signing role. |

An eligible signing document must have a valid saved signing definition that contains Signer 1.
Repair invalid signing fields or roles before creating the Experience.
An invitation URL alone does not prove that a document is signable or signed.

## Configure the Flow

1. Generate the XP document and require Success equals `true`.
2. Add **Create Experience** from the Apex action list.
3. Map `contentRecordId` to Primary Document Content ID.
4. Select Primary Recipient ID. Confirm the recipient's email and eligibility.
5. Set Experience Template ID only when a published Experience layout is required.
6. Review the action's Advanced transaction setting for the Flow type.
7. Store Success, Message, Room ID and Primary Recipient Invite URL.
8. Continue only when Success equals `true`.
9. Send email in a separate Flow action. Include Primary Recipient Invite URL in the email body.

```mermaid
flowchart TD
    A[Confirmed generated Content ID and recipient] --> B[Create Experience callout]
    B --> C{Success is true?}
    C -- Yes --> D[Keep Room ID and invitation URL]
    D --> E[Send native Flow email with the URL]
    C -- No --> F[Inspect existing Rooms and Message]
    B -- Fault --> F
    E -- Email retry --> E
```

Confirm the Flow user's action access and the required document, recipient and related-record access.
Review the configured Salesforce API connection user's access.
Apply the required parent-record approval and sending rules.
See [XP access and permissions](/content/support/xp-permissions.md).

## Troubleshooting

**You have uncommitted work pending.** This action makes an API callout.
Check record writes and other pending work before the action in the same transaction.
Review [transaction settings and debugger limits](/content/build/flows/index.md#resolve-uncommitted-work-pending).

**The document is rejected.** Supply a generated XP Content record with a saved PDF.
Check its source record, File and exact File-version references.
Use the confirmed `contentRecordId` from Generate XP Document.

**The recipient is rejected.** Select a Contact, Lead or active internal User with an email address.
Use a Contact or active internal User for supported signing.

**The Experience template is rejected.** Confirm that it is active and published, with one unfilled document slot.
Check its target object and delivery settings. Republish the corrected template before use.

**The response is unsuccessful or uncertain.** Read Message and inspect related Rooms and DialogueOne Events.
Record creation can complete before a response fails.
Do not automatically invoke Create Experience again. A repeated invocation can create another Room and invitation.

**Email fails or its result is uncertain.** Check the email result before retrying.
Reuse the confirmed Primary Recipient Invite URL for an email-only retry.
Do not regenerate the document or recreate the Experience as an email retry.

See the [single-signer quote Flow XML](/assets/flows/v2.166/IDialogue_Single_Signer_Quote.flow-meta.xml)
and [Flow action index](/content/build/flows/index.md) for the complete sequence.
