1.0.10 • Published 10 years ago

node-okbitbucket v1.0.10

Weekly downloads
3
License
-
Repository
-
Last release
10 years ago

node-okbitbucket

Mac/LinuxWindows

Build Status | Windows Build status

API to programmatically query / write on bitbucket.

Pure NodeJS implementation.

Install

    npm i node-okbitbucket --save

Usage

    var secrets = {
        username:'',
        password:'',
        oauth = {
            clientId: '',
            secret: ''
        }
    };

    // var secrets = require('./secrets.json');
    
    // enable debug messages
    if ( process.env.NODE_ENV === 'test' ){
      process.env.DEBUG='*';
    }
    
    var BitBucket = require('node-okbitbucket');
    
    var bbt = (new BitBucket())
            .authenticatePassword(secrets.username, secrets.password);

    bbt.getUserApi().getRepositories(username, function(err, repos){  });
    
    bbt.getUsersApi().getUserData(username, function(err, user){  });
    
    bbt.getSshApi().getKeys(function(err, keys){  });
    bbt.getSshApi().addKey(pubkey, function(err){  });
    bbt.getSshApi().deleteKey(pubkey, function(err){  });
    bbt.getSshApi().deleteAllKeys(function(){  });
    
    bbt.getRepoApi().show(username, repo, function(err, userRepo){  })
    bbt.getRepoApi().getUserRepos(username, function(err, repositories){  })
    
    
    bbt.getEmailApi().getAll(username, repo, function(err, userRepo){  })
    

Documentation

Test

npm run test
DEBUG=node-okbitbucket mocha

Todo

  • write documentation
  • write missing tests (see tests files directly)
  • re write example
  • fix lint

About this repo

It s a fork or original repo found on github, itself a fork of a bitbucket repo.

I only want to note about the license, i see there is one, i m not interested into this, not at all.

I just need this to work, the rest is pointless.

1.0.10

10 years ago

1.0.8

10 years ago

1.0.7

10 years ago

1.0.6

10 years ago

1.0.5

10 years ago

1.0.4

10 years ago

0.0.4

10 years ago

0.0.3

10 years ago

0.0.2

10 years ago