generated from peter-evans/swagger-github-pages
-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add model `UserAdditionalInfo`
- Loading branch information
Showing
4 changed files
with
98 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
namespace SolvedAC; | ||
|
||
/** | ||
* solved.ac 사용자 개인정보입니다. | ||
*/ | ||
model UserAdditionalInfo { | ||
/** | ||
* 사용자의 국가/지역 코드입니다. | ||
* | ||
* @example "kr" | ||
*/ | ||
countryCode: string; | ||
|
||
/** | ||
* 사용자의 성별입니다. | ||
* - 0: 선택 안 함 | ||
* - 1: 남성 | ||
* - 2: 여성 | ||
* - 9: 기타 | ||
* | ||
* @example 0 | ||
*/ | ||
gender: uint64; | ||
|
||
/** | ||
* 사용자를 영어로 표기할 때 사용하는 대명사입니다. | ||
* | ||
* @example "he/him" | ||
*/ | ||
pronouns: string; | ||
|
||
/** | ||
* 사용자의 생년입니다. | ||
* | ||
* @example 1998 | ||
*/ | ||
birthYear: uint64; | ||
|
||
/** | ||
* 사용자의 생월입니다. | ||
* | ||
* @example 8 | ||
*/ | ||
birthMonth: uint64; | ||
|
||
/** | ||
* 사용자의 생일입니다. | ||
* | ||
* @example 6 | ||
*/ | ||
birthDay: uint64; | ||
|
||
/** | ||
* 사용자의 영어 이름입니다. | ||
* | ||
* @example "Suhyun Park" | ||
*/ | ||
name: string; | ||
|
||
/** | ||
* 사용자의 모국어 이름입니다. | ||
* | ||
* @example "박수현" | ||
*/ | ||
nameNative: string; | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
using TypeSpec.Http; | ||
using TypeSpec.OpenAPI; | ||
|
||
namespace SolvedAC; | ||
|
||
/** | ||
* 해당 핸들의 사용자 개인정보를 가져옵니다. | ||
* | ||
* @return | ||
* 사용자 개인정보를 가져옵니다 | ||
*/ | ||
@summary("사용자 핸들로 개인정보 가져오기") | ||
@tag("user") | ||
@get | ||
@route("/user/additional_info") | ||
op getUserAdditionalInfo( | ||
/** | ||
* 요청할 사용자명 | ||
*/ | ||
@query | ||
handle: string, | ||
): GetUserAdditionalInfo.Ok; | ||
|
||
namespace GetUserAdditionalInfo { | ||
@extension(XInternal, true) | ||
model Ok { | ||
@statusCode status: 200; | ||
@body user: UserAdditionalInfo; | ||
} | ||
} |