May 2015
Intermediate to advanced
234 pages
4h 18m
English
In this recipe, you'll learn how to retrieve a user's Twitter profile data, which automatically becomes available to the Twitter application once the user has authorized the Twitter application.
This recipe uses the code from the Connecting to Twitter recipe.
Here are the steps to retrieve data from the profile of a Twitter user:
TwitterController class, add a Model argument to the tw() method:@RequestMapping("/fw")
public String fb(HttpServletRequest request, Model model) {
...TwitterProfile profile = twitter.userOperations().getUserProfile();
model.addAttribute("profile", profile); ...Read now
Unlock full access