What to do with twitter oauth token once retrieved?

后端 未结 2 658
悲哀的现实
悲哀的现实 2021-02-04 05:48

I\'m writing a web app that will use twitter as its primary log on method. I\'ve written code which gets the oauth token back from Twitter. My plan is now to

  1. Find
2条回答
  •  生来不讨喜
    2021-02-04 06:25

    Sounds good.

    However, I suggest not using the Twitter User Name as the primary index for the User table. As Twitter user names can be changed. I learned this the hard way.

    You should be fine using the Twitter User ID (big int) as the primary index as it doesn't change if the user changes their user name.

    As for the token its self, you are a-okay with storing it for future use. In fact, you are encouraged to do so.

提交回复
热议问题