<commit_before>var aws = require("aws-lib");
var prodAdv = aws.createProdAdvClient('<KEY>', '<KEY>', 'noobish-20');

var options = {SearchIndex: "Books", Keywords: "<NAME>"}

prodAdv.call("ItemSearch", options, function(err, result) {
  console.log(JSON.stringify(result));
  // console.log(JSON.stringify(result["Items"]["Item"][0]["ItemAttributes"]["Manufacturer"]));
  // console.log(JSON.stringify(result["Items"]["Item"][0]["ItemAttributes"]["Author"]));
  // console.log(JSON.stringify(result["Items"]["Item"][0]["ItemAttributes"]["Title"]));
})<commit_msg>added another API call to fetch the price of an item<commit_after>var aws = require("aws-lib");
var prodAdv = aws.createProdAdvClient('<KEY>', '<KEY>', 'noobish-20');

var options = {SearchIndex: "Video", Keywords: "<NAME> - The Complete 8-Film Collection"}

prodAdv.call("ItemSearch", options, function(err, result) {
  var product = [result["Items"]["Item"][0]["ASIN"], result["Items"]["Item"][0]["ItemAttributes"]["Title"]]
  var prices = {IdType: 'ASIN', ItemId: product[0], ResponseGroup: 'Offers'}

prodAdv.call("ItemLookup", prices, function(err, results) {
  var lowNewPrice = results["Items"]["Item"]["OfferSummary"]["LowestNewPrice"]["FormattedPrice"]
  console.log(product[1], lowNewPrice);
  })
})
{'fraction_non_alphanumeric': 0.22327044025157233, 'fraction_numerical': 0.009433962264150943, 'mean_word_length': 7.964788732394366, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6922670', 'n_tokens_mistral': 406, 'n_tokens_neox': 434, 'n_words': 75}