0.1.0 • Published 6 years ago

wykop-sdk1-node v0.1.0

Weekly downloads
3
License
MIT
Repository
github
Last release
6 years ago

wykop-sdk1-node

Dependencies checker Build Status npm version

It's SDK for Wykop.pl API v1 written in JavaScript.

Install it with npm:

npm install wykop-sdk1-node

Sample use:

var Wykop = require('wykop-sdk1-node'); //importing library

//can be unspecified, it'll still work
var options = {
    'ssl': true,        //true for https requests
    'outputClean': true, //true to get your output cleaned from html
    'userAgent': 'Cronox obserwuje cie' //User-Agent sent in request. must be specified (but it's not verified, insert here anything you want like this)
}

var wykop = Wykop(appkey, secretkey, options); //creating new instance of SDK. you can do it for every account you use in your app

//log in your user with accountkey
wykop.login(accountkey);

//create parameters object for your request
var params = {
    'method': [2137]
}

//send request
//request types, methods and response types are available in docs:
// https://github.com/p1c2u/wykop-sdk
// or here (be aware of fake info):
// https://www.wykop.pl/dla-programistow/dokumentacja/
wykop.request('entries', 'index', params, function(response) {
    console.log(response.body);
});
0.1.0

6 years ago

0.0.3

6 years ago

0.0.1

6 years ago