Giveaways among channel subscribers — from signup to winner

A bot in Microsoft Teams collects entrants, tracks them in Postgres, verifies channel subscription and fairly picks a winner.

  • Entrants collected by the bot automatically
  • Subscription to required channels verified
  • Winner drawn randomly and fairly
  • Winner and organizer notified in Microsoft Teams

How it works

To connect Microsoft Teams and Postgres, you don't need a developer: a ready-made scenario links them in minutes.

  1. Starts when: Telegram Trigger
  2. Then: Variables TG
  3. Then: Initialization
  4. Check: Start?
  5. If yes: Referal?
  6. If yes: Welcome message Referal
  7. Then: Update bot status and referal
  8. Then: Add participant in Giveaway
  9. If no: Welcome message Manager
  10. Then: Upsert bot status on START
  11. If no: Button?
  12. If yes: Buttons
  13. If yes: Update bot status on GIVEAWAY RUN
  14. Then: Create Giveaway
  15. If no: Get Bot Status
  16. Check: Define flow
  17. If yes: Commands
  18. If yes: List Channels
  19. Then: Update bot status on GIVEAWAY REQUEST CHANNEL
  20. If no: Add channel
  21. Then: Request New Channel
  22. Then: Channel Exists
  23. If no: Define Step Giveaway
  24. If no: Get Participants
  25. Then: Random Participants
  26. Then: Get Channels
  27. Then: Telegram
  28. Then: Union Statuses
  29. Check: Check Success?
  30. If yes: Check Success
  31. If yes: SMS for Winner
  32. Then: SMS for Manager
  33. Then: Delete Channels
  34. Then: Delete Participants
  35. Then: Update bot status on START
  36. Then: End Message
  37. If no: Check Failed

You can launch this Microsoft Teams + Postgres integration in Scriptera: describe the task in plain words — the scenario is built, launched and monitored for you.