jira-ruby 2.1.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (154) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +13 -0
  3. data/.travis.yml +9 -0
  4. data/Gemfile +14 -0
  5. data/Guardfile +14 -0
  6. data/LICENSE +19 -0
  7. data/README.md +427 -0
  8. data/Rakefile +31 -0
  9. data/example.rb +224 -0
  10. data/http-basic-example.rb +113 -0
  11. data/jira-ruby.gemspec +35 -0
  12. data/lib/jira-ruby.rb +49 -0
  13. data/lib/jira/base.rb +525 -0
  14. data/lib/jira/base_factory.rb +46 -0
  15. data/lib/jira/client.rb +308 -0
  16. data/lib/jira/has_many_proxy.rb +42 -0
  17. data/lib/jira/http_client.rb +112 -0
  18. data/lib/jira/http_error.rb +14 -0
  19. data/lib/jira/jwt_client.rb +67 -0
  20. data/lib/jira/oauth_client.rb +114 -0
  21. data/lib/jira/railtie.rb +10 -0
  22. data/lib/jira/request_client.rb +31 -0
  23. data/lib/jira/resource/agile.rb +79 -0
  24. data/lib/jira/resource/applinks.rb +39 -0
  25. data/lib/jira/resource/attachment.rb +50 -0
  26. data/lib/jira/resource/board.rb +91 -0
  27. data/lib/jira/resource/board_configuration.rb +9 -0
  28. data/lib/jira/resource/comment.rb +12 -0
  29. data/lib/jira/resource/component.rb +8 -0
  30. data/lib/jira/resource/createmeta.rb +44 -0
  31. data/lib/jira/resource/field.rb +83 -0
  32. data/lib/jira/resource/filter.rb +15 -0
  33. data/lib/jira/resource/issue.rb +141 -0
  34. data/lib/jira/resource/issuelink.rb +20 -0
  35. data/lib/jira/resource/issuelinktype.rb +14 -0
  36. data/lib/jira/resource/issuetype.rb +8 -0
  37. data/lib/jira/resource/priority.rb +8 -0
  38. data/lib/jira/resource/project.rb +41 -0
  39. data/lib/jira/resource/rapidview.rb +67 -0
  40. data/lib/jira/resource/remotelink.rb +26 -0
  41. data/lib/jira/resource/resolution.rb +8 -0
  42. data/lib/jira/resource/serverinfo.rb +18 -0
  43. data/lib/jira/resource/sprint.rb +105 -0
  44. data/lib/jira/resource/sprint_report.rb +8 -0
  45. data/lib/jira/resource/status.rb +8 -0
  46. data/lib/jira/resource/transition.rb +29 -0
  47. data/lib/jira/resource/user.rb +30 -0
  48. data/lib/jira/resource/version.rb +8 -0
  49. data/lib/jira/resource/watcher.rb +35 -0
  50. data/lib/jira/resource/webhook.rb +37 -0
  51. data/lib/jira/resource/worklog.rb +14 -0
  52. data/lib/jira/tasks.rb +0 -0
  53. data/lib/jira/version.rb +3 -0
  54. data/lib/tasks/generate.rake +18 -0
  55. data/spec/integration/attachment_spec.rb +32 -0
  56. data/spec/integration/comment_spec.rb +52 -0
  57. data/spec/integration/component_spec.rb +39 -0
  58. data/spec/integration/field_spec.rb +32 -0
  59. data/spec/integration/issue_spec.rb +93 -0
  60. data/spec/integration/issuelinktype_spec.rb +26 -0
  61. data/spec/integration/issuetype_spec.rb +24 -0
  62. data/spec/integration/priority_spec.rb +24 -0
  63. data/spec/integration/project_spec.rb +49 -0
  64. data/spec/integration/rapidview_spec.rb +74 -0
  65. data/spec/integration/resolution_spec.rb +26 -0
  66. data/spec/integration/status_spec.rb +24 -0
  67. data/spec/integration/transition_spec.rb +49 -0
  68. data/spec/integration/user_spec.rb +41 -0
  69. data/spec/integration/version_spec.rb +39 -0
  70. data/spec/integration/watcher_spec.rb +62 -0
  71. data/spec/integration/webhook.rb +25 -0
  72. data/spec/integration/worklog_spec.rb +51 -0
  73. data/spec/jira/base_factory_spec.rb +45 -0
  74. data/spec/jira/base_spec.rb +598 -0
  75. data/spec/jira/client_spec.rb +291 -0
  76. data/spec/jira/has_many_proxy_spec.rb +46 -0
  77. data/spec/jira/http_client_spec.rb +328 -0
  78. data/spec/jira/http_error_spec.rb +24 -0
  79. data/spec/jira/jwt_uri_builder_spec.rb +59 -0
  80. data/spec/jira/oauth_client_spec.rb +162 -0
  81. data/spec/jira/request_client_spec.rb +41 -0
  82. data/spec/jira/resource/agile_spec.rb +135 -0
  83. data/spec/jira/resource/attachment_spec.rb +138 -0
  84. data/spec/jira/resource/board_spec.rb +224 -0
  85. data/spec/jira/resource/createmeta_spec.rb +258 -0
  86. data/spec/jira/resource/field_spec.rb +85 -0
  87. data/spec/jira/resource/filter_spec.rb +97 -0
  88. data/spec/jira/resource/issue_spec.rb +227 -0
  89. data/spec/jira/resource/issuelink_spec.rb +14 -0
  90. data/spec/jira/resource/project_factory_spec.rb +11 -0
  91. data/spec/jira/resource/project_spec.rb +123 -0
  92. data/spec/jira/resource/sprint_spec.rb +90 -0
  93. data/spec/jira/resource/user_factory_spec.rb +31 -0
  94. data/spec/jira/resource/worklog_spec.rb +22 -0
  95. data/spec/mock_responses/board/1.json +33 -0
  96. data/spec/mock_responses/board/1_issues.json +62 -0
  97. data/spec/mock_responses/component.post.json +28 -0
  98. data/spec/mock_responses/component/10000.invalid.put.json +5 -0
  99. data/spec/mock_responses/component/10000.json +39 -0
  100. data/spec/mock_responses/component/10000.put.json +39 -0
  101. data/spec/mock_responses/empty_issues.json +8 -0
  102. data/spec/mock_responses/field.json +32 -0
  103. data/spec/mock_responses/field/1.json +15 -0
  104. data/spec/mock_responses/issue.json +1108 -0
  105. data/spec/mock_responses/issue.post.json +5 -0
  106. data/spec/mock_responses/issue/10002.invalid.put.json +6 -0
  107. data/spec/mock_responses/issue/10002.json +126 -0
  108. data/spec/mock_responses/issue/10002.put.missing_field_update.json +6 -0
  109. data/spec/mock_responses/issue/10002/attachments/10000.json +20 -0
  110. data/spec/mock_responses/issue/10002/comment.json +65 -0
  111. data/spec/mock_responses/issue/10002/comment.post.json +29 -0
  112. data/spec/mock_responses/issue/10002/comment/10000.json +29 -0
  113. data/spec/mock_responses/issue/10002/comment/10000.put.json +29 -0
  114. data/spec/mock_responses/issue/10002/transitions.json +49 -0
  115. data/spec/mock_responses/issue/10002/transitions.post.json +1 -0
  116. data/spec/mock_responses/issue/10002/watchers.json +13 -0
  117. data/spec/mock_responses/issue/10002/worklog.json +98 -0
  118. data/spec/mock_responses/issue/10002/worklog.post.json +30 -0
  119. data/spec/mock_responses/issue/10002/worklog/10000.json +31 -0
  120. data/spec/mock_responses/issue/10002/worklog/10000.put.json +30 -0
  121. data/spec/mock_responses/issueLinkType.json +25 -0
  122. data/spec/mock_responses/issueLinkType/10000.json +7 -0
  123. data/spec/mock_responses/issuetype.json +42 -0
  124. data/spec/mock_responses/issuetype/5.json +8 -0
  125. data/spec/mock_responses/jira/rest/webhooks/1.0/webhook.json +11 -0
  126. data/spec/mock_responses/jira/rest/webhooks/1.0/webhook/2.json +11 -0
  127. data/spec/mock_responses/priority.json +42 -0
  128. data/spec/mock_responses/priority/1.json +8 -0
  129. data/spec/mock_responses/project.json +12 -0
  130. data/spec/mock_responses/project/SAMPLEPROJECT.issues.json +1108 -0
  131. data/spec/mock_responses/project/SAMPLEPROJECT.json +84 -0
  132. data/spec/mock_responses/rapidview.json +10 -0
  133. data/spec/mock_responses/rapidview/SAMPLEPROJECT.issues.full.json +276 -0
  134. data/spec/mock_responses/rapidview/SAMPLEPROJECT.issues.json +111 -0
  135. data/spec/mock_responses/rapidview/SAMPLEPROJECT.json +6 -0
  136. data/spec/mock_responses/resolution.json +15 -0
  137. data/spec/mock_responses/resolution/1.json +7 -0
  138. data/spec/mock_responses/sprint/1_issues.json +125 -0
  139. data/spec/mock_responses/status.json +37 -0
  140. data/spec/mock_responses/status/1.json +7 -0
  141. data/spec/mock_responses/user_username=admin.json +17 -0
  142. data/spec/mock_responses/version.post.json +7 -0
  143. data/spec/mock_responses/version/10000.invalid.put.json +5 -0
  144. data/spec/mock_responses/version/10000.json +11 -0
  145. data/spec/mock_responses/version/10000.put.json +7 -0
  146. data/spec/mock_responses/webhook.json +11 -0
  147. data/spec/mock_responses/webhook/webhook.json +11 -0
  148. data/spec/spec_helper.rb +21 -0
  149. data/spec/support/clients_helper.rb +16 -0
  150. data/spec/support/matchers/have_attributes.rb +11 -0
  151. data/spec/support/matchers/have_many.rb +9 -0
  152. data/spec/support/matchers/have_one.rb +5 -0
  153. data/spec/support/shared_examples/integration.rb +177 -0
  154. metadata +491 -0
@@ -0,0 +1,5 @@
1
+ {
2
+ "id": "10005",
3
+ "key": "SAMPLEPROJECT-4",
4
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10005"
5
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "errorMessages": [],
3
+ "errors": {
4
+ "invalid": "Field 'invalid' is not valid for this operation."
5
+ }
6
+ }
@@ -0,0 +1,126 @@
1
+ {
2
+ "expand": "renderedFields,names,schema,transitions,editmeta,changelog",
3
+ "id": "10002",
4
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002",
5
+ "key": "SAMPLEPROJECT-1",
6
+ "fields": {
7
+ "summary": "Sample Issue",
8
+ "progress": {
9
+ "progress": 0,
10
+ "total": 0
11
+ },
12
+ "timetracking": {},
13
+ "issuetype": {
14
+ "self": "http://localhost:2990/jira/rest/api/2/issuetype/3",
15
+ "id": "3",
16
+ "description": "A task that needs to be done.",
17
+ "iconUrl": "http://localhost:2990/jira/images/icons/task.gif",
18
+ "name": "Task",
19
+ "subtask": false
20
+ },
21
+ "votes": {
22
+ "self": "http://localhost:2990/jira/rest/api/2/issue/SAMPLEPROJECT-1/votes",
23
+ "votes": 0,
24
+ "hasVoted": false
25
+ },
26
+ "resolution": null,
27
+ "fixVersions": [],
28
+ "resolutiondate": null,
29
+ "timespent": null,
30
+ "reporter": {
31
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
32
+ "name": "admin",
33
+ "emailAddress": "admin@example.com",
34
+ "avatarUrls": {
35
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
36
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
37
+ },
38
+ "displayName": "admin",
39
+ "active": true
40
+ },
41
+ "aggregatetimeoriginalestimate": null,
42
+ "updated": "2011-12-14T10:26:06.030+1300",
43
+ "created": "2011-12-14T10:26:06.030+1300",
44
+ "description": null,
45
+ "priority": {
46
+ "self": "http://localhost:2990/jira/rest/api/2/priority/3",
47
+ "iconUrl": "http://localhost:2990/jira/images/icons/priority_major.gif",
48
+ "name": "Major",
49
+ "id": "3"
50
+ },
51
+ "duedate": "2011-12-14",
52
+ "issuelinks": [],
53
+ "watches": {
54
+ "self": "http://localhost:2990/jira/rest/api/2/issue/SAMPLEPROJECT-1/watchers",
55
+ "watchCount": 0,
56
+ "isWatching": false
57
+ },
58
+ "worklog": {
59
+ "startAt": 0,
60
+ "maxResults": 0,
61
+ "total": 0,
62
+ "worklogs": []
63
+ },
64
+ "subtasks": [],
65
+ "status": {
66
+ "self": "http://localhost:2990/jira/rest/api/2/status/1",
67
+ "description": "The issue is open and ready for the assignee to start work on it.",
68
+ "iconUrl": "http://localhost:2990/jira/images/icons/status_open.gif",
69
+ "name": "Open",
70
+ "id": "1"
71
+ },
72
+ "labels": [],
73
+ "workratio": -1,
74
+ "assignee": {
75
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
76
+ "name": "admin",
77
+ "emailAddress": "admin@example.com",
78
+ "avatarUrls": {
79
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
80
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
81
+ },
82
+ "displayName": "admin",
83
+ "active": true
84
+ },
85
+ "attachment": [],
86
+ "aggregatetimeestimate": null,
87
+ "project": {
88
+ "self": "http://localhost:2990/jira/rest/api/2/project/SAMPLEPROJECT",
89
+ "id": "10001",
90
+ "key": "SAMPLEPROJECT",
91
+ "name": "Sample Project for Developing RoR RESTful API",
92
+ "avatarUrls": {
93
+ "16x16": "http://localhost:2990/jira/secure/projectavatar?size=small&pid=10001&avatarId=10011",
94
+ "48x48": "http://localhost:2990/jira/secure/projectavatar?pid=10001&avatarId=10011"
95
+ }
96
+ },
97
+ "versions": [],
98
+ "environment": null,
99
+ "timeestimate": null,
100
+ "aggregateprogress": {
101
+ "progress": 0,
102
+ "total": 0
103
+ },
104
+ "components": [
105
+ {
106
+ "self": "http://localhost:2990/jira/rest/api/2/component/10001",
107
+ "id": "10001",
108
+ "name": "Jamflam"
109
+ },
110
+ {
111
+ "self": "http://localhost:2990/jira/rest/api/2/component/10000",
112
+ "id": "10000",
113
+ "name": "Jammy",
114
+ "description": "Description!"
115
+ }
116
+ ],
117
+ "comment": {
118
+ "startAt": 0,
119
+ "maxResults": 0,
120
+ "total": 0,
121
+ "comments": []
122
+ },
123
+ "timeoriginalestimate": null,
124
+ "aggregatetimespent": null
125
+ }
126
+ }
@@ -0,0 +1,6 @@
1
+ {
2
+ "errorMessages": [
3
+ "one of 'fields' or 'update' required"
4
+ ],
5
+ "errors": {}
6
+ }
@@ -0,0 +1,20 @@
1
+ {
2
+ "self": "http://localhost:2990/jira/rest/api/2/attachment/10000",
3
+ "filename": "ballmer.png",
4
+ "author": {
5
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
6
+ "name": "admin",
7
+ "avatarUrls": {
8
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
9
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
10
+ },
11
+ "displayName": "admin",
12
+ "active": true
13
+ },
14
+ "created": "2012-01-11T10:54:50.875+1300",
15
+ "size": 15360,
16
+ "mimeType": "image/png",
17
+ "properties": {},
18
+ "content": "http://localhost:2990/jira/secure/attachment/10000/ballmer.png",
19
+ "thumbnail": "http://localhost:2990/jira/secure/thumbnail/10000/_thumb_10000.png"
20
+ }
@@ -0,0 +1,65 @@
1
+ {
2
+ "startAt": 0,
3
+ "maxResults": 2,
4
+ "total": 2,
5
+ "comments": [
6
+ {
7
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/comment/10000",
8
+ "id": "10000",
9
+ "author": {
10
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
11
+ "name": "admin",
12
+ "emailAddress": "admin@example.com",
13
+ "avatarUrls": {
14
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
15
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
16
+ },
17
+ "displayName": "admin",
18
+ "active": true
19
+ },
20
+ "body": "This is a comment. Creative.",
21
+ "updateAuthor": {
22
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
23
+ "name": "admin",
24
+ "emailAddress": "admin@example.com",
25
+ "avatarUrls": {
26
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
27
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
28
+ },
29
+ "displayName": "admin",
30
+ "active": true
31
+ },
32
+ "created": "2012-01-11T10:02:14.430+1300",
33
+ "updated": "2012-01-12T15:15:13.074+1300"
34
+ },
35
+ {
36
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/comment/10001",
37
+ "id": "10001",
38
+ "author": {
39
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
40
+ "name": "admin",
41
+ "emailAddress": "admin@example.com",
42
+ "avatarUrls": {
43
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
44
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
45
+ },
46
+ "displayName": "admin",
47
+ "active": true
48
+ },
49
+ "body": "new comment",
50
+ "updateAuthor": {
51
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
52
+ "name": "admin",
53
+ "emailAddress": "admin@example.com",
54
+ "avatarUrls": {
55
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
56
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
57
+ },
58
+ "displayName": "admin",
59
+ "active": true
60
+ },
61
+ "created": "2012-01-12T14:29:59.209+1300",
62
+ "updated": "2012-01-12T14:29:59.209+1300"
63
+ }
64
+ ]
65
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/comment/10001",
3
+ "id": "10001",
4
+ "author": {
5
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
6
+ "name": "admin",
7
+ "emailAddress": "admin@example.com",
8
+ "avatarUrls": {
9
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
10
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
11
+ },
12
+ "displayName": "admin",
13
+ "active": true
14
+ },
15
+ "body": "new comment",
16
+ "updateAuthor": {
17
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
18
+ "name": "admin",
19
+ "emailAddress": "admin@example.com",
20
+ "avatarUrls": {
21
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
22
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
23
+ },
24
+ "displayName": "admin",
25
+ "active": true
26
+ },
27
+ "created": "2012-01-12T14:29:59.209+1300",
28
+ "updated": "2012-01-12T14:29:59.209+1300"
29
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/comment/10000",
3
+ "id": "10000",
4
+ "author": {
5
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
6
+ "name": "admin",
7
+ "emailAddress": "admin@example.com",
8
+ "avatarUrls": {
9
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
10
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
11
+ },
12
+ "displayName": "admin",
13
+ "active": true
14
+ },
15
+ "body": "This is a comment. Creative.",
16
+ "updateAuthor": {
17
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
18
+ "name": "admin",
19
+ "emailAddress": "admin@example.com",
20
+ "avatarUrls": {
21
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
22
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
23
+ },
24
+ "displayName": "admin",
25
+ "active": true
26
+ },
27
+ "created": "2012-01-11T10:02:14.430+1300",
28
+ "updated": "2012-01-11T10:02:14.430+1300"
29
+ }
@@ -0,0 +1,29 @@
1
+ {
2
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/comment/10000",
3
+ "id": "10000",
4
+ "author": {
5
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
6
+ "name": "admin",
7
+ "emailAddress": "admin@example.com",
8
+ "avatarUrls": {
9
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
10
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
11
+ },
12
+ "displayName": "admin",
13
+ "active": true
14
+ },
15
+ "body": "new body",
16
+ "updateAuthor": {
17
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
18
+ "name": "admin",
19
+ "emailAddress": "admin@example.com",
20
+ "avatarUrls": {
21
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
22
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
23
+ },
24
+ "displayName": "admin",
25
+ "active": true
26
+ },
27
+ "created": "2012-01-11T10:02:14.430+1300",
28
+ "updated": "2012-01-12T14:37:41.933+1300"
29
+ }
@@ -0,0 +1,49 @@
1
+ {
2
+ "expand": "transitions",
3
+ "transitions": [
4
+ {
5
+ "id": "41",
6
+ "name": "Review",
7
+ "to": {
8
+ "self": "http://localhost:2990/rest/api/2/status/10006",
9
+ "description": "",
10
+ "iconUrl": "http://localhost:2990/images/icons/statuses/generic.png",
11
+ "name": "Reviewable",
12
+ "id": "10006"
13
+ }
14
+ },
15
+ {
16
+ "id": "101",
17
+ "name": "Stop Progress",
18
+ "to": {
19
+ "self": "http://localhost:2990/rest/api/2/status/10017",
20
+ "description": "Mapping for Accepted in Pivotal Tracker",
21
+ "iconUrl": "http://localhost:2990/images/icons/statuses/closed.png",
22
+ "name": "Accepted",
23
+ "id": "10017"
24
+ }
25
+ },
26
+ {
27
+ "id": "21",
28
+ "name": "Remove from Backlog",
29
+ "to": {
30
+ "self": "http://localhost:2990/rest/api/2/status/1",
31
+ "description": "The issue is open and ready for the assignee to start work on it.",
32
+ "iconUrl": "http://localhost:2990/images/icons/statuses/open.png",
33
+ "name": "Open",
34
+ "id": "1"
35
+ }
36
+ },
37
+ {
38
+ "id": "71",
39
+ "name": "Resolve",
40
+ "to": {
41
+ "self": "http://localhost:2990/rest/api/2/status/5",
42
+ "description": "A resolution has been taken, and it is awaiting verification by reporter. From here issues are either reopened, or are closed.",
43
+ "iconUrl": "http://localhost:2990/images/icons/statuses/resolved.png",
44
+ "name": "Resolved",
45
+ "id": "5"
46
+ }
47
+ }
48
+ ]
49
+ }
@@ -0,0 +1,13 @@
1
+ {
2
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/watchers",
3
+ "isWatching": false,
4
+ "watchCount": 1,
5
+ "watchers": [
6
+ {
7
+ "self": "http://www.example.com/jira/rest/api/2/user?username=admin",
8
+ "name": "admin",
9
+ "displayName": "admin",
10
+ "active": false
11
+ }
12
+ ]
13
+ }
@@ -0,0 +1,98 @@
1
+ {
2
+ "startAt": 0,
3
+ "maxResults": 3,
4
+ "total": 3,
5
+ "worklogs": [
6
+ {
7
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/worklog/10000",
8
+ "author": {
9
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
10
+ "name": "admin",
11
+ "emailAddress": "admin@example.com",
12
+ "avatarUrls": {
13
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
14
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
15
+ },
16
+ "displayName": "admin",
17
+ "active": true
18
+ },
19
+ "updateAuthor": {
20
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
21
+ "name": "admin",
22
+ "emailAddress": "admin@example.com",
23
+ "avatarUrls": {
24
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
25
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
26
+ },
27
+ "displayName": "admin",
28
+ "active": true
29
+ },
30
+ "comment": "Some epic work.",
31
+ "created": "2012-01-11T13:33:25.604+1300",
32
+ "updated": "2012-01-11T13:33:25.604+1300",
33
+ "started": "2012-01-11T13:33:00.000+1300",
34
+ "timeSpent": "18w 2d",
35
+ "id": "10000"
36
+ },
37
+ {
38
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/worklog/10001",
39
+ "author": {
40
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
41
+ "name": "admin",
42
+ "emailAddress": "admin@example.com",
43
+ "avatarUrls": {
44
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
45
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
46
+ },
47
+ "displayName": "admin",
48
+ "active": true
49
+ },
50
+ "updateAuthor": {
51
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
52
+ "name": "admin",
53
+ "emailAddress": "admin@example.com",
54
+ "avatarUrls": {
55
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
56
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
57
+ },
58
+ "displayName": "admin",
59
+ "active": true
60
+ },
61
+ "created": "2012-01-12T16:08:58.529+1300",
62
+ "updated": "2012-01-12T16:11:22.266+1300",
63
+ "started": "2012-01-12T16:08:58.529+1300",
64
+ "timeSpent": "4d",
65
+ "id": "10001"
66
+ },
67
+ {
68
+ "self": "http://localhost:2990/jira/rest/api/2/issue/10002/worklog/10002",
69
+ "author": {
70
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
71
+ "name": "admin",
72
+ "emailAddress": "admin@example.com",
73
+ "avatarUrls": {
74
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
75
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
76
+ },
77
+ "displayName": "admin",
78
+ "active": true
79
+ },
80
+ "updateAuthor": {
81
+ "self": "http://localhost:2990/jira/rest/api/2/user?username=admin",
82
+ "name": "admin",
83
+ "emailAddress": "admin@example.com",
84
+ "avatarUrls": {
85
+ "16x16": "http://localhost:2990/jira/secure/useravatar?size=small&avatarId=10122",
86
+ "48x48": "http://localhost:2990/jira/secure/useravatar?avatarId=10122"
87
+ },
88
+ "displayName": "admin",
89
+ "active": true
90
+ },
91
+ "created": "2012-01-12T16:20:39.542+1300",
92
+ "updated": "2012-01-12T16:20:39.542+1300",
93
+ "started": "2012-01-12T16:20:39.541+1300",
94
+ "timeSpent": "3d",
95
+ "id": "10002"
96
+ }
97
+ ]
98
+ }