Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  1. Create a rotten_tomatoes ruleset and register it using KDK.
  2. Define a function in the global block of the ruleset that uses http:get() to interact with the movies.json endpoint of the Rotten Tomatoes API. Be sure to include your API key as the first argument of the query string. Note that if you can't retrieve the data using curl or a browser, your function won't be able to either. 
  3. Use the techniques from Web Rule Exercises and the (Classic) Quickstart for SquareTag, build a SquareTag app that displays a form that asks the user for a movie title. 
  4. The rule that responds to the web:submit event should extract the movie title from the the form data and query the Rotten Tomatoes datasource with the movie title and retrieve the desired information (e.g., critic and audience ratings) from the JSON response using the pick() operator.
  5. The rule should then display the following information on SquareTag: 
    1. Movie thumbnail
    2. Title
    3. Release Year
    4. Synopsis
    5. Critic ratings
    6. and other data you find interesting. 
  6. The data should be nicely formatted and allow the user to type another movie title in at the bottom. 
  7. If the movie isn't found, display a nice error message that returns the title the user put in. 

...