Deploying Tiledesk
Introduction
Tiledesk is an open-source customer support platform that combines live chat, AI-powered chatbots, and multi-channel messaging. It enables businesses to engage customers across websites, mobile apps, and messaging platforms like WhatsApp and Facebook Messenger. With a visual chatbot builder and powerful automation features, Tiledesk helps teams deliver exceptional customer experiences.
Key features of Tiledesk include:
- Live Chat Widget: Embeddable chat for websites and mobile apps
- AI Chatbots: Build intelligent chatbots without coding
- Visual Bot Builder: Drag-and-drop conversation flow designer
- Multi-Channel: WhatsApp, Facebook, Telegram integration
- Smart Routing: Assign conversations to the right agents
- Canned Responses: Quick replies for common questions
- Knowledge Base: Integrated help center and FAQs
- Analytics: Track support metrics and chatbot performance
- Ticketing: Convert chats to support tickets
- CRM Integration: Connect with existing customer systems
- Team Collaboration: Internal notes and chat transfers
- Open Source: Self-hosted for complete data control
This guide walks you through deploying Tiledesk on Klutch.sh, configuring the chat widget, and building your first chatbot.
Why Deploy Tiledesk on Klutch.sh
Deploying Tiledesk on Klutch.sh provides several advantages:
Always Available Support: Customer support requires 24/7 availability. Klutch.sh ensures your chat platform remains accessible.
Data Ownership: Self-hosting keeps customer conversations under your control.
Simplified Deployment: Klutch.sh handles container orchestration, letting you focus on customer engagement.
Scalable Resources: Adjust resources based on chat volume and agent count.
HTTPS by Default: Secure chat communications with automatic SSL certificates.
Prerequisites
Before deploying Tiledesk on Klutch.sh, ensure you have:
- A Klutch.sh account
- A GitHub account with a repository for your configuration
- MongoDB database (can be deployed on Klutch.sh)
- Basic familiarity with Docker and customer support concepts
Understanding Tiledesk Architecture
Tiledesk consists of several components:
Server (Backend): Node.js API handling conversations and business logic
Dashboard: Admin panel for managing agents and settings
Chat Widget: Embeddable JavaScript widget for websites
Chat21: Real-time messaging engine
MongoDB: Database for storing conversations and configuration
Preparing Your Repository
Create a GitHub repository with the following structure:
tiledesk-deploy/├── Dockerfile├── .dockerignore└── .env.exampleCreating the Dockerfile
FROM tiledesk/tiledesk-server:latest
# Environment configurationENV MONGODB_URI=${MONGODB_URI}ENV EMAIL_BASEURL=${EMAIL_BASEURL}ENV FIREBASE_PRIVATE_KEY=${FIREBASE_PRIVATE_KEY}ENV FIREBASE_CLIENT_EMAIL=${FIREBASE_CLIENT_EMAIL}ENV FIREBASE_PROJECT_ID=${FIREBASE_PROJECT_ID}
# Widget configurationENV WIDGET_LOCATION=${WIDGET_LOCATION}
# Email configurationENV EMAIL_HOST=${EMAIL_HOST}ENV EMAIL_USERNAME=${EMAIL_USERNAME}ENV EMAIL_PASSWORD=${EMAIL_PASSWORD}ENV EMAIL_FROM_ADDRESS=${EMAIL_FROM_ADDRESS}
EXPOSE 3000
# The base image includes the default entrypointEnvironment Variables Reference
| Variable | Required | Default | Description |
|---|---|---|---|
MONGODB_URI | Yes | - | MongoDB connection string |
EMAIL_BASEURL | Yes | - | Your Tiledesk server URL |
FIREBASE_PRIVATE_KEY | No | - | Firebase private key for push notifications |
FIREBASE_CLIENT_EMAIL | No | - | Firebase client email |
FIREBASE_PROJECT_ID | No | - | Firebase project ID |
EMAIL_HOST | No | - | SMTP server for notifications |
EMAIL_USERNAME | No | - | SMTP username |
EMAIL_PASSWORD | No | - | SMTP password |
EMAIL_FROM_ADDRESS | No | - | Sender email address |
Deploying on Klutch.sh
- Create a Firebase project
- Generate service account credentials
- Note the project ID and private key
Set Up MongoDB
Tiledesk requires MongoDB. Deploy it as a separate app on Klutch.sh:
| Mount Path | Size | Purpose |
|---|---|---|
/data/db | 20 GB | MongoDB data storage |
Set Up Firebase (Optional)
For push notifications:
Push Your Repository to GitHub
Commit and push your Dockerfile and configuration.
Create a New Project on Klutch.sh
Navigate to the Klutch.sh dashboard and create a new project named “tiledesk” or “customer-support”.
Create the Tiledesk Server App
Within your project, create a new app and connect your GitHub repository.
Configure HTTP Traffic
Set the traffic type to HTTP with the internal port set to 3000.
Set Environment Variables
Configure the required variables:
| Variable | Value |
|---|---|
MONGODB_URI | mongodb://user:pass@host:27017/tiledesk |
EMAIL_BASEURL | https://your-app-name.klutch.sh |
Attach Persistent Volumes
Add persistent storage:
| Mount Path | Size | Purpose |
|---|---|---|
/app/uploads | 10 GB | File attachments |
/app/logs | 2 GB | Application logs |
Deploy Your Application
Click Deploy to build and launch Tiledesk.
Create Admin Account
Access the dashboard to create your first admin account.
Initial Configuration
Creating Your First Project
- Log in to the Tiledesk dashboard
- Click “Create Project”
- Enter project name and details
- Configure project settings
Adding Team Members
Invite support agents:
- Navigate to Settings > Team
- Click “Add Team Member”
- Enter email address
- Assign role (Admin, Agent, etc.)
Configuring the Chat Widget
Customize the widget appearance:
- Go to Widget Settings
- Configure colors and branding
- Set welcome messages
- Configure pre-chat form
Installing the Chat Widget
Website Integration
Add the widget to your website:
<script type="text/javascript"> window.tiledeskSettings = { projectid: "YOUR_PROJECT_ID" }; (function(d, s, id) { var w = window; var js, fjs = d.getElementsByTagName(s)[0]; if (d.getElementById(id)) return; js = d.createElement(s); js.id = id; js.src = "https://your-tiledesk-server/widget/launch.js"; fjs.parentNode.insertBefore(js, fjs); }(document, 'script', 'tiledesk-jssdk'));</script>React Integration
import { useEffect } from 'react';
function App() { useEffect(() => { window.tiledeskSettings = { projectid: "YOUR_PROJECT_ID" };
const script = document.createElement('script'); script.src = "https://your-tiledesk-server/widget/launch.js"; script.async = true; document.body.appendChild(script); }, []);
return <div>Your App</div>;}Building Chatbots
Using the Visual Bot Builder
Create chatbots without coding:
- Navigate to Bots section
- Click “Create Bot”
- Use drag-and-drop blocks:
- Message blocks
- Question blocks
- Action blocks
- Intent recognition
Bot Block Types
| Block Type | Purpose |
|---|---|
| Send Message | Display text to user |
| Ask Question | Collect user input |
| Go To | Navigate to another block |
| Set Attribute | Store user data |
| Web Request | Call external APIs |
| Transfer | Hand off to human agent |
Intent Recognition
Configure AI-based intent matching:
- Define intents with example phrases
- Map intents to conversation flows
- Train the bot with sample conversations
- Test and refine accuracy
Multi-Channel Integration
WhatsApp Business
Connect WhatsApp:
- Set up WhatsApp Business API
- Configure webhook in Tiledesk
- Link phone number to project
- Test message routing
Facebook Messenger
Integrate Facebook:
- Create Facebook App
- Configure Messenger webhook
- Link Facebook Page
- Verify integration
Telegram
Add Telegram bot:
- Create bot via BotFather
- Get bot token
- Configure in Tiledesk
- Test messaging
Agent Features
Managing Conversations
Agents can:
- View assigned conversations
- Send replies and attachments
- Add internal notes
- Transfer to other agents
- Convert to tickets
Canned Responses
Create quick replies:
- Go to Settings > Canned Responses
- Add response with shortcut
- Use in conversations with
/shortcut
Working Hours
Configure availability:
- Set business hours
- Configure offline messages
- Set up auto-responses
Production Best Practices
Security Recommendations
- Strong Passwords: Enforce strong passwords for all agents
- Role-Based Access: Use appropriate roles for team members
- Secure Widget: Configure allowed domains for widget embedding
- Data Retention: Configure conversation data retention policies
Performance Optimization
- MongoDB Indexes: Ensure proper database indexing
- Resource Allocation: Scale based on concurrent conversation count
- CDN for Widget: Consider CDN for widget assets
- Connection Pooling: Optimize MongoDB connections
Backup Strategy
Protect your customer data:
- Regular MongoDB backups
- Export conversation history
- Back up bot configurations
- Document integrations
Troubleshooting
Widget Not Loading
- Verify project ID in widget code
- Check for JavaScript errors
- Confirm server is accessible
- Test in incognito mode
Chatbot Not Responding
- Verify bot is active and assigned
- Check intent training
- Review conversation flow
- Test with debug mode
Messages Not Syncing
- Check MongoDB connectivity
- Verify real-time connections
- Review server logs
- Check network connectivity
Notification Issues
- Verify email configuration
- Check Firebase credentials
- Review notification settings
- Test with debug notifications
Additional Resources
- Tiledesk Documentation
- Tiledesk GitHub Organization
- Tiledesk Community
- Tiledesk Developer Portal
- Klutch.sh Persistent Volumes
- Klutch.sh Deployments
Conclusion
Deploying Tiledesk on Klutch.sh provides a comprehensive customer support platform with live chat, AI chatbots, and multi-channel capabilities. With self-hosting, you maintain complete control over customer conversations while delivering exceptional support experiences. The combination of Tiledesk’s feature-rich platform and Klutch.sh’s reliable infrastructure ensures your support team can engage customers effectively across all channels.