@treyhoover/lotr-sdk
TypeScript icon, indicating that this package has built-in type declarations

0.0.1 • Public • Published

Getting Started

Installation

npm i @treyhoover/lotr-sdk

Generate Your Api Key

Click here to sign up and generate an Api key to use in your project.

Query Examples

import { Sdk } from "@treyhoover/lotr-sdk";

const sdk = new Sdk("YOUR_API_KEY");

const movies = await sdk.movies().fetch();

const hobbitMovie = await sdk
  .movie({ id: "5cd95395de30eff6ebccde57" })
  .fetch();

const fellowshipQuotes = await sdk
  .movie({ id: "5cd95395de30eff6ebccde5c" })
  .quotes()
  .limit(5)
  .fetch();

TODO:

  • Use Zod for api response types
  • Narrow sort/filter typing
  • Add support for remaining routes
  • Add tests
  • Add JSDoc comments for better IntelliSense support

Readme

Keywords

none

Package Sidebar

Install

npm i @treyhoover/lotr-sdk

Weekly Downloads

0

Version

0.0.1

License

ISC

Unpacked Size

20.8 kB

Total Files

16

Last publish

Collaborators

  • treyhoover