pjt29-3
Tables (8)
account_action_tokens
- action_token_id — CHAR(36) — Primary key — NOT NULL
- user_id — CHAR(36) — Foreign key → users.user_id — NOT NULL
- purpose — VARCHAR(32) — NOT NULL
- target_email — VARCHAR(320) — Signup/email-change destination
- token_hash — CHAR(64) — NOT NULL
- expires_at — DATETIME(6) — NOT NULL
- consumed_at — DATETIME(6)
- revoked_at — DATETIME(6)
- created_at — DATETIME(6) — NOT NULL
account_deletion_requests
- deletion_request_id — CHAR(36) — Primary key — NOT NULL
- user_id — CHAR(36) — Foreign key → users.user_id — NOT NULL
- reason_code — VARCHAR(40) — NOT NULL
- reason_detail — VARCHAR(500) — Required only when reason_code is OTHER
- data_deletion_consent_at — DATETIME(6) — NOT NULL
- requested_at — DATETIME(6) — NOT NULL
- scheduled_delete_at — DATETIME(6) — NOT NULL
- cancelled_at — DATETIME(6)
- completed_at — DATETIME(6)
- active_user_id — CHAR(36)
home_analysis_snapshots
- snapshot_id — CHAR(36) — NOT NULL
- user_home_id — CHAR(36) — NOT NULL
- status — VARCHAR(20) — NOT NULL
- error_code — VARCHAR(100)
- external_property_key — VARCHAR(255) — NOT NULL
- external_unit_type_key — VARCHAR(255)
- road_address — VARCHAR(500) — NOT NULL
- jibun_address — VARCHAR(500)
- building_name — VARCHAR(255)
- postal_code — VARCHAR(20)
- latitude — DECIMAL(10, 7) — NOT NULL
- longitude — DECIMAL(10, 7) — NOT NULL
- move_in_date — DATE — NOT NULL — Move-in date used for this estimate
- built_date — DATE
- building_age_years — SMALLINT
- total_households — INT
- building_count — SMALLINT
- heating_type — VARCHAR(100)
- selected_supply_area_sqm — DECIMAL(10, 2)
- selected_exclusive_area_sqm — DECIMAL(10, 2)
- room_count — SMALLINT
- bathroom_count — SMALLINT
- unit_household_count — INT
- estimated_market_price_amount — BIGINT — External market API estimate
- mortgage_balance_amount — BIGINT — NOT NULL
- estimated_selling_cost_amount — BIGINT — Backend-calculated cost estimate
- estimated_net_proceeds_amount — BIGINT — Backend-calculated net proceeds estimate
- suitability_grade — VARCHAR(20
housing_preference_profiles
- profile_code — VARCHAR(40) — Primary key — NOT NULL
- title — VARCHAR(100) — NOT NULL
- card_description — VARCHAR(500) — NOT NULL
- popup_description — TEXT — NOT NULL
- popup_footer — VARCHAR(500)
- safety_weight — DECIMAL(5, 2) — NOT NULL
- convenience_weight — DECIMAL(5, 2) — NOT NULL
- asset_weight — DECIMAL(5, 2) — NOT NULL
- display_order — SMALLINT — NOT NULL
- is_active — BOOLEAN — NOT NULL
- created_at — DATETIME(6) — NOT NULL
- updated_at — DATETIME(6) — NOT NULL
refresh_tokens
- refresh_token_id — CHAR(36) — Primary key — NOT NULL
- user_id — CHAR(36) — Foreign key → users.user_id — NOT NULL
- token_hash — CHAR(64) — NOT NULL
- device_name — VARCHAR(255) — Session/device label shown to the user
- expires_at — DATETIME(6) — NOT NULL
- revoked_at — DATETIME(6) — Rotation or logout revocation timestamp
- created_at — DATETIME(6) — NOT NULL
social_accounts
- social_account_id — CHAR(36) — Primary key — NOT NULL
- user_id — CHAR(36) — Foreign key → users.user_id — NOT NULL
- provider — VARCHAR(20) — NOT NULL
- provider_user_id — VARCHAR(255) — NOT NULL
- provider_email — VARCHAR(320)
- linked_at — DATETIME(6) — NOT NULL
user_homes
- user_home_id — CHAR(36) — Primary key — NOT NULL
- user_id — CHAR(36) — Foreign key → users.user_id — NOT NULL
- external_property_key — VARCHAR(255) — NOT NULL
- external_unit_type_key — VARCHAR(255)
- road_address — VARCHAR(500) — NOT NULL
- jibun_address — VARCHAR(500)
- detail_address — VARCHAR(255)
- building_name — VARCHAR(255)
- postal_code — VARCHAR(20)
- latitude — DECIMAL(10, 7) — NOT NULL
- longitude — DECIMAL(10, 7) — NOT NULL
- move_in_date — DATE — NOT NULL — Simple selling-cost estimate input
- selected_supply_area_sqm — DECIMAL(10, 2)
- selected_exclusive_area_sqm — DECIMAL(10, 2)
- has_mortgage — BOOLEAN — NOT NULL
- mortgage_balance_amount — BIGINT — NOT NULL
- created_at — DATETIME(6) — NOT NULL
- updated_at — DATETIME(6) — NOT NULL
users
- user_id — CHAR(36) — Primary key — NOT NULL — UUID user identifier
- email — VARCHAR(320) — NOT NULL — Login email; anonymized on completed withdrawal
- password_hash — VARCHAR(255) — Password hash; NULL for social-only accounts
- name — VARCHAR(100) — User display name
- birth_year — SMALLINT — Birth year collected during signup/profile completion
- email_verified_at — DATETIME(6) — One-time signup email verification timestamp
- status — VARCHAR(32) — NOT NULL — Account lifecycle status
- created_at — DATETIME(6) — NOT NULL
- updated_at — DATETIME(6) — NOT NULL