ez-movie-node
Advanced tools
Comparing version 1.0.5 to 1.0.6
@@ -208,2 +208,5 @@ const endpoints = { | ||
}, | ||
primary_release_year: { | ||
isRequired: false | ||
}, | ||
"primary_release_date.gte": { | ||
@@ -210,0 +213,0 @@ isRequired: false |
{ | ||
"name": "ez-movie-node", | ||
"version": "1.0.5", | ||
"version": "1.0.6", | ||
"description": "A TMDb API wrapper", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
66
test.js
@@ -1,15 +0,51 @@ | ||
// const EZMovie = require("./index.js") | ||
// | ||
// const ezmovie = new EZMovie("dac9aa883d0da24390c85f37d8728aef") | ||
// | ||
// console.log(ezmovie) | ||
// | ||
// const main = async () => { | ||
// const response = await ezmovie.company.details({ | ||
// company_id: 2 | ||
// }) | ||
// const body = await response.json() | ||
// console.log(body) | ||
// } | ||
// | ||
// main() | ||
const http = require("http") | ||
const fs = require("fs") | ||
const EZMovie = require("./index.js") | ||
const ezmovie = new EZMovie("dac9aa883d0da24390c85f37d8728aef") | ||
const main = async () => { | ||
// const file = fs.createWriteStream("test.gzip") | ||
// const request = http.get("http://files.tmdb.org/p/exports/keyword_ids_05_25_2020.json.gz", (res) => { | ||
// res.pipe(file) | ||
// }) | ||
// console.log(ezmovie) | ||
// | ||
// console.log(await callAPI("search", "keywords", { | ||
// query: "CoWBoY", | ||
// page: 1 | ||
// })) | ||
const res = await callAPI("discover", "movie", { | ||
primary_release_year: 2019, | ||
"with_runtime.gte": 90, | ||
with_keywords: "155291 | 6091" | ||
}) | ||
const movie = res.results[0] | ||
// console.log(movie) | ||
const details = await callAPI("movie", "details", { | ||
movie_id: 301528 | ||
}) | ||
const videos = await callAPI("movie", "videos", { | ||
movie_id: 301528 | ||
}) | ||
console.log(videos) | ||
} | ||
const callAPI = async (endpoint, direction, params) => { | ||
const res = await ezmovie[endpoint][direction](params) | ||
const body = await res.json() | ||
return body | ||
} | ||
main() |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Network access
Supply chain riskThis module accesses the network.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
33157
1240
1
2