soma
Tables (40)
answer_key_assignment_log
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- problem_id — BIGINT — Foreign key → problem.id — NOT NULL
- actor_id — BIGINT — Foreign key → user.id — NOT NULL
- action — VARCHAR(20)
- created_at — TIMESTAMP
app_version
- id — BIGINT — Primary key — NOT NULL
- version_code — INT
- version_name — VARCHAR(20)
- min_supported_version — VARCHAR(20)
- release_note — VARCHAR(1000)
- platform — VARCHAR(10)
- released_at — TIMESTAMP
badge
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- badge_type — VARCHAR(30)
- awarded_at — TIMESTAMP
badge_definition
- id — BIGINT — Primary key — NOT NULL
- badge_type — VARCHAR(30)
- name — VARCHAR(50)
- description — VARCHAR(255)
- icon_url — VARCHAR(500)
- condition — JSON
banned_word
- id — BIGINT — Primary key — NOT NULL
- word — VARCHAR(50)
- created_at — TIMESTAMP
blocked_user
- id — BIGINT — Primary key — NOT NULL
- blocker_id — BIGINT — Foreign key → user.id — NOT NULL
- blocked_user_id — BIGINT — Foreign key → user.id — NOT NULL
- created_at — TIMESTAMP
challenge
- id — BIGINT — Primary key — NOT NULL
- crew_id — BIGINT — Foreign key → crew.id — NOT NULL
- creator_id — BIGINT — Foreign key → user.id — NOT NULL
- title — VARCHAR(100)
- challenge_type — VARCHAR(30)
- target_value — INT
- start_date — DATE
- end_date — DATE
- status — VARCHAR(20)
- created_at — TIMESTAMP
challenge_participant
- id — BIGINT — Primary key — NOT NULL
- challenge_id — BIGINT — Foreign key → challenge.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- current_value — INT
- joined_at — TIMESTAMP
- status — VARCHAR(20)
character_template
- id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(50)
- image_url — VARCHAR(500)
comment
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- content — VARCHAR(500)
- is_edited — BOOLEAN
- moderation_status — VARCHAR(20)
- created_at — TIMESTAMP
- updated_at — TIMESTAMP
- deleted_at — TIMESTAMP
crew
- id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(50)
- description — VARCHAR(500)
- leader_id — BIGINT — Foreign key → user.id — NOT NULL
- join_type — VARCHAR(20)
- max_capacity — INT
- member_count — INT
- created_at — TIMESTAMP
- deleted_at — TIMESTAMP
crew_join_request
- id — BIGINT — Primary key — NOT NULL
- crew_id — BIGINT — Foreign key → crew.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- status — VARCHAR(20)
- requested_at — TIMESTAMP
- reviewed_at — TIMESTAMP
crew_member
- id — BIGINT — Primary key — NOT NULL
- crew_id — BIGINT — Foreign key → crew.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- role — VARCHAR(20)
- status — VARCHAR(20)
- joined_at — TIMESTAMP
crew_ranking
- id — BIGINT — Primary key — NOT NULL
- crew_id — BIGINT — Foreign key → crew.id — NOT NULL
- period — VARCHAR(20)
- rank_type — VARCHAR(20)
- score — INT
- rank — INT
- calculated_at — TIMESTAMP
device_token
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- token — VARCHAR(500)
- platform — VARCHAR(10)
- created_at — TIMESTAMP
- updated_at — TIMESTAMP
exported_video
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- output_duration — INT
- output_format — VARCHAR(10)
- overlay_data — JSON
- export_status — VARCHAR(20)
- created_at — TIMESTAMP
favorite_gym
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- created_at — TIMESTAMP
follow
- id — BIGINT — Primary key — NOT NULL
- follower_id — BIGINT — Foreign key → user.id — NOT NULL
- following_id — BIGINT — Foreign key → user.id — NOT NULL
- created_at — TIMESTAMP
gym
- id — BIGINT — Primary key — NOT NULL
- name — VARCHAR(100)
- region — VARCHAR(50)
- address — VARCHAR(255)
- latitude — DECIMAL(10,7)
- longitude — DECIMAL(10,7)
- phone — VARCHAR(20)
- naver_map_url — VARCHAR(500)
- logo_image_url — VARCHAR(500)
- difficulty_system — JSON
- facility_info — JSON
- business_hours — JSON
- total_problems — INT
- is_active — BOOLEAN
- is_visualized — BOOLEAN
- created_at — TIMESTAMP
- updated_at — TIMESTAMP
gym_difficulty
- id — BIGINT — Primary key — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- name — VARCHAR(50)
- color — VARCHAR(20)
- sort_order — INT
moderation_appeal
- id — BIGINT — Primary key — NOT NULL
- moderation_log_id — BIGINT — Foreign key → moderation_log.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- reason — VARCHAR(500)
- status — VARCHAR(20)
- created_at — TIMESTAMP
- reviewed_at — TIMESTAMP
moderation_log
- id — BIGINT — Primary key — NOT NULL
- target_type — VARCHAR(20)
- target_id — BIGINT
- method — VARCHAR(20)
- result — VARCHAR(20)
- detected_category — VARCHAR(30)
- confidence — DECIMAL(5,4)
- reviewed_by — BIGINT — Foreign key → user.id
- created_at — TIMESTAMP
notification
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- type — VARCHAR(30)
- title — VARCHAR(100)
- body — VARCHAR(500)
- payload — JSON
- read_at — TIMESTAMP
- created_at — TIMESTAMP
problem
- id — BIGINT — Primary key — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- sector_id — BIGINT — Foreign key → sector.id
- difficulty — VARCHAR(20)
- color — VARCHAR(20)
- is_active — BOOLEAN
- set_date — DATE
- remove_date — DATE
record
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- video_id — BIGINT — Foreign key → video.id
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- problem_id — BIGINT — Foreign key → problem.id
- difficulty — VARCHAR(20)
- attempt_status — VARCHAR(20)
- recorded_at — TIMESTAMP
- created_at — TIMESTAMP
- deleted_at — TIMESTAMP
refresh_token
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- token — VARCHAR(500)
- expires_at — TIMESTAMP
- created_at — TIMESTAMP
report
- id — BIGINT — Primary key — NOT NULL
- reporter_id — BIGINT — Foreign key → user.id — NOT NULL
- target_type — VARCHAR(20)
- target_id — BIGINT
- reason — VARCHAR(30)
- reason_detail — VARCHAR(300)
- status — VARCHAR(20)
- priority — VARCHAR(10)
- created_at — TIMESTAMP
- reviewed_at — TIMESTAMP
report_action
- id — BIGINT — Primary key — NOT NULL
- report_id — BIGINT — Foreign key → report.id — NOT NULL
- action_type — VARCHAR(30)
- action_detail — VARCHAR(500)
- admin_id — BIGINT — Foreign key → user.id — NOT NULL
- created_at — TIMESTAMP
sector
- id — BIGINT — Primary key — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- name — VARCHAR(100)
- image_url — VARCHAR(500)
- position_x — INT
- position_y — INT
- width — INT
- height — INT
- sort_order — INT
- created_at — TIMESTAMP
share_link
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- share_token — VARCHAR(36)
- created_at — TIMESTAMP
social_account
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- provider — VARCHAR(20)
- provider_user_id — VARCHAR(100)
- created_at — TIMESTAMP
user
- id — BIGINT — Primary key — NOT NULL
- email — VARCHAR(255)
- nickname — VARCHAR(50)
- bio — VARCHAR(500)
- role — VARCHAR(20)
- profile_image_url — VARCHAR(500)
- home_gym_id — BIGINT — Foreign key → gym.id
- climbing_career — VARCHAR(50)
- current_tier — VARCHAR(20)
- account_status — VARCHAR(20)
- is_onboarded — BOOLEAN
- nickname_changed_at — TIMESTAMP
- deleted_at — TIMESTAMP
- created_at — TIMESTAMP
- updated_at — TIMESTAMP
user_interest_gym
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- created_at — TIMESTAMP
user_sanction
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- sanction_type — VARCHAR(30)
- reason — VARCHAR(500)
- start_date — DATE
- end_date — DATE
- admin_id — BIGINT — Foreign key → user.id — NOT NULL
- created_at — TIMESTAMP
user_score
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- total_points — INT
- level — INT
- updated_at — TIMESTAMP
user_setting
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- notification_comment — BOOLEAN
- notification_like — BOOLEAN
- notification_crew — BOOLEAN
- notification_badge — BOOLEAN
- notification_system — BOOLEAN
- updated_at — TIMESTAMP
user_stat
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- post_count — INT
- follower_count — INT
- following_count — INT
- completed_count — INT
- total_climbing_day — INT
- updated_at — TIMESTAMP
video
- id — BIGINT — Primary key — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- gym_id — BIGINT — Foreign key → gym.id — NOT NULL
- problem_id — BIGINT — Foreign key → problem.id
- url — VARCHAR(500)
- content — VARCHAR(1000)
- difficulty — VARCHAR(20)
- duration — INT
- file_size — BIGINT
- format — VARCHAR(10)
- file_hash — VARCHAR(64)
- visibility — VARCHAR(20)
- moderation_status — VARCHAR(20)
- status — VARCHAR(20)
- thumbnail_url — VARCHAR(500)
- face_processing_mode — VARCHAR(20)
- face_processing_status — VARCHAR(20)
- is_answer_key — BOOLEAN
- deleted_at — TIMESTAMP
- created_at — TIMESTAMP
- updated_at — TIMESTAMP
video_like
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- user_id — BIGINT — Foreign key → user.id — NOT NULL
- created_at — TIMESTAMP
video_tag
- id — BIGINT — Primary key — NOT NULL
- video_id — BIGINT — Foreign key → video.id — NOT NULL
- tag_type — VARCHAR(30)
- auto_value — VARCHAR(100)
- final_value — VARCHAR(100)
- confidence — DECIMAL(5,4)
- status — VARCHAR(20)