aksejs / warsaw-public-api

Node.js SDK for Warsaw Public Api

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Warsaw Public API

Unofficial Node.js/Typescript bindings for Warsaw Public API

Installation

npm  install  threads-api
# or with yarn
yarn  add  threads-api
# or with pnpm
pnpm  install  threads-api

Features

  • Fully typed
  • Supports keep alive
  • Supports retry
  • Supports custom axios instance

Quick Start

Import using ES6 module:

import { WarsawPublicApi } from 'warsaw-public-api';

Import using commonJS:

const { WarsawPublicApi } = require('warsaw-public-api');

Below is example of usage TranpsortService

const api = new WarsawPublicApi({ apikey: YOUR_KEY });

api.transportApi
.getTransportBikeRoutes({ limit: 2 })
.then((res) =>  console.log(res.data.result))
.catch((error) =>  console.log(error.response));

TODO

– adapter

License

MIT

About

Node.js SDK for Warsaw Public Api


Languages

Language:TypeScript 99.1%Language:JavaScript 0.9%