This Spring Boot application provides a web service for playing Buzzword Bingo with the Timeline of a someone's Twitter account.
Add your Twitter OAuth credentials to the application.properties
file:
twitter4j.consumerKey=
twitter4j.consumerSecret=
twitter4j.accessToken=
twitter4j.accessTokenSecret=
Start the application and create a bingo card by POSTing to the bingoCards
endpoint:
curl -H "Content-Type: application/json" -X POST -d '{"id":"myFirstBingoCard","size":"3","words":["upper-left", "upper-middle", "upper-right", "center-left", "center-middle", "center-right", "lower-left", "lower-middle", "lower-right"]}' http://localhost:8080/bingoCards
Now start playing by entering someone's Twitter user id:
curl -i http://localhost:8080/play?bingoCardId=myFirstBingoCard\&twitterUserId=
If a row can be filled, either horizontal, vertical or diagonal, the server returns 200
. Otherwise, it will return 404
.