SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Guru hifigrafix's Avatar
    Join Date
    Oct 2005
    Location
    Nashville, TN
    Posts
    628
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Application Based Twitter OAuth

    OAuth is a relatively new concept to me and I'm having a really hard time understanding.

    I've got an app that used to run many times a day grabbing data via Twitter's API. Now Twitter requires authentication my data scrape no longer works.

    I need to implement a way for my Application/Server to become authorized to run all the time.

    All of the Oauth examples I see require a logged in user clicking "Log In With Twitter".

    I'm looking for some direction on how I can authorize my app once and let it continue to run as desired. I briefly read about PIN based authentication but not sure if that's what I want. In addition I can't find out how to use any of the popular PHP Libraries for PIN based authentication.

    Any direction is appreciated.

    Thank You

  2. #2
    Community Advisor bronze trophy
    fretburner's Avatar
    Join Date
    Apr 2013
    Location
    Brazil
    Posts
    1,412
    Mentioned
    45 Post(s)
    Tagged
    12 Thread(s)
    Hi,

    What you need to do is log into Twitter's dev portal and add your app to their system. This will generate a set of keys that you need to use the API.. what you need is your consumer key, consumer secret, access token and access secret. Once you have those, you can access the API from your server with one of the PHP libraries (this one seems to be good) without being prompted to log in or authorize every time.
    Last edited by fretburner; Jun 19, 2013 at 14:05. Reason: Added link to dev portal

  3. #3
    SitePoint Guru hifigrafix's Avatar
    Join Date
    Oct 2005
    Location
    Nashville, TN
    Posts
    628
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks - yea I was over-complicating it a bit. I'm making progress with the library you pointed out.

    Thanks


Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •