Norway Porridge Makers

    node-cowin-api

    1.0.9 • Public • Published

    🔗 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()
    

    Install

    npm i node-cowin-api

    DownloadsWeekly Downloads

    13

    Version

    1.0.9

    License

    ISC

    Unpacked Size

    3.66 kB

    Total Files

    3

    Last publish

    Collaborators

    • rajkaria21