GithubHelp home page GithubHelp logo

semaf / telegram-shop Goto Github PK

View Code? Open in Web Editor NEW

This project forked from jeraldlyh/telegram-shop

0.0 0.0 0.0 1 MB

Bringing e-commerce experience live to Telegram

Home Page: https://t.me/teleshop_beta_bot

JavaScript 69.84% TypeScript 29.64% CSS 0.52%

telegram-shop's Introduction

TeleShop

TeleShop is an e-commerce application that has an integration built between Telegram and web app. It uses Telegram as a client to serve customers, while the web app acts as a CRM system for shop owners to manage their shop.

Table of Contents

Demo

Demo can be found on Telegram via @teleshop_beta_bot. A dummy visa card can be used for testing of the payment - 4242 4242 4242 4242 in Telegram.

Note that the responses might be slow due to Heroku's web dyno sleeping, do wait for a couple of seconds for the bot to respond!

Features

Feature Description Released
Message Cleanup Messages that are sent between the user and bot are cleared upon each transition in scenes ✔️
Live Stock Count Users are able to capture updated stock counts and reserve the items in their cart ✔️
Payment Integration with Stripe has been provided for users to transact with shops ✔️
Voucher Codes Users are able to enter voucher code provided by the shop owners ✔️
Order Message Users are able to leave a note on their order for the shop owners ✔️
Order Hogging Cron job will be run daily midnight to prevent users from hogging the items for too long ✔️
Order Date Users are able to select their delivery date (if applicable) ✔️
Order Limit Each order is limited to $13,725.35 which is supported by Telegram ✔️
Web Dashboard Shop owners are able to upload their products via the dashboard

Improvements

  • Develop a full fledged dashboard using Next.js.
  • Currently, the bot is being deployed via a hacky way using Express.js while running Telegraf in the background. For production usage, optimise by changing to webhooks.

User Flow

Database Design

Deployment

Local Deployment

git clone https://github.com/jeraldlyh/telegram-shop

cd telegram && npm i
npm run start

Environment Variables

Name Description
BOT_TOKEN Telegram bot token from BotFather
DATABASE_URL Postgres database URL
PGSSLMODE Requires a SSL TCP/IP connection with the database (set to 'require', only required if hosting on Heroku)
PROVIDER_TOKEN Stripe provider token provided by Telegram
MODE Sets the mode of the environment (set to 'demo' to allow seeding of data upon using commands)

telegram-shop's People

Contributors

jeraldlyh avatar laughingkid-sg avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.