Skip to main content

django-deskcrew

DeskCrew widget for Django

Live chat, an AI support chatbot and helpdesk ticketing for Django, in one package. django-deskcrew adds the DeskCrew support widget to a Django project: visitors chat with an AI that answers from your knowledge base, anything it cannot answer becomes a ticket, and a human approves every reply before it sends. A template tag for your base template or an opt-in middleware, plus a small client so a contact form, a view or a Celery task can open a ticket from Python.

Works with Django 4.2 to 5.2, HTMX, Django REST Framework sites with a template front end, Wagtail and django-allauth. Nothing to add to static files or a bundler. Free plan, no credit card: https://deskcrew.io/signup

Use it for

  • Live chat on a Django site without writing JavaScript: one template tag, or one setting for every page.
  • An AI chatbot for customer support that only answers from your own help articles and hands off to a person when unsure.
  • Contact form to support ticket: pass the cleaned form data to create_ticket and the message lands in your inbox as a ticket, no email backend needed.
  • A help center and knowledge base for a SaaS, an online store, a Wagtail site or an internal tool.
  • Replacing a paid chat widget (Intercom, Crisp, Tawk.to, Zendesk, Freshdesk, HelpScout) with one that starts free and never sends a reply you did not approve.

Install

pip install django-deskcrew
# settings.py
INSTALLED_APPS = [..., "deskcrew"]

DESKCREW = {
    "WIDGET_KEY": os.environ.get("DESKCREW_WIDGET_KEY"),  # pub_... from Dashboard → Install
    "BOARD": "your-board",                               # optional
    "SITE_URL": "https://www.example.com",               # this site's public origin
    # "COLOR": "#4f46e5", "POSITION": "right", "GREETING": "Hi! How can we help?",
}

Show the widget

In your base template, just before </body>:

{% load deskcrew %}
{% deskcrew_widget %}

Or set "AUTO_INJECT": True and add "deskcrew.middleware.DeskcrewMiddleware" to MIDDLEWARE; the tag is then added to every successful HTML response. JSON, redirects, streaming responses, errors and pages that already carry the tag are left alone.

Allow your domain

Once per environment:

python manage.py deskcrew_register_origin

Create tickets from your code

from deskcrew.client import create_ticket

create_ticket(email=request.user.email, message=form.cleaned_data["message"], name=request.user.get_full_name())

Returns True when DeskCrew accepted the ticket. It never raises into your request cycle and gives up after ten seconds.

FAQ

How do I add live chat to a Django project?

pip install django-deskcrew, add "deskcrew" to INSTALLED_APPS, put your widget key in the DESKCREW setting, and add {% load deskcrew %}{% deskcrew_widget %} before </body> in your base template. Every template that extends it gets the chat bubble. Set "AUTO_INJECT": True with the middleware instead if you would rather not touch templates.

Does it work with HTMX, Wagtail or Django REST Framework?

Yes. The widget mounts once into its own container, so HTMX swaps and partial updates do not touch it. Wagtail pages render through your base template like any other. A DRF project only needs it on the templates that serve a browser; the middleware skips JSON responses.

Do I need to add anything to static files, Whitenoise or a bundler?

No. The widget is a single external script loaded from deskcrew.io, not a static asset. There is nothing to collect, pin or bundle.

Can I create a support ticket from a view, a form or a Celery task?

Yes. create_ticket(name=, email=, message=) posts the ticket and returns True or False. It never raises into your request cycle and times out after ten seconds, so call it from a task (Celery, Django-Q, Huey) when you create tickets in bulk.

Is the AI chatbot going to make things up?

It answers only from the knowledge base you publish on DeskCrew and says so when it does not know. Anything it cannot answer becomes a ticket, and a person approves every outbound reply. The AI never emails a customer on its own.

Is there a free plan?

Yes. The free plan includes the chat widget, ticketing, a public help center and a monthly AI answer allowance, with no credit card. Paid plans add inbound email, white-label and more AI answers: https://deskcrew.io/pricing

Does it work with Flask or FastAPI?

The client in deskcrew.client is plain Python and works anywhere. The template tag, middleware and management command are Django-only; on Flask or FastAPI paste the one-line widget snippet from https://deskcrew.io/integrations/django into your base template instead.

What the app sends to DeskCrew

One script tag pointing at https://deskcrew.io/desk.js with your public key and the optional board, colour, position and greeting, each validated and escaped. deskcrew_register_origin posts your SITE_URL and key to https://deskcrew.io/api/widget/register-origin. create_ticket posts the name, email and message to https://deskcrew.io/api/widget/submit with SITE_URL as the Origin. Nothing else leaves your project. Terms: https://deskcrew.io/terms. Privacy: https://deskcrew.io/privacy.

Requirements

Python 3.9 to 3.13. Django 4.2, 5.0, 5.1 or 5.2.

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

django_deskcrew-1.0.1.tar.gz (11.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

django_deskcrew-1.0.1-py3-none-any.whl (9.8 kB view details)

Uploaded Python 3

File details

Details for the file django_deskcrew-1.0.1.tar.gz.

File metadata

  • Download URL: django_deskcrew-1.0.1.tar.gz
  • Upload date:
  • Size: 11.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.3

File hashes

Hashes for django_deskcrew-1.0.1.tar.gz
Algorithm Hash digest
SHA256 7408fc1030f1d085dc9750fe6b28d56ec9b690dbe2cd07d420917874c4199c60
MD5 36079b6052626b57f6692a2a802b8906
BLAKE2b-256 7af5f730f48aabd7d6c4e576ccff2b2730bc564e90979d5f40ca8c2b562ddd15

See more details on using hashes here.

File details

Details for the file django_deskcrew-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for django_deskcrew-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 0304ea1af469d1305bc4346da625585cb658aca1a3055e66d121412e85067b6d
MD5 ee0542a839efd592d54409d76e62d2b1
BLAKE2b-256 022b2853912caa8aa862ede602e07ed635e9b9b7f94ffb2e1f12e2bf990e345f

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 files

1.0.0

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page