group
Resource Group ¶
Issue ¶
一覧GET/issues
Example URI
GET /issues
Response
200
Headers
Content-Type: application/json
Body
[
{
id: 1,
title: "Create Awesome Service",
status: "open",
comment_count: 1,
assignee: {
id: 1,
name: "Akiko"
},
created_at: "2016-06-08T23:26:54.316+09:00",
created: "約12時間前",
updated_at: "2016-06-08T23:26:54.316+09:00",
updated: "約12時間前",
content: "Let's Rock!",
comments: []
}
]
作成POST/issues
Example URI
POST /issues
Request
Headers
Content-Type: application/json
Body
{
"title": "Create Awesome Service",
"status": "open",
"content": "Let's Rock!",
"assignee_id": 1,
"label_ids": [
"[1",
"2",
"3]"
]
}
Schema
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"title": {
"type": "string"
},
"status": {
"type": "string"
},
"content": {
"type": "string"
},
"assignee_id": {
"type": "number"
},
"label_ids": {
"type": "array"
}
}
}
Response
200
Headers
Content-Type: application/json
Body
{
id: 1,
title: "Create Awesome Service",
status: "open",
comment_count: 1,
content: "Let's Rock!",
comments: [],
labels: [
{ id: 1, name: "Good", color: #fff },
{ id: 2, name: "Nice", color: #ddd }
],
assignee: {
id: 1,
name: "Akiko"
},
created_at: "2016-06-08T23:26:54.316+09:00",
created: "約12時間前",
updated_at: "2016-06-08T23:26:54.316+09:00",
updated: "約12時間前"
}
Issue ¶
更新PUT/issues/{id}
Example URI
PUT /issues/id
URI Parameters
- id
integer
(required)
Request
Headers
Content-Type: application/json
Body
{
"title": "Create Awesome Service",
"status": "open",
"content": "Let's Rock!",
"assignee_id": 1,
"label_ids": [
"[1",
"2]"
]
}
Schema
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"title": {
"type": "string"
},
"status": {
"type": "string"
},
"content": {
"type": "string"
},
"assignee_id": {
"type": "number"
},
"label_ids": {
"type": "array"
}
}
}
Response
200
Headers
Content-Type: application/json
Body
{
id: 1,
title: "Create Awesome Service",
status: "open",
comment_count: 1,
content: "Let's Rock!",
comments: [],
labels: [
{ id: 1, name: "Good", color: #fff },
{ id: 2, name: "Nice", color: #ddd }
],
assignee: {
id: 1,
name: "Akiko"
},
created_at: "2016-06-08T23:26:54.316+09:00",
created: "約12時間前",
updated_at: "2016-06-08T23:26:54.316+09:00",
updated: "約12時間前"
}
削除DELETE/issues/{id}
Example URI
DELETE /issues/id
URI Parameters
- id
integer
(required)
Response
200
Headers
Content-Type: application/json
Comment ¶
Comment ¶
作成POST/issues/{issue_id}/comments/{comment_id}
Example URI
POST /issues/issue_id/comments/comment_id
URI Parameters
- issue_id
integer
(required)- comment_id
integer
(required)
Request
Headers
Content-Type: application/json
Body
{
"user_name": "Kawai",
"content": "Good Issue"
}
Schema
{
"$schema": "http://json-schema.org/draft-04/schema#",
"type": "object",
"properties": {
"user_name": {
"type": "string"
},
"content": {
"type": "string"
}
}
}
Response
200
Headers
Content-Type: application/json
Body
{
id: 1,
user_name: "Kawai",
content: "Good Issue",
issue_id: 1,
created_at: "2016-06-08T23:26:54.316+09:00",
created: "約12時間前",
updated_at: "2016-06-08T23:26:54.316+09:00",
updated: "約12時間前"
}
削除DELETE/issues/{issue_id}/comments/{comment_id}
Example URI
DELETE /issues/issue_id/comments/comment_id
URI Parameters
- issue_id
integer
(required)- comment_id
integer
(required)
Response
200
Headers
Content-Type: application/json
/issues/{issue_id}/comments
Example URI
integer
(required)Headers
Content-Type: application/json
Body
{ "user_name": "Kawai", "content": "Good Issue" }
Schema
{ "$schema": "http://json-schema.org/draft-04/schema#", "type": "object", "properties": { "user_name": { "type": "string" }, "content": { "type": "string" } } }
200
Headers
Content-Type: application/json
Body
{ id: 1, user_name: "Kawai", content: "Good Issue", issue_id: 1, created_at: "2016-06-08T23:26:54.316+09:00", created: "約12時間前", updated_at: "2016-06-08T23:26:54.316+09:00", updated: "約12時間前" }