Skip to content

mattwills09/Liri-Node-App

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LIRI (Language Interpreting and Recognition Interface) Node Terminal App

In this project we were asked to create a language interpreting and recognition interface, or LIRI, that users could use to input a simple command to the terminal, along with some further search criteria, and be given clear and updated information for that artist or movie or whatever the user would be searching for. The user is able to search for an artist/band, song, or movie, and then using API calls, be given either show locations and times for a band's next show using the Bands In Town API, or the rating, cast and synopsis for any movie through OMDb's API, or lastly through Spotify's API, search by any song name to find that release year, album, etc.

Getting Started

To run the LIRI Node Application after cloning the repository, run 'npm install' to install required node modules (including FS, Axios, Spotify and Moment), then simply open a terminal to run a Node JS application, and then the four options users can run are:

  • Movies: $ node liri.js movie-this
  • Concerts: $ node liri.js concert-this
  • Songs: $ node liri.js spotify-this-song
  • Do What It Says: $ node liri.js do-what-it-says (runs a preselected code that is in the random.txt file)

Throughout this project, the aspects that I found to go smoothy was finding, downloading and implementing the API keys, calling the query URLs, and setting variables to be used for the functions. The bugs that I had encountered with this project was after writing the function code for the 'concert', 'song', and 'movie', and then figuring out how the code for those would be added to the 'doWhat' function. Not wanting to copy and paste long lines of code over again, I worked with two associates to end up writing one 'querySearch' that can be added in each function (to shorten each), and then be able to call those functions in the 'doWhat' function without having to add excess code. After that edit was made to the liri.js file, the project became much easier to understand through the code, and also with implementing each function. In the future, the ability for all the information found through each search will be appended to a txt file for the users' records.


  • Using the API keys, and requiring FS, Axios, Spotify and moment - and installing those node-modules through the terminal window - the user is able to use the correct query URL's to call upon their servers when the required code is entered. Variables were also created for the process.argv string to be used in each function, for each Concert, Song, Movie, and a function named 'doWhat' that will take the entered string - separate it as the 'action' and 'value', and then run the correct search for the information. There were also default values set for the 'movie' and 'song' searches as well when no term is used for the search. Screenshots for each of those will be provided below:

BandsInTown - 'concert-this' Request concert-this - Code Spotify - 'song-this' Request OMDb - 'movie-this' Request do-what-it-says Song Requests do-what-it-says Movie Requests do-what-it-says Concert Requests


Built With

Authors

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published