123ArticleOnline Logo
Welcome to 123ArticleOnline.com!
ALL >> Web-Design >> View Article

Vue 3 Telegram Login

Profile Picture
By Author: Rizwan Aslam
Total Articles: 1
Comment this article
Facebook ShareTwitter ShareGoogle+ ShareTwitter Share

Installation
You've to run this command to install it with npm:

$ npm i vue3-telegram-login --save
Usage
Next, You've to Import telegram-login-temp, pass it to the component, and then you can utilize it in your template.



Loading...



import { telegramLoginTemp } from 'vue3-telegram-login'
import { ref } from 'vue'

const isLoaded = ref(false)

function telegramLoadedCallbackFunc () {
console.log('script is loaded')
isLoaded.value = true
}

function yourCallbackFunction (user) {
// gets user as an input
// id, first_name, last_name, username,
// photo_url, auth_date and hash
console.log(user)
}

Closing Notes
You need to set the domain to your bot if you want to use Telegram Login (/setdomain command to @BotFather)
You've to validate the authentication and the integrity of the data received by correlating the received hash parameter with the hexadecimal representation of the HMAC-SHA-256 signature of the data-check-string with the SHA256 hash of the bot's token utilized as a secret key (source).
You can observe some code samples on this page.
Don't disable third party cookies if you want to use Telegram Login as a User (thanks @robverhoef )

Total Views: 465Word Count: 221See All articles From Author

Add Comment

Web Design Articles

1. Website Design In Thoothukudi
Author: SM Tech

2. Why Businesses Need A Professional Social Media Branding Agency For Long-term Growth
Author: Cloudy Bites

3. How To Find Website Design Near You – Digital Webdesign India
Author: Soma Manna

4. Find Best Website Design Company In Kolkata
Author: Soma Manna

5. Best Digital Marketing Agency In Noida: A Complete 2026 Guide For Businesses
Author: Visionclick360

6. How To Choose The Right Custom Mobile App Development Company For Your Business
Author: Cloudy Bites

7. This Is Why You Should Choose Ventrux Informatics Pvt Ltd
Author: Soma Manna

8. What Makes Blinkit Onboarding Different From Traditional Marketplace Registration And How Can Zane Marketing Help You Get Ready?
Author: Zane Marketing

9. Can A Website Development Company In Mumbai Turn Your Website Into A Growth Engine?
Author: Sunil Yadav

10. Digital Marketing Services Help Businesses Grow Online
Author: ImageTraders

11. It Consulting: Helping Businesses Build Smarter And More Reliable Technology Strategies
Author: Xelovix

12. What Companies Look For When Hiring A Php Developer In India
Author: Nevil Martin

13. Best Website Builder For Small Business
Author: Scope Hosts

14. Wordpress Web Design Trends In 2026: How Ai, Ux And Seo Are Shaping Modern Websites
Author: Michael Lordan

15. Let Your Business Flourish With Web Development Services
Author: Liam Mackie

Login To Account
Login Email:
Password:
Forgot Password?
New User?
Sign Up Newsletter
Email Address: