-
Notifications
You must be signed in to change notification settings - Fork 3
/
index.json
6900 lines (6900 loc) · 241 KB
/
index.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
[
{
"__docId__": 1,
"kind": "external",
"name": "Infinity",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Infinity",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Infinity",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 2,
"kind": "external",
"name": "NaN",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/NaN",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~NaN",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 3,
"kind": "external",
"name": "undefined",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/undefined",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~undefined",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 4,
"kind": "external",
"name": "null",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/null",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~null",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 5,
"kind": "external",
"name": "Object",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Object",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 6,
"kind": "external",
"name": "object",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Object",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~object",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 7,
"kind": "external",
"name": "Function",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Function",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 8,
"kind": "external",
"name": "function",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Function",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~function",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 9,
"kind": "external",
"name": "Boolean",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Boolean",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 10,
"kind": "external",
"name": "boolean",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Boolean",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~boolean",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 11,
"kind": "external",
"name": "Symbol",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Symbol",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Symbol",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 12,
"kind": "external",
"name": "Error",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Error",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 13,
"kind": "external",
"name": "EvalError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/EvalError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~EvalError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 14,
"kind": "external",
"name": "InternalError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/InternalError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~InternalError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 15,
"kind": "external",
"name": "RangeError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RangeError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~RangeError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 16,
"kind": "external",
"name": "ReferenceError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ReferenceError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~ReferenceError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 17,
"kind": "external",
"name": "SyntaxError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SyntaxError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~SyntaxError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 18,
"kind": "external",
"name": "TypeError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/TypeError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~TypeError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 19,
"kind": "external",
"name": "URIError",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/URIError",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~URIError",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 20,
"kind": "external",
"name": "Number",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Number",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 21,
"kind": "external",
"name": "number",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Number",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~number",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 22,
"kind": "external",
"name": "Date",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Date",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 23,
"kind": "external",
"name": "String",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~String",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 24,
"kind": "external",
"name": "string",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/String",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~string",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 25,
"kind": "external",
"name": "RegExp",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/RegExp",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~RegExp",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 26,
"kind": "external",
"name": "Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 27,
"kind": "external",
"name": "Int8Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int8Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Int8Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 28,
"kind": "external",
"name": "Uint8Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Uint8Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 29,
"kind": "external",
"name": "Uint8ClampedArray",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint8ClampedArray",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Uint8ClampedArray",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 30,
"kind": "external",
"name": "Int16Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int16Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Int16Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 31,
"kind": "external",
"name": "Uint16Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint16Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Uint16Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 32,
"kind": "external",
"name": "Int32Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Int32Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Int32Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 33,
"kind": "external",
"name": "Uint32Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Uint32Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Uint32Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 34,
"kind": "external",
"name": "Float32Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Float32Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Float32Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 35,
"kind": "external",
"name": "Float64Array",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Float64Array",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Float64Array",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 36,
"kind": "external",
"name": "Map",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Map",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 37,
"kind": "external",
"name": "Set",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Set",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Set",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 38,
"kind": "external",
"name": "WeakMap",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakMap",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~WeakMap",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 39,
"kind": "external",
"name": "WeakSet",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/WeakSet",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~WeakSet",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 40,
"kind": "external",
"name": "ArrayBuffer",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/ArrayBuffer",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~ArrayBuffer",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 41,
"kind": "external",
"name": "DataView",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/DataView",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~DataView",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 42,
"kind": "external",
"name": "JSON",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/JSON",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~JSON",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 43,
"kind": "external",
"name": "Promise",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Promise",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Promise",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 44,
"kind": "external",
"name": "Generator",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Generator",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Generator",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 45,
"kind": "external",
"name": "GeneratorFunction",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/GeneratorFunction",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~GeneratorFunction",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 46,
"kind": "external",
"name": "Reflect",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Reflect",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Reflect",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 47,
"kind": "external",
"name": "Proxy",
"externalLink": "https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Proxy",
"memberof": "src/.external-ecmascript.js",
"static": true,
"longname": "src/.external-ecmascript.js~Proxy",
"access": "public",
"description": "",
"builtinExternal": true
},
{
"__docId__": 48,
"kind": "file",
"name": "src/jira.js",
"content": "import _request from 'postman-request';\nimport url from 'url';\n\nfunction request(uri, options) {\n return new Promise((resolve, reject) => {\n _request(uri, options, (err, httpResponse) => {\n if (err) {\n reject(err);\n } else {\n // for compatibility with request-promise\n resolve(httpResponse.body);\n }\n });\n });\n}\n/**\n * @name JiraApi\n * @class\n * Wrapper for the JIRA Rest Api\n * https://docs.atlassian.com/jira/REST/6.4.8/\n */\nexport default class JiraApi {\n /**\n * @constructor\n * @function\n * @param {JiraApiOptions} options\n */\n constructor(options) {\n this.protocol = options.protocol || 'http';\n this.host = options.host;\n this.port = options.port || null;\n this.apiVersion = options.apiVersion || '2';\n this.base = options.base || '';\n this.intermediatePath = options.intermediatePath;\n this.strictSSL = options.hasOwnProperty('strictSSL') ? options.strictSSL : true;\n // This is so we can fake during unit tests\n this.request = options.request || request;\n this.webhookVersion = options.webHookVersion || '1.0';\n this.greenhopperVersion = options.greenhopperVersion || '1.0';\n this.baseOptions = {};\n\n if (options.ca) {\n this.baseOptions.ca = options.ca;\n }\n\n if (options.oauth && options.oauth.consumer_key && options.oauth.access_token) {\n this.baseOptions.oauth = {\n consumer_key: options.oauth.consumer_key,\n consumer_secret: options.oauth.consumer_secret,\n token: options.oauth.access_token,\n token_secret: options.oauth.access_token_secret,\n signature_method: options.oauth.signature_method || 'RSA-SHA1',\n };\n } else if (options.bearer) {\n this.baseOptions.auth = {\n user: '',\n pass: '',\n sendImmediately: true,\n bearer: options.bearer,\n };\n } else if (options.username && options.password) {\n this.baseOptions.auth = {\n user: options.username,\n pass: options.password,\n };\n }\n\n if (options.timeout) {\n this.baseOptions.timeout = options.timeout;\n }\n }\n\n /**\n * @typedef JiraApiOptions\n * @type {object}\n * @property {string} [protocol=http] - What protocol to use to connect to\n * jira? Ex: http|https\n * @property {string} host - What host is this tool connecting to for the jira\n * instance? Ex: jira.somehost.com\n * @property {string} [port] - What port is this tool connecting to jira with? Only needed for\n * none standard ports. Ex: 8080, 3000, etc\n * @property {string} [username] - Specify a username for this tool to authenticate all\n * requests with.\n * @property {string} [password] - Specify a password for this tool to authenticate all\n * requests with. Cloud users need to generate an [API token](https://confluence.atlassian.com/cloud/api-tokens-938839638.html) for this value.\n * @property {string} [apiVersion=2] - What version of the jira rest api is the instance the\n * tool is connecting to?\n * @property {string} [base] - What other url parts exist, if any, before the rest/api/\n * section?\n * @property {string} [intermediatePath] - If specified, overwrites the default rest/api/version\n * section of the uri\n * @property {boolean} [strictSSL=true] - Does this tool require each request to be\n * authenticated? Defaults to true.\n * @property {function} [request] - What method does this tool use to make its requests?\n * Defaults to request from request-promise\n * @property {number} [timeout] - Integer containing the number of milliseconds to wait for a\n * server to send response headers (and start the response body) before aborting the request. Note\n * that if the underlying TCP connection cannot be established, the OS-wide TCP connection timeout\n * will overrule the timeout option ([the default in Linux can be anywhere from 20-120 *\n * seconds](http://www.sekuda.com/overriding_the_default_linux_kernel_20_second_tcp_socket_connect_timeout)).\n * @property {string} [webhookVersion=1.0] - What webhook version does this api wrapper need to\n * hit?\n * @property {string} [greenhopperVersion=1.0] - What webhook version does this api wrapper need\n * to hit?\n * @property {string} [ca] - Specify a CA certificate\n * @property {OAuth} [oauth] - Specify an OAuth object for this tool to authenticate all requests\n * using OAuth.\n * @property {string} [bearer] - Specify an OAuth bearer token to authenticate all requests with.\n */\n\n /**\n * @typedef OAuth\n * @type {object}\n * @property {string} consumer_key - The consumer entered in Jira Preferences.\n * @property {string} consumer_secret - The private RSA file.\n * @property {string} access_token - The generated access token.\n * @property {string} access_token_secret - The generated access toke secret.\n * @property {string} signature_method [signature_method=RSA-SHA1] - OAuth signurate methode\n * Possible values RSA-SHA1, HMAC-SHA1, PLAINTEXT. Jira Cloud supports only RSA-SHA1.\n */\n\n /**\n * @typedef {object} UriOptions\n * @property {string} pathname - The url after the specific functions path\n * @property {object} [query] - An object of all query parameters\n * @property {string} [intermediatePath] - Overwrites with specified path\n */\n\n /**\n * @name makeRequestHeader\n * @function\n * Creates a requestOptions object based on the default template for one\n * @param {string} uri\n * @param {object} [options] - an object containing fields and formatting how the\n */\n makeRequestHeader(uri, options = {}) {\n return {\n rejectUnauthorized: this.strictSSL,\n method: options.method || 'GET',\n uri,\n json: true,\n ...options,\n };\n }\n\n /**\n * @typedef makeRequestHeaderOptions\n * @type {object}\n * @property {string} [method] - HTTP Request Method. ie GET, POST, PUT, DELETE\n */\n\n /**\n * @name makeUri\n * @function\n * Creates a URI object for a given pathname\n * @param {object} [options] - an object containing path information\n */\n makeUri({\n pathname, query, intermediatePath, encode = false,\n }) {\n const intermediateToUse = this.intermediatePath || intermediatePath;\n const tempPath = intermediateToUse || `/rest/api/${this.apiVersion}`;\n const uri = url.format({\n protocol: this.protocol,\n hostname: this.host,\n port: this.port,\n pathname: `${this.base}${tempPath}${pathname}`,\n query,\n });\n return encode ? encodeURI(uri) : decodeURIComponent(uri);\n }\n\n /**\n * @typedef makeUriOptions\n * @type {object}\n * @property {string} pathname - The url after the /rest/api/version\n * @property {object} query - a query object\n * @property {string} intermediatePath - If specified will overwrite the /rest/api/version section\n */\n\n /**\n * @name makeWebhookUri\n * @function\n * Creates a URI object for a given pathName\n * @param {object} [options] - An options object specifying uri information\n */\n makeWebhookUri({ pathname, intermediatePath }) {\n const intermediateToUse = this.intermediatePath || intermediatePath;\n const tempPath = intermediateToUse || `/rest/webhooks/${this.webhookVersion}`;\n const uri = url.format({\n protocol: this.protocol,\n hostname: this.host,\n port: this.port,\n pathname: `${this.base}${tempPath}${pathname}`,\n });\n return decodeURIComponent(uri);\n }\n\n /**\n * @typedef makeWebhookUriOptions\n * @type {object}\n * @property {string} pathname - The url after the /rest/webhooks\n * @property {string} intermediatePath - If specified will overwrite the /rest/webhooks section\n */\n\n /**\n * @name makeSprintQueryUri\n * @function\n * Creates a URI object for a given pathName\n * @param {object} [options] - The url after the /rest/\n */\n makeSprintQueryUri({ pathname, query, intermediatePath }) {\n const intermediateToUse = this.intermediatePath || intermediatePath;\n const tempPath = intermediateToUse || `/rest/greenhopper/${this.greenhopperVersion}`;\n const uri = url.format({\n protocol: this.protocol,\n hostname: this.host,\n port: this.port,\n pathname: `${this.base}${tempPath}${pathname}`,\n query,\n });\n return decodeURIComponent(uri);\n }\n\n /**\n * @typedef makeSprintQueryUriOptions\n * @type {object}\n * @property {string} pathname - The url after the /rest/api/version\n * @property {object} query - a query object\n * @property {string} intermediatePath - will overwrite the /rest/greenhopper/version section\n */\n\n /**\n * @typedef makeDevStatusUri\n * @function\n * Creates a URI object for a given pathname\n * @arg {pathname, query, intermediatePath} obj1\n * @param {string} pathname obj1.pathname - The url after the /rest/api/version\n * @param {object} query obj1.query - a query object\n * @param {string} intermediatePath obj1.intermediatePath - If specified will overwrite the\n * /rest/dev-status/latest/issue/detail section\n */\n makeDevStatusUri({ pathname, query, intermediatePath }) {\n const intermediateToUse = this.intermediatePath || intermediatePath;\n const tempPath = intermediateToUse || '/rest/dev-status/latest/issue';\n const uri = url.format({\n protocol: this.protocol,\n hostname: this.host,\n port: this.port,\n pathname: `${this.base}${tempPath}${pathname}`,\n query,\n });\n return decodeURIComponent(uri);\n }\n\n /**\n * @name makeAgile1Uri\n * @function\n * Creates a URI object for a given pathname\n * @param {UriOptions} object\n */\n makeAgileUri(object) {\n const intermediateToUse = this.intermediatePath || object.intermediatePath;\n const tempPath = intermediateToUse || '/rest/agile/1.0';\n const uri = url.format({\n protocol: this.protocol,\n hostname: this.host,\n port: this.port,\n pathname: `${this.base}${tempPath}${object.pathname}`,\n query: object.query,\n });\n return decodeURIComponent(uri);\n }\n\n /**\n * @name doRequest\n * @function\n * Does a request based on the requestOptions object\n * @param {object} requestOptions - fields on this object get posted as a request header for\n * requests to jira\n */\n async doRequest(requestOptions) {\n const options = {\n ...this.baseOptions,\n ...requestOptions,\n };\n\n const response = await this.request(options);\n\n if (response) {\n if (Array.isArray(response.errorMessages) && response.errorMessages.length > 0) {\n throw new Error(response.errorMessages.join(', '));\n }\n }\n\n return response;\n }\n\n /**\n * @name findIssue\n * @function\n * Find an issue in jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290709)\n * @param {string} issueNumber - The issue number to search for including the project key\n * @param {string} expand - The resource expansion to return additional fields in the response\n * @param {string} fields - Comma separated list of field ids or keys to retrieve\n * @param {string} properties - Comma separated list of properties to retrieve\n * @param {boolean} fieldsByKeys - False by default, used to retrieve fields by key instead of id\n */\n findIssue(issueNumber, expand, fields, properties, fieldsByKeys) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}`,\n query: {\n expand: expand || '',\n fields: fields || '*all',\n properties: properties || '*all',\n fieldsByKeys: fieldsByKeys || false,\n },\n })));\n }\n\n /**\n * @name downloadAttachment\n * @function\n * Download an attachment\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id288524)\n * @param {object} attachment - the attachment\n */\n downloadAttachment(attachment) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/attachment/${attachment.id}/${attachment.filename}`,\n intermediatePath: '/secure',\n encode: true,\n }), { json: false, encoding: null }));\n }\n\n /**\n * @name deleteAttachment\n * @function\n * Remove the attachment\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issue-attachments/#api-rest-api-3-attachment-id-delete)\n * @param {string} attachmentId - the attachment id\n */\n deleteAttachment(attachmentId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/attachment/${attachmentId}`,\n }), { method: 'DELETE', json: false, encoding: null }));\n }\n\n /**\n * @name getUnresolvedIssueCount\n * @function\n * Get the unresolved issue count\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id288524)\n * @param {string} version - the version of your product you want to find the unresolved\n * issues of.\n */\n async getUnresolvedIssueCount(version) {\n const requestHeaders = this.makeRequestHeader(\n this.makeUri({\n pathname: `/version/${version}/unresolvedIssueCount`,\n }),\n );\n const response = await this.doRequest(requestHeaders);\n return response.issuesUnresolvedCount;\n }\n\n /**\n * @name getProject\n * @function\n * Get the Project by project key\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id289232)\n * @param {string} project - key for the project\n */\n getProject(project) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/project/${project}`,\n })));\n }\n\n /**\n * @name createProject\n * @function\n * Create a new Project\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#api/2/project-createProject)\n * @param {object} project - with specs\n */\n createProject(project) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/project/',\n }), {\n method: 'POST',\n body: project,\n }));\n }\n\n /** Find the Rapid View for a specified project\n * @name findRapidView\n * @function\n * @param {string} projectName - name for the project\n */\n async findRapidView(projectName) {\n const response = await this.doRequest(this.makeRequestHeader(this.makeSprintQueryUri({\n pathname: '/rapidviews/list',\n })));\n\n if (typeof projectName === 'undefined' || projectName === null) return response.views;\n\n const rapidViewResult = response.views\n .find((x) => x.name.toLowerCase() === projectName.toLowerCase());\n\n return rapidViewResult;\n }\n\n /** Get the most recent sprint for a given rapidViewId\n * @name getLastSprintForRapidView\n * @function\n * @param {string} rapidViewId - the id for the rapid view\n */\n async getLastSprintForRapidView(rapidViewId) {\n const response = await this.doRequest(\n this.makeRequestHeader(this.makeSprintQueryUri({\n pathname: `/sprintquery/${rapidViewId}`,\n })),\n );\n return response.sprints.pop();\n }\n\n /** Get the issues for a rapidView / sprint\n * @name getSprintIssues\n * @function\n * @param {string} rapidViewId - the id for the rapid view\n * @param {string} sprintId - the id for the sprint\n */\n getSprintIssues(rapidViewId, sprintId) {\n return this.doRequest(this.makeRequestHeader(this.makeSprintQueryUri({\n pathname: '/rapid/charts/sprintreport',\n query: {\n rapidViewId,\n sprintId,\n },\n })));\n }\n\n /** Get a list of Sprints belonging to a Rapid View\n * @name listSprints\n * @function\n * @param {string} rapidViewId - the id for the rapid view\n */\n listSprints(rapidViewId) {\n return this.doRequest(this.makeRequestHeader(this.makeSprintQueryUri({\n pathname: `/sprintquery/${rapidViewId}`,\n })));\n }\n\n /** Get details about a Sprint\n * @name getSprint\n * @function\n * @param {string} sprintId - the id for the sprint view\n */\n getSprint(sprintId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/sprint/${sprintId}`,\n })));\n }\n\n /** Add an issue to the project's current sprint\n * @name addIssueToSprint\n * @function\n * @param {string} issueId - the id of the existing issue\n * @param {string} sprintId - the id of the sprint to add it to\n */\n addIssueToSprint(issueId, sprintId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/sprint/${sprintId}/issue`,\n }), {\n method: 'POST',\n body: {\n issues: [issueId],\n },\n }));\n }\n\n /** Create an issue link between two issues\n * @name issueLink\n * @function\n * @param {object} link - a link object formatted how the Jira API specifies\n */\n issueLink(link) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/issueLink',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: link,\n }));\n }\n\n /** List all issue link types jira knows about\n * [Jira Doc](https://docs.atlassian.com/software/jira/docs/api/REST/8.5.0/#api/2/issueLinkType-getIssueLinkTypes)\n * @name listIssueLinkTypes\n * @function\n */\n listIssueLinkTypes() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/issueLinkType',\n })));\n }\n\n /** Retrieves the remote links associated with the given issue.\n * @name getRemoteLinks\n * @function\n * @param {string} issueNumber - the issue number to find remote links for.\n */\n getRemoteLinks(issueNumber) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/remotelink`,\n })));\n }\n\n /**\n * @name createRemoteLink\n * @function\n * Creates a remote link associated with the given issue.\n * @param {string} issueNumber - The issue number to create the remotelink under\n * @param {object} remoteLink - the remotelink object as specified by the Jira API\n */\n createRemoteLink(issueNumber, remoteLink) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/remotelink`,\n }), {\n method: 'POST',\n body: remoteLink,\n }));\n }\n\n /**\n * @name deleteRemoteLink\n * @function\n * Delete a remote link with given issueNumber and id\n * @param {string} issueNumber - The issue number to delete the remotelink under\n * @param {string} id the remotelink id\n */\n deleteRemoteLink(issueNumber, id) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/remotelink/${id}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /** Get Versions for a project\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id289653)\n * @name getVersions\n * @function\n * @param {string} project - A project key to get versions for\n */\n getVersions(project) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/project/${project}/versions`,\n })));\n }\n\n /** Get details of single Version in project\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/version-getVersion)\n * @name getVersion\n * @function\n * @param {string} version - The id of this version\n */\n getVersion(version) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/version/${version}`,\n })));\n }\n\n /** Create a version\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id288232)\n * @name createVersion\n * @function\n * @param {object} version - an object of the new version\n */\n createVersion(version) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/version',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: version,\n }));\n }\n\n /** Update a version\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#d2e510)\n * @name updateVersion\n * @function\n * @param {object} version - an new object of the version to update\n */\n updateVersion(version) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/version/${version.id}`,\n }), {\n method: 'PUT',\n followAllRedirects: true,\n body: version,\n }));\n }\n\n /** Delete a version\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#api/2/version-delete)\n * @name deleteVersion\n * @function\n * @param {string} versionId - the ID of the version to delete\n * @param {string} moveFixIssuesToId - when provided, existing fixVersions will be moved\n * to this ID. Otherwise, the deleted version will be removed from all\n * issue fixVersions.\n * @param {string} moveAffectedIssuesToId - when provided, existing affectedVersions will\n * be moved to this ID. Otherwise, the deleted version will be removed\n * from all issue affectedVersions.\n */\n deleteVersion(versionId, moveFixIssuesToId, moveAffectedIssuesToId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/version/${versionId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n qs: {\n moveFixIssuesTo: moveFixIssuesToId,\n moveAffectedIssuesTo: moveAffectedIssuesToId,\n },\n }));\n }\n\n /** Move version\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/version-moveVersion)\n * @name moveVersion\n * @function\n * @param {string} versionId - the ID of the version to delete\n * @param {string} position - an object of the new position\n */\n\n moveVersion(versionId, position) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/version/${versionId}/move`,\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: position,\n }));\n }\n\n /** Pass a search query to Jira\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#d2e4424)\n * @name searchJira\n * @function\n * @param {string} searchString - jira query string in JQL\n * @param {object} optional - object containing any of the following properties\n * @param {integer} [optional.startAt=0]: optional starting index number\n * @param {integer} [optional.maxResults=50]: optional The maximum number of items to\n * return per page. To manage page size, Jira may return fewer items per\n * page where a large number of fields are requested.\n * @param {array} [optional.fields]: optional array of string names of desired fields\n * @param {array} [optional.expand]: optional array of string names of desired expand nodes\n */\n searchJira(searchString, optional = {}) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/search',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: {\n jql: searchString,\n ...optional,\n },\n }));\n }\n\n /** Create a Jira user\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/user-createUser)\n * @name createUser\n * @function\n * @param {object} user - Properly Formatted User object\n */\n createUser(user) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/user',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: user,\n }));\n }\n\n /** Search user on Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#d2e3756)\n * @name searchUsers\n * @function\n * @param {SearchUserOptions} options\n */\n searchUsers({\n username, query, startAt, maxResults, includeActive, includeInactive,\n }) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/user/search',\n query: {\n username,\n query,\n startAt: startAt || 0,\n maxResults: maxResults || 50,\n includeActive: includeActive || true,\n includeInactive: includeInactive || false,\n },\n }), {\n followAllRedirects: true,\n }));\n }\n\n /**\n * @typedef SearchUserOptions\n * @type {object}\n * @property {string} username - (DEPRECATED) A query string used to search username, name or\n * e-mail address\n * @property {string} query - A query string that is matched against user attributes\n * (displayName, and emailAddress) to find relevant users. The string can match the prefix of\n * the attribute's value. For example, query=john matches a user with a displayName of John\n * Smith and a user with an emailAddress of johnson@example.com. Required, unless accountId\n * or property is specified.\n * @property {integer} [startAt=0] - The index of the first user to return (0-based)\n * @property {integer} [maxResults=50] - The maximum number of users to return\n * @property {boolean} [includeActive=true] - If true, then active users are included\n * in the results\n * @property {boolean} [includeInactive=false] - If true, then inactive users\n * are included in the results\n */\n\n /** Get all users in group on Jira\n * @name getUsersInGroup\n * @function\n * @param {string} groupname - A query string used to search users in group\n * @param {integer} [startAt=0] - The index of the first user to return (0-based)\n * @param {integer} [maxResults=50] - The maximum number of users to return (defaults to 50).\n */\n getUsersInGroup(groupname, startAt = 0, maxResults = 50) {\n return this.doRequest(\n this.makeRequestHeader(this.makeUri({\n pathname: '/group',\n query: {\n groupname,\n expand: `users[${startAt}:${maxResults}]`,\n },\n }), {\n followAllRedirects: true,\n }),\n );\n }\n\n /** Get issues related to a user\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id296043)\n * @name getUsersIssues\n * @function\n * @param {string} username - username of user to search for\n * @param {boolean} open - determines if only open issues should be returned\n */\n getUsersIssues(username, open) {\n const openJql = open ? ' AND status in (Open, \\'In Progress\\', Reopened)' : '';\n return this.searchJira(`assignee = ${username.replace('@', '\\\\u0040')}${openJql}`, {});\n }\n\n /** Returns a user.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-user-get)\n * @name getUser\n * @function\n * @param {string} accountId - The accountId of user to search for\n * @param {string} expand - The expand for additional info (groups,applicationRoles)\n */\n getUser(accountId, expand) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/user',\n query: {\n accountId,\n expand,\n },\n })));\n }\n\n /** Returns a list of all (active and inactive) users.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-users-search-get)\n * @name getUsers\n * @function\n * @param {integer} [startAt=0] - The index of the first user to return (0-based)\n * @param {integer} [maxResults=50] - The maximum number of users to return (defaults to 50).\n */\n getUsers(startAt = 0, maxResults = 100) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/users',\n query: {\n startAt,\n maxResults,\n },\n })));\n }\n\n /** Add issue to Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290028)\n * @name addNewIssue\n * @function\n * @param {object} issue - Properly Formatted Issue object\n */\n addNewIssue(issue) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/issue',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: issue,\n }));\n }\n\n /** Add a user as a watcher on an issue\n * @name addWatcher\n * @function\n * @param {string} issueKey - the key of the existing issue\n * @param {string} username - the jira username to add as a watcher to the issue\n */\n addWatcher(issueKey, username) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueKey}/watchers`,\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: username,\n }));\n }\n\n /** Change an assignee on an issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/issue-assign)\n * @name assignee\n * @function\n * @param {string} issueKey - the key of the existing issue\n * @param {string} assigneeName - the jira username to add as a new assignee to the issue\n */\n updateAssignee(issueKey, assigneeName) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueKey}/assignee`,\n }), {\n method: 'PUT',\n followAllRedirects: true,\n body: { name: assigneeName },\n }));\n }\n\n /** Change an assignee on an issue\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v2/#api-rest-api-2-issue-issueIdOrKey-assignee-put)\n * @name updateAssigneeWithId\n * @function\n * @param {string} issueKey - the key of the existing issue\n * @param {string} userId - the jira username to add as a new assignee to the issue\n */\n updateAssigneeWithId(issueKey, userId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueKey}/assignee`,\n }), {\n method: 'PUT',\n followAllRedirects: true,\n body: { accountId: userId },\n }));\n }\n\n /** Delete issue from Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290791)\n * @name deleteIssue\n * @function\n * @param {string} issueId - the Id of the issue to delete\n */\n deleteIssue(issueId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /** Update issue in Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290878)\n * @name updateIssue\n * @function\n * @param {string} issueId - the Id of the issue to update\n * @param {object} issueUpdate - update Object as specified by the rest api\n * @param {object} query - adds parameters to the query string\n */\n updateIssue(issueId, issueUpdate, query = {}) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}`,\n query,\n }), {\n body: issueUpdate,\n method: 'PUT',\n followAllRedirects: true,\n }));\n }\n\n /** List Components\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290489)\n * @name listComponents\n * @function\n * @param {string} project - key for the project\n */\n listComponents(project) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/project/${project}/components`,\n })));\n }\n\n /** Add component to Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290028)\n * @name addNewComponent\n * @function\n * @param {object} component - Properly Formatted Component\n */\n addNewComponent(component) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/component',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: component,\n }));\n }\n\n /** Update Jira component\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/component-updateComponent)\n * @name updateComponent\n * @function\n * @param {string} componentId - the Id of the component to update\n * @param {object} component - Properly Formatted Component\n */\n updateComponent(componentId, component) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/component/${componentId}`,\n }), {\n method: 'PUT',\n followAllRedirects: true,\n body: component,\n }));\n }\n\n /** Delete component from Jira\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v2/#api-api-2-component-id-delete)\n * @name deleteComponent\n * @function\n * @param {string} id - The ID of the component.\n * @param {string} moveIssuesTo - The ID of the component to replace the deleted component.\n * If this value is null no replacement is made.\n */\n deleteComponent(id, moveIssuesTo) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/component/${id}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n qs: moveIssuesTo ? { moveIssuesTo } : null,\n }));\n }\n\n /** Get count of issues assigned to the component.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v2/#api-rest-api-2-component-id-relatedIssueCounts-get)\n * @name relatedIssueCounts\n * @function\n * @param {string} id - Component Id.\n */\n relatedIssueCounts(id) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/component/${id}/relatedIssueCounts`,\n })));\n }\n\n /** Create custom Jira field\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field-createCustomField)\n * @name createCustomField\n * @function\n * @param {object} field - Properly formatted Field object\n */\n createCustomField(field) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/field',\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: field,\n }));\n }\n\n /** List all fields custom and not that jira knows about.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290489)\n * @name listFields\n * @function\n */\n listFields() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/field',\n })));\n }\n\n /** Add an option for a select list issue field.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field/{fieldKey}/option-createOption)\n * @name createFieldOption\n * @function\n * @param {string} fieldKey - the key of the select list field\n * @param {object} option - properly formatted Option object\n */\n createFieldOption(fieldKey, option) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/field/${fieldKey}/option`,\n }), {\n method: 'POST',\n followAllRedirects: true,\n body: option,\n }));\n }\n\n /** Returns all options defined for a select list issue field.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field/{fieldKey}/option-getAllOptions)\n * @name listFieldOptions\n * @function\n * @param {string} fieldKey - the key of the select list field\n */\n listFieldOptions(fieldKey) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/field/${fieldKey}/option`,\n })));\n }\n\n /** Creates or updates an option for a select list issue field.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field/{fieldKey}/option-putOption)\n * @name upsertFieldOption\n * @function\n * @param {string} fieldKey - the key of the select list field\n * @param {string} optionId - the id of the modified option\n * @param {object} option - properly formatted Option object\n */\n upsertFieldOption(fieldKey, optionId, option) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/field/${fieldKey}/option/${optionId}`,\n }), {\n method: 'PUT',\n followAllRedirects: true,\n body: option,\n }));\n }\n\n /** Returns an option for a select list issue field.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field/{fieldKey}/option-getOption)\n * @name getFieldOption\n * @function\n * @param {string} fieldKey - the key of the select list field\n * @param {string} optionId - the id of the option\n */\n getFieldOption(fieldKey, optionId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/field/${fieldKey}/option/${optionId}`,\n })));\n }\n\n /** Deletes an option from a select list issue field.\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#api/2/field/{fieldKey}/option-delete)\n * @name deleteFieldOption\n * @function\n * @param {string} fieldKey - the key of the select list field\n * @param {string} optionId - the id of the deleted option\n */\n deleteFieldOption(fieldKey, optionId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/field/${fieldKey}/option/${optionId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /**\n * @name getIssueProperty\n * @function\n * Get Property of Issue by Issue and Property Id\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/issue/{issueIdOrKey}/properties-getProperty)\n * @param {string} issueNumber - The issue number to search for including the project key\n * @param {string} property - The property key to search for\n */\n getIssueProperty(issueNumber, property) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/properties/${property}`,\n })));\n }\n\n /**\n * @name getIssueChangelog\n * @function\n * List all changes for an issue, sorted by date, starting from the latest\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/issue/{issueIdOrKey}/changelog)\n * @param {string} issueNumber - The issue number to search for including the project key\n * @param {integer} [startAt=0] - optional starting index number\n * @param {integer} [maxResults=50] - optional ending index number\n */\n getIssueChangelog(issueNumber, startAt = 0, maxResults = 50) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/changelog`,\n query: {\n startAt,\n maxResults,\n },\n })));\n }\n\n /**\n * @name getIssueWatchers\n * @function\n * List all watchers for an issue\n * [Jira Doc](http://docs.atlassian.com/jira/REST/cloud/#api/2/issue-getIssueWatchers)\n * @param {string} issueNumber - The issue number to search for including the project key\n */\n getIssueWatchers(issueNumber) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueNumber}/watchers`,\n })));\n }\n\n /** List all priorities jira knows about\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290489)\n * @name listPriorities\n * @function\n */\n listPriorities() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/priority',\n })));\n }\n\n /** List Transitions for a specific issue that are available to the current user\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290489)\n * @name listTransitions\n * @function\n * @param {string} issueId - get transitions available for the issue\n */\n listTransitions(issueId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/transitions`,\n query: {\n expand: 'transitions.fields',\n },\n })));\n }\n\n /** Transition issue in Jira\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id290489)\n * @name transitionsIssue\n * @function\n * @param {string} issueId - the Id of the issue to delete\n * @param {object} issueTransition - transition object from the jira rest API\n */\n transitionIssue(issueId, issueTransition) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/transitions`,\n }), {\n body: issueTransition,\n method: 'POST',\n followAllRedirects: true,\n }));\n }\n\n /** List all Viewable Projects\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id289193)\n * @name listProjects\n * @function\n */\n listProjects() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/project',\n })));\n }\n\n /** Add a comment to an issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#id108798)\n * @name addComment\n * @function\n * @param {string} issueId - Issue to add a comment to\n * @param {string} comment - string containing comment\n */\n addComment(issueId, comment) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment`,\n }), {\n body: {\n body: comment,\n },\n method: 'POST',\n followAllRedirects: true,\n }));\n }\n\n /** Add a comment to an issue, supports full comment object\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#id108798)\n * @name addCommentAdvanced\n * @function\n * @param {string} issueId - Issue to add a comment to\n * @param {object} comment - The object containing your comment data\n */\n addCommentAdvanced(issueId, comment) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment`,\n }), {\n body: comment,\n method: 'POST',\n followAllRedirects: true,\n }));\n }\n\n /** Update comment for an issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/issue-updateComment)\n * @name updateComment\n * @function\n * @param {string} issueId - Issue with the comment\n * @param {string} commentId - Comment that is updated\n * @param {string} comment - string containing new comment\n * @param {object} [options={}] - extra options\n */\n updateComment(issueId, commentId, comment, options = {}) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment/${commentId}`,\n }), {\n body: {\n body: comment,\n ...options,\n },\n method: 'PUT',\n followAllRedirects: true,\n }));\n }\n\n /**\n * @name getComments\n * @function\n * Get Comments by IssueId.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-comment-list-post)\n * @param {string} issueId - this issue this comment is on\n */\n getComments(issueId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment`,\n })));\n }\n\n /**\n * @name getComment\n * @function\n * Get Comment by Id.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-comment-list-post)\n * @param {string} issueId - this issue this comment is on\n * @param {number} commentId - the id of the comment\n */\n getComment(issueId, commentId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment/${commentId}`,\n })));\n }\n\n /**\n * @name deleteComment\n * @function\n * Delete Comments by Id.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-comment-list-post)\n * @param {string} issueId - this issue this comment is on\n * @param {number} commentId - the id of the comment\n */\n deleteComment(issueId, commentId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/comment/${commentId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /** Add a worklog to a project\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id291617)\n * @name addWorklog\n * @function\n * @param {string} issueId - Issue to add a worklog to\n * @param {object} worklog - worklog object from the rest API\n * @param {object} newEstimate - the new value for the remaining estimate field\n * @param {object} [options={}] - extra options\n */\n addWorklog(issueId, worklog, newEstimate = null, options = {}) {\n const query = {\n adjustEstimate: newEstimate ? 'new' : 'auto',\n ...newEstimate ? { newEstimate } : {},\n ...options,\n };\n\n const header = {\n uri: this.makeUri({\n pathname: `/issue/${issueId}/worklog`,\n query,\n }),\n body: worklog,\n method: 'POST',\n 'Content-Type': 'application/json',\n json: true,\n };\n\n return this.doRequest(header);\n }\n\n /** Get ids of worklogs modified since\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/worklog-getWorklogsForIds)\n * @name updatedWorklogs\n * @function\n * @param {number} since - a date time in unix timestamp format since when updated worklogs\n * will be returned.\n * @param {string} expand - ptional comma separated list of parameters to expand: properties\n * (provides worklog properties).\n */\n updatedWorklogs(since, expand) {\n const header = {\n uri: this.makeUri({\n pathname: '/worklog/updated',\n query: { since, expand },\n }),\n method: 'GET',\n 'Content-Type': 'application/json',\n json: true,\n };\n\n return this.doRequest(header);\n }\n\n /** Delete worklog from issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#d2e1673)\n * @name deleteWorklog\n * @function\n * @param {string} issueId - the Id of the issue to delete\n * @param {string} worklogId - the Id of the worklog in issue to delete\n */\n deleteWorklog(issueId, worklogId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/worklog/${worklogId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /** Deletes an issue link.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-issueLink-linkId-delete)\n * @name deleteIssueLink\n * @function\n * @param {string} linkId - the Id of the issue link to delete\n */\n deleteIssueLink(linkId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issueLink/${linkId}`,\n }), {\n method: 'DELETE',\n followAllRedirects: true,\n }));\n }\n\n /** Returns worklog details for a list of worklog IDs.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-rest-api-3-worklog-list-post)\n * @name getWorklogs\n * @function\n * @param {array} worklogsIDs - a list of worklog IDs.\n * @param {string} expand - expand to include additional information about worklogs\n *\n */\n getWorklogs(worklogsIDs, expand) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/worklog/list',\n query: {\n expand,\n },\n }), {\n method: 'POST',\n body: {\n ids: worklogsIDs,\n },\n }));\n }\n\n /** Get worklogs list from a given issue\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/#api-api-3-issue-issueIdOrKey-worklog-get)\n * @name getIssueWorklogs\n * @function\n * @param {string} issueId - the Id of the issue to find worklogs for\n * @param {integer} [startAt=0] - optional starting index number\n * @param {integer} [maxResults=1000] - optional ending index number\n */\n getIssueWorklogs(issueId, startAt = 0, maxResults = 1000) {\n return this.doRequest(this.makeRequestHeader(\n this.makeUri({\n pathname: `/issue/${issueId}/worklog`,\n query: {\n startAt,\n maxResults,\n },\n }),\n ));\n }\n\n /** List all Issue Types jira knows about\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id295946)\n * @name listIssueTypes\n * @function\n */\n listIssueTypes() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/issuetype',\n })));\n }\n\n /** Register a webhook\n * [Jira Doc](https://developer.atlassian.com/display/JIRADEV/JIRA+Webhooks+Overview)\n * @name registerWebhook\n * @function\n * @param {object} webhook - properly formatted webhook\n */\n registerWebhook(webhook) {\n return this.doRequest(this.makeRequestHeader(this.makeWebhookUri({\n pathname: '/webhook',\n }), {\n method: 'POST',\n body: webhook,\n }));\n }\n\n /** List all registered webhooks\n * [Jira Doc](https://developer.atlassian.com/display/JIRADEV/JIRA+Webhooks+Overview)\n * @name listWebhooks\n * @function\n */\n listWebhooks() {\n return this.doRequest(this.makeRequestHeader(this.makeWebhookUri({\n pathname: '/webhook',\n })));\n }\n\n /** Get a webhook by its ID\n * [Jira Doc](https://developer.atlassian.com/display/JIRADEV/JIRA+Webhooks+Overview)\n * @name getWebhook\n * @function\n * @param {string} webhookID - id of webhook to get\n */\n getWebhook(webhookID) {\n return this.doRequest(this.makeRequestHeader(this.makeWebhookUri({\n pathname: `/webhook/${webhookID}`,\n })));\n }\n\n /** Delete a registered webhook\n * [Jira Doc](https://developer.atlassian.com/display/JIRADEV/JIRA+Webhooks+Overview)\n * @name issueLink\n * @function\n * @param {string} webhookID - id of the webhook to delete\n */\n deleteWebhook(webhookID) {\n return this.doRequest(this.makeRequestHeader(this.makeWebhookUri({\n pathname: `/webhook/${webhookID}`,\n }), {\n method: 'DELETE',\n }));\n }\n\n /** Describe the currently authenticated user\n * [Jira Doc](http://docs.atlassian.com/jira/REST/latest/#id2e865)\n * @name getCurrentUser\n * @function\n */\n getCurrentUser() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/myself',\n })));\n }\n\n /** Retrieve the backlog of a certain Rapid View\n * @name getBacklogForRapidView\n * @function\n * @param {string} rapidViewId - rapid view id\n */\n getBacklogForRapidView(rapidViewId) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/xboard/plan/backlog/data',\n query: {\n rapidViewId,\n },\n })));\n }\n\n /** Add attachment to a Issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#api/2/issue/{issueIdOrKey}/attachments-addAttachment)\n * @name addAttachmentOnIssue\n * @function\n * @param {string} issueId - issue id\n * @param {object} readStream - readStream object from fs\n */\n addAttachmentOnIssue(issueId, readStream) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/attachments`,\n }), {\n method: 'POST',\n headers: {\n 'X-Atlassian-Token': 'nocheck',\n },\n formData: {\n file: readStream,\n },\n }));\n }\n\n /** Notify people related to issue\n * [Jira Doc](https://docs.atlassian.com/jira/REST/cloud/#api/2/issue-notify)\n * @name issueNotify\n * @function\n * @param {string} issueId - issue id\n * @param {object} notificationBody - properly formatted body\n */\n issueNotify(issueId, notificationBody) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/issue/${issueId}/notify`,\n }), {\n method: 'POST',\n body: notificationBody,\n }));\n }\n\n /** Get list of possible statuses\n * [Jira Doc](https://docs.atlassian.com/jira/REST/latest/#api/2/status-getStatuses)\n * @name listStatus\n * @function\n */\n listStatus() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/status',\n })));\n }\n\n /** Get a Dev-Status summary by issue ID\n * @name getDevStatusSummary\n * @function\n * @param {string} issueId - id of issue to get\n */\n getDevStatusSummary(issueId) {\n return this.doRequest(this.makeRequestHeader(this.makeDevStatusUri({\n pathname: '/summary',\n query: {\n issueId,\n },\n })));\n }\n\n /** Get a Dev-Status detail by issue ID\n * @name getDevStatusDetail\n * @function\n * @param {string} issueId - id of issue to get\n * @param {string} applicationType - type of application (stash, bitbucket)\n * @param {string} dataType - info to return (repository, pullrequest)\n */\n getDevStatusDetail(issueId, applicationType, dataType) {\n return this.doRequest(this.makeRequestHeader(this.makeDevStatusUri({\n pathname: '/detail',\n query: {\n issueId,\n applicationType,\n dataType,\n },\n })));\n }\n\n /** Get issue\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/issue-getIssue)\n * @name getIssue\n * @function\n * @param {string} issueIdOrKey - Id of issue\n * @param {string} [fields] - The list of fields to return for each issue.\n * @param {string} [expand] - A comma-separated list of the parameters to expand.\n */\n getIssue(issueIdOrKey, fields, expand) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/issue/${issueIdOrKey}`,\n query: {\n fields,\n expand,\n },\n })));\n }\n\n /** Move issues to backlog\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/backlog-moveIssuesToBacklog)\n * @name moveToBacklog\n * @function\n * @param {array} issues - id or key of issues to get\n */\n moveToBacklog(issues) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: '/backlog/issue',\n }), {\n method: 'POST',\n body: {\n issues,\n },\n }));\n }\n\n /** Get all boards\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-getAllBoards)\n * @name getAllBoards\n * @function\n * @param {number} [startAt=0] - The starting index of the returned boards.\n * @param {number} [maxResults=50] - The maximum number of boards to return per page.\n * @param {string} [type] - Filters results to boards of the specified type.\n * @param {string} [name] - Filters results to boards that match the specified name.\n * @param {string} [projectKeyOrId] - Filters results to boards that are relevant to a project.\n */\n getAllBoards(startAt = 0, maxResults = 50, type, name, projectKeyOrId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: '/board',\n query: {\n startAt,\n maxResults,\n type,\n name,\n ...projectKeyOrId && { projectKeyOrId },\n },\n })));\n }\n\n /** Create Board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-createBoard)\n * @name createBoard\n * @function\n * @param {object} boardBody - Board name, type and filter Id is required.\n * @param {string} boardBody.type - Valid values: scrum, kanban\n * @param {string} boardBody.name - Must be less than 255 characters.\n * @param {string} boardBody.filterId - Id of a filter that the user has permissions to view.\n */\n createBoard(boardBody) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: '/board',\n }), {\n method: 'POST',\n body: boardBody,\n }));\n }\n\n /** Get Board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-getBoard)\n * @name getBoard\n * @function\n * @param {string} boardId - Id of board to retrieve\n */\n getBoard(boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}`,\n })));\n }\n\n /** Delete Board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-deleteBoard)\n * @name deleteBoard\n * @function\n * @param {string} boardId - Id of board to retrieve\n */\n deleteBoard(boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}`,\n }), {\n method: 'DELETE',\n }));\n }\n\n /** Get issues for backlog\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-getIssuesForBacklog)\n * @name getIssuesForBacklog\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned issues. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of issues to return per page. Default: 50.\n * @param {string} [jql] - Filters results using a JQL query.\n * @param {boolean} [validateQuery] - Specifies whether to validate the JQL query or not.\n * Default: true.\n * @param {string} [fields] - The list of fields to return for each issue.\n */\n getIssuesForBacklog(boardId, startAt = 0, maxResults = 50, jql, validateQuery = true, fields) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/backlog`,\n query: {\n startAt,\n maxResults,\n jql,\n validateQuery,\n fields,\n },\n })));\n }\n\n /** Get Configuration\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-getConfiguration)\n * @name getConfiguration\n * @function\n * @param {string} boardId - Id of board to retrieve\n */\n getConfiguration(boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/configuration`,\n })));\n }\n\n /** Get issues for board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board-getIssuesForBoard)\n * @name getIssuesForBoard\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned issues. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of issues to return per page. Default: 50.\n * @param {string} [jql] - Filters results using a JQL query.\n * @param {boolean} [validateQuery] - Specifies whether to validate the JQL query or not.\n * Default: true.\n * @param {string} [fields] - The list of fields to return for each issue.\n */\n getIssuesForBoard(boardId, startAt = 0, maxResults = 50, jql, validateQuery = true, fields) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/issue`,\n query: {\n startAt,\n maxResults,\n jql,\n validateQuery,\n fields,\n },\n })));\n }\n\n /** Get issue estimation for board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/issue-getIssueEstimationForBoard)\n * @name getIssueEstimationForBoard\n * @function\n * @param {string} issueIdOrKey - Id of issue\n * @param {number} boardId - The id of the board required to determine which field\n * is used for estimation.\n */\n getIssueEstimationForBoard(issueIdOrKey, boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/issue/${issueIdOrKey}/estimation`,\n query: {\n boardId,\n },\n })));\n }\n\n /** Get Epics\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/epic-getEpics)\n * @name getEpics\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned epics. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of epics to return per page. Default: 50.\n * @param {string} [done] - Filters results to epics that are either done or not done.\n * Valid values: true, false.\n */\n getEpics(boardId, startAt = 0, maxResults = 50, done) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/epic`,\n query: {\n startAt,\n maxResults,\n done,\n },\n })));\n }\n\n /** Get board issues for epic\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/epic-getIssuesForEpic)\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/epic-getIssuesWithoutEpic)\n * @name getBoardIssuesForEpic\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {string} epicId - Id of epic to retrieve, specify 'none' to get issues without an epic.\n * @param {number} [startAt=0] - The starting index of the returned issues. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of issues to return per page. Default: 50.\n * @param {string} [jql] - Filters results using a JQL query.\n * @param {boolean} [validateQuery] - Specifies whether to validate the JQL query or not.\n * Default: true.\n * @param {string} [fields] - The list of fields to return for each issue.\n */\n getBoardIssuesForEpic(\n boardId,\n epicId,\n startAt = 0,\n maxResults = 50,\n jql,\n validateQuery = true,\n fields,\n ) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/epic/${epicId}/issue`,\n query: {\n startAt,\n maxResults,\n jql,\n validateQuery,\n fields,\n },\n })));\n }\n\n /** Estimate issue for board\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/issue-estimateIssueForBoard)\n * @name estimateIssueForBoard\n * @function\n * @param {string} issueIdOrKey - Id of issue\n * @param {number} boardId - The id of the board required to determine which field\n * is used for estimation.\n * @param {string} body - value to set\n */\n estimateIssueForBoard(issueIdOrKey, boardId, body) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/issue/${issueIdOrKey}/estimation`,\n query: {\n boardId,\n },\n }), {\n method: 'PUT',\n body,\n }));\n }\n\n /** Rank Issues\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/issue-rankIssues)\n * @name rankIssues\n * @function\n * @param {string} body - value to set\n */\n rankIssues(body) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: '/issue/rank',\n }), {\n method: 'PUT',\n body,\n }));\n }\n\n /** Get Projects\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/project-getProjects)\n * @name getProjects\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned projects. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of projects to return per page.\n * Default: 50.\n */\n getProjects(boardId, startAt = 0, maxResults = 50) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/project`,\n query: {\n startAt,\n maxResults,\n },\n })));\n }\n\n /** Get Projects Full\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/project-getProjectsFull)\n * @name getProjectsFull\n * @function\n * @param {string} boardId - Id of board to retrieve\n */\n getProjectsFull(boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/project/full`,\n })));\n }\n\n /** Get Board Properties Keys\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/properties-getPropertiesKeys)\n * @name getBoardPropertiesKeys\n * @function\n * @param {string} boardId - Id of board to retrieve\n */\n getBoardPropertiesKeys(boardId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/properties`,\n })));\n }\n\n /** Delete Board Property\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/properties-deleteProperty)\n * @name deleteBoardProperty\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {string} propertyKey - Id of property to delete\n */\n deleteBoardProperty(boardId, propertyKey) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/properties/${propertyKey}`,\n }), {\n method: 'DELETE',\n }));\n }\n\n /** Set Board Property\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/properties-setProperty)\n * @name setBoardProperty\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {string} propertyKey - Id of property to delete\n * @param {string} body - value to set, for objects make sure to stringify first\n */\n setBoardProperty(boardId, propertyKey, body) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/properties/${propertyKey}`,\n }), {\n method: 'PUT',\n body,\n }));\n }\n\n /** Get Board Property\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/properties-getProperty)\n * @name getBoardProperty\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {string} propertyKey - Id of property to retrieve\n */\n getBoardProperty(boardId, propertyKey) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/properties/${propertyKey}`,\n })));\n }\n\n /** Get All Sprints\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/sprint-getAllSprints)\n * @name getAllSprints\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned sprints. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of sprints to return per page.\n * Default: 50.\n * @param {string} [state] - Filters results to sprints in specified states.\n * Valid values: future, active, closed.\n */\n getAllSprints(boardId, startAt = 0, maxResults = 50, state) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/sprint`,\n query: {\n startAt,\n maxResults,\n state,\n },\n })));\n }\n\n /** Get Board issues for sprint\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/software/rest/api-group-board/#api-agile-1-0-board-boardid-sprint-sprintid-issue-get)\n * @name getBoardIssuesForSprint\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {string} sprintId - Id of sprint to retrieve\n * @param {number} [startAt=0] - The starting index of the returned issues. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of issues to return per page. Default: 50.\n * @param {string} [jql] - Filters results using a JQL query.\n * @param {boolean} [validateQuery] - Specifies whether to validate the JQL query or not.\n * Default: true.\n * @param {string} [fields] - The list of fields to return for each issue.\n * @param {string} [expand] - A comma-separated list of the parameters to expand.\n */\n getBoardIssuesForSprint(\n boardId,\n sprintId,\n startAt = 0,\n maxResults = 50,\n jql,\n validateQuery = true,\n fields,\n expand,\n ) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/sprint/${sprintId}/issue`,\n query: {\n startAt,\n maxResults,\n jql,\n validateQuery,\n fields,\n expand,\n },\n })));\n }\n\n /** Get All Versions\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/board/{boardId}/version-getAllVersions)\n * @name getAllVersions\n * @function\n * @param {string} boardId - Id of board to retrieve\n * @param {number} [startAt=0] - The starting index of the returned versions. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of versions to return per page.\n * Default: 50.\n * @param {string} [released] - Filters results to versions that are either released or\n * unreleased.Valid values: true, false.\n */\n getAllVersions(boardId, startAt = 0, maxResults = 50, released) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/board/${boardId}/version`,\n query: {\n startAt,\n maxResults,\n released,\n },\n })));\n }\n\n /** Get Filter\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/filter)\n * @name getFilter\n * @function\n * @param {string} filterId - Id of filter to retrieve\n */\n\n getFilter(filterId) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/filter/${filterId}`,\n })));\n }\n\n /** Get Epic\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-getEpic)\n * @name getEpic\n * @function\n * @param {string} epicIdOrKey - Id of epic to retrieve\n */\n getEpic(epicIdOrKey) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/epic/${epicIdOrKey}`,\n })));\n }\n\n /** Partially update epic\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-partiallyUpdateEpic)\n * @name partiallyUpdateEpic\n * @function\n * @param {string} epicIdOrKey - Id of epic to retrieve\n * @param {string} body - value to set, for objects make sure to stringify first\n */\n partiallyUpdateEpic(epicIdOrKey, body) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/epic/${epicIdOrKey}`,\n }), {\n method: 'POST',\n body,\n }));\n }\n\n /** Get issues for epic\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-getIssuesForEpic)\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-getIssuesWithoutEpic)\n * @name getIssuesForEpic\n * @function\n * @param {string} epicId - Id of epic to retrieve, specify 'none' to get issues without an epic.\n * @param {number} [startAt=0] - The starting index of the returned issues. Base index: 0.\n * @param {number} [maxResults=50] - The maximum number of issues to return per page. Default: 50.\n * @param {string} [jql] - Filters results using a JQL query.\n * @param {boolean} [validateQuery] - Specifies whether to validate the JQL query or not.\n * Default: true.\n * @param {string} [fields] - The list of fields to return for each issue.\n */\n getIssuesForEpic(\n epicId,\n startAt = 0,\n maxResults = 50,\n jql,\n validateQuery = true,\n fields,\n ) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/epic/${epicId}/issue`,\n query: {\n startAt,\n maxResults,\n jql,\n validateQuery,\n fields,\n },\n })));\n }\n\n /** Move Issues to Epic\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-moveIssuesToEpic)\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-removeIssuesFromEpic)\n * @name moveIssuesToEpic\n * @function\n * @param {string} epicIdOrKey - Id of epic to move issue to, or 'none' to remove from epic\n * @param {array} issues - array of issues to move\n */\n moveIssuesToEpic(epicIdOrKey, issues) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/epic/${epicIdOrKey}/issue`,\n }), {\n method: 'POST',\n body: {\n issues,\n },\n }));\n }\n\n /** Rank Epics\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/#agile/1.0/epic-rankEpics)\n * @name rankEpics\n * @function\n * @param {string} epicIdOrKey - Id of epic\n * @param {string} body - value to set\n */\n rankEpics(epicIdOrKey, body) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/epic/${epicIdOrKey}/rank`,\n }), {\n method: 'PUT',\n body,\n }));\n }\n\n /**\n * @name getServerInfo\n * @function\n * Get server info\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v2/#api-api-2-serverInfo-get)\n */\n getServerInfo() {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/serverInfo',\n })));\n }\n\n /**\n * @name getIssueCreateMetadata\n * @param {object} optional - object containing any of the following properties\n * @param {array} [optional.projectIds]: optional Array of project ids to return metadata for\n * @param {array} [optional.projectKeys]: optional Array of project keys to return metadata for\n * @param {array} [optional.issuetypeIds]: optional Array of issuetype ids to return metadata for\n * @param {array} [optional.issuetypeNames]: optional Array of issuetype names to return metadata\n * for\n * @param {string} [optional.expand]: optional Include additional information about issue\n * metadata. Valid value is 'projects.issuetypes.fields'\n * Get metadata for creating an issue.\n * [Jira Doc](https://developer.atlassian.com/cloud/jira/platform/rest/v3/api-group-issues/#api-rest-api-3-issue-createmeta-get)\n */\n getIssueCreateMetadata(optional = {}) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: '/issue/createmeta',\n query: optional,\n })));\n }\n\n /** Generic Get Request\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/2/)\n * @name genericGet\n * @function\n * @param {string} endpoint - Rest API endpoint\n */\n genericGet(endpoint) {\n return this.doRequest(this.makeRequestHeader(this.makeUri({\n pathname: `/${endpoint}`,\n })));\n }\n\n /** Generic Get Request to the Agile API\n * [Jira Doc](https://docs.atlassian.com/jira-software/REST/cloud/2/)\n * @name genericGet\n * @function\n * @param {string} endpoint - Rest API endpoint\n */\n genericAgileGet(endpoint) {\n return this.doRequest(this.makeRequestHeader(this.makeAgileUri({\n pathname: `/${endpoint}`,\n })));\n }\n}\n",
"static": true,
"longname": "/Users/piou/Dev/node-jira-client/src/jira.js",
"access": "public",
"description": null,
"lineNumber": 1
},
{
"__docId__": 49,
"kind": "function",
"name": "request",
"memberof": "src/jira.js",
"generator": false,
"async": false,
"static": true,
"longname": "src/jira.js~request",
"access": "public",
"export": false,
"importPath": "jira-client/src/jira.js",
"importStyle": null,
"description": null,
"lineNumber": 4,
"undocument": true,
"params": [
{
"name": "uri",
"types": [
"*"
]
},
{
"name": "options",
"types": [
"*"
]
}
],
"return": {
"types": [
"*"
]
},
"ignore": true
},
{
"__docId__": 50,
"kind": "class",
"name": "JiraApi",
"memberof": "src/jira.js",
"static": true,
"longname": "src/jira.js~JiraApi",
"access": "public",
"export": true,
"importPath": "jira-client/src/jira.js",
"importStyle": "JiraApi",
"description": "",
"lineNumber": 22,
"unknown": [
{
"tagName": "@class",
"tagValue": "Wrapper for the JIRA Rest Api\nhttps://docs.atlassian.com/jira/REST/6.4.8/"
}
],
"interface": false
},
{
"__docId__": 51,
"kind": "constructor",
"name": "constructor",
"memberof": "src/jira.js~JiraApi",
"generator": false,
"async": false,
"static": false,
"longname": "src/jira.js~JiraApi#constructor",
"access": "public",
"description": "",
"lineNumber": 28,
"unknown": [
{
"tagName": "@constructor",
"tagValue": ""
},
{
"tagName": "@function",
"tagValue": ""
}
],
"params": [
{
"nullable": null,
"types": [
"JiraApiOptions"
],
"spread": false,
"optional": false,
"name": "options",
"description": ""
}
]
},
{
"__docId__": 52,
"kind": "member",
"name": "protocol",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#protocol",
"access": "public",
"description": null,
"lineNumber": 29,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 53,
"kind": "member",
"name": "host",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#host",
"access": "public",
"description": null,
"lineNumber": 30,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 54,
"kind": "member",
"name": "port",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#port",
"access": "public",
"description": null,
"lineNumber": 31,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 55,
"kind": "member",
"name": "apiVersion",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#apiVersion",
"access": "public",
"description": null,
"lineNumber": 32,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 56,
"kind": "member",
"name": "base",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#base",
"access": "public",
"description": null,
"lineNumber": 33,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 57,
"kind": "member",
"name": "intermediatePath",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#intermediatePath",
"access": "public",
"description": null,
"lineNumber": 34,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 58,
"kind": "member",
"name": "strictSSL",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#strictSSL",
"access": "public",
"description": null,
"lineNumber": 35,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 59,
"kind": "member",
"name": "request",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#request",
"access": "public",
"description": null,
"lineNumber": 37,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 60,
"kind": "member",
"name": "webhookVersion",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#webhookVersion",
"access": "public",
"description": null,
"lineNumber": 38,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 61,
"kind": "member",
"name": "greenhopperVersion",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#greenhopperVersion",
"access": "public",
"description": null,
"lineNumber": 39,
"undocument": true,
"type": {
"types": [
"*"
]
}
},
{
"__docId__": 62,
"kind": "member",
"name": "baseOptions",
"memberof": "src/jira.js~JiraApi",
"static": false,
"longname": "src/jira.js~JiraApi#baseOptions",
"access": "public",
"description": null,
"lineNumber": 40,
"undocument": true,
"type": {
"types": [
"{}"
]
}
},
{
"__docId__": 63,
"kind": "typedef",
"name": "JiraApiOptions",
"memberof": "src/jira.js~JiraApi",
"static": true,
"longname": "src/jira.js~JiraApi.JiraApiOptions",
"access": "public",
"description": "",
"properties": [
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"defaultValue": "http",
"defaultRaw": "http",
"name": "protocol",
"description": "What protocol to use to connect to\njira? Ex: http|https"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": false,
"name": "host",
"description": "What host is this tool connecting to for the jira\ninstance? Ex: jira.somehost.com"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"name": "port",
"description": "What port is this tool connecting to jira with? Only needed for\nnone standard ports. Ex: 8080, 3000, etc"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"name": "username",
"description": "Specify a username for this tool to authenticate all\nrequests with."
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"name": "password",
"description": "Specify a password for this tool to authenticate all\nrequests with. Cloud users need to generate an [API token](https://confluence.atlassian.com/cloud/api-tokens-938839638.html) for this value."
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"defaultValue": "2",
"defaultRaw": 2,
"name": "apiVersion",
"description": "What version of the jira rest api is the instance the\ntool is connecting to?"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"name": "base",
"description": "What other url parts exist, if any, before the rest/api/\nsection?"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"name": "intermediatePath",
"description": "If specified, overwrites the default rest/api/version\nsection of the uri"
},
{
"nullable": null,
"types": [
"boolean"
],
"spread": false,
"optional": true,
"defaultValue": "true",
"defaultRaw": true,
"name": "strictSSL",
"description": "Does this tool require each request to be\nauthenticated? Defaults to true."
},
{
"nullable": null,
"types": [
"function"
],
"spread": false,
"optional": true,
"name": "request",
"description": "What method does this tool use to make its requests?\nDefaults to request from request-promise"
},
{
"nullable": null,
"types": [
"number"
],
"spread": false,
"optional": true,
"name": "timeout",
"description": "Integer containing the number of milliseconds to wait for a\nserver to send response headers (and start the response body) before aborting the request. Note\nthat if the underlying TCP connection cannot be established, the OS-wide TCP connection timeout\nwill overrule the timeout option ([the default in Linux can be anywhere from 20-120 *\nseconds](http://www.sekuda.com/overriding_the_default_linux_kernel_20_second_tcp_socket_connect_timeout))."
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,
"optional": true,
"defaultValue": "1.0",
"defaultRaw": 1,
"name": "webhookVersion",
"description": "What webhook version does this api wrapper need to\nhit?"
},
{
"nullable": null,
"types": [
"string"
],
"spread": false,