Embedded Mode Configuration

embeddedConfiguration

Defines the layout and behavior of the agent when mode is set to EMBEDDED. This object controls how the agent mounts into your application's DOM and its initial UI state.

Structure:

Container: The HTML element into which the agent will mount. Type: HTMLElement

Example

const containerElement = document.getElementById('agent-container');

window.foldspace.agent({
  apiName: 'AGENT_API_NAME',
  mode: 'EMBEDDED',
  configuration: {
    embeddedConfiguration: {
      container: containerElement,
    }
  }
});