2.0.5 • Published 8 years ago

norsk-tipping v2.0.5

Weekly downloads
5
License
ISC
Repository
github
Last release
8 years ago

Norsk-Tipping

This is an unofficial API for retrieving various lotto result.

Supported gametypes:

  • lotto
  • keno
  • extra
  • vikinglotto
  • joker
  • eurojackpot

Installation

npm install norsk-tipping

Usage

Example usage for getting latest result for a given game:

var results = require('norsk-tipping');
var options = {
    type: 'vikinglotto'
};

results(options)
    .then(function (response) {
        console.log(response);
    }).catch(function (err) {
        console.log(err);
    });

Retrieve a range of draw results? Just add the following to the options object:

var options = {
    type: 'vikinglotto',
    range: {
        fromDrawID: 1050,
        toDrawID: 1051
    }
};

If you don't want to pass in a specific range between two ID's, it's possible to get the X latest draw-results.

Modify the options object to the following:

var options = {
    type: 'vikinglotto',
    fetchResult: 10
};

If both a range-object and fetchResult is passed in to the options-object, the range will be used.

2.0.5

8 years ago

2.0.4

8 years ago

2.0.3

8 years ago

1.0.2

8 years ago

1.0.1

8 years ago

1.0.0

8 years ago