Skip to content

TriadSocial/spotatweet

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

spotatweet

A real-time Spotify & Twtter API mashup.

This web app filters the Twitter stream for #NowPlaying tweets, extracts track IDs from Spotify URLs, requests track data from the Spotify API and plays the audio in the web browser. Implements Twitter status/filter stream and oEmbed API.

Inspired by Serendipity by @kcimc, a Spotify Media Artist in Residence.

![Screenshot](screenshot.png?raw=true =858x "Screenshot")

Installing and Running

Install Node.js.

Clone GitHub repo:

git clone https://github.com/twitterdev/spotatweet.git

Create Twitter and Spotify Apps:

Create a config.json file using config.sample.json as a template. Fill in your Twitter & Spotify App API Keys.

Install Compass Ruby Gem.

gem install compass

If you do not want Compass support, comment out this line in app.js

// app.use(require('node-compass')({mode: 'compress'}));

Install node module dependencies:

npm install 

Run application:

npm start

Go to http://localhost:3000 in your browser.

A GET request to /nowplaying.json will return a Tweet object hydrated with a "spotify_track" object and a "oembed" object of the latest #NowPlaying Tweet.

Deploying

This application is already configured to run on Heroku and can be deployed with Git.

Before deployment set your Heroku environment config vars to mirror config.json.

On Heroku set NODE_ENV to "production."

Resources

About

A Spotify & Twitter API mashup showing what people are listening to now. Written in Node.js.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • JavaScript 69.5%
  • CSS 30.5%