Documentation

Learn how to integrate and use CareTalk in your application

Chat Widget Integration

Integrate the CareTalk chat widget into your website to provide real-time customer support.

Step 1: Get Your API Key
You'll need an API key to authenticate your widget.

Your API key can be found in your dashboard under Integrations → Chat Widget.

Step 2: Add the Widget Script
Add the following script to your website's HTML, just before the closing </body> tag.
<script>
  window.careTalkSettings = {
    apiKey: "YOUR_API_KEY",
    websiteId: "YOUR_WEBSITE_ID",
    primaryColor: "#6B46C1"
  };
  
  (function(w,d,s,id){
    if(d.getElementById(id)) return;
    var js, fjs = d.getElementsByTagName(s)[0];
    js = d.createElement(s); js.id = id;
    js.src = "https://cdn.caretalk.app/widget.js";
    fjs.parentNode.insertBefore(js,fjs);
  }(window,document,"script","caretalk-widget"));
</script>
Step 3: Customize Your Widget
Customize the appearance and behavior of your chat widget.

You can customize your widget by modifying the careTalkSettings object:

  • primaryColor: The main color of your widget (HEX format)
  • welcomeMessage: The initial message shown to users
  • position: Widget position ('right' or 'left')
  • language: Default language for the widget
Need help?
Built with v0