1.0.9 • Published 4 years ago

node-cowin-api v1.0.9

Weekly downloads
-
License
ISC
Repository
github
Last release
4 years ago

🔗 Installation

npm install node-cowin-api

Available methods:

  • getStates - Get all states in India
  • getDistricts - Get get all the districts of state based on stateId
  • getByAppointmentListByPin - Get planned vaccination sessions on a specific date in a given pin

⚡️ Usage:

I have added all the Co-WIN public API methods except Authentication. Will be adding them ASAP, Maybe you can contribute too.

const { 
  getStates, 
  getDistricts, 
  getByAppointmentListByPin 
  } = require('node-cowin-api')
  • Write asynchronous function
async function getData() {
    const allStates = await getStates()
    console.log(allStates)
    const districts = await getDistricts(11)
    console.log(districts)
    const appointments = await getByAppointmentListByPin(360001, '30-07-2021')
    console.log(appointments)
}

getData()
1.0.9

4 years ago

1.0.8

4 years ago

1.0.7

4 years ago

1.0.6

4 years ago

1.0.5

4 years ago

1.0.4

4 years ago

1.0.3

4 years ago

1.0.2

4 years ago

1.0.1

4 years ago

1.0.0

4 years ago