Add quiz-lead internal endpoint for Typebot → Listmonk funnel

POST /api/internal/quiz-lead accepts archetype quiz results and
idempotently upserts subscriber in Listmonk (create on 201, PUT on 409).
Documents QUIZ_LEAD_SECRET and LISTMONK_* vars in .env.example.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
2026-06-22 14:27:54 +05:00
parent 9fbb7aea6c
commit bb6c806cdd
2 changed files with 159 additions and 0 deletions
+8
View File
@@ -24,3 +24,11 @@ INTERNAL_GRANT_SECRET=""
# Freemium: slug бесплатного курса, в который авто-записываем новых юзеров при регистрации
FREE_COURSE_SLUG=obsidian-start
# Freemium quiz funnel (Typebot → /api/internal/quiz-lead)
QUIZ_LEAD_SECRET=""
# Listmonk API base — публичный домен (Listmonk живёт на Hetzner, наружу через newsletter.)
LISTMONK_URL="https://newsletter.second-brain.ru"
LISTMONK_USER="apiuser"
LISTMONK_TOKEN=""
LISTMONK_QUIZ_LIST_ID=""