andy-widget-vanilla 2.0.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (3) hide show
  1. package/README.md +89 -0
  2. package/dist/bundle.js +2140 -0
  3. package/package.json +43 -0
package/README.md ADDED
@@ -0,0 +1,89 @@
1
+ # andy-widget-vanilla
2
+
3
+ AndyChat vanilla JavaScript Widget - embeddable AI agent for any website.
4
+
5
+ ## Overview
6
+
7
+ A lightweight, framework-agnostic Agent Widget that can be embedded into any website. Built with vanilla JavaScript and completely self-contained.
8
+
9
+ ## Installation
10
+
11
+ ### Via NPM
12
+
13
+ ```bash
14
+ bun add andy-widget-vanilla@2.0.5
15
+ ```
16
+
17
+ ### Via a pinned CDN artifact
18
+
19
+ ```html
20
+ <script src="https://unpkg.com/andy-widget-vanilla@2.0.5/dist/bundle.js"></script>
21
+ <script>
22
+ window.ANDY_CHATBOT_ID = 'your-chatbot-id'
23
+ </script>
24
+ ```
25
+
26
+ ## Quick Start
27
+
28
+ 1. **Get your Agent ID** from Andy
29
+ 2. **Add the script** to your website
30
+ 3. **Set your Agent ID** via global variable
31
+
32
+ ```html
33
+ <!DOCTYPE html>
34
+ <html>
35
+ <head>
36
+ <title>Your Website</title>
37
+ </head>
38
+ <body>
39
+ <!-- Your website content -->
40
+
41
+ <!-- AndyChat Widget -->
42
+ <script>
43
+ window.ANDY_CHATBOT_ID = 'your-chatbot-id-here'
44
+ </script>
45
+ <script src="https://unpkg.com/andy-widget-vanilla@2.0.5/dist/bundle.js"></script>
46
+ </body>
47
+ </html>
48
+ ```
49
+
50
+ ## Configuration
51
+
52
+ Set global variables before loading the script:
53
+
54
+ ```javascript
55
+ // Required: Your chatbot ID
56
+ window.ANDY_CHATBOT_ID = 'your-chatbot-id'
57
+
58
+ // Optional: Custom API endpoint (defaults to production)
59
+ window.ANDY_CHAT_API_URL = 'https://your-api.com/api'
60
+ ```
61
+
62
+ Or set via script tag attributes (no globals):
63
+
64
+ ```html
65
+ <script
66
+ src="https://unpkg.com/andy-widget-vanilla@2.0.5/dist/bundle.js"
67
+ data-andy-embed-id="your-chatbot-id"
68
+ data-andy-api-url="https://app.andypartner.com/api"
69
+ ></script>
70
+ ```
71
+
72
+ ## Features
73
+
74
+ - 🎨 **Fully customizable** - Colors, logo, messages via dashboard
75
+ - 📱 **Mobile responsive** - Works on all devices
76
+ - 🚀 **Lightweight** - ~40KB minified bundle
77
+ - 🔒 **Secure** - Shadow DOM isolation, no style conflicts
78
+ - âš¡ **Fast** - Instant loading, minimal dependencies
79
+
80
+ ## Browser Support
81
+
82
+ - Chrome (latest)
83
+ - Firefox (latest)
84
+ - Safari (latest)
85
+ - Edge (latest)
86
+
87
+ ## License
88
+
89
+ MIT