API 공통 사항

이 API는 JSend Format을 따르는 API로, 아래와 같은 공통된 응답을 줍니다.

추가 사항으로, 권한 인증이 필요한 API는 클라이언트에서 가지고 있는 JWT 토큰을 요청시 Authorization 헤더에 Bearer token과 같은 형태로 함께 전송해야합니다.

Type Description Required Keys

success

요청이 성공하였으며, 일반적으로 데이터를 응답합니다.

status, data

fail

클라이언트의 요청에서 문제가 있으며, 그에 따른 문제점을 응답합니다.

status, data

error

요청을 처리하는 도중 서버에서 문제가 발생하였으며, 그에 따른 에러 메시지를 응답합니다.

status, message

Example

Success

{
    "status" : "success",
    "data" : {
        "posts" : [
            { "id" : 1, "title" : "A blog post", "body" : "Some useful content" },
            { "id" : 2, "title" : "Another blog post", "body" : "More content" },
        ]
     }
}

Fail

{
    "status" : "fail",
    "data" : {
        "title" : "A title is required"
     }
}

Error

{
    "status" : "error",
    "message" : "Unable to communicate with database"
}

End-User APIs

사용자가 사용하는 실 서비스에 이용되는 API입니다.

Auth API ( /api/v1/auth )

회원가입

description
회원가입을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/auth/signup
Sample Request
POST /api/v1/auth/signup HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 82
Host: localhost:8080

{
  "email" : "test@test.com",
  "username" : "test",
  "password" : "Test123@!"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 94

{
  "status" : "success",
  "data" : {
    "id" : "870dbe47-0ef2-44dc-8d0d-c49fcfe047b1"
  }
}
Request Body
{
  "email" : "test@test.com",
  "username" : "test",
  "password" : "Test123@!"
}
Path Type Description

email

String

이메일

username

String

닉네임

password

String

비밀번호

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "870dbe47-0ef2-44dc-8d0d-c49fcfe047b1"
  }
}
Path Type Description

status

String

결과 상태

data.id

String

UUID

로그인

description
로그인을 위한 API입니다. ( 예외적으로, Back Office에서 함께 사용되는 API입니다. )

HTTP Method : POST
End-Point   : /api/v1/auth/login
Sample Request
POST /api/v1/auth/login HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 59
Host: localhost:8080

{
  "email" : "test@test.com",
  "password" : "Test123@!"
}
Sample Response
HTTP/1.1 200 OK
Set-Cookie: refresh_token=refreshToken; Path=/; Max-Age=1; Expires=Sun, 21 Jan 2024 13:35:58 GMT; Secure; HttpOnly
Content-Type: application/json
Content-Length: 226

{
  "status" : "success",
  "data" : {
    "id" : "af96f9d0-302d-42cf-b0f6-11f81043a612",
    "username" : "seongil-kim",
    "email" : "seongil.kim@gmail.com",
    "role" : "ROLE_USER",
    "accessToken" : "accessToken"
  }
}
Request Body
{
  "email" : "test@test.com",
  "password" : "Test123@!"
}
Path Type Description

email

String

이메일

password

String

비밀번호

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "af96f9d0-302d-42cf-b0f6-11f81043a612",
    "username" : "seongil-kim",
    "email" : "seongil.kim@gmail.com",
    "role" : "ROLE_USER",
    "accessToken" : "accessToken"
  }
}
Path Type Description

status

String

결과 상태

data.id

String

회원의 UUID

data.username

String

닉네임

data.email

String

이메일

data.role

String

권한

data.accessToken

String

Access 토큰 (JWT)

Response Header

response를 살펴보면 set-cookie 헤더에서 refresh-token 이라는 이름의 쿠키가 세팅되는 것을 알 수 있습니다.

이 값을 이용하여 token refresh를 하게 됩니다.

Name Description

Set-Cookie

Refresh 토큰 쿠키 세팅 ( JWT )

토큰 재발급

description
토큰 재발급을 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/auth/refresh
Sample Request
GET /api/v1/auth/refresh HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Set-Cookie: refresh_token=refreshToken; Path=/; Max-Age=1; Expires=Sun, 21 Jan 2024 13:35:58 GMT; Secure; HttpOnly
Content-Type: application/json
Content-Length: 78

{
  "status" : "success",
  "data" : {
    "accessToken" : "accessToken"
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 만료된 Access Token이며, 토큰 재발급시 쿠키에 포함되어 함께 전송되는 Refresh token과 함께 토큰 재발급시 사용됩니다.

Name Description

Authorization

만료된 Access 토큰 ( JWT )

Response Body
{
  "status" : "success",
  "data" : {
    "accessToken" : "accessToken"
  }
}
Path Type Description

status

String

결과 상태

data.accessToken

String

Access 토큰 (JWT)

Response Header

response를 살펴보면 set-cookie 헤더에서 refresh-token 이라는 이름의 쿠키가 세팅되는 것을 알 수 있습니다.

이 refresh token은 요청에 포함되어 전송된 refresh token의 기한이 3일 이하로 남았을 때, access token과 함께 재발급됩니다.

만약, 요청에 포함되어 전송된 refresh token의 유효기간이 3일 이상이라면 새로운 refresh token을 전송하지 않습니다.

Name Description

Set-Cookie

새로운 Refresh 토큰 쿠키 세팅 ( JWT )

유저 정보 조회

description
토큰을 이용한 유저 정보 조회를 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/auth/info
Sample Request
GET /api/v1/auth/info HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 182

{
  "status" : "success",
  "data" : {
    "id" : "623d94f3-083f-45dd-9abd-07ecd10e67cf",
    "username" : "admin",
    "email" : "admin@csbroker.io",
    "role" : "ROLE_ADMIN"
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

Access 토큰 ( JWT )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "623d94f3-083f-45dd-9abd-07ecd10e67cf",
    "username" : "admin",
    "email" : "admin@csbroker.io",
    "role" : "ROLE_ADMIN"
  }
}
Path Type Description

status

String

결과 상태

data.id

String

회원의 UUID

data.username

String

닉네임

data.email

String

이메일

data.role

String

권한

비밀번호 변경 메일 전송

description
비밀번호 변경 메일 전송을 위한 API입니다.
비밀번호 변경 메일에는 "프론트엔드주소/password-change/코드" 와 같은 값이 전달됩니다.
즉, 프론트엔드에서는 위 링크에 해당하는 비밀번호 변경 창을 만들어줘야합니다.

HTTP Method : POST
End-Point   : /api/v1/password/code
Sample Request
POST /api/v1/auth/password/code HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 31
Host: localhost:8080

{
  "email" : "test@test.com"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 48

{
  "status" : "success",
  "data" : "success"
}
Request Body
{
  "email" : "test@test.com"
}
Response Body
{
  "status" : "success",
  "data" : "success"
}
Path Type Description

status

String

결과 상태

data

String

비밀번호 변경 요청 결과

비밀번호 변경

description
비밀번호 변경을 위한 API입니다.
유저가 "프론트엔드주소/password-change/코드" 와 같은 값으로 접근 하였을 때,
코드와 새로운 비밀번호를 함께 전송하면 비밀번호가 새로운 비밀번호로 변경됩니다.

코드는 5분동안 유효하며, 코드와 새로운 비밀번호를 전송해야 새로운 비밀번호로 성공적으로 변경됩니다.

HTTP Method : PUT
End-Point   : /api/v1/password/change
Sample Request
PUT /api/v1/auth/password/change HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 51
Host: localhost:8080

{
  "code" : "123456",
  "password" : "Test123@!"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 48

{
  "status" : "success",
  "data" : "success"
}
Request Body
{
  "code" : "123456",
  "password" : "Test123@!"
}
Response Body
{
  "status" : "success",
  "data" : "success"
}
Path Type Description

status

String

결과 상태

data

String

비밀번호 변경 결과

Common API ( /api/v1 )

메인페이지 통계 조회

description
메인페이지 통계 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/stats
Sample Request
GET /api/v1/stats HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 118

{
  "status" : "success",
  "data" : {
    "problemCnt" : 10,
    "gradableProblemCnt" : 10,
    "userCnt" : 100
  }
}
Response Body
{
  "status" : "success",
  "data" : {
    "problemCnt" : 10,
    "gradableProblemCnt" : 10,
    "userCnt" : 100
  }
}
Path Type Description

status

String

결과 상태

data.problemCnt

Number

문제 수

data.gradableProblemCnt

Number

채점 가능한 문제 수

data.userCnt

Number

회원 수

기술 스택 데이터 조회

description
기술 스택 데이터 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/techs
Sample Request
GET /api/v1/techs?query=a HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 59

{
  "status" : "success",
  "data" : [ "aws", "android" ]
}
Request parameters

조회를 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/common/techs/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : [ "aws", "android" ]
}
Path Type Description

status

String

결과 상태

data

Array

기술 데이터

랭킹 리스트 조회

description
랭킹 리스트 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/ranks
Sample Request
GET /api/v1/ranks?size=3&page=0 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 281

{
  "status" : "success",
  "data" : {
    "size" : 3,
    "totalPage" : 10,
    "currentPage" : 0,
    "numberOfElements" : 1,
    "contents" : [ {
      "id" : "0b58a8cb-6b24-457d-a82a-f07c6a6a00de",
      "username" : "test",
      "rank" : 1,
      "score" : 10.0
    } ]
  }
}
Request parameters

조회를 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/common/ranks/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "size" : 3,
    "totalPage" : 10,
    "currentPage" : 0,
    "numberOfElements" : 1,
    "contents" : [ {
      "id" : "0b58a8cb-6b24-457d-a82a-f07c6a6a00de",
      "username" : "test",
      "rank" : 1,
      "score" : 10.0
    } ]
  }
}
Path Type Description

status

String

결과 상태

data

Object

랭킹 데이터

data.size

Number

가져온 랭킹 데이터 사이즈

data.totalPage

Number

총 페이지 수

data.currentPage

Number

현재 페이지 수

data.numberOfElements

Number

총 데이터 수

data.contents

Array

랭킹 데이터

data.contents.[].id

String

유저 id

data.contents.[].username

String

유저 닉네임

data.contents.[].rank

Number

유저 랭킹

data.contents.[].score

Number

유저 점수

Problem API ( /api/v1/problems )

서술형 문제 단건 조회

description
서술형 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problems/long/{problem_id:Long}
Sample Request
GET /api/v1/problems/long/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 438

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "Long problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "Long problem description",
    "avgScore" : 10.0,
    "topScore" : 10.0,
    "bottomScore" : 0.0,
    "score" : 10.0,
    "totalSubmission" : 10,
    "isSolved" : true,
    "isGradable" : true,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Table 1. /api/v1/problems/long/{problem_id}
Parameter Description

problem_id

문제 id

서술형 문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "Long problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "Long problem description",
    "avgScore" : 10.0,
    "topScore" : 10.0,
    "bottomScore" : 0.0,
    "score" : 10.0,
    "totalSubmission" : 10,
    "isSolved" : true,
    "isGradable" : true,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.avgScore

Number

평균 점수 ( 푼 사람이 없는 경우 null return )

data.topScore

Number

최고 점수 ( 푼 사람이 없는 경우 null return )

data.bottomScore

Number

최저 점수 ( 푼 사람이 없는 경우 null return )

data.totalSubmission

Number

총 제출 수

data.isSolved

Boolean

푼 문제 여부

data.isGradable

Boolean

문제 채점 가능 여부

data.score

Number

문제 배점

data.bookmarkCount

Number

북마크 수

data.likeCount

Number

좋아요 수

data.isBookmarked

Boolean

북마크 여부

data.isLiked

Boolean

좋아요 여부

서술형 문제 채점

description
서술형 문제 채점을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/problems/long/{problem_id:Long}/grade
Sample Request

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/http-request.adoc[]

Sample Response

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/http-response.adoc[]

Path parameters

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/path-parameters.adoc[]

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다. Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/request-headers.adoc[]

Request Params

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/request-parameters.adoc[]

Response Body

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/response-body.adoc[] Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/grade/response-fields.adoc[]

서술형 문제 제출 (채점 X)

description
서술형 문제 제출을 위한 API 입니다.

HTTP Method : POST
End-Point   : /api/v1/problems/long/{problem_id:Long}/submit
Sample Request
POST /api/v1/problems/long/1/submit HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 30
Host: localhost:8080

{
  "answer" : "user answer"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 274

{
  "status" : "success",
  "data" : {
    "title" : "title",
    "tags" : [ "tag1", "tag2", "tag3" ],
    "description" : "description",
    "totalSubmission" : 100,
    "userSubmission" : 10,
    "userAnswer" : "user answer",
    "standardAnswer" : "standard answer"
  }
}
Table 2. /api/v1/problems/long/{problem_id}/submit
Parameter Description

problem_id

문제 id

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

인증을 위한 Access 토큰

Request Params

Unresolved directive in index.adoc - include::./build/generated-snippets/problems/long/submit/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "title" : "title",
    "tags" : [ "tag1", "tag2", "tag3" ],
    "description" : "description",
    "totalSubmission" : 100,
    "userSubmission" : 10,
    "userAnswer" : "user answer",
    "standardAnswer" : "standard answer"
  }
}
Path Type Description

status

String

결과 상태

data.title

String

문제 제목

data.tags

Array

태그

data.description

String

문제 설명

data.totalSubmission

Number

해당 문제에 대해 전체 유저가 제출한 수 (총 제출 수)

data.userSubmission

Number

해당 문제에 대해 유저가 제출한 수

data.userAnswer

String

유저의 답변

data.standardAnswer

String

모범 답안

단답형 문제 단건 조회

description
단답형 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problems/short/{problem_id:Long}
Sample Request
GET /api/v1/problems/short/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 438

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "answerLength" : 10,
    "isEnglish" : true,
    "isSolved" : true,
    "score" : 10.0,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Table 3. /api/v1/problems/short/{problem_id}
Parameter Description

problem_id

문제 id

객관식 문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "answerLength" : 10,
    "isEnglish" : true,
    "isSolved" : true,
    "score" : 10.0,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.correctUserCnt

Number

맞은 사람 수

data.correctSubmission

Number

맞은 제출 수

data.totalSubmission

Number

총 제출 수

data.answerLength

Number

정답 글자수 ( 힌트 )

data.isEnglish

Boolean

정답 언어 ( 영어면 true, 한국어면 false )

data.isSolved

Boolean

푼 문제 여부

data.score

Number

문제 배점

data.bookmarkCount

Number

북마크 수

data.likeCount

Number

좋아요 수

data.isBookmarked

Boolean

북마크 여부

data.isLiked

Boolean

좋아요 여부

단답형 문제 채점

description
단답형 문제 채점을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/problems/short/{problem_id:Long}/grade
Sample Request
POST /api/v1/problems/short/1/grade HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 30
Host: localhost:8080

{
  "answer" : "user answer"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 427

{
  "status" : "success",
  "data" : {
    "gradingHistoryId" : 1,
    "problemId" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "userAnswer" : "user answer",
    "answerLength" : 10,
    "isAnswer" : false,
    "score" : 10.0,
    "correctAnswer" : "correct answer"
  }
}
Table 4. /api/v1/problems/short/{problem_id}/grade
Parameter Description

problem_id

문제 id

단답형 문제 단건 조회를 위한 path parameter의 설명입니다.

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

인증을 위한 Access 토큰

Response Body
{
  "status" : "success",
  "data" : {
    "gradingHistoryId" : 1,
    "problemId" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "userAnswer" : "user answer",
    "answerLength" : 10,
    "isAnswer" : false,
    "score" : 10.0,
    "correctAnswer" : "correct answer"
  }
}
Path Type Description

status

String

결과 상태

data.gradingHistoryId

Number

채점 결과 id

data.problemId

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.correctUserCnt

Number

맞은 사람 수

data.correctSubmission

Number

맞은 제출 수

data.totalSubmission

Number

총 제출 수

data.score

Number

채점 된 유저 답안의 점수

data.userAnswer

String

채점 된 유저 답안

data.answerLength

Number

모범 답안의 글자 수

data.isAnswer

Boolean

유저 답안의 정답 여부

data.correctAnswer

String

모범 답안

객관식 문제 단건 조회

description
객관식 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problems/multiple/{problem_id:Long}
Sample Request
GET /api/v1/problems/multiple/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 489

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "choices" : [ {
      "id" : 1,
      "content" : "123"
    } ],
    "isSolved" : true,
    "isMultipleAnswer" : true,
    "score" : 10.0,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Table 5. /api/v1/problems/multiple/{problem_id}
Parameter Description

problem_id

문제 id

객관식 문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "choices" : [ {
      "id" : 1,
      "content" : "123"
    } ],
    "isSolved" : true,
    "isMultipleAnswer" : true,
    "score" : 10.0,
    "likeCount" : 10,
    "bookmarkCount" : 10,
    "isLiked" : true,
    "isBookmarked" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.avgScore

Number

평균 점수 ( 푼 사람이 없는 경우 null return )

data.correctUserCnt

Number

맞은 사람 수

data.correctSubmission

Number

맞은 제출 수

data.totalSubmission

Number

총 제출 수

data.choices.[].id

Number

선지 id

data.choices.[].content

String

선지 내용

data.isSolved

Boolean

푼 문제 여부

data.isMultipleAnswer

Boolean

다중 답안 여부

data.score

Number

문제 배점

data.bookmarkCount

Number

북마크 수

data.likeCount

Number

좋아요 수

data.isBookmarked

Boolean

북마크 여부

data.isLiked

Boolean

좋아요 여부

객관식 문제 채점

description
객관식 문제 채점을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/problems/multiple/{problem_id:Long}/grade
Sample Request
POST /api/v1/problems/multiple/1/grade HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 25
Host: localhost:8080

{
  "answerIds" : [ 1 ]
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 425

{
  "status" : "success",
  "data" : {
    "gradingHistoryId" : 1,
    "problemId" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "choices" : [ {
      "id" : 1,
      "content" : "123"
    } ],
    "userAnswerIds" : [ 1 ],
    "isAnswer" : true,
    "score" : 10.0
  }
}
Table 6. /api/v1/problems/multiple/{problem_id}/grade
Parameter Description

problem_id

문제 id

객관식 문제 단건 조회를 위한 path parameter의 설명입니다.

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

인증을 위한 Access 토큰

Response Body
{
  "status" : "success",
  "data" : {
    "gradingHistoryId" : 1,
    "problemId" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "choices" : [ {
      "id" : 1,
      "content" : "123"
    } ],
    "userAnswerIds" : [ 1 ],
    "isAnswer" : true,
    "score" : 10.0
  }
}
Path Type Description

status

String

결과 상태

data.gradingHistoryId

Number

채점 결과 id

data.problemId

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.correctUserCnt

Number

맞은 사람 수

data.correctSubmission

Number

맞은 제출 수

data.totalSubmission

Number

총 제출 수

data.score

Number

채점 된 유저 답안의 점수

data.userAnswerIds

Array

채점 된 유저 답안 ( 고른 선지의 id 배열 )

data.isAnswer

Boolean

유저 답안의 정답 여부

data.choices

Array

문제의 선지

data.choices

Array

문제의 선지

data.choices

Array

문제의 선지

data.choices.[].id

Number

선지 id

data.choices.[].content

String

선지 내용

문제 검색

description
문제 검색을 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problems
Req Params  : query, tags, isSolved, page, size, type, isGradable
Sample Request
GET /api/v1/problems?query=test&isSolved=false&tags=os,ds&page=0&size=10&type=long&isGradable=false HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 335

{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "title" : "test",
      "tags" : [ "os", "ds" ],
      "avgScore" : 1.0,
      "totalSubmission" : 10,
      "type" : "long"
    } ],
    "currentPage" : 0,
    "totalPages" : 1,
    "totalElements" : 1,
    "numberOfElements" : 1,
    "size" : 10
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 아래의 설명과 같이 푼 문제 검색 기능을 활용할 때만 포함하면 됩니다.

Name Description

Authorization

인증을 위한 Access 토큰 ( 푼 문제로 검색을 하는 경우가 아니라면, 포함하지 않아도 됨. )

Request parameters

문제 검색을 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/problems/search/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "title" : "test",
      "tags" : [ "os", "ds" ],
      "avgScore" : 1.0,
      "totalSubmission" : 10,
      "type" : "long"
    } ],
    "currentPage" : 0,
    "totalPages" : 1,
    "totalElements" : 1,
    "numberOfElements" : 1,
    "size" : 10
  }
}
Path Type Description

status

String

결과 상태

data.contents

Array

문제 데이터

data.contents.[].id

Number

문제 id

data.contents.[].title

String

문제 제목

data.contents.[].tags

Array

태그

data.contents.[].avgScore

Number

평균 점수 ( 푼 사람이 없는 경우 null return )

data.contents.[].totalSubmission

Number

총 제출 수

data.contents.[].type

String

문제의 타입 ( short, multiple, long )

data.currentPage

Number

현재 페이지 번호

data.totalPages

Number

검색된 페이지 수

data.totalElements

Number

검색된 전체 데이터 수

data.numberOfElements

Number

전체 데이터 중 현재 페이지의 데이터 수

data.size

Number

요청한 데이터 수

문제 랜덤 조회

description
문제를 랜덤하게 가져오기 위한 API입니다.영

HTTP Method : GET
End-Point   : /api/v1/problems/shuffle
Req Params  : size
Sample Request
GET /api/v1/problems/shuffle?size=2 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 371

{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "title" : "test",
      "tags" : [ "os", "ds" ],
      "avgScore" : 1.0,
      "totalSubmission" : 10,
      "type" : "long"
    }, {
      "id" : 2,
      "title" : "test2",
      "tags" : [ "db" ],
      "avgScore" : 2.0,
      "totalSubmission" : 20,
      "type" : "long"
    } ]
  }
}
Name Description

Authorization

인증을 위한 Access 토큰

Request parameters

문제 랜덤 조회를 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/problems/shuffle/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "title" : "test",
      "tags" : [ "os", "ds" ],
      "avgScore" : 1.0,
      "totalSubmission" : 10,
      "type" : "long"
    }, {
      "id" : 2,
      "title" : "test2",
      "tags" : [ "db" ],
      "avgScore" : 2.0,
      "totalSubmission" : 20,
      "type" : "long"
    } ]
  }
}
Path Type Description

status

String

결과 상태

data.contents

Array

문제 데이터

data.contents.[].id

Number

문제 id

data.contents.[].title

String

문제 제목

data.contents.[].tags

Array

태그

data.contents.[].avgScore

Number

평균 점수 ( 푼 사람이 없는 경우 null return )

data.contents.[].totalSubmission

Number

총 제출 수

data.contents.[].type

String

문제의 타입 ( short, multiple, long )

문제 채점 결과 평가 의견

description
문제 채점 결과에 대한 평가 의견을 남기기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/problems/grade/{problem_id:Long}/assessment
Sample Request
POST /api/v1/problems/grade/1/assessment HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 53
Host: localhost:8080

{
  "assessmentType" : "GOOD",
  "content" : "test"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Table 7. /api/v1/problems/grade/{grading_history_id}/assessment
Parameter Description

grading_history_id

문제 채점 id

객관식 문제 단건 조회를 위한 path parameter의 설명입니다.

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

인증을 위한 Access 토큰

Request Body
{
  "assessmentType" : "GOOD",
  "content" : "test"
}
Path Type Description

assessmentType

String

평가 의견 타입 ( 좋음 : GOOD, 나쁨 : BAD, 적당 : NORMAL )

content

String

평가 의견 내용 ( 없어도 상관 없음, 최대 150자 )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

평가 의견 아이디

Problems API V2 ( /api/v2/problems )

단답형 문제 단건 조회

description
단답형 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v2/problems/short/{problem_id:Long}
Sample Request
GET /api/v2/problems/short/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 346

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "answerLength" : 10,
    "consistOf" : "ENGLISH",
    "isSolved" : true,
    "score" : 10.0
  }
}
Table 8. /api/v2/problems/short/{problem_id}
Parameter Description

problem_id

문제 id

객관식 문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "problem title",
    "tags" : [ "tag1", "tag2" ],
    "description" : "problem description",
    "correctSubmission" : 10,
    "correctUserCnt" : 10,
    "totalSubmission" : 10,
    "answerLength" : 10,
    "consistOf" : "ENGLISH",
    "isSolved" : true,
    "score" : 10.0
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 id

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.correctUserCnt

Number

맞은 사람 수

data.correctSubmission

Number

맞은 제출 수

data.totalSubmission

Number

총 제출 수

data.answerLength

Number

정답 글자수 ( 힌트 )

data.consistOf

String

정답 언어 ( 영어면 ENGLISH, 한국어면 KOREAN, 숫자면 NUMERIC )

data.isSolved

Boolean

푼 문제 여부

data.score

Number

문제 배점

문제 이의 제기

description
문제 이의 제기를 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v2/problems/{problem_id:Long}/challenge
Sample Request
POST /api/v2/problems/1/challenge HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 69
Host: localhost:8080

{
  "content" : "이것은 이의제기를 위한 내용입니다."
}
Table 9. /api/v2/problems/{problem_id}/challenge
Parameter Description

problem_id

문제 id

이의 제기를 위한 path parameter의 설명입니다.

Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

Name Description

Authorization

인증을 위한 Access 토큰

Request Body
{
  "content" : "이것은 이의제기를 위한 내용입니다."
}
Path Type Description

content

String

이의제기 내용 ( 최소 10자 ~ 최대 150자 )

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 43

{
  "status" : "success",
  "data" : true
}
Table 10. /api/v2/problems/{problem_id}/challenge
Parameter Description

problem_id

문제 id

Response Body
{
  "status" : "success",
  "data" : true
}
Path Type Description

status

String

결과 상태

data

Boolean

이의제기 데이터 생성 여부

문제 좋아요 API ( /api/v2/problems/{postId}/like )

description
문제를 좋아요하기 위한 API입니다.
HTTP Method : POST
End-Point   : /api/v2/problems/{postId}/like
Sample Request
POST /api/v2/problems/1/like HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Table 11. /api/v2/problems/{problemId}/like
Parameter Description

problemId

문제 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 26

{
  "status" : "success"
}
Response Body
{
  "status" : "success"
}
Path Type Description

status

String

결과 상태

문제 북마크 API ( /api/v2/problems/{postId}/bookmark )

description
문제를 북마크하기 위한 API입니다.
HTTP Method : POST
End-Point   : /api/v2/problems/{postId}/bookmark
Sample Request
POST /api/v2/problems/1/bookmark HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Table 12. /api/v2/problems/{problemId}/bookmark
Parameter Description

problemId

문제 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 26

{
  "status" : "success"
}
Response Body
{
  "status" : "success"
}
Path Type Description

status

String

결과 상태

User API ( /api/v1/users )

유저 조회

description
유저 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/users/{user_id:UUID}
Sample Request
GET /api/v1/users/a6a9affc-9707-4ed7-8eff-10d5ddb6618a HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 414

{
  "status" : "success",
  "data" : {
    "id" : "293e7ba5-cf6b-48d2-aceb-98648d34b38c",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 회원 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

Access 토큰 ( JWT )

Table 13. /api/v1/users/{user_id}
Parameter Description

user_id

회원 UUID

유저 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "293e7ba5-cf6b-48d2-aceb-98648d34b38c",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  }
}
Path Type Description

status

String

결과 상태

data.id

String

UUID

data.email

String

이메일

data.username

String

닉네임

data.role

String

권한

data.major

String

전공

data.job

String

직업

data.jobObjective

String

희망 직무

data.techs

Array

사용 기술

data.profileImgUrl

String

프로필 이미지 url

data.githubUrl

String

Github url

data.linkedinUrl

String

LinkedIn url

data.providerType

String

Provider Type ( GOOGLE, GITHUB, LOCAL )

유저 전체 조회

description
유저 전체 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/users
Sample Request
GET /api/v1/users HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 418

{
  "status" : "success",
  "data" : [ {
    "id" : "81fba690-31d8-4aa4-8e13-5b1d6af4394e",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  } ]
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 Admin 권한을 가진 유저의 Access Token이며, 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

Admin 권한의 Access 토큰 ( JWT )

Response Body
{
  "status" : "success",
  "data" : [ {
    "id" : "81fba690-31d8-4aa4-8e13-5b1d6af4394e",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  } ]
}
Path Type Description

status

String

결과 상태

data.[].id

String

UUID

data.[].email

String

이메일

data.[].username

String

닉네임

data.[].role

String

권한

data.[].major

String

전공

data.[].job

String

직업

data.[].jobObjective

String

희망 직무

data.[].techs

Array

사용 기술

data.[].profileImgUrl

String

프로필 이미지 url

data.[].githubUrl

String

Github url

data.[].linkedinUrl

String

LinkedIn url

data.[].providerType

String

Provider Type ( GOOGLE, GITHUB, LOCAL )

유저 정보 수정

description
유저 정보 수정을 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/v1/users/{userID: UUID}
Sample Request
PUT /api/v1/users/bb6fa695-dc16-4cb1-95d9-8b5c06cd450a HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 436
Host: localhost:8080

{
  "profileImageUrl" : "https://test.com/test.png",
  "username" : "test-admin-update",
  "originalPassword" : "password",
  "password" : "changePassword123!",
  "major" : "환경공학",
  "job" : "대학생",
  "jobObjective" : "프론트엔드 개발자",
  "techs" : [ "react", "typescript" ],
  "githubUrl" : "https://github.com/Kim-Hyunjo",
  "linkedinUrl" : "https://www.linkedin.com/in/%EC%9E%AC%EC%9B%90-%EB%AF%BC-2b5149211"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 414

{
  "status" : "success",
  "data" : {
    "id" : "e4b9c356-c7a2-4180-bb55-1ab0068a8c21",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 회원 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

Access 토큰 ( JWT )

Request Body
{
  "profileImageUrl" : "https://test.com/test.png",
  "username" : "test-admin-update",
  "originalPassword" : "password",
  "password" : "changePassword123!",
  "major" : "환경공학",
  "job" : "대학생",
  "jobObjective" : "프론트엔드 개발자",
  "techs" : [ "react", "typescript" ],
  "githubUrl" : "https://github.com/Kim-Hyunjo",
  "linkedinUrl" : "https://www.linkedin.com/in/%EC%9E%AC%EC%9B%90-%EB%AF%BC-2b5149211"
}
Path Type Description

username

String

수정할 닉네임 ( 필수 X )

profileImageUrl

String

수정할 프로필 이미지 url ( 필수 X )

originalPassword

String

수정전 비밀번호 ( 필수 X, but 수정시 필수 )

password

String

수정할 비밀번호 ( 필수 X )

major

String

수정할 전공 ( 필수 X )

job

String

수정할 직업 ( 필수 X )

jobObjective

String

수정할 희망 직무 ( 필수 X )

techs

Array

수정할 사용 기술 ( 필수 X )

githubUrl

String

수정할 github url ( 필수 X )

linkedinUrl

String

수정할 linkedin url ( 필수 X )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "e4b9c356-c7a2-4180-bb55-1ab0068a8c21",
    "email" : "email",
    "username" : "username",
    "role" : "ROLE_USER",
    "major" : "major",
    "job" : "job",
    "jobObjective" : "jobObjective",
    "techs" : [ "tech" ],
    "profileImgUrl" : "profileImageUrl",
    "githubUrl" : "githubUrl",
    "linkedinUrl" : "linkedinUrl",
    "providerType" : "LOCAL"
  }
}
Path Type Description

status

String

결과 상태

data.id

String

UUID

data.email

String

이메일

data.username

String

닉네임

data.role

String

권한

data.major

String

전공

data.job

String

직업

data.jobObjective

String

희망 직무

data.techs

Array

사용 기술

data.profileImgUrl

String

프로필 이미지 url

data.githubUrl

String

Github url

data.linkedinUrl

String

LinkedIn url

data.providerType

String

Provider Type ( GOOGLE, GITHUB, LOCAL )

유저 삭제

description
유저 삭제를 위한 API입니다.

HTTP Method : DELETE
End-Point   : /api/v1/users/{userID: UUID}
Sample Request
DELETE /api/v1/users/d2d8b3f2-360d-4b43-8161-a54f9aa12e3c HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 115

{
  "status" : "success",
  "data" : {
    "id" : "d2d8b3f2-360d-4b43-8161-a54f9aa12e3c",
    "result" : true
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 회원 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

Access 토큰 ( JWT )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : "d2d8b3f2-360d-4b43-8161-a54f9aa12e3c",
    "result" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

String

UUID

data.result

Boolean

삭제 결과

유저 통계 조회

description
유저 통계 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/users/{user_id}/stats
Sample Request
GET /api/v1/users/be866e92-93e8-4b46-9216-1d640fe857ea/stats HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 514

{
  "status" : "success",
  "data" : {
    "correctAnsweredProblem" : [ {
      "id" : 1,
      "type" : "long",
      "title" : "Long Problem"
    } ],
    "wrongAnsweredProblem" : [ {
      "id" : 2,
      "type" : "short",
      "title" : "Short Problem"
    } ],
    "partialAnsweredProblem" : [ {
      "id" : 3,
      "type" : "short",
      "title" : "Short Problem"
    } ],
    "count" : {
      "os" : 1,
      "network" : 2,
      "ds" : 3,
      "db" : 4
    },
    "rank" : 1,
    "score" : 10.0
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

Admin 권한의 Access 토큰 ( JWT )

Response Body
{
  "status" : "success",
  "data" : {
    "correctAnsweredProblem" : [ {
      "id" : 1,
      "type" : "long",
      "title" : "Long Problem"
    } ],
    "wrongAnsweredProblem" : [ {
      "id" : 2,
      "type" : "short",
      "title" : "Short Problem"
    } ],
    "partialAnsweredProblem" : [ {
      "id" : 3,
      "type" : "short",
      "title" : "Short Problem"
    } ],
    "count" : {
      "os" : 1,
      "network" : 2,
      "ds" : 3,
      "db" : 4
    },
    "rank" : 1,
    "score" : 10.0
  }
}
Path Type Description

status

String

결과 상태

data.correctAnsweredProblem

Array

맞은 문제

data.correctAnsweredProblem.[].id

Number

문제 id

data.correctAnsweredProblem.[].type

String

문제 타입

data.correctAnsweredProblem.[].title

String

문제 제목

data.wrongAnsweredProblem

Array

틀린 문제

data.wrongAnsweredProblem.[].id

Number

문제 id

data.wrongAnsweredProblem.[].type

String

문제 타입

data.wrongAnsweredProblem.[].title

String

문제 제목

data.partialAnsweredProblem

Array

부분 점수를 받은 문제

data.partialAnsweredProblem.[].id

Number

문제 id

data.partialAnsweredProblem.[].type

String

문제 타입

data.partialAnsweredProblem.[].title

String

문제 제목

data.count

Object

푼 문제 수 통계

data.count.os

Number

맞은 운영체제 문제 수 통계

data.count.network

Number

맞은 네트워크 문제 수 통계

data.count.ds

Number

맞은 자료구조 문제 수 통계

data.count.db

Number

맞은 데이터베이스 문제 수 통계

data.rank

Number

랭킹 ( 랭킹이 집계되지 않았다면, null )

data.score

Number

점수

Notification API ( /api/v1/notifications )

Notification 조회

description
Notification 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/notifications
Req Params : page, size
Sample Request
GET /api/v1/notifications?page=0&size=10 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 331

{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "content" : "content",
      "link" : "link",
      "isRead" : false,
      "createdAt" : "2024-01-21T13:35:58.02883887"
    } ],
    "currentPage" : 0,
    "totalPages" : 1,
    "totalElements" : 1,
    "numberOfElements" : 1,
    "size" : 10
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

인증을 위한 Access 토큰

Request Params

Unresolved directive in index.adoc - include::./build/generated-snippets/notifications/getAll/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "contents" : [ {
      "id" : 1,
      "content" : "content",
      "link" : "link",
      "isRead" : false,
      "createdAt" : "2024-01-21T13:35:58.02883887"
    } ],
    "currentPage" : 0,
    "totalPages" : 1,
    "totalElements" : 1,
    "numberOfElements" : 1,
    "size" : 10
  }
}
Path Type Description

status

String

결과 상태

data.contents

Array

알림 내용 리스트

data.contents.[].id

Number

알림 ID

data.contents.[].content

String

알림 내용

data.contents.[].link

String

알림 링크

data.contents.[].isRead

Boolean

알림 읽음 여부

data.contents.[].createdAt

String

알림 생성 시간

data.currentPage

Number

요청한 현재 페이지

data.totalPages

Number

총 페이지

data.totalElements

Number

총 알림 개수

data.numberOfElements

Number

현재 페이지의 알림 개수

data.size

Number

한 페이지에 보여줄 알림 개수

Notification 단건 읽음 처리

description
Notification 읽음 처리를 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/v1/notifications/read/{notification_id}
Sample Request
PUT /api/v1/notifications/read/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 65

{
  "status" : "success",
  "data" : {
    "success" : true
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

인증을 위한 Access 토큰

Response Body
{
  "status" : "success",
  "data" : {
    "success" : true
  }
}
Path Type Description

status

String

결과 상태

data.success

Boolean

읽음 처리 성공 여부

Notification 다건 읽음 처리

description
Notification 여러건의 읽음 처리를 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/v1/notifications/read
Sample Request
PUT /api/v1/notifications/read HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 19
Host: localhost:8080

{
  "ids" : [ 1 ]
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 65

{
  "status" : "success",
  "data" : {
    "success" : true
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

인증을 위한 Access 토큰

Response Body
{
  "status" : "success",
  "data" : {
    "success" : true
  }
}
Path Type Description

status

String

결과 상태

data.success

Boolean

읽음 처리 성공 여부

읽지않은 Notification 개수 조회

description
읽지않은 Notification 개수 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/notifications/count
Sample Request
GET /api/v1/notifications/count HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 61

{
  "status" : "success",
  "data" : {
    "count" : 10
  }
}
Request Header

request를 살펴보면 Authorization 헤더에서 Bearer token 형태로, access token을 전달하는 것을 알 수 있습니다.

이 Access Token은 인증을 위해 필수적으로 포함되어야 합니다.

Name Description

Authorization

인증을 위한 Access 토큰

Response Body
{
  "status" : "success",
  "data" : {
    "count" : 10
  }
}
Path Type Description

status

String

결과 상태

data.count

Number

읽지 않은 알림 개수

문제 세트 API ( /api/v1/problem-sets )

문제 세트 전체 조회

description
문제 세트 전체 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problem-sets
Sample Request
GET /api/v1/problem-sets HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 166

{
  "status" : "success",
  "data" : [ {
    "id" : 1,
    "problemCnt" : 0,
    "name" : "test 문제세트",
    "description" : "테스트용 문제세트"
  } ]
}
Response Body
{
  "status" : "success",
  "data" : [ {
    "id" : 1,
    "problemCnt" : 0,
    "name" : "test 문제세트",
    "description" : "테스트용 문제세트"
  } ]
}
Path Type Description

status

String

결과 상태

data.[].id

Number

문제 세트 ID

data.[].problemCnt

Number

문제 세트에 포함된 문제 수

data.[].name

String

문제 세트 이름

data.[].description

String

문제 세트 설명

문제 세트 단건 조회

description
문제 세트 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problem-sets/{problemSetId}
Sample Request
GET /api/v1/problem-sets/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 676

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "problems" : [ {
      "id" : 1,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "long"
    }, {
      "id" : 2,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "multiple"
    }, {
      "id" : 3,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "short"
    } ],
    "name" : "test 문제세트",
    "description" : "테스트용 문제세트"
  }
}
Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "problems" : [ {
      "id" : 1,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "long"
    }, {
      "id" : 2,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "multiple"
    }, {
      "id" : 3,
      "title" : "test 문제",
      "tags" : [ "DS", "Network" ],
      "avgScore" : 10.0,
      "totalSubmission" : 100,
      "type" : "short"
    } ],
    "name" : "test 문제세트",
    "description" : "테스트용 문제세트"
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 세트 ID

data.name

String

문제 세트 이름

data.description

String

문제 세트 설명

data.problems

Array

문제 세트에 포함된 문제

data.problems.[].id

Number

문제 ID

data.problems.[].title

String

문제 이름

data.problems.[].tags

Array

문제 태그

data.problems.[].avgScore

Number

문제 평균 점수

data.problems.[].totalSubmission

Number

문제 제출 수

data.problems.[].type

String

문제 타입

게시판 API

글 작성 API ( /api/v1/posts )

description
글을 생성하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/posts
Sample Request
POST /api/v1/posts HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Content-Length: 46
Host: localhost:8080

{
  "problemId" : 1,
  "content" : "content"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 40

{
  "status" : "success",
  "data" : 1
}
Request Body
{
  "problemId" : 1,
  "content" : "content"
}
Path Type Description

problemId

Number

문제 ID

content

String

글 내용

Response Body
{
  "status" : "success",
  "data" : 1
}
Path Type Description

status

String

결과 상태

data

Number

글 ID

글 조회 API ( /api/v1/problems/{problemId}/posts )

description
글을 조회하기 위한 API입니다.

HTTP Method : GET
End-Point   : /api/v1/problems/{problemId}/posts
Sample Request
GET /api/v1/problems/1/posts HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Host: localhost:8080
Table 14. /api/v1/problems/{problemId}/posts
Parameter Description

problemId

문제 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 469

{
  "status" : "success",
  "data" : [ {
    "id" : 1,
    "content" : "CONTENT",
    "username" : "USER",
    "userId" : "efa1d7d1-3fc1-4cef-a1f8-263050594ab2",
    "likeCount" : 1,
    "isLiked" : true,
    "comments" : [ {
      "id" : 1,
      "content" : "CONTENT",
      "username" : "USER",
      "userId" : "3b7f1958-4bc5-421c-b3aa-650a68200938",
      "likeCount" : 1,
      "isLiked" : true,
      "createdAt" : "2024-01-21T13:35:59.272512244"
    } ]
  } ]
}
Response Body
{
  "status" : "success",
  "data" : [ {
    "id" : 1,
    "content" : "CONTENT",
    "username" : "USER",
    "userId" : "efa1d7d1-3fc1-4cef-a1f8-263050594ab2",
    "likeCount" : 1,
    "isLiked" : true,
    "comments" : [ {
      "id" : 1,
      "content" : "CONTENT",
      "username" : "USER",
      "userId" : "3b7f1958-4bc5-421c-b3aa-650a68200938",
      "likeCount" : 1,
      "isLiked" : true,
      "createdAt" : "2024-01-21T13:35:59.272512244"
    } ]
  } ]
}
Path Type Description

status

String

결과 상태

data[].id

Number

글 ID

data[].content

String

글 내용

data[].username

String

작성자

data[].userId

String

작성자 ID

data[].likeCount

Number

좋아요 수

data[].isLiked

Boolean

좋아요 여부

data[].comments[].id

Number

댓글 ID

data[].comments[].content

String

댓글 내용

data[].comments[].username

String

댓글 작성자

data[].comments[].userId

String

댓글 작성자 ID

data[].comments[].likeCount

Number

좋아요 수

data[].comments[].isLiked

Boolean

좋아요 여부

data[].comments[].createdAt

String

댓글 생성일시

글 삭제 API ( /api/v1/posts/{postId} )

description
글을 삭제하기 위한 API입니다.

HTTP Method : DELETE
End-Point   : /api/v1/posts/{postId}
Sample Request
DELETE /api/v1/posts/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Host: localhost:8080
Table 15. /api/v1/posts/{postId}
Parameter Description

postId

글 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 26

{
  "status" : "success"
}
Response Body
{
  "status" : "success"
}
Path Type Description

status

String

결과 상태

글 좋아요 API ( /api/v1/posts/{postId}/like )

description
글을 좋아요하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/posts/{postId}/like
Sample Request
POST /api/v1/posts/1/like HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Host: localhost:8080
Table 16. /api/v1/posts/{postId}/like
Parameter Description

postId

글 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 26

{
  "status" : "success"
}
Response Body
{
  "status" : "success"
}
Path Type Description

status

String

결과 상태

댓글 작성 API ( /api/v1/comments )

description
댓글을 생성하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/v1/comments
Sample Request
POST /api/v1/comments HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Content-Length: 43
Host: localhost:8080

{
  "postId" : 1,
  "content" : "content"
}
Path parameters

Unresolved directive in index.adoc - include::./build/generated-snippets/posts/comments/create/path-parameters.adoc[]

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 40

{
  "status" : "success",
  "data" : 1
}
Request Body
{
  "postId" : 1,
  "content" : "content"
}
Path Type Description

postId

Number

글 id

content

String

댓글 내용

Response Body
{
  "status" : "success",
  "data" : 1
}
Path Type Description

status

String

결과 상태

data

Number

댓글 ID

댓글 삭제 API ( /api/v1/comments/{commentId} )

description
댓글을 삭제하기 위한 API입니다.

HTTP Method : DELETE
End-Point   : /api/v1/comments/{commentId}
Sample Request
DELETE /api/v1/comments/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Host: localhost:8080
Table 17. /api/v1/comments/{commentId}
Parameter Description

commentId

댓글 id

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 26

{
  "status" : "success"
}
Response Body
{
  "status" : "success"
}
Path Type Description

status

String

결과 상태

Back-Office APIs

백오피스에서 사용되는 API입니다.

이 API들의 호출을 위해서는 필수적으로 ADMIN 권한이 필요합니다.

각 설명에서는 생략하겠지만, 항상 ADMIN 권한을 가진 Access Token을 Authorization Header에 포함해야합니다.

Long Problem API ( /api/admin/problems/long )

서술형 문제 생성

description
서술형 문제를 생성하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/problems/long
Sample Request
POST /api/admin/problems/long HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 264
Host: localhost:8080

{
  "title" : "test",
  "description" : "test",
  "standardAnswers" : [ "test" ],
  "tags" : [ "db", "network" ],
  "gradingStandards" : [ {
    "content" : "keyword-1",
    "score" : 1.0,
    "type" : "KEYWORD"
  } ],
  "isGradable" : false,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test",
  "description" : "test",
  "standardAnswers" : [ "test" ],
  "tags" : [ "db", "network" ],
  "gradingStandards" : [ {
    "content" : "keyword-1",
    "score" : 1.0,
    "type" : "KEYWORD"
  } ],
  "isGradable" : false,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

standardAnswers

Array

모범 답안

tags

Array

태그

gradingStandards

Array

채점기준

gradingStandards.[].content

String

채점기준 내용

gradingStandards.[].score

Number

채점기준 점수

gradingStandards.[].type

String

채점기준 타입 ( 'KEYWORD' or 'CONTENT' )

isGradable

Boolean

채점 가능 여부 ( 필수 x, 기본 값 false )

isActive

Boolean

활성화 여부 ( 필수 x, 기본 값 true )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

서술형 문제 단건 조회

description
단답형 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/long/{problem_id:Long}
Sample Request
GET /api/admin/problems/long/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 363

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "title",
    "description" : "description",
    "standardAnswers" : [ "answer" ],
    "tags" : [ "tag1", "tag2" ],
    "gradingStandards" : [ {
      "id" : 1,
      "content" : "content",
      "score" : 1.0,
      "type" : "KEYWORD"
    } ],
    "isActive" : true,
    "isGradable" : true
  }
}
Table 18. /api/admin/problems/long/{problem_id}
Parameter Description

problem_id

문제 id

문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "title",
    "description" : "description",
    "standardAnswers" : [ "answer" ],
    "tags" : [ "tag1", "tag2" ],
    "gradingStandards" : [ {
      "id" : 1,
      "content" : "content",
      "score" : 1.0,
      "type" : "KEYWORD"
    } ],
    "isActive" : true,
    "isGradable" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

data.title

String

문제 제목

data.description

String

문제 설명

data.standardAnswers

Array

모범 답안

data.tags

Array

태그

data.gradingStandards

Array

채점기준

data.gradingStandards.[].id

Number

채점기준 ID

data.gradingStandards.[].content

String

채점기준 내용

data.gradingStandards.[].score

Number

채점기준 점수

data.gradingStandards.[].type

String

채점기준 타입 ( 'KEYWORD' or 'CONTENT' )

data.isGradable

Boolean

채점 가능 여부

data.isActive

Boolean

활성화 여부

서술형 문제 검색

description
서술형 문제 검색을 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/long
Req Params  : id, title, description page, size
Sample Request
GET /api/admin/problems/long?title=title&description=description&size=10&page=0 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 303

{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "avgKeywordScore" : 1.0,
      "avgContentScore" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Request parameters

문제 검색을 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/admin/problems/long/search/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "avgKeywordScore" : 1.0,
      "avgContentScore" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Path Type Description

status

String

결과 상태

data.problems

Array

문제 데이터

data.problems.[].id

Number

문제 id

data.problems.[].title

String

문제 제목

data.problems.[].creator

String

문제 제작자 닉네임

data.problems.[].avgKeywordScore

Number

평균 키워드 점수 ( 푼 사람이 없으면 null )

data.problems.[].avgContentScore

Number

평균 내용 점수 ( 푼 사람이 없으면 null )

data.problems.[].userAnswerCnt

Number

제출된 답안 수

data.problems.[].isActive

Boolean

활성화 여부

data.totalPages

Number

총 페이지 수

data.totalElements

Number

검색된 총 문제수

서술형 문제 수정

description
서술형 문제 수정를 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/admin/problems/long/{problem_id:Long}
Sample Request
PUT /api/admin/problems/long/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 264
Host: localhost:8080

{
  "title" : "test",
  "description" : "test",
  "standardAnswers" : [ "test" ],
  "tags" : [ "db", "network" ],
  "gradingStandards" : [ {
    "content" : "keyword-1",
    "score" : 1.0,
    "type" : "KEYWORD"
  } ],
  "isGradable" : false,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test",
  "description" : "test",
  "standardAnswers" : [ "test" ],
  "tags" : [ "db", "network" ],
  "gradingStandards" : [ {
    "content" : "keyword-1",
    "score" : 1.0,
    "type" : "KEYWORD"
  } ],
  "isGradable" : false,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

standardAnswers

Array

모범 답안

tags

Array

태그

gradingStandards

Array

채점기준

gradingStandards.[].content

String

채점기준 내용

gradingStandards.[].score

Number

채점기준 점수

gradingStandards.[].type

String

채점기준 타입 ( 'KEYWORD' or 'CONTENT' )

isGradable

Boolean

채점 가능 여부

isActive

Boolean

활성화 여부

Table 19. /api/admin/problems/long/{problem_id}
Parameter Description

problem_id

문제 id

문제 수정을 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

Multiple Choice Problem API ( /api/admin/problems/multiple )

객관식 문제 생성

description
객관식 문제를 생성하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/problems/multiple
Sample Request
POST /api/admin/problems/multiple HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 274
Host: localhost:8080

{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "choices" : [ {
    "content" : "choice-1",
    "isAnswer" : true
  }, {
    "content" : "choice-2",
    "isAnswer" : false
  } ],
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "choices" : [ {
    "content" : "choice-1",
    "isAnswer" : true
  }, {
    "content" : "choice-2",
    "isAnswer" : false
  } ],
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

tags

Array

태그

choices

Array

선지

choices.[].content

String

선지 내용

choices.[].isAnswer

Boolean

선지 정답 여부

score

Number

채점기준 점수

isGradable

Boolean

채점 가능 여부 ( 필수 x, 기본 값 true )

isActive

Boolean

활성화 여부 ( 필수 x, 기본 값 true )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

객관식 문제 단건 조회

description
객관식 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/multiple/{problem_id:Long}
Sample Request
GET /api/admin/problems/multiple/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 383

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "test",
    "description" : "test",
    "tags" : [ "db", "network" ],
    "isMultiple" : true,
    "choiceData" : [ {
      "content" : "choice-1",
      "isAnswer" : true
    }, {
      "content" : "choice-2",
      "isAnswer" : false
    } ],
    "score" : 5.0,
    "isActive" : true,
    "isGradable" : true
  }
}
Table 20. /api/admin/problems/multiple/{problem_id}
Parameter Description

problem_id

문제 id

문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "test",
    "description" : "test",
    "tags" : [ "db", "network" ],
    "isMultiple" : true,
    "choiceData" : [ {
      "content" : "choice-1",
      "isAnswer" : true
    }, {
      "content" : "choice-2",
      "isAnswer" : false
    } ],
    "score" : 5.0,
    "isActive" : true,
    "isGradable" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.isMultiple

Boolean

다중 정답 유무

data.choiceData

Array

선지 데이터

data.choiceData.[].content

String

선지 내용

data.choiceData.[].isAnswer

Boolean

선지 정답 여부

data.score

Number

문제 점수

data.isGradable

Boolean

채점 가능 여부

data.isActive

Boolean

활성화 여부

객관식 문제 검색

description
객관식 문제 검색을 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/multiple
Req Params  : id, title, description page, size
Sample Request
GET /api/admin/problems/multiple?title=test&description=t&size=5&page=1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 267

{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "answerRate" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Request parameters

문제 검색을 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/admin/problems/multiple/search/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "answerRate" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Path Type Description

status

String

결과 상태

data.problems

Array

문제 데이터

data.problems.[].id

Number

문제 id

data.problems.[].title

String

문제 제목

data.problems.[].creator

String

문제 제작자 닉네임

data.problems.[].answerRate

Number

정답률 ( 푼 사람이 없으면 null )

data.problems.[].userAnswerCnt

Number

제출된 답안 수

data.problems.[].isActive

Boolean

활성화 여부

data.totalPages

Number

총 페이지 수

data.totalElements

Number

검색된 총 문제수

객관식 문제 수정

description
객관식 문제 수정를 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/admin/problems/multiple/{problem_id:Long}
Sample Request
PUT /api/admin/problems/multiple/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 274
Host: localhost:8080

{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "choices" : [ {
    "content" : "choice-1",
    "isAnswer" : true
  }, {
    "content" : "choice-2",
    "isAnswer" : false
  } ],
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "choices" : [ {
    "content" : "choice-1",
    "isAnswer" : true
  }, {
    "content" : "choice-2",
    "isAnswer" : false
  } ],
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

tags

Array

태그

choices

Array

선지

choices.[].content

String

선지 내용

choices.[].isAnswer

Boolean

선지 정답 여부

score

Number

채점기준 점수

isGradable

Boolean

채점 가능 여부

isActive

Boolean

활성화 여부

Table 21. /api/admin/problems/multiple/{problem_id}
Parameter Description

problem_id

문제 id

문제 수정을 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

Short Problem API ( /api/admin/problems/short)

단답형 문제 생성

description
단답형 문제를 생성하기 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/problems/short
Sample Request
POST /api/admin/problems/short HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 162
Host: localhost:8080

{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "answer" : "test",
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test",
  "description" : "test",
  "tags" : [ "db", "network" ],
  "answer" : "test",
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

tags

Array

태그

answer

String

정답

score

Number

채점기준 점수

isGradable

Boolean

채점 가능 여부 ( 필수 x, 기본 값 true )

isActive

Boolean

활성화 여부 ( 필수 x, 기본 값 true )

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

단답형 문제 단건 조회

description
단답형 문제 단건 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/short/{problem_id:Long}
Sample Request
GET /api/admin/problems/short/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 231

{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "test",
    "description" : "test",
    "tags" : [ "db", "network" ],
    "answer" : "test",
    "score" : 5.0,
    "isActive" : true,
    "isGradable" : true
  }
}
Table 22. /api/admin/problems/short/{problem_id}
Parameter Description

problem_id

문제 id

문제 단건 조회를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1,
    "title" : "test",
    "description" : "test",
    "tags" : [ "db", "network" ],
    "answer" : "test",
    "score" : 5.0,
    "isActive" : true,
    "isGradable" : true
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

data.title

String

문제 제목

data.description

String

문제 설명

data.tags

Array

태그

data.answer

String

문제 정답

data.score

Number

문제 점수

data.isGradable

Boolean

채점 가능 여부

data.isActive

Boolean

활성화 여부

단답형 문제 검색

description
단답형 문제 검색을 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/problems/short
Req Params  : id, title, description page, size
Sample Request
GET /api/admin/problems/short?title=test&description=t&size=5&page=1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 267

{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "answerRate" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Request parameters

문제 검색을 위한 request parameter의 설명입니다. Unresolved directive in index.adoc - include::./build/generated-snippets/admin/problems/short/search/request-parameters.adoc[]

Response Body
{
  "status" : "success",
  "data" : {
    "problems" : [ {
      "id" : 1,
      "title" : "title",
      "creator" : "creator",
      "answerRate" : 1.0,
      "userAnswerCnt" : 1,
      "isActive" : true
    } ],
    "totalPages" : 1,
    "totalElements" : 1
  }
}
Path Type Description

status

String

결과 상태

data.problems

Array

문제 데이터

data.problems.[].id

Number

문제 id

data.problems.[].title

String

문제 제목

data.problems.[].creator

String

문제 제작자 닉네임

data.problems.[].answerRate

Number

정답률 ( 푼 사람이 없으면 null )

data.problems.[].userAnswerCnt

Number

제출된 답안 수

data.problems.[].isActive

Boolean

활성화 여부

data.totalPages

Number

총 페이지 수

data.totalElements

Number

검색된 총 문제수

단답형 문제 수정

description
단답형 문제 수정를 위한 API입니다.

HTTP Method : PUT
End-Point   : /api/admin/problems/short/{problem_id:Long}
Sample Request
PUT /api/admin/problems/short/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 164
Host: localhost:8080

{
  "title" : "test1",
  "description" : "test1",
  "tags" : [ "db", "network" ],
  "answer" : "test",
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Request Body
{
  "title" : "test1",
  "description" : "test1",
  "tags" : [ "db", "network" ],
  "answer" : "test",
  "score" : 5.0,
  "isGradable" : true,
  "isActive" : true
}
Path Type Description

title

String

문제 제목

description

String

문제 설명

tags

Array

태그

answer

String

문제 정답

score

Number

문제 점수

isGradable

Boolean

채점 가능 여부

isActive

Boolean

활성화 여부

Table 23. /api/admin/problems/short/{problem_id}
Parameter Description

problem_id

문제 id

문제 수정을 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

문제 ID

Problem Delete API ( /api/admin/problems )

문제 단건 삭제

description
문제 삭제를 위한 API입니다.

HTTP Method : DELETE
End-Point   : /api/admin/problems/{problem_id:Long}
Sample Request
DELETE /api/admin/problems/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 43

{
  "status" : "success",
  "data" : true
}
Table 24. /api/admin/problems/{problem_id}
Parameter Description

problem_id

문제 id

문제 삭제를 위한 path parameter의 설명입니다.

Response Body
{
  "status" : "success",
  "data" : true
}
Path Type Description

status

String

결과 상태

data

Boolean

성공 유무 ( 삭제 성공시 true를 return )

문제 다중 삭제

description
여러 개의 문제 삭제를 위한 API입니다.

HTTP Method : DELETE
End-Point   : /api/admin/problems
Sample Request
DELETE /api/admin/problems HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 25
Host: localhost:8080

{
  "ids" : [ 1, 2, 3 ]
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 43

{
  "status" : "success",
  "data" : true
}
Request Body
{
  "ids" : [ 1, 2, 3 ]
}
Path Type Description

ids

Array

삭제 할 문제 id 리스트

Response Body
{
  "status" : "success",
  "data" : true
}
Path Type Description

status

String

결과 상태

data

Boolean

성공 유무 ( 삭제 성공시 true를 return )

User API ( /api/admin/users )

ADMIN 유저 조회

description
ADMIN 유저 조회를 위한 API입니다.

HTTP Method : GET
End-Point   : /api/admin/users/admin
Sample Request
GET /api/admin/users/admin HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Host: localhost:8080
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 124

{
  "status" : "success",
  "data" : [ {
    "id" : "66b95f70-b7fc-4b82-bbd4-df734bf3da85",
    "username" : "email"
  } ]
}
Response Body
{
  "status" : "success",
  "data" : [ {
    "id" : "66b95f70-b7fc-4b82-bbd4-df734bf3da85",
    "username" : "email"
  } ]
}
Path Type Description

status

String

결과 상태

data

Array

ADMIN 유저 정보

data.[].id

String

유저 ID

data.[].username

String

유저 닉네임

Notification API ( /api/admin/notification )

Notification 생성

description
Notification 단일 생성을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/notification
Sample Request
POST /api/admin/notification HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 110
Host: localhost:8080

{
  "content" : "알림이 왓어요",
  "userId" : "aec0b6cc-f670-43dd-aeff-1c8b0ccd603d",
  "link" : "url"
}
Request Body
{
  "content" : "알림이 왓어요",
  "userId" : "aec0b6cc-f670-43dd-aeff-1c8b0ccd603d",
  "link" : "url"
}
Path Type Description

content

String

알림 내용

userId

String

유저 아이디 ( UUID )

link

String

알림에 해당하는 링크

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 57

{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Response Body
{
  "status" : "success",
  "data" : {
    "id" : 1
  }
}
Path Type Description

status

String

결과 상태

data.id

Number

알림 ID

Notification 다중 생성

description
Notification 다중 생성을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/notifications
Sample Request
POST /api/admin/notifications HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 140
Host: localhost:8080

{
  "content" : [ {
    "content" : "알림이 왔어요",
    "userId" : "ccbcf6b3-103b-4fff-89dc-ad98ef735c72",
    "link" : "url"
  } ]
}
Request Body
{
  "content" : [ {
    "content" : "알림이 왔어요",
    "userId" : "ccbcf6b3-103b-4fff-89dc-ad98ef735c72",
    "link" : "url"
  } ]
}
Path Type Description

content

Array

알림 데이터

content.[].content

String

알림 내용

content.[].userId

String

유저 아이디 ( UUID )

content.[].link

String

알림에 해당하는 링크

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 59

{
  "status" : "success",
  "data" : {
    "size" : 1
  }
}
Response Body
{
  "status" : "success",
  "data" : {
    "size" : 1
  }
}
Path Type Description

status

String

결과 상태

data.size

Number

생성 된 알림 개수

Notification 삭제

description
Notification 삭제를 위한 API입니다.
단일 삭제는 List에 ID 한 개만 넣어서 요청하시면 됩니다.

HTTP Method : DELETE
End-Point   : /api/admin/notification
Sample Request

Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/http-request.adoc[]

Request Body

Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/request-body.adoc[] Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/request-fields.adoc[]

Sample Response

Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/http-response.adoc[]

Response Body

Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/response-body.adoc[] Unresolved directive in index.adoc - include::./build/generated-snippets/admin/notifications/delete/response-fields.adoc[]

문제 세트 API ( /api/admin/problem-sets )

문제 세트 생성

description
문제 세트 생성을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/problem-sets
Sample Request
POST /api/admin/problem-sets HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 81
Host: localhost:8080

{
  "problemIds" : [ 1, 2 ],
  "name" : "name",
  "description" : "description"
}
Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 40

{
  "status" : "success",
  "data" : 1
}
Request Body
{
  "problemIds" : [ 1, 2 ],
  "name" : "name",
  "description" : "description"
}
Path Type Description

problemIds

Array

문제 ID 목록

name

String

문제 세트 이름

description

String

문제 세트 설명

Response Body
{
  "status" : "success",
  "data" : 1
}
Path Type Description

status

String

결과 상태

data

Number

문제 세트 ID

문제 세트 수정

description
문제 세트 수정을 위한 API입니다.

HTTP Method : POST
End-Point   : /api/admin/problem-sets/{problem_set_id}
Sample Request
PUT /api/admin/problem-sets/1 HTTP/1.1
Content-Type: application/json
Content-Type: application/json
Accept: application/json
Authorization: Bearer TEST-TOKEN
Content-Length: 81
Host: localhost:8080

{
  "problemIds" : [ 1, 2 ],
  "name" : "name",
  "description" : "description"
}
Table 25. /api/admin/problem-sets/{problem_set_id}
Parameter Description

problem_set_id

문제 세트 id

문제 세트 단건 조회을 위한 path parameter의 설명입니다.

Request Body
{
  "problemIds" : [ 1, 2 ],
  "name" : "name",
  "description" : "description"
}
Path Type Description

problemIds

Array

문제 ID 목록

name

String

문제 세트 이름

description

String

문제 세트 설명

Sample Response
HTTP/1.1 200 OK
Content-Type: application/json
Content-Length: 40

{
  "status" : "success",
  "data" : 1
}
Response Body
{
  "status" : "success",
  "data" : 1
}
Path Type Description

status

String

결과 상태

data

Number

문제 세트 ID