{"_id":"@desaisamir/lotr-sdk","_rev":"3-acc91693a428beab668c4ca596836c1b","name":"@desaisamir/lotr-sdk","dist-tags":{"latest":"1.0.3"},"versions":{"1.0.0":{"name":"@desaisamir/lotr-sdk","version":"1.0.0","description":"SDK for the Lord of the Rings API.","main":"index.js","scripts":{"test":"jest"},"keywords":["lotr","sdk","lord of the rings"],"author":{"name":"Samir Desai"},"license":"MIT","dependencies":{"axios":"^1.4.0","dotenv":"^16.3.1"},"devDependencies":{"jest":"^29.6.0"},"gitHead":"ded287a061cc9001f5a5c2e5706dbd2b4286f0f6","_id":"@desaisamir/lotr-sdk@1.0.0","_nodeVersion":"18.16.1","_npmVersion":"9.5.1","dist":{"integrity":"sha512-qedsV233s6sH5l9lzXvEYJIZBxfXeUpZqQ+5ZvusEwE3V3Ft6YyaAccZ2ZSGOInddp4KLvWN20hk75B7MMG2Rg==","shasum":"0e07d1ea96962881eea3854d146c6c382ff2571c","tarball":"https://registry.npmjs.org/@desaisamir/lotr-sdk/-/lotr-sdk-1.0.0.tgz","fileCount":11,"unpackedSize":14369,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQD/GBTbhcCjMEzkuDHvR7GVfvEk6rbfuN3m83ZIE4Fg9QIhAJWeoP1Ppn++xDqzpSfCp8pn9CZ+irfZBu8QahZjtt/f"}]},"_npmUser":{"name":"desaisamir","email":"desaisamirv@gmail.com"},"directories":{},"maintainers":[{"name":"desaisamir","email":"desaisamirv@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/lotr-sdk_1.0.0_1688657740737_0.5855792934790376"},"_hasShrinkwrap":false},"1.0.1":{"name":"@desaisamir/lotr-sdk","version":"1.0.1","description":"SDK for the Lord of the Rings API.","main":"index.js","scripts":{"test":"jest"},"keywords":["lotr","sdk","lord of the rings"],"author":{"name":"Samir Desai"},"license":"MIT","dependencies":{"axios":"^1.4.0","dotenv":"^16.3.1"},"devDependencies":{"jest":"^29.6.0"},"gitHead":"ded287a061cc9001f5a5c2e5706dbd2b4286f0f6","_id":"@desaisamir/lotr-sdk@1.0.1","_nodeVersion":"18.16.1","_npmVersion":"9.5.1","dist":{"integrity":"sha512-NhAjAcBRATQovF4x8fF/B3qZS9V4ObCC//hfhB3OJXjjrt9TY6QgTqy/MffVlEZu2QLo2K1iCdtk1tS3KVY9jQ==","shasum":"f1d7d1b68a4e04dd6be551a32632c1b20b2f8520","tarball":"https://registry.npmjs.org/@desaisamir/lotr-sdk/-/lotr-sdk-1.0.1.tgz","fileCount":11,"unpackedSize":14393,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIE55jK2i3bj1+DWsWc0bGlnUhs+U1e3udOwa5ifKpvLSAiEA9aQuhWOViSBeTXynhER+jNgCyVfmH0hjO4RqVhs1bvg="}]},"_npmUser":{"name":"desaisamir","email":"desaisamirv@gmail.com"},"directories":{},"maintainers":[{"name":"desaisamir","email":"desaisamirv@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/lotr-sdk_1.0.1_1688658080758_0.7836146821335384"},"_hasShrinkwrap":false},"1.0.2":{"name":"@desaisamir/lotr-sdk","version":"1.0.2","description":"SDK for the Lord of the Rings API.","main":"index.js","scripts":{"test":"jest"},"keywords":["lotr","sdk","lord of the rings"],"author":{"name":"Samir Desai"},"license":"MIT","dependencies":{"axios":"^1.4.0","dotenv":"^16.3.1"},"devDependencies":{"jest":"^29.6.0"},"gitHead":"ded287a061cc9001f5a5c2e5706dbd2b4286f0f6","_id":"@desaisamir/lotr-sdk@1.0.2","_nodeVersion":"18.16.1","_npmVersion":"9.5.1","dist":{"integrity":"sha512-XUHRwfYEPcYrbAjkMGUJudcMkMcC8xrvJVpFkdCkqUk1I/jdzGfoDK3cFCjX3m3dnRksmcTw4rtiKsKoGlxQHw==","shasum":"7e588d80f7dc7571150785eb54c1137f607c897c","tarball":"https://registry.npmjs.org/@desaisamir/lotr-sdk/-/lotr-sdk-1.0.2.tgz","fileCount":12,"unpackedSize":14644,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIBRB0IpBajA6qFhHqIt+fc6TaA/5OfRzLR6eTzwyUf9iAiAt0Yn2Y5C1uAALHzjLMzMIqzI38346iWbq3TrNZdJrfQ=="}]},"_npmUser":{"name":"desaisamir","email":"desaisamirv@gmail.com"},"directories":{},"maintainers":[{"name":"desaisamir","email":"desaisamirv@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/lotr-sdk_1.0.2_1688658415979_0.4960984286265555"},"_hasShrinkwrap":false},"1.0.3":{"name":"@desaisamir/lotr-sdk","version":"1.0.3","description":"SDK for the Lord of the Rings API.","main":"index.js","scripts":{"test":"jest"},"keywords":["lotr","sdk","lord of the rings"],"author":{"name":"Samir Desai"},"license":"MIT","dependencies":{"axios":"^1.4.0","dotenv":"^16.3.1"},"devDependencies":{"jest":"^29.6.0"},"gitHead":"ded287a061cc9001f5a5c2e5706dbd2b4286f0f6","_id":"@desaisamir/lotr-sdk@1.0.3","_nodeVersion":"18.16.1","_npmVersion":"9.5.1","dist":{"integrity":"sha512-OEkAmt3Ek4pNWxDC6Zz8jhJWcsMRESziBl/eoi9N4lyVpBafHYFbxBxw4wrbEHrmbQWLVLHlj8/0FEH06XdaCA==","shasum":"f160e4cb40da10eb46bd083d440c2475928c4384","tarball":"https://registry.npmjs.org/@desaisamir/lotr-sdk/-/lotr-sdk-1.0.3.tgz","fileCount":12,"unpackedSize":14648,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDooG3OqWYyFn8Zmjqq2iBqEXZYuz7/eBsNcWpOYZCr8AiAux5EacTIZ6/A4pjZEBZpsqf2op/CG4/GXZjNFOhBm4A=="}]},"_npmUser":{"name":"desaisamir","email":"desaisamirv@gmail.com"},"directories":{},"maintainers":[{"name":"desaisamir","email":"desaisamirv@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/lotr-sdk_1.0.3_1688658610133_0.2764441590153184"},"_hasShrinkwrap":false}},"time":{"created":"2023-07-06T15:35:40.614Z","1.0.0":"2023-07-06T15:35:40.913Z","modified":"2023-07-06T15:50:10.499Z","1.0.1":"2023-07-06T15:41:20.934Z","1.0.2":"2023-07-06T15:46:56.176Z","1.0.3":"2023-07-06T15:50:10.340Z"},"maintainers":[{"name":"desaisamir","email":"desaisamirv@gmail.com"}],"description":"SDK for the Lord of the Rings API.","keywords":["lotr","sdk","lord of the rings"],"author":{"name":"Samir Desai"},"license":"MIT","readme":"# Lord of the Rings SDK\r\n\r\nThis is an SDK for the Lord of the Rings API, providing easy access to movie and quote data.\r\n\r\n## Installation\r\n\r\nTo install the Lord of the Rings SDK, you can use npm:\r\n\r\n```shell\r\nnpm install @desaisamir/lotr-sdk\r\n```\r\n\r\n## Usage\r\n\r\nTo use the SDK in your Node.js application, follow these steps:\r\n\r\nImport the SDK:\r\n```javascript\r\nconst sdk = require('@desaisamir/lotr-sdk');\r\n```\r\n\r\nSet up your environment variables:\r\nCreate a `.env` file in the root of your project and populate it with the following content. There is template `.env-example` file provided in the root of your project.\r\n```javascript\r\nACCESS_TOKEN=YOUR_ACCESS_TOKEN\r\nBASE_API_URL=https://the-one-api.dev/v2\r\n```\r\nReplace `YOUR_ACCESS_TOKEN` with your actual access token for the Lord of the Rings API. If you do not have ACCESS_TOKEN you can obtain access key once you [sign up](https://the-one-api.dev/sign-up).\r\n\r\nCall the desired functions from the SDK:\r\n```javascript\r\n// Get the list of movies\r\nconst movies = await sdk.getMovies();\r\nconsole.log(movies);\r\n\r\n// Get a specific movie by ID\r\nconst movieId = '5cd95395de30eff6ebccde56';\r\nconst movie = await sdk.getMovieById(movieId);\r\nconsole.log(movie);\r\n\r\n// Get quotes by movie ID\r\nconst quotes = await sdk.getQuotesByMovieId(movieId);\r\nconsole.log(quotes);\r\n\r\n// Get the list of quotes\r\nconst allQuotes = await sdk.getQuotes();\r\nconsole.log(allQuotes);\r\n\r\n// Get a specific quote by ID\r\nconst quoteId = '5cd96e05de30eff6ebcce7a1';\r\nconst quote = await sdk.getQuoteById(quoteId);\r\nconsole.log(quote);\r\n```\r\n\r\nThat's it! You can now make use of the Lord of the Rings SDK in your application.\r\n\r\nMake sure to handle any errors that may occur during API requests and follow best practices when integrating the SDK into your codebase.\r\n\r\n## Testing\r\nTo run the tests for the SDK, you can use the following command:\r\n```shell\r\nnpm test\r\n```\r\n\r\nMake sure to set up your environment properly before running the tests.","readmeFilename":"README.md"}