An uploader utility for Node
JavaScript
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Failed to load latest commit information.
example
lib
LICENSE first commit Sep 11, 2012
README.md
package.json

README.md

node-uploader - An uploader utility for Node

Install

npm install node-uploader

Usage

var uploader = require('node-uploader');
/**
 * @param {Object} options 文件上传的设置项
 *     @param {String} options.url 服务器接收地址
 *     @param {Object} options.files 上传的文件哈希
 *     @param {Object} options.data 上传携带的额外表单数据
 * @param {Function} callback 上传过程的回调函数
 */
uploader.upload({
  url: 'http://my-service.com/upload-endpoint',
  files: {
    key1: 'photo.png',
    key2: 'data.txt'
  },
  data: {
    username: 'xiaobai'
  }
}, function(e, response){
  if(!e){
    console.log(response);
  }
});

Licence

node-uploader is free to use under MIT license.

Bugs & Feedback

Please feel free to report bugs or feature requests. You can send me private message on github, or send me an email to: [colorhook@gmail.com]