Setup and Initialization
1. Script Tag (Vanilla JS)
Include the Querlo embed script in your HTML. Once loaded, it attaches a global Querlo object to the window.
html
<!-- Load the Querlo SDK -->
<script src="https://static.querlo.com/js/embeds/dist/querlo-sdk.umd.js"></script>
<!-- Optional: Wait for the SDK to be ready -->
<script>
window.addEventListener('querlo-ready', function(e) {
console.log('Querlo SDK is ready!', e.detail);
});
</script>2. Package Manager (NPM)
For modern projects using bundlers (Vite, Webpack), install the package:
bash
npm install @querlo/sdkThen import it in your JavaScript or TypeScript files:
javascript
import Querlo from '@querlo/sdk';
// Initialize embedded chatbots automatically
// Or use the programmatic API below3. ES Module (CDN)
The .es file is also available directly from our CDN. You can import it in native module scripts or modern environments at the following address:
html
<script type="module">
import Querlo from 'https://static.querlo.com/js/embeds/dist/querlo-sdk.es.js';
</script>