-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
Siyuan Zhang | 张豆 edited this page Oct 11, 2019
·
1 revision
GET /api/v1/commits
Parameter | Default | Description |
---|---|---|
page |
0 |
|
size |
10 |
|
isPractice |
null |
|
username |
null |
|
language |
null |
CPP/C/JAVA/PYTHON2/PYTHON3 |
{
"currentPage": 0,
"currentSize": 10,
"total": 2,
"list": [
{
"id": 773,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 50,
"problemTitle": "test1",
"contestId": null,
"code": "src",
"createDate": null,
"language": "JAVA",
"duration": 10,
"result": "ACCEPTED"
},
{
"id": 774,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 50,
"problemTitle": "test1",
"contestId": null,
"code": "src",
"createDate": "2018-10-11 14:09:43",
"language": "JAVA",
"duration": 10,
"result": "ACCEPTED"
}
]
}
GET /api/v1/commits/:id
{
"id": 773,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 50,
"problemTitle": "test1",
"contestId": null,
"code": "src",
"createDate": null,
"language": "JAVA",
"duration": 10,
"result": "ACCEPTED"
}
GET /api/v1/contests/:contestId/problems/:problemId/commits
[
{
"id": 785,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 53,
"problemTitle": "test3",
"contestId": 778,
"code": "code",
"createDate": "2018-10-14 15:07:05",
"language": "JAVA",
"duration": 10,
"result": "TIME_LIMIT_EXCEEDED"
}
]
POST /api/v1/contests/:contestId/problems/:problemId/commits
Parameter | Default | Description |
---|---|---|
code |
null | Source code |
language |
null | JAVA / CPP / C |
{
"id": 785,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 53,
"problemTitle": "test3",
"contestId": 778,
"code": "code",
"createDate": "2018-10-14 15:07:05",
"language": "JAVA",
"duration": 10,
"result": "TIME_LIMIT_EXCEEDED"
}
GET /api/v1/problems/:id/commits
[
{
"id": 787,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 53,
"problemTitle": "test3",
"contestId": null,
"code": "src",
"createDate": "2018-10-15 10:39:04",
"language": "CPP",
"duration": 10,
"result": "ACCEPTED"
}
]
POST /api/v1/problems/:problemId/commits
Parameter | Default | Description |
---|---|---|
code |
null | Source code |
language |
null | JAVA / CPP / C |
{
"id": 785,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 53,
"problemTitle": "test3",
"contestId": 778,
"code": "code",
"createDate": "2018-10-14 15:07:05",
"language": "JAVA",
"duration": 10,
"result": "TIME_LIMIT_EXCEEDED"
}
PUT /api/v1/commits/:id
{
"id": 785,
"authorId": 20,
"authorName": "kastnerorz",
"problemId": 53,
"problemTitle": "test3",
"contestId": 778,
"code": "code",
"createDate": "2018-10-14 15:07:05",
"language": "JAVA",
"duration": 10,
"result": "ACCEPTED"
}