@_solaris/messenger-widget 0.4.9 → 0.4.10
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.
- package/README.md +9 -5
- package/dist/messenger.cjs +1 -1
- package/dist/messenger.embed.js +1 -1
- package/dist/messenger.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -56,12 +56,16 @@ import {
|
|
|
56
56
|
userHash: '…', // HMAC-SHA256(secret, userId), computed server-side
|
|
57
57
|
displayMode: 'floating',// 'floating' | 'sheet' | 'embedded'
|
|
58
58
|
language: 'en', // optional — 'fr' | 'en'; else customer.language / widget.default_language
|
|
59
|
-
context
|
|
60
|
-
|
|
61
|
-
|
|
59
|
+
// Optional agent context. `context.customer` is a flat object pushed
|
|
60
|
+
// once to PATCH /customers/me on boot so the agent has it as context.
|
|
61
|
+
// `name`/`email` map to the customer's columns; any other key is a
|
|
62
|
+
// named variable value (server keeps variables you don't pass):
|
|
63
|
+
context: {
|
|
64
|
+
customer: {
|
|
65
|
+
name: 'Jane Doe',
|
|
62
66
|
email: 'jane@acme.io',
|
|
63
|
-
plan: 'pro',
|
|
64
|
-
seats: 12,
|
|
67
|
+
plan: 'pro',
|
|
68
|
+
seats: 12,
|
|
65
69
|
},
|
|
66
70
|
},
|
|
67
71
|
});
|