AI Form Component

From 3B Knowledge
Jump to navigation Jump to search

Intro

Similar to AI Chat Component, you can embed an n8n form in Salesforce, Digital Experiences and 3B Portals.

Setup

The AI Form component requires the following setup:

  1. In Custom Settings -> Onboarding Default Settings -> N8N Endpoint - set this field to the endpoint for the customer's n8n instance. You can obtain this url from the R&D team.
  2. When you add the component on a Record, Utility, Portal Page, you need to pass a few parameters:
    1. Form ID - this is obtained from N8N from the Form Trigger node. Only use Production Form Id
    2. Height - this defines the height of the component

Record Embedding

You can embed the AI Form Component on any record inside salesforce, by using the AI Form component in the app builder.

Utility Item Embedding

You can embed the AI Form as a Utility Item in a Salesforce App. Simply add the LWC component AI Form and define the properties displayed.

Visualforce Page Embedding

You can use the /apex/b3o__AiFormComponent Visualforce page directly to surface the AI Form. You will need to pass additional URL parameters like so:

/apex/b3o__AiFormComponent?formId=123...

The url parameters you can pass are:

  • formId - required

Via Portals Component Embedding

You can use the AI Form component inside 3B Portals pages by dropping the AI Form Component element on a portals page.

Important:

  • You will need to provide the Form Id AND the correct AI Endpoint url when using the element in 3B Portals. We are currently unable to automatically set the AI Endpoint to Custom Settings -> Onboarding Default Settings -> N8N Endpoint

Note:

  • You can restrict the component's height and width by applying hight and width modifiers to the parent element in a 3B Portals Page.