New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

@sleavely/bitbucket

Package Overview
Dependencies
Maintainers
0
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sleavely/bitbucket

Client and utils for Bitbucket Cloud REST APIs

  • 1.0.0
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
1
decreased by-66.67%
Maintainers
0
Weekly downloads
 
Created
Source

@sleavely/bitbucket

API client and collection of common utility methods for managing Bitbucket Cloud via their REST API.

Usage

npm install @sleavely/bitbucket
import { BitbucketClient } from '@sleavely/bitbucket'

const bitbucket = new BitbucketClient({
  auth: {
    username: 'foobar',
    password: 'secret', // Create an app password: https://bitbucket.org/account/settings/app-passwords/
  },
})

console.log(await bitbucket.getCurrentUser())

FAQ

The response type for xyz is wrong

The initial types were handcrafted according to the Bitbucket Cloud REST API reference which in turn are likely autogenerated from their OpenAPI schema. Unfortunately their schema in many cases differs from reality, so discrepancies will occur from time to time. Let me know in an issue (or pull request) and I'll do my best to amend it.

A feature I need is missing!

I've only added utility methods for things I've personally needed in the past, but I'd be happy to add more. In the meantime the public client property acts as an escape hatch to the got instance:

// List branches and tags without the need for helper utils.
await bitbucket.client('/repositories/{workspace}/{repo_slug}/refs')
  .json<unknown>()
  // or simply `.json()`

Keywords

FAQs

Package last updated on 29 Sep 2024

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

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

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc