playMaker

Author Topic: Twitter Api  (Read 949 times)

dudebxl

  • Hero Member
  • *****
  • Posts: 602
    • View Profile
Twitter Api
« on: March 22, 2016, 04:07:19 PM »
Twitter Api

Action name: Twitter_Api
Can be used for GET or POST from twitter api.

You will get the raw Json data from Twitter (then Datamaker is recommended)

Setup:
  • Get your OAuth keys from twitter dev account
  • Build your query. You query is a single string that you can build dynamically (manually or from arraymaker or hashtables or any other option) - Query format is a broken into sections that are separated by () with parameter=value -- resulting in this: (Parameter=Value)
    For example: (q=Ufo)(count=100)(result_type=popular)
  • Set the correct url to twitter api
  • Set url extension needed for the query (depending on query type)
  • Json raw data is returned as a string - If you get a message in the error section then something you setup is incorrect (always check OAuth first as it is extremely sensitive).

All the information for query building and url extension can be found at https://dev.twitter.com/rest/public

Any problems post here.

On ecosystem or https://snipt.net/dudebxl/

« Last Edit: March 22, 2016, 04:22:11 PM by dudebxl »

KellyRay

  • Full Member
  • ***
  • Posts: 169
    • View Profile
Re: Twitter Api
« Reply #1 on: March 22, 2016, 09:50:10 PM »
Rockin, will check this out!

Thanks

dudebxl

  • Hero Member
  • *****
  • Posts: 602
    • View Profile
Re: Twitter Api
« Reply #2 on: March 23, 2016, 12:53:28 PM »
When using the api and you want to show text as ASCII characters, I recommend that you also use this action: CleanUtf8String (on ecosystem) to clean all non-ASCII characters.

dudebxl

  • Hero Member
  • *****
  • Posts: 602
    • View Profile
Re: Twitter Api
« Reply #3 on: April 02, 2016, 05:56:02 PM »
*** Update bump - corrected a small bug

m3ndi3

  • Playmaker Newbie
  • *
  • Posts: 7
    • View Profile
Re: Twitter Api
« Reply #4 on: May 07, 2017, 01:32:28 PM »
I need help with this... I'm trying to tweet something using this https://dev.twitter.com/rest/reference/post/statuses/update

I don't know how to do it... it always gives me an error...

twitter url: https://api.twitter.com/1.1/
twitter url type: statuses/update.json

Query: "testing tweet"

I don't know how to make it a post and how to just post "testing tweet"

Please help!

dudebxl

  • Hero Member
  • *****
  • Posts: 602
    • View Profile
Re: Twitter Api
« Reply #5 on: May 19, 2017, 06:48:13 AM »
The query is wrong..

Can you get it to work using the Ufo example?

Did you read the setup guide and https://dev.twitter.com/rest/public?