Node npm for pinboard.in
This is just a partial implementation of the api. The rest of the API will be wired up in the future.
Install the module with: npm install pinboard-api
var pin = require('pinboard-api');
var required = {user: "username", password: "password"};
pin.getAcessToken( required, function() {
console.log( data )
//returns access_token
});
var required = {user: "username", password: "password"};
pin.getLastupdate( required, function() {
console.log( data )
//returns time of last update
});
More info on update method
var required = {
user: "username",
token: "access_token",
url: "http://www.example.com",
title: "Title of page"
};
pin.addBookmark( required, options, function() {
console.log( data );
//returns done
});
'options' is an optional parameter and needs to be an object using the parameters of the pinboard.in add method
options = {
tags: "tag1,tag2,tag3",
toread: "yes",
....
}
var required = {user: "username", password: "password", url: "url"};
pin.deleteBookmark( required, function() {
console.log( data )
//returns done
});
More info on delete method
var required = {user: "username", token: "access_token"};
pin.getRecent( required, options, function() {
console.log( data );
//returns recent post
});
'options' is an optional parameter and needs to be an object using the parameters of the pinboard.in post_recent method
options = {
tag: "tag1,tag2,tag3",
count: 5,
....
}
var required = {user: "username", token: "access_token"};
pin.getAll( required, options, function() {
console.log( data );
//returns all post
});
'options' is an optional parameter and needs to be an object using the parameters of the pinboard.in post_all method
options = {
tag: "tag1,tag2,tag3",
count: 5
}
Copyright (c) 2014 Tobias Wright. Licensed under the MIT license.