# kusitms-botem/botem-fe architecture

> Architecture diagram of the GitHub repository kusitms-botem/botem-fe, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-12-04). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/kusitms-botem/botem-fe
- Repository: https://github.com/kusitms-botem/botem-fe

## Overview

보탬은 위시를 등록하고 공유해 친구들이 함께 금액을 보태는 개인 선물 펀딩 서비스입니다. 대표 흐름은 가입·프로필 설정, 위시 등록, 펀딩 개설·공유, 참여와 메시지 전달, 달성 확인으로 이어집니다. 친구 탐색, 추천 상품, 서프라이즈 펀딩, 감사 카드와 롤링페이퍼도 별도 기능으로 보존했습니다. API·쿼리 계층은 인덱스와 발췌 코드에 나타난 연결만 표시했으며, 페이지 내부 호출 관계는 확인하지 못해 일부 흐름은 README 근거로 요약했습니다.

Main entry points: [`src/app/(afterLogin)/funding`](https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/funding) (펀딩 화면), [`src/apis/client.ts`](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/client.ts) (API 클라이언트), [`src/hooks/queries`](https://github.com/kusitms-botem/botem-fe/tree/dev/src/hooks/queries) (서버 상태 쿼리), [`src/widgets/wish`](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/wish) (위시 등록)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_onboarding["가입과 프로필"]
  node_onboarding_ui["가입 온보딩"]
  node_profile_ui["프로필 설정"]
end

subgraph group_discovery["위시와 친구 탐색"]
  node_wish_ui["위시 등록"]
  node_wish_routes["위시 화면"]
  node_recommendations["추천 상품"]
  node_friends["친구와 위시 탐색"]
end

subgraph group_funding["펀딩과 참여"]
  node_funding_setup["펀딩 개설"]
  node_funding_routes["펀딩 화면"]
  node_share_routes["공유 참여 화면"]
  node_contribution_flow["金额与消息参与"]
  node_surprise["서프라이즈 펀딩"]
end

subgraph group_experience["완료와 감사"]
  node_result["달성 결과"]
  node_gift_verification["선물 인증"]
  node_thank_card["감사 카드<br/>[ThankCard.tsx]"]
  node_rolling_paper["롤링페이퍼"]
end

subgraph group_platform["데이터와 API"]
  node_auth_api["인증 API"]
  node_user_api["사용자 API<br/>[userService.ts]"]
  node_wish_api["위시 API<br/>[wishService.ts]"]
  node_recommendation_api["상품 추천 API"]
  node_friend_api["친구 API<br/>[friendService.ts]"]
  node_funding_api["펀딩 API<br/>[fundingService.ts]"]
  node_contribution_api["보탬 API"]
  node_client["API 클라이언트<br/>[client.ts]"]
  node_query_hooks["서버 상태 쿼리"]
  node_query_client["쿼리·오류 관리<br/>[queryClient.ts]"]
end

node_guest(("사용자"))
node_backend[("서비스 백엔드")]

node_guest -->|"가입"| node_onboarding_ui
node_onboarding_ui -->|"카카오 로그인"| node_auth_api
node_guest -->|"프로필 입력"| node_profile_ui
node_profile_ui -.->|"저장"| node_user_api
node_guest -->|"위시 등록"| node_wish_ui
node_wish_routes -.->|"화면 제공"| node_wish_ui
node_wish_ui -.->|"위시 저장"| node_wish_api
node_guest -.->|"상품 탐색"| node_recommendations
node_recommendations -->|"상품 조회"| node_recommendation_api
node_guest -.->|"친구 탐색"| node_friends
node_friends -->|"친구 조회"| node_friend_api
node_guest -->|"펀딩 개설"| node_funding_setup
node_funding_routes -.->|"개설 흐름"| node_funding_setup
node_funding_setup -.->|"펀딩 생성"| node_funding_api
node_guest -->|"공유 링크 참여"| node_share_routes
node_share_routes -.->|"참여 진행"| node_contribution_flow
node_contribution_flow -->|"보탬 제출"| node_contribution_api
node_surprise -.->|"서프라이즈 데이터"| node_funding_api
node_funding_routes -.->|"결과 확인"| node_result
node_funding_routes -.->|"선물 인증"| node_gift_verification
node_result -.->|"감사 전달"| node_thank_card
node_funding_routes -->|"롤링페이퍼 열기"| node_rolling_paper
node_query_hooks -->|"상세 조회"| node_funding_api
node_query_hooks -->|"API 호출"| node_client
node_query_hooks -->|"홈·친구·상품 호출"| node_client
node_client -->|"HTTP 요청"| node_backend
node_query_client -->|"오류·재시도 관리"| node_client

click node_onboarding_ui "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/auth"
click node_auth_api "https://github.com/kusitms-botem/botem-fe/tree/dev/src/apis/auth"
click node_profile_ui "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/user"
click node_user_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/user/userService.ts"
click node_wish_ui "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/wish"
click node_wish_routes "https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/wish"
click node_wish_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/wish/wishService.ts"
click node_recommendations "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/recommended-product"
click node_recommendation_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/recommended-product/recommendedProductService.ts"
click node_friends "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/friend"
click node_friend_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/friend/friendService.ts"
click node_funding_setup "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/funding"
click node_funding_routes "https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/funding"
click node_funding_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/funding/fundingService.ts"
click node_share_routes "https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/share"
click node_contribution_flow "https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/useContributionFlow.ts"
click node_contribution_api "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/contribution/contributionService.ts"
click node_surprise "https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/surprised"
click node_result "https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/FundingResultContainer.tsx"
click node_gift_verification "https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/FundingGiftVerifyContainer.tsx"
click node_thank_card "https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/ThankCard.tsx"
click node_rolling_paper "https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/rolling-paper"
click node_client "https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/client.ts"
click node_query_hooks "https://github.com/kusitms-botem/botem-fe/tree/dev/src/hooks/queries"
click node_query_client "https://github.com/kusitms-botem/botem-fe/blob/dev/src/lib/queryClient.ts"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_onboarding_ui,node_profile_ui toneBlue
class node_wish_ui,node_wish_routes,node_recommendations,node_friends,node_backend toneAmber
class node_funding_setup,node_funding_routes,node_share_routes,node_contribution_flow,node_surprise toneMint
class node_result,node_gift_verification,node_thank_card,node_rolling_paper toneRose
class node_auth_api,node_user_api,node_wish_api,node_recommendation_api,node_friend_api,node_funding_api,node_contribution_api,node_client,node_query_hooks,node_query_client,node_guest toneIndigo
```

## Components

### 가입과 프로필

- [가입 온보딩](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/auth): `src/widgets/auth`
- [프로필 설정](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/user): `src/widgets/user`

### 위시와 친구 탐색

- [위시 등록](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/wish): `src/widgets/wish`
- [위시 화면](https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/wish): `src/app/(afterLogin)/wish`
- [추천 상품](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/recommended-product): `src/widgets/recommended-product`
- [친구와 위시 탐색](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/friend): `src/widgets/friend`

### 펀딩과 참여

- [펀딩 개설](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/funding): `src/widgets/funding`
- [펀딩 화면](https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/funding): `src/app/(afterLogin)/funding`
- [공유 참여 화면](https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/share): `src/app/share`
- [金额与消息参与](https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/useContributionFlow.ts): `src/widgets/funding/useContributionFlow.ts`
- [서프라이즈 펀딩](https://github.com/kusitms-botem/botem-fe/tree/dev/src/app/(afterLogin)/surprised): `src/app/(afterLogin)/surprised`

### 완료와 감사

- [달성 결과](https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/FundingResultContainer.tsx): `src/widgets/funding/FundingResultContainer.tsx`
- [선물 인증](https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/FundingGiftVerifyContainer.tsx): `src/widgets/funding/FundingGiftVerifyContainer.tsx`
- [감사 카드](https://github.com/kusitms-botem/botem-fe/blob/dev/src/widgets/funding/ThankCard.tsx): `src/widgets/funding/ThankCard.tsx`
- [롤링페이퍼](https://github.com/kusitms-botem/botem-fe/tree/dev/src/widgets/rolling-paper): `src/widgets/rolling-paper`

### 데이터와 API

- [인증 API](https://github.com/kusitms-botem/botem-fe/tree/dev/src/apis/auth): `src/apis/auth`
- [사용자 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/user/userService.ts): `src/apis/user/userService.ts`
- [위시 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/wish/wishService.ts): `src/apis/wish/wishService.ts`
- [상품 추천 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/recommended-product/recommendedProductService.ts): `src/apis/recommended-product/recommendedProductService.ts`
- [친구 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/friend/friendService.ts): `src/apis/friend/friendService.ts`
- [펀딩 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/funding/fundingService.ts): `src/apis/funding/fundingService.ts`
- [보탬 API](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/contribution/contributionService.ts): `src/apis/contribution/contributionService.ts`
- [API 클라이언트](https://github.com/kusitms-botem/botem-fe/blob/dev/src/apis/client.ts): `src/apis/client.ts`
- [서버 상태 쿼리](https://github.com/kusitms-botem/botem-fe/tree/dev/src/hooks/queries): `src/hooks/queries`
- [쿼리·오류 관리](https://github.com/kusitms-botem/botem-fe/blob/dev/src/lib/queryClient.ts): `src/lib/queryClient.ts`

### Other components

- **사용자**
- **서비스 백엔드**

## Connections

- 사용자 → 가입 온보딩: 가입 (evidence: `README.md`)
- 가입 온보딩 → 인증 API: 카카오 로그인 (evidence: `README.md`)
- 사용자 → 프로필 설정: 프로필 입력 (evidence: `README.md`)
- 프로필 설정 → 사용자 API: 저장
- 사용자 → 위시 등록: 위시 등록 (evidence: `README.md`)
- 위시 화면 → 위시 등록: 화면 제공
- 위시 등록 → 위시 API: 위시 저장
- 사용자 → 추천 상품: 상품 탐색
- 추천 상품 → 상품 추천 API: 상품 조회
- 사용자 → 친구와 위시 탐색: 친구 탐색
- 친구와 위시 탐색 → 친구 API: 친구 조회
- 사용자 → 펀딩 개설: 펀딩 개설 (evidence: `README.md`)
- 펀딩 화면 → 펀딩 개설: 개설 흐름
- 펀딩 개설 → 펀딩 API: 펀딩 생성
- 사용자 → 공유 참여 화면: 공유 링크 참여 (evidence: `README.md`)
- 공유 참여 화면 → 金额与消息参与: 참여 진행
- 金额与消息参与 → 보탬 API: 보탬 제출 (evidence: `src/widgets/funding/useContributionFlow.ts`)
- 서프라이즈 펀딩 → 펀딩 API: 서프라이즈 데이터
- 펀딩 화면 → 달성 결과: 결과 확인
- 펀딩 화면 → 선물 인증: 선물 인증
- 달성 결과 → 감사 카드: 감사 전달
- 펀딩 화면 → 롤링페이퍼: 롤링페이퍼 열기 (evidence: `README.md`)
- 서버 상태 쿼리 → 펀딩 API: 상세 조회 (evidence: `src/hooks/queries/funding/useFundingDetailQuery.ts`)
- 서버 상태 쿼리 → API 클라이언트: API 호출
- 서버 상태 쿼리 → API 클라이언트: 홈·친구·상품 호출
- API 클라이언트 → 서비스 백엔드: HTTP 요청 (evidence: `src/apis/client.ts`)
- 쿼리·오류 관리 → API 클라이언트: 오류·재시도 관리 (evidence: `src/lib/queryClient.ts`)
