Socket
Socket
Sign inDemoInstall

bitbucket-api-v2

Package Overview
Dependencies
6
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.6.0 to 0.6.1

.nyc_output/00009cc691d89cf54299ba87d9bcd42d.json

4

package.json
{
"name": "bitbucket-api-v2",
"version": "0.6.0",
"version": "0.6.1",
"description": "Wrapper for the BitBucket API v2, the version required to use OAuth2. Includes support for XHR requests.",

@@ -27,3 +27,2 @@ "homepage": "https://github.com/kristianmandrup/bitbucket-api-v2.git",

"xhr": "^2.4.0",
"generic-test-generator": "github:kristianmandrup/generic-test-generator",
"bitbucket-auth": "github:kristianmandrup/bitbucket-auth"

@@ -41,2 +40,3 @@ },

"babili": "^0.1.4",
"generic-test-generator": "github:kristianmandrup/generic-test-generator",
"babili-webpack-plugin": "^0.1.2",

@@ -43,0 +43,0 @@ "eslint": "^4.9.0",

@@ -40,2 +40,18 @@ # Bitbucket API v2

If you are unable to use ES 2015 modules directly, try using the pre-compiled `dist` bundles:
```js
const { createBitbucketAPI } = require('bitbucket-api-v2/dist/bitbucketAPI')
```
Minified:
```js
const { createBitbucketAPI } = require('bitbucket-api-v2/dist/bitbucketAPI.min')
```
Note: You may also use `createBitBucketAPI` (deprecated)
## API usage
Get the user info (of authenticated user)

@@ -42,0 +58,0 @@

@@ -18,3 +18,3 @@ const {

async function createAuthenticatedAPI(opts = {}) {
getAccessToken = opts.getAccessToken
const getAccessToken = opts.getAccessToken
if (!getAccessToken) {

@@ -25,6 +25,6 @@ throw 'ERROR: Missing getAccessToken (function) option'

opts.accessToken = accessToken
return createBitBucketAPI(opts)
return createBitbucketAPI(opts)
}
function createBitBucketAPI(opts = {}) {
function createBitbucketAPI(opts = {}) {
let bitbucketApi = new Bitbucket(opts)

@@ -211,4 +211,4 @@ if (opts.accessToken) {

Bitbucket,
createBitBucketAPI,
createBitbucketAPI,
createAuthenticatedAPI
}
const {
Bitbucket,
createBitBucketAPI,
createBitbucketAPI,
createAuthenticatedAPI

@@ -17,2 +17,3 @@ } = require('./bitbucket')

createBitBucketAPI,
createBitBucketAPI: createBitbucketAPI, // alias
createAuthenticatedAPI,

@@ -19,0 +20,0 @@ createRequest,

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc