# @atlassian/jira

> Jira API client for Browser and Node.js

Latest version **0.1.0** (published 2018-12-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install @atlassian/jira
pnpm add @atlassian/jira
yarn add @atlassian/jira
bun add @atlassian/jira
```

## Health

**Score 25/100 (F)** — status: abandoned.

Positive: has types; no vulnerabilities; high quality score.

Warnings: low downloads; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.1.0 |
| Published | 2018-12-13 |
| First published | 2018-11-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | bundled |
| Module format | CommonJS |
| Dependencies | 6 |
| Unpacked size | 329.6 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Atlassian |
| Maintainers | atlassian_fabric_elements, atlassian-aui, cdarroch, cwhittington, dboyd, dmorrow, doklovic, dwalker, jameslnewell, jhoarau, jvdl, macku, mdejongh, mstaas, mszczepanski, prkb, raqystyle, shnooshnoo |
| Keywords | jira, api-client, rest |

## Links

- npm: https://www.npmjs.com/package/@atlassian/jira
- Repository: https://bitbucket.org/atlassianlabs/node-jira
- Issues: https://bitbucket.org/atlassianlabs/node-jira/issues
- npm.io page: https://npm.io/package/@atlassian/jira

## Dependencies (6)

- [debug](https://npm.io/package/debug.md) ^3.1.0
- [btoa-lite](https://npm.io/package/btoa-lite.md) ^1.0.0
- [node-fetch](https://npm.io/package/node-fetch.md) ^2.1.2
- [url-template](https://npm.io/package/url-template.md) ^2.0.8
- [is-plain-object](https://npm.io/package/is-plain-object.md) ^2.0.4
- [before-after-hook](https://npm.io/package/before-after-hook.md) ^1.1.0

## Alternatives

- [launchdarkly-js-client-sdk](https://npm.io/package/launchdarkly-js-client-sdk.md) — 2.5M weekly downloads
- [@elastic/elasticsearch](https://npm.io/package/@elastic/elasticsearch.md) — 2.1M weekly downloads
- [@c8y/client](https://npm.io/package/@c8y/client.md) — 15.3K weekly downloads
- [@signaldb/maverickjs](https://npm.io/package/@signaldb/maverickjs.md) — 1.7K weekly downloads
- [@bbc/http-transport-cache](https://npm.io/package/@bbc/http-transport-cache.md) — 1.2K weekly downloads

## Recent versions

- 0.1.0 (latest) — 2018-12-13
- 0.0.3 — 2018-11-28
- 0.0.2 — 2018-11-13
- 0.0.1 — 2018-11-08

## README

[![version:@latest](https://img.shields.io/npm/v/bitbucket.svg?style=for-the-badge)](https://www.npmjs.com/package/@atlassian/jira)

# Jira.js

JIRA API client for Browser and Node.js

This is a port of the excellent bitbucket library by Munif Tanjim:
[https://github.com/MunifTanjim/node-bitbucket](https://github.com/MunifTanjim/node-bitbucket)

JIRA API docs: [https://developer.atlassian.com/cloud/jira/platform/rest/v2/](https://developer.atlassian.com/cloud/jira/platform/rest/v2/)

## Installation

via **npm**:

```sh
$ npm install @atlassian/jira --save
```

via **yarn**:

```sh
$ yarn add @atlassian/jira
```

## Usage

### Node

```js
const JIRA = require('@atlassian/jira')

const jira = new JIRA()
```

#### Client Options

You can set the APIs' `baseUrl` and modify some behaviors (e.g. request timeout etc.) by passing a clientOptions object to the `JIRA` constructor.

```js
const clientOptions = {
  baseUrl: 'https://api.atlassian.com/ex/jira/${cloudId}/rest/',
  headers: {},
  options: {
    timeout: 10
  }
}

const jira = new JIRA(clientOptions)
```

This enables you to use `jira` with Jira Cloud.

#### Authentication

Basic
```js
jira.authenticate({
  type: 'basic',
  username: 'username',
  password: 'password'
})
```
OAuth
```js
jira.authenticate({
  type: 'token',
  token: 'access token'
})
```

---
_Source: https://npm.io/package/@atlassian/jira · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
