xenial-black
xenial-black2y ago

ChatBot not loading

My chatbot is not appearing in my Shopify store, I see that the javascript is loading and running but even with a manual call to show, it doesn't produce anything, can someone help?
6 Replies
Tico | Voiceflow Assistant
It seems like you're having trouble with the chatbot not appearing on your Shopify store. Here are a few things you could check: 1. Ensure that the JavaScript code is correctly implemented. The chat.load() function should be used to load the agent by setting the project ID, the runtime URL, and a version ID. Here's an example:
window.voiceflow.chat.load({
verify: {
projectID: "YourProjectID"
},
url: "https://general-runtime.voiceflow.com",
versionID: "production"
});
window.voiceflow.chat.load({
verify: {
projectID: "YourProjectID"
},
url: "https://general-runtime.voiceflow.com",
versionID: "production"
});
2. If you want the chat widget to automatically open, you can use the chat.open() function like this:
window.voiceflow.chat.load({
verify: {
projectID: "YourProjectID"
},
url: "https://general-runtime.voiceflow.com",
versionID: "production"
}).then(() => {
window.voiceflow.chat.open();
});
window.voiceflow.chat.load({
verify: {
projectID: "YourProjectID"
},
url: "https://general-runtime.voiceflow.com",
versionID: "production"
}).then(() => {
window.voiceflow.chat.open();
});
3. You can also trigger a specific intent with the chat.interact() function:
window.voiceflow.chat.load({
verify: {
projectID: 'YourProjectID'
},
url: 'https://general-runtime.voiceflow.com',
versionID: 'production'
}).then(() => {
setTimeout(function () {
window.voiceflow.chat.open();
}, 1000);
setTimeout(function () {
window.voiceflow.chat.interact({
type: "intent",
payload: {
intent: {
name: "account_services"
},
entities: []
}
})
}, 2000);
});
window.voiceflow.chat.load({
verify: {
projectID: 'YourProjectID'
},
url: 'https://general-runtime.voiceflow.com',
versionID: 'production'
}).then(() => {
setTimeout(function () {
window.voiceflow.chat.open();
}, 1000);
setTimeout(function () {
window.voiceflow.chat.interact({
type: "intent",
payload: {
intent: {
name: "account_services"
},
entities: []
}
})
}, 2000);
});
Please ensure that you replace "YourProjectID" with your actual project ID. If the issue persists, it might be due to a more complex problem that the community members could help you with. Sources: - Voiceflow Developer Documentation - Voiceflow Learning Center
xenial-black
xenial-blackOP2y ago
It appears like this: window.voiceflow.chat.load({ verify: { projectID: "65c9009e8c45dbdd731cc3b9" }, url: "https://general-runtime.voiceflow.com", versionID: "production" }).then(() => { window.voiceflow.chat.open(); }); Promise {<pending>}[[Prototype]]: Promisecatch: ƒ catch()constructor: ƒ Promise()finally: ƒ finally()then: ƒ then()Symbol(Symbol.toStringTag): "Promise"[[Prototype]]: Object[[PromiseState]]: "fulfilled"[[PromiseResult]]: undefined Promise {<pending>} [[Prototype]] : Promise catch : ƒ catch() constructor : ƒ Promise() finally : ƒ finally() then : ƒ then() Symbol(Symbol.toStringTag) : "Promise" [[Prototype]] : Object [[PromiseState]] : "fulfilled" [[PromiseResult]] : undefined Still not appear without any error So it loads but the widget doesn't show
NiKo | Voiceflow
Double check on your end where those extra promise lines are coming from (right after the chat widget snippet code).
xenial-black
xenial-blackOP2y ago
the problem is not on our code, the promise lines are fine, you can check the code I left as well
NiKo | Voiceflow
If this is related to an extension you're loading on Shopify, check this thread: https://discord.com/channels/1079548823610871889/1197561953242054817 If it's because of your template, this one: https://discord.com/channels/1079548823610871889/1192322706524356778
xenial-black
xenial-blackOP2y ago
https://7965ac-2.myshopify.com/ we didnt saw any conflict within shopify with any extension the css sugested didnt made any diference: <style> #voiceflow-chat { display: block !important; } </style> can you please check on our site if you see any strange thing thanks hello?

Did you find this page helpful?