Skip to content

[Task] 통계 API 서비스 구현 #69

Description

@DDINGJOO

상위 Story

목표

전체 통계, 일별 통계, 약점 분석 API 서비스 함수 구현

구현 내용

API 엔드포인트

함수 메서드 엔드포인트
statsService.getOverall GET /vocab/stats/{userId}
statsService.getDaily GET /vocab/stats/{userId}/daily
statsService.getWeakness GET /vocab/stats/{userId}/weakness

구현 예시

export const statsService = {
  getOverall: (userId) =>
    vocabApi.get(`/vocab/stats/${userId}`),
  
  getDaily: (userId, { limit = 30 } = {}) =>
    vocabApi.get(`/vocab/stats/${userId}/daily`, { params: { limit } }),
  
  getWeakness: (userId) =>
    vocabApi.get(`/vocab/stats/${userId}/weakness`),
}

완료 조건

  • statsService 객체 구현
  • 3개 API 함수 구현

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions