Evernote wrapper.
$ npm install --save node-note
You need Evernote API Key and config.json
, like this.
{
"develop": {
"token": "DEVELOPER_TOKEN_FOR_SANDBOX"
},
"production": {
"token": "DEVELOPER_TOKEN_FOR_PRODUCTION"
}
}
var config = require('./config.json');
var nodeNote = require('node-note');
var evernote = new nodeNote({token: config.develop.token, sandbox: true});
// Create new note
var options = {
title: 'New Note created by node-note',
body: 'Here is the Evernote logo',
file: './ev-logo.png'
}
evernote.createNote(options, function (createdNote) {
console.log('Create new note ' + createdNote.guid);
});
// Delete note
var options = {
title: 'note title'
}
evernote.deleteNote(options, function (deletedNote) {
console.log('Delete note ' + deletedNote.guid);
});
Create new note.
Required
Type: String
Note title.
Type: String
Note body.
Type: String
Notebook name of target.
Type: String
Attachement file.
Type: Array
List of the tag name.
Type: String
The author of the content of the note.
Type: String
The original location where the resource was hosted.
Type: String
ex: 500px
Centering note contents by width
value.
Type: Function
Type: Object
Return created note. Represents a single note in the user's account.
Delete note.
Required title
or guid
field.
If you can set both field, set both field.
Type: String
Note title.
Type: String
Note guid.
Type: Function
Type: Object
Return deleted note. Represents a single note in the user's account.
Get note metadata.
Type: String
If present, a search query string that will filter the set of notes to be returned.
Type: Number
The mximum notes to return in this query.
Type: Function
Type: List
Return the metadata list of notes that match the criteria.
Get note.
Required
Type: String
The GUID of the note to be retrieved.
Type: Bool
If true, the note will include the ENML contents of its 'content' field.
Type: Bool
If true, any Resource elements in this Note will include the binary contents of their 'data' field's body.
Type: Function
Type: Object
Returns the current state of the note in the service.
Restore note in trash.
Required title
or guid
field.
If you can set both field, set both field.
Type: String
note's title.
Type: String
note's guid.
Type: Function
Type: Object
Return restored note.
Submit a set of changes to a note to the service.
Required
Type: String
Note title.
Type: String
New note title.
Type: String
Note body.
Type: Array
List of the tag name.
Type: String
ex: 500px
Centering note contents by width
value.
Type: Function
Type: Object
Return the metadata (no contents) for the Note on the server after the update.
Permanently removes a Note, and all of its Resources, from the service.
Required
Type: String
Note guid.
Type: Function
Type: Number
The Update Sequence Number for this change within the account.
Create new notebook.
Required
Type: String
Notebook name.
Type: Function
Type: Object
Permanently removes a Notebook from the service.
Type: String
Note guid.
Type: Function
Type: Number
The Update Sequence Number for this change within the account.
MIT