Skip to content

Feat: 9주차 미션_묵은지#65

Open
mookeunji05 wants to merge 26 commits into
mainfrom
mookeunji-9
Open

Feat: 9주차 미션_묵은지#65
mookeunji05 wants to merge 26 commits into
mainfrom
mookeunji-9

Conversation

@mookeunji05
Copy link
Copy Markdown
Collaborator

@mookeunji05 mookeunji05 commented May 27, 2026

📌 PR 제목

🔗 관련 이슈

Closes #이슈번호

✨ 변경 사항

  • 기능1 추가
  • UI 수정
  • 버그 수정

🔍 테스트

  • 테스트 완료
  • 에러 없음

📸 스크린샷 (선택)

image

🚨 추가 이슈

Comment on lines +24 to +36
@GET("api/users/{id}")
suspend fun getUser(
@Path("id") id: Int,
@Header("x-api-key")
apiKey: String = "reqres_3fd0bc2b94a34359a2e2b56a6f1f7d85"
): UserResponse

@GET("api/users")
suspend fun getUsers(
@Query("page") page: Int = 2,
@Header("x-api-key")
apiKey: String = "reqres_3fd0bc2b94a34359a2e2b56a6f1f7d85"
): UserListResponse
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

이거 아마 하나로 합칠 수 있을 것 같아요! 어차피 1번이 사용자인거니까 그것만 따로 걸러주면 될 것 같아요.

Comment on lines +24 to +37
@GET("api/users/{id}")
suspend fun getUser(
@Path("id") id: Int,
@Header("x-api-key")
apiKey: String = "reqres_3fd0bc2b94a34359a2e2b56a6f1f7d85"
): UserResponse

@GET("api/users")
suspend fun getUsers(
@Query("page") page: Int = 2,
@Header("x-api-key")
apiKey: String = "reqres_3fd0bc2b94a34359a2e2b56a6f1f7d85"
): UserListResponse
}
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getUsers의 기본 page가 2로 고정되어 있는데, 호출부에서 명시적으로 넘기거나 기본값을 1로 두면 API 동작을 더 예측하기 쉬울 것 같습니다!


object RetrofitClient {

private const val BASE_URL = "https://reqres.in/"
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BASE_URL이 하드코딩 되어 있는데 보완 관점에서 추후에 local.properties 통해 buildconfig로 관리하면 좋을 거 같아요 !!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants