Agent Embed code and parameters

Embed code

<script id="oneai-snippet" src="https://oneai.com/~widget?id=<YOUR-AGENT-NAME-HERE>" defer>
</script>
  • The code snippet should be inserted into the part of your webpage.
  • The widget is only available for PUBLIC Agents. Any PRIVATE Agent will not be accessible through the snippet.

Parameters

NameTypeDescriptionDefault Value
position stringThe location of the widget on your webpage -
bottom left (left) or bottom right (right).
right
initial-statestringDefines whether the widget will be automatically open (open)
or minimalized (closed).
closed

Here's an example of a snippet that dictates the Agent will be open and located on the bottom left corner of the page:

<script id="oneai-snippet" src="https://oneai.com/~widget?
id=<YOUR-AGENT-NAME-HERE>
&position=left
&initial-state=open" defer>
</script>