Giter VIP home page Giter VIP logo

nawodyaishan / discord-firebase-auth Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 305 KB

This repository contains a full-stack application that integrates Discord OAuth2 for authentication with Firebase to manage authenticated sessions.

Home Page: https://discord-twitter-auth-demo.web.app/

JavaScript 3.57% TypeScript 93.76% HTML 0.37% CSS 2.30%
authentication discord firebase firebase-admin-sdk firebase-auth nestjs oauth2 radix-ui shadcn-ui typescript vite

discord-firebase-auth's Introduction

Discord-Firebase Authentication System

This repository contains a full-stack application that integrates Discord OAuth2 for authentication with Firebase to manage authenticated sessions. The system is divided into two main parts:

  • Backend (discord-auth-backend): Implemented with NestJS, it handles Discord OAuth2 authentication, user data retrieval, and Firebase custom token generation.
  • Frontend (discord-auth-frontend): Built with React, it utilizes Firebase to authenticate users based on the tokens generated by the backend and manage user sessions.

Repository Structure

.
├── discord-auth-backend    # Backend service using NestJS
│   ├── src
│   │   ├── app.controller.ts   # Handles incoming requests
│   │   ├── app.service.ts      # Business logic for Discord authentication
│   │   └── ...
│   └── package.json
├── discord-auth-frontend   # Frontend service using React
│   ├── src
│   │   ├── App.tsx         # Main React component
│   │   ├── auth            # Authentication related components
│   │   └── ...
│   └── package.json
└── README.md               # Repository documentation

Getting Started

Prerequisites

  • Node.js
  • Yarn or npm
  • Firebase project
  • Discord Developer Account

Installation

  1. Clone the repository

    git clone https://github.com/nawodyaishan/discord-firebase-auth.git
    cd discord-firebase-auth
  2. Set up the backend

    cd discord-auth-backend
    yarn install
    # Configure environment variables in .env file
    yarn start
  3. Set up the frontend

    cd ../discord-auth-frontend
    yarn install
    # Configure environment variables in .env file
    yarn start

Configuration

Ensure you have the necessary Discord credentials and Firebase configuration details set up in your environment variables or configuration files for both the backend and frontend services.

Usage

Navigate to http://localhost:3000 (or your configured frontend URL) to access the application and test the authentication flow using Discord.

Contributing

Contributions are welcome! Please feel free to submit a pull request or open issues to improve the documentation or code.

discord-firebase-auth's People

Contributors

nawodyaishan avatar

Watchers

 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.