Skip to content

bz-hashtag-0780/kitty-kombat-lite

Repository files navigation

Kitty Kombat Lite

View live demo on Telegram: https://t.me/KittyKombatLiteBot/app/

Watch tutorial: https://youtu.be/w70ICeVh6fY

Deploy your own onchain Telegram game powered by Flow blockchain: 1-Click Starter

Live Demo


Production Setup Guide

Follow Video Tutorial

You can follow this video tutorial on how to setup your onchain Telegram game

View Tutorial Video

Prerequisites

  1. Create accounts and gather credentials:

Frontend Deployment on Vercel

  1. Visit Vercel and sign in

  2. Add a new project and import your repo

Add new project

Import repo

  1. Before you click deploy, choose build and output settings and add the following custom install command
npm install --legacy-peer-deps

Custom install command

  1. Click on the Deploy button and save your domain URL

Save domain url

Magic Link Setup

  1. Visit https://magic.link and sign in

  2. Create a new app and enable email and sms login

create new app

enable email and sms login

  1. Go to Settings and Add Domain from your Vercel deployment to Allowed Origins & Redirects and press Save

add domain

  1. Save your publishable api key and add it to your Vercel Environment Variables under your Vercel project's Settings. Remember to press Save
NEXT_PUBLIC_MAGIC_API_KEY

publishable api key

environment variables

  1. Redeploy your latest build to make sure the magic api key environment variable gets added to your app.

redeploy latest build

Telegram Web App Setup

  1. Go to BotFather on Telegram, the official bot for managing Telegram bots and web apps.

  2. Create a Telegram Bot

Use the command

/newbot
  1. Create a Telegram App

Use the command

/newapp
  1. Configure Menu Button

Use the command /mybots, choose your Telegram bot to access Bot Settings -> Menu Button -> Configure menu button, type in your domain URL and enter the text to be displayed on your button (E.g. "Play")

  1. Configure Mini App

Go to Bot Settings -> Configure Mini App -> Enable Mini App and type in your domain URL.

Security Notes

  • Your Magic.link publishable key NEXT_PUBLIC_MAGIC_API_KEY is safe to commit

  • Add .env to your .gitignore file if it's not already there

Environment Setup

  1. Create a .env file in your project root:
NEXT_PUBLIC_MAGIC_API_KEY=your_magic_publishable_key

Run locally

  1. Install dependencies:
npm install
  1. Run the project:
npm run dev

Releases

No releases published

Packages

No packages published