Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7761647
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T14:11:27+00:00 2026-06-01T14:11:27+00:00

im trying to implement a login with facebook/twitter functionality in my app, i read

  • 0

im trying to implement a login with facebook/twitter functionality in my app, i read some guides on oAuth, and i think i understood some of the basic concept, and here is what i understood (please correct me if i’m wrong):

  1. myApp send request to the oAuth provider, get the (A)request token.
  2. send user to authenticate the (A), returns with (B)authenticated request token (is this whats called oAuth token?)
  3. use the (B) to get the (C)access token.
  4. use C to access user information.

and here is what i can’t get around my head, which one of these that i should use/store to identify the user? i thought about the possibility of using each one of those, but im always stuck on how to check if the user has signed in before…

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T14:11:29+00:00Added an answer on June 1, 2026 at 2:11 pm

    If all you need is just authentication, then storing only user_id is enough.

    So create another table like:

    id | service_name | user_id | my_user_id
    

    where service_name is either twitter or facebook, user_id – is user’s id from twitter/facebook and my_user_id is a user_id in your authentication system.

    So:

    SELECT my_user_id FROM oauths WHERE service_name = 'twitter' AND user_id = 42
    

    would return you your system user_id or nothing

    PS: service_name could (and should) be normalized, I kept it as a string just to simplify an example

    PPS: as you said in comments you probably would want “posting/tweeting”.

    In that case you need to store user’s access token for twitter, and store nothing additional for facebook, but request for publish_stream permission when authenticate user.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to implement Facebook Login functionality to my website. I followed the
Hi i was trying to implement facebook login for my django app using django-facebook
I was trying to implement facebook logout functionality for my django app. In my
I am trying to use django-social-auth to implement google openid login into my app,
I am trying to implement Facebook Connect functionality into a website that I am
I'm trying to implement Twitter login for my web application. I use scribe to
I am trying to implement the Facebook Login and Logout in my website. I
I'm trying to implement some customize login through the custom methods in Django's models.
I'm trying to implement a Remember Me login functionality for an ASP.NET MVC site
I'm trying to implement the Facebook login for one of my applications and the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.