> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tricetel.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Embed your Agent

> Embed your Tricetel AI agent into your website to allow visitors to talk to your agent from anywhere.

Your Tricetel AI phone agent can be embedded into any website so your visitors can talk or chat with your Tricetel Agent just like they would over the phone or sms.

Here is an example code that embeds a Tricetel AI agent into a web page:

```html theme={null}
	<!-- 
	  -- data-target = the Tricetel agent username you want to embed (required)
	  -- data-type = call or chat
	-->
	<button
		className="TricetelButton"
	    data-Tricetel-button
	    data-target="Tricetelsales"
	    data-type="call"
  	>
    	Call
  	</button>
  	<button
  		className="TricetelButton"
	    data-Tricetel-button
	    data-target="Tricetelsales"
	    data-type="chat"
  	>
    	Chat
  	</button>
	<script src="https://docs.tricetel.ai/embed/button/v1/script.js" defer />
```

### Explanation of data fields

* **data-target**: (Required) The agent username you want to embed (required).
* **data-type**: (Required) "call" or "chat" depending on if you want to initiate a call or text chat with the target agent.
* **data-number**: (Optional) If on a mobile device, when pressing the button it will dial this number instead of initiating a call via WebRTC.

You can find or edit your agent's username to use in the `data-target` parameter by visiting the [Settings page](https://docs.tricetel.ai/app/inbox?filter=priority\&settings=true\&showOrgSettings=true\&settingsTab=general) if logged in.

### JS File URL Location

Make sure to include the correct JS file location as shown in the example:

* JS: `<script src="https://docs.tricetel.ai/embed/button/v1/script.js" defer />`

## Live example

Below is an example of an Tricetel AI agent embed.

<div class>
  <button className="TricetelButton" data-Tricetel-button data-target="Tricetelsales" data-type="call">
    Call
  </button>

  <button className="TricetelButton" data-Tricetel-button data-target="Tricetelsales" data-type="chat">
    Chat
  </button>
</div>

By embedding your Tricetel AI agent, you can enhance your website's interactivity, allowing visitors to engage with your Tricetel AI agent directly from your site. Explore other helpful articles and guides to make the most out of your AI phone agents and transform your business interactions!
