New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

kwingram25-sdk

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

kwingram25-sdk

Simple TypeScript SDK for the-one-api

  • 1.0.0
  • unpublished
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
0
Maintainers
1
Weekly downloads
 
Created
Source

kwingram25-sdk

This is a basic promise-based TypeScript SDK for TheOneApi.

import { TheOneApi, Character } from 'kwingram25-sdk';

const lotr = new TheOneApi({ apiKey: 'YOUR_API_KEY' });

// Fetch all characters
const characters = lotr.character.list()
    .then((characters: Character[]) => {
        console.log(characters);
    })
    .catch(console.error);

// Fetch one movie
const rotk = lotr.movie.withId('5cd95395de30eff6ebccde5d');
console.log(await rotk.get());

// Fetch all quotes from a movie
console.log(await rotk.quotes());

// Search for quotes
const quotes = await lotr.quotes.list({
    filter: { 'dialog': { 'regex': '/[Ss]amwise/' } },
    sort: { key: 'book', asc: true }
})

Dependencies

  • Typescript-Starter - initial module/ESM boilerplate
  • Axios - browser/Node friendly fetching

Running

git clone https://github.com/kwingram25-sdk
cd ./kwingram25-sdk
yarn install

# Tests
TEST_API_KEY=your-key yarn test

FAQs

Package last updated on 21 Dec 2022

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc