node package manager


Simple command-line client and Node.js library for use


Simple command-line client and Node.js library for use

npm install imgbi -g
$ imgbi-client -i image.png!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam!Rl80pmqeXIgRhZz9TQvCrYLAIAi
$ imgbi-client -d '!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam' -o images
OK: Saved to XqL4IVp.png
$ imgbi-client -r '!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam!Rl80pmqeXIgRhZz9TQvCrYLAIAi'
OK: Removed
  imgbi-client [OPTIONS] [ARGS]

  -i, --image FILE       Image location
  -r, --remove URL       URL of file to be removed
  -d, --download URL     URL of file to be downloaded and decrypted
  -e, --expire [NUMBER]  Set expire time in days for image, 0 for store forever  (Default is 180)
  -o, --output [PATH]    Location to save file (Default is .)
  -u, --url [URL]        URL of instance (Default is
  -n, --norm             Don't print removal link
  -l, --nolink           Don't print link to show image
  -a, --autorm           Print autoremove link
  -em, --embed           Print embed code
  -k, --no-color         Omit color from output
      --debug            Show debug information
  -h, --help             Display help and usage details
var imgbi = require('imgbi');
var options = {};
options.image = 'image.jpg'; // image location 
options.expire = '180'; // time to expire in days, default 180 
options.url = ''; // url of server, by default 
imgbi.upload(options, function(err, result) {
  if (err) {
    new Error(err); // if there any error during the upload 
  else {
    console.log(; // id of file 
    console.log(result.pass); // pass used for encryption 
    console.log(result.removalpass); // pass for remove file 
    console.log(result.viewlink); // link to view image 
    console.log(result.rmlink); // link to remove image 
    console.log(result.autormlink); // link to autoremove image after first view 
    console.log(result.embedcode); // code to embed image using script 
imgbi = require('imgbi');
var url = '!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam!Rl80pmqeXIgRhZz9TQvCrYLAIAi'; // link to remove image 
imgbi.remove(url, function(err) {
  if (err) {
    new Error(err); // if there any error during the remove 
  else {
imgbi = require('imgbi');
var url = '!XqL4IVp!jxJccrgkodebbxlaplteabgtbkllab5tberiWkam'; // link to view image 
var path = '~/images'; // path to save image, path, function(err, result) {
  if (err) {
    new Error(err); // if there any error during the download 
  else {
    console.log(result); // filename