jira-rest-client
v1.0.4
Published
A Javascript client to the JIRA Cloud REST API
Downloads
2
Readme
JIRA REST API Client
A Javascript client to the JIRA Cloud REST API
Installation
npm install jira-rest-client
Usage
To write an script using the client
Require 'jira-rest-client' in your file
var JiraClient = require('jira-rest-client');
Create a client with your server url.
var client = new JiraClient('https://jira.atlassian.com');
Invoke the rest api resource with required parameters.
client.getPermissions().then(function(permissions) { console.log(permissions); });
Reference
https://docs.atlassian.com/jira/REST/cloud/
All the resources from the API Reference are transformed into a single API object.
For example, given a resource
api/2/application-properties
Get property
Set property via restful table
Get advanced settings
You can expect methods
* client['application-properties'].getProperty()
* client['application-properties'].setPropertyViaRestfulTable()
* client['application-properties'].getAdvancedSettings()
Methods can accept the following positional parameters
* Object [routeParams] - expected IFF the resource has route parameters
* String [body] - expected IFF the resource method is PUT/POST
* Object requestOptions - always accepted.
See request documentation for available requestOptions.
All methods return a promise.
License
MIT: License