How to display live tweets in twitter-vibe using datasift in Ruby on Rails - ruby-on-rails

I am trying to configure an existing Ruby on Rails application (https://github.com/richcaudle/twitter-vibe) with datasift. Application displays live tweets of a user on the page. The datasift authentication parameters are set in config/social-config.yml. I have provided the correct authentication parameters in config/social-config.yml but yet the tweets do not show up. Only the html layout is displayed. Entire application is available in the same github link. I needed some help in fixing this application. What am i missing?

I created this app a while ago, before I joined DataSift. It's not something I've had time to maintain. I've added some instructions to the Readme file which I hope will help, I've also updated the app to use the latest DataSift library.
You'll need to have a Twitter, DataSift and Pusher account to get it running. Fortunately all are free or give you a free trial!
Probably all you were missing is that you need to start the data-collector & tasks scripts in /script to get it all running. I've added these to the Readme.
If you are going to use this in production or in public, please adapt the demo to meet Twitter's Terms of Service (for instance the display requirements). I created the app as an internal demo.
https://dev.twitter.com/terms/api-terms
Thanks,
Rich

Well, you can always use the datasift ruby library. The repository that you mentioned; probably you might need a pusher account. You can use the datasift library.

Related

The restful api function is good to iOS?

i'm a mobile-develop engineer.work on IOS platform,using Xcode.
a few days ago.the man server developer has been changed in our company.he said the popular way of developed is using the template whose name was Restful API,then I was starting know something about the Restful api.
what i knew the thought of the template was the server need only developed the just the one http-interface.they didn't care whatever clients how to requested and how hardly used.
i didn't agree that, example in the page.the requirements is search friends depends on the text which user input on search-bar.
the 1.0 version is just searched the information which key included name.maybe we will send the requestPostDate=xx(which user inputed),filter=name.
the 2.0 version is searched the information which key included name、sex、age or your personal description.but I can't changed the requirements as soon as possible. because i have been wroten filter=name.
what should we did if it should changed in 1.0 versions on AppStore platform.
so what we did is modified the code which filter=name,sex,age. and upload the new library(IPA),then send it to AppStore.hope it's successful during these days.
what i need to say is if we not using restful api.we can be controlled by server.we just tell them we had a key which is xx,the clients didn't care about what the logic of how to search, it easier? and it changed quickly?the client didn't modified any code.maybe we have Web-platform、IOS-platform、android-platform.
i don't know what's the template your company using now.if it's restful api.please tell me how to fix about the questions what i said before?
the problem what i said is the restful api is suitable in IOS platform? maybe is suitable in Web platform,but not suitable in Mobile-developed-platform.
do you agree what i said? if not.give me some point which you think is right please.

What is a good strategy for staying up-to-date with external API's?

My project is reliant on several API's, like Twitter and Youtube for example. Recently, Youtube deprecated their old API, and it caused issues with my team's iPad app.
We could have stayed ahead of the change if we were paying attention to Youtube's announcements of the upcoming deprecation. But alas, we were not and the idea of staying up to date with all of our dependencies manually(browsing the web) seems exhausting and inefficient.
I have found the following tool to help notify when changes occur with external library dependencies, https://libraries.io. However, this does not help with API dependencies.
Besides checking the API source webpages every so often, I was wondering if anyone had suggestions on how to stay notified and up-to-date with news regarding updates to a specified list of external API's?
After some time looking at different options, I have found a solution that is not perfect, but seems to work best at fitting this need.
Solution Description
This solution uses a combination of Twitter, Google Scripts, and website blogtrottr.com. I am creating a twitter list of reliable dev handles that often post updates on new API. For example I made a list that contained #twitterapi and #YouTubeDev. Used Google Scripts to create an online feed out of the twitter list. Then used blogtrottr to email me every time that feed gets a new posting.
Steps to Implement
Create a twitter list of reliable handles that often post about updates to their API
Create an RSS Feed from that Twitter list. The details for how to do this can be found here.
Plug that url that you get from Google Script into blogtrotter.
I did find some other ways to do this, but so far this is the only solution that was 100% free!

how to get twitter feeds in shopify

I am trying to get twitter feeds in to my shopify site. I want to get the feeds and style them as I want and thus cant use a app.
I know how to do it using PHP but can not use that code in shopify and looking for a way I can use OAuth in shopify and get the feeds. I tried the shopify docs but without an example its kinda hard to actually get my head around it.
http://docs.shopify.com/api/tutorials/oauth
Thats the link I am using as a guide. If anyone can direct me to an example which might be similar that would be awesome. (google didnt seem to be that helpful this time either)
Cheers
I know you said you didn't want to use an app, but can I suggest taking a look at Twitify? You can use custom CSS to style your tweets. Also see discussions about Twitify here and here.
Twitter changed their display guidelines and policies on embedding of tweets on websites in June 2013. One of the themes I used for a client earlier in the year had custom styling of tweets, and they have now changed it to use the official Twitter widget to meet the new guidelines. In fact, the images on the Shopify theme store show how it used to look before Twitter changed things:
And after:
I think using an app like Twitify would be the easiest way to deal with these changes to embedding tweets.
Thanx for the suggestion. I did take a look at that before I posted this question. This is a project for a client and I dont think getting a plug in is a viable option. Anyways I found a work around.
Hosted the file on a server and then accessed it. So that resolved the problem. :)
I used node.js to write the script and get the posts as required.
Cheers.
you can use the app for that Twitify https://apps.shopify.com/twitify or you can Embed a Twitter feed in your online store
Go to your Twitter settings.
Click Widgets to open the widgets menu.
Create a new widget, following Twitter's instructions.
Copy the embed code.

Tracking users' clicks and page visits in Rails

I would like to monitor users' page visits and clicks in my Rails app to make recommendations. My questions are:
Is there a Rails gem for this, or Google Analytics is the standard? If latter is true, then how should I link a page visit to a particular user profile?
It is typical in Rails to have a section in application.html.erb, which is shared for all pages. If I add Google Analytics pageview tracking code to in application.html.erb, will it be able to track all individual pages?
There are other ways, but the vast majority probably use Google Analytics. Several gems exist that help you integrate with GA to get at the data. See here: https://www.ruby-toolbox.com/categories/Web_Analytics.
Based on your first question, it seems you may want more insight than GA can provide. I've used ClickTale (http://www.clicktale.com) and Woopra (http://www.woopra.com) before, to good effect. This article lists several other alternatives, too - notice the high marks for Clicky: http://imimpact.com/web-stats-alternatives-to-google-analytics/.
Google Analytics (and almost all of these others) will take care of your second question automatically whenever the user loads a new page, since it keyed by URL. That means that, although you put the GA script code in a single place, each unique page is tracked individually.
If you have AJAX requests that change that page without changing the URL, you'll need to dig in to the GA script API. Essentially you'll need to push a new url (possibly with a # in it) whenever you want to track an AJAX-driven link/button click. See here: http://davidwalsh.name/ajax-analytics
I am biased, but I would recommend checking out impressionist, if you need to integrate the page views into the app in real-time. With analytics you will always have some lag time and you are also relying on an external dependency. Impressionist is good if you need this kind of control, but if you are just looking for simple metrics and don't need to pull them into the app, then analytics is probably the way to go.
Check out Ahoy, at https://github.com/ankane/ahoy. With just a few lines of code in your app, you can track page views and tie them to user accounts.
You can further customize Ahoy to track custom events, both the client (with JavaScript) and server.
Ahoy does not depend on any third-party services.

How to integrate carrier site using Rails application

I am integrating the UPS, USPS, DHL and FEDEX with my Rails application.
For that I am using 'trackify' plugin to find the carrier type for given Tracking Number and for also finding the XML response from the respective tracking site.
I want a complete guide for each of the above about how to integrate tracking API's?
You need to go to the companies' sites themselves to get that information. Once you've done that then come back if you have any questions about actual implementation. Sorry for leaving this as an answer but I can't leave comments yet.

Resources