kapa.ai ๋ฏน์คํจ๋ ๋ฐ์ดํฐ๋ชจ๋ธ์์ mp_country_code๋ ๋ญ ์๋ฏธํ๋
Please stand by DONGHYO L. as I search the knowledge base. I normally take about 15 seconds or so. ๐
Feel free to ask a follow-up question once I've answered by mentioning me with @kapa.ai
mp_country_code
๋ ๋ฏน์คํจ๋ ์ด๋ฒคํธ ๋ฐ์ดํฐ์์ ์ฌ์ฉ์์ ๊ตญ๊ฐ๋ฅผ ๋ํ๋ด๋ ๊ธฐ๋ณธ ์์ฑ(Default Property)์
๋๋ค. ์ด ๊ฐ์ ์ด๋ฒคํธ๋ฅผ ๋ณด๋ธ ์ฌ์ฉ์์ IP ์ฃผ์(๋๋ ์๋/๊ฒฝ๋ ์ ๋ณด)๋ฅผ ๊ธฐ๋ฐ์ผ๋ก Mixpanel์ด ์๋์ผ๋ก ์ถ์ถํ๋ฉฐ, 2์๋ฆฌ ๊ตญ๊ฐ ์ฝ๋(์: "US", "KR")๋ก ์ ์ฅ๋ฉ๋๋ค. ์ด ์์ฑ์ ์ด๋ฒคํธ์ ์์ฑ(properties)์ผ๋ก ์๋ ์ถ๊ฐ๋์ด, ๊ตญ๊ฐ๋ณ ๋ถ์์ด๋ ์ธ๋ถํ์ ํ์ฉํ ์ ์์ต๋๋ค.์ฆ, mp_country_code
๋ ์ด๋ฒคํธ๊ฐ ๋ฐ์ํ ์ฌ์ฉ์์ ๊ตญ๊ฐ ์ ๋ณด๋ฅผ ์๋ฏธํฉ๋๋ค. ์ฐธ๊ณ ๋ก, ํ๋กํ ๋ฐ์ดํฐ(์ฌ์ฉ์ ํ๋กํ)์๋ $country_code
๋ผ๋ ์ ์ฌํ ์์ฑ์ด ์ฌ์ฉ๋ฉ๋๋ค. ๋ ์์ฑ ๋ชจ๋ Mixpanel์ด ์๋์ผ๋ก ์์งํ๋ ์์น ์ ๋ณด์
๋๋คDefault Properties: Automatically collected propertiesGeolocation: IP address and location properties.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
์ฐํ๋ฆฌํ๋ country๋ South Korea๋ก ๋์ค๋๋ฐ ๊ทธ๋๋ก ์ด๊ดํด๋ ๋ผ?
kapa.ai ์ฐํ๋ฆฌํ๋ country๋ South Korea๋ก ๋์ค๋๋ฐ ๊ทธ๋๋ก ์ด๊ดํด๋ ๋ผ?
Let me check the knowledge base for you again. One moment! ๐
Mixpanel์ mp_country_code
์์ฑ์ 2์๋ฆฌ ๊ตญ๊ฐ ์ฝ๋(์: "KR")๋ก ์ ์ฅ๋ฉ๋๋ค. ๋ฐ๋ฉด, Amplitude์ country ๊ฐ์ด "South Korea"
์ฒ๋ผ ๊ตญ๊ฐ ์ด๋ฆ(์๋ฌธ ์ ์ฒด ์ด๋ฆ)์ผ๋ก ์ ์ฅ๋์ด ์๋ค๋ฉด, ๊ทธ๋๋ก ์ด๊ดํ๋ฉด Mixpanel์ ๊ธฐ๋ณธ ์์น ์์ฑ(mp_country_code
)๊ณผ ํ์์ด ๋ค๋ฅด๊ธฐ ๋๋ฌธ์ ์ง์ ๋งคํ์ด ํ์ํฉ๋๋ค.์ฆ, Amplitude์ "South Korea"
๊ฐ์ Mixpanel๋ก ์ด๊ดํ ๋๋ "KR"
๋ก ๋ณํํด์ mp_country_code
์ ๋ฃ์ด์ผ Mixpanel์ ์์น ๋ถ์ ๊ธฐ๋ฅ์ด ์ ์์ ์ผ๋ก ๋์ํฉ๋๋ค. Mixpanel์ ๊ตญ๊ฐ ์ด๋ฆ์ด ์๋๋ผ 2์๋ฆฌ ISO ๊ตญ๊ฐ ์ฝ๋๋ฅผ ์ฌ์ฉํฉ๋๋คDefault Properties: Automatically collected properties.๋ฐ๋ผ์, ์ด๊ด ์ ๊ตญ๊ฐ๋ช
์ ์ฝ๋๋ก ๋ณํํ๋ ๋ฐ์ดํฐ ๋ณํ ์์
์ด ํ์ํฉ๋๋ค.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
kapa.ai $initial_referrer ์ด None ์ธ ๊ฒฝ์ฐ๊ฐ ์์ด?
Let me check the knowledge base for you again. One moment! ๐
๋ค, $initial_referrer
๊ฐ์ด None(๋๋ undefined)์ธ ๊ฒฝ์ฐ๊ฐ ์์ ์ ์์ต๋๋ค.๋ฏน์คํจ๋์์๋ ์ฌ์ฉ์๊ฐ ์ฌ์ดํธ์ ์ฒ์ ๋ฐฉ๋ฌธํ ๋ ๋ฆฌํผ๋ฌ ์ ๋ณด๊ฐ ์๋ ๊ฒฝ์ฐ(์: ์ง์ URL ์
๋ ฅ, ์ฆ๊ฒจ์ฐพ๊ธฐ, ์ด๋ฉ์ผ ๋งํฌ ํด๋ฆญ, ๋๋ ๋ธ๋ผ์ฐ์ ๋ณด์ ์ค์ ๋ฑ์ผ๋ก ์ธํด referrer๊ฐ ์ ๋ฌ๋์ง ์๋ ๊ฒฝ์ฐ) $initial_referrer
๊ฐ์ด ๊ธฐ๋ณธ์ ์ผ๋ก "$direct"
๋ก ์ค์ ๋ฉ๋๋ค. ํ์ง๋ง, ๋ง์ฝ ํด๋น ์์ฑ์ด ์ด๋ฒคํธ์ ์์ ํฌํจ๋์ง ์์ ๊ฒฝ์ฐ, ๋ฏน์คํจ๋ ๋ฆฌํฌํธ์์ ํด๋น ๊ฐ์ โundefinedโ ๋๋ โ(not set)โ์ผ๋ก ํ์๋ ์ ์์ต๋๋ค.์ฆ, ๋ค์๊ณผ ๊ฐ์ ์ํฉ์์ $initial_referrer
๊ฐ None/undefined๊ฐ ๋ ์ ์์ต๋๋ค: - ์ฌ์ฉ์๊ฐ ์ง์ ๋ฐฉ๋ฌธํ์ฌ ๋ฆฌํผ๋ฌ ์ ๋ณด๊ฐ ์์ ์๋ ๊ฒฝ์ฐ(์ด๋๋ ๋ณดํต "$direct"
๋ก ์ ์ฅ๋จ)
- ์ด๋ฒคํธ์ $initial_referrer
์์ฑ์ด ํฌํจ๋์ง ์์ ๊ฒฝ์ฐ(์ด๋๋ undefined๋ก ํ์๋จ)
- ๋ธ๋ผ์ฐ์ ๋๋ ํ๊ฒฝ์ ๋ฐ๋ผ referrer ์ ๋ณด๊ฐ ์ฐจ๋จ๋ ๊ฒฝ์ฐ๋ฏน์คํจ๋ ๋ฆฌํฌํธ์์ undefined ๊ฐ์ ์์ฑ์ด ์์ ์๋ ๊ฒฝ์ฐ๋ฅผ ์๋ฏธํ๋ฉฐ, UI์์๋ โ(not set)โ์ผ๋ก ๋ณด์
๋๋ค. ์์ธํ ๋ด์ฉ์ Falsy Values์ Web Attribution ๋ฌธ์๋ฅผ ์ฐธ๊ณ ํ์ธ์.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
kapa.ai ์ฐํ๋ฆฌํ๋ ๋ฐ์ดํฐ๋ฅผ ์ด๊ด ์ค์ธ๋ฐ $initial_referrer ๊ฐ Nan ์ด์ผ. "undefined" ๋ณํํ๋ฉด ๋๋๊ฑฐ์ผ?
Let me check the knowledge base for you again. One moment! ๐
๋ค, ๋ฏน์คํจ๋์์๋ ์ด๋ฒคํธ ์์ฑ์ด ์๋ ๊ฒฝ์ฐ(์ฆ, ๊ฐ์ด undefined์ด๊ฑฐ๋ null์ธ ๊ฒฝ์ฐ) ๋ฆฌํฌํธ์์ โ(not set)โ ๋๋ โundefinedโ๋ก ํ์๋ฉ๋๋ค. ๊ณต์ ๋ฌธ์์ ๋ฐ๋ฅด๋ฉด, ์์ฑ์ด ์์ ์๋ ๊ฒฝ์ฐ undefined๋ก ๊ฐ์ฃผ๋๋ฉฐ, UI์์๋ โ(not set)โ์ผ๋ก ๋ณด์
๋๋ค. ๋ฐ๋ผ์ ์ฐํ๋ฆฌํ๋์ $initial_referrer
๊ฐ์ด NaN์ด๋ผ๋ฉด, ๋ฏน์คํจ๋๋ก ์ด๊ดํ ๋ ํด๋น ์์ฑ์ ์์ ํฌํจํ์ง ์๊ฑฐ๋, ๋ช
์์ ์ผ๋ก undefined๋ก ์ฒ๋ฆฌํด๋ ๋ฌด๋ฐฉํฉ๋๋ค. ๋ณ๋๋ก "undefined"๋ผ๋ ๋ฌธ์์ด๋ก ๋ณํํ ํ์๋ ์์ต๋๋ค. ์์ฑ์ด ์์ผ๋ฉด ๋ฏน์คํจ๋์ด ์๋์ผ๋ก undefined๋ก ์ธ์ํฉ๋๋คFalsy Values.์ฆ, NaN ๊ฐ์ "undefined" ๋ฌธ์์ด๋ก ๋ณํํ์ง ๋ง๊ณ , ํด๋น ์์ฑ์ ์ด๋ฒคํธ์ ํฌํจํ์ง ์๋ ๊ฒ์ด ๋ฏน์คํจ๋์ ๊ธฐ๋ณธ ๋์๊ณผ ์ผ์นํฉ๋๋ค.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
kapa.ai ์ฐํ๋ฆฌํ๋ ๋๋ฐ์ด์ค ID ์ IP ๊ธฐ์ค์ผ๋ก merged๋ ์ ์ ๊ฐ ๋ฏน์คํจ๋์์ ์๋์ผ๋ก ๋ฌถ์ผ๊น..?
Let me check the knowledge base for you again. One moment! ๐
์ฐํ๋ฆฌํ๋์ ๋๋ฐ์ด์ค ID์ IP ๊ธฐ์ค์ผ๋ก merged๋ ์ ์ ๊ฐ ๋ฏน์คํจ๋์์ ์๋์ผ๋ก ๋ฌถ์ด๋์ง์ ๋ํด, ๋ฏน์คํจ๋์ ๊ณต์ ๋ฌธ์์ ๋ฐ๋ฅด๋ฉด Mixpanel์ ๋๋ฐ์ด์ค ID์ IP๋ง์ผ๋ก ์๋์ผ๋ก ์ ์ ๋ฅผ ๋ณํฉ(merge)ํ์ง ์์ต๋๋ค.๋ฏน์คํจ๋์ ID Merge(์ ์ ๋ณํฉ)๋ $device_id
์ $user_id
๊ฐ ๊ฐ์ ์ด๋ฒคํธ์ ํจ๊ป ํฌํจ๋์ด ์์ ๋, ๋๋ .identify()
ํธ์ถ์ ํตํด ๋ช
์์ ์ผ๋ก ๋ณํฉ์ด ํธ๋ฆฌ๊ฑฐ๋ ๋๋ง ๋์ํฉ๋๋ค. ์ฆ, ๋จ์ํ ๋๋ฐ์ด์ค ID๋ IP๊ฐ ๊ฐ๋ค๊ณ ํด์ ์๋์ผ๋ก ๊ฐ์ ์ ์ ๋ก ์ธ์ํ๊ฑฐ๋ ๋ณํฉํ์ง ์์ต๋๋ค. ๋ฐ๋์ $device_id
์ $user_id
๊ฐ ํจ๊ป ํฌํจ๋ ์ด๋ฒคํธ๊ฐ ํ์ํ๋ฉฐ, ์ด๋๋ง ๋ ID๊ฐ ํ๋์ ์ ์ ๋ก ๋ฌถ์
๋๋ค. IP ์ ๋ณด๋ ๋ณํฉ ๋ก์ง์ ์ฌ์ฉ๋์ง ์์ต๋๋คIdentifying Users (Simplified).๋ฐ๋ผ์, ์ฐํ๋ฆฌํ๋์์ ๋๋ฐ์ด์ค ID์ IP ๊ธฐ์ค์ผ๋ก ๋ณํฉ๋ ์ ์ ๋ฅผ ๋ฏน์คํจ๋๋ก ์ด๊ดํ ๋, ๋ฏน์คํจ๋์์๋ ๋์ผํ๊ฒ ์ ์ ๋ฅผ ๋ณํฉํ๋ ค๋ฉด ์ด๋ฒคํธ์ $device_id์ $user_id๋ฅผ ๋ชจ๋ ํฌํจํด์ ์ ์กํด์ผ ํฉ๋๋ค. ๊ทธ๋ ์ง ์์ผ๋ฉด ์๋ ๋ณํฉ์ด ์ผ์ด๋์ง ์์ต๋๋ค.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.
kapa.ai user_properies ์ํฌํธํ๋ ค๋ฉด ์ด๋ ํฅ ํด?
Let me check the knowledge base for you again. One moment! ๐
Mixpanel์์ user properties(์ฌ์ฉ์ ํ๋กํ ์์ฑ)๋ฅผ ์ํฌํธํ๋ ๋ฐฉ๋ฒ์ ์ฌ๋ฌ ๊ฐ์ง๊ฐ ์์ต๋๋ค. ๋ํ์ ์ธ ๋ฐฉ๋ฒ์ ๋ค์๊ณผ ๊ฐ์ต๋๋ค:
1. CSV ํ์ผ๋ก ๋๋ ์ํฌํธ (UI ์ฌ์ฉ)
- Users ํ์ด์ง์์ Add/Edit Profile ๋๋ Import from CSV๋ฅผ ์ ํํฉ๋๋ค.
- CSV ํ์ผ์ ์
๋ก๋ํ ๋, ๋ฐ๋์ $distinct_id
(๋๋ $email
๋ฑ ๊ณ ์ ์๋ณ์) ์ปฌ๋ผ์ ์ง์ ํด์ผ ํ๋ฉฐ, ๋๋จธ์ง ์ปฌ๋ผ์ ์ํฌํธํ user property๋ก ๋งคํํฉ๋๋ค.
- CSV์๋ ํค๋๋ฅผ ํฌํจํ์ง ์๊ณ , ์
๋ก๋ ๊ณผ์ ์์ ๊ฐ ์ปฌ๋ผ์ Mixpanel ์์ฑ์ ๋งคํํฉ๋๋ค.
- ์ด๋ฏธ ์กด์ฌํ๋ $distinct_id
๊ฐ ์์ผ๋ฉด ํด๋น ํ๋กํ์ด ์
๋ฐ์ดํธ๋๊ณ , ์๋ก์ด ์์ฑ์ ์ถ๊ฐ๋ฉ๋๋ค.
์์ธํ ๋ณด๊ธฐ
2. API๋ฅผ ํตํ ์ํฌํธ
- Engage API๋ฅผ ์ฌ์ฉํด user profile์ ์์ฑ/์ ๋ฐ์ดํธํ ์ ์์ต๋๋ค. - Python ์์ ์ฝ๋:
import requestsLBKS PROJECT_TOKEN = "YOUR_PROJECT_TOKEN"LBKS def get_users_from_database():
return [
{"user_id": "123", "$name": "Alice", "$email": "alice@โ[linear.app](http://linear.app)", "department": "engineering"},
{"user_id": "456", "$name": "Bob", "$email": "bob@โnotion.so", "department": "product"},
]LBKS def transform_to_mp_format(user):
distinct_id = user.pop("user_id")
return {"$distinct_id": distinct_id, "$token": PROJECT_TOKEN, "$ip": "0", "$set": user}LBKS users = get_users_from_database()
profiles = [transform_to_mp_format(u) for u in users]LBKS resp = [requests.post](http://requests.post)(
"[https://api.mixpanel.com/engage](https://api.mixpanel.com/engage)",
params={"verbose": "2"},
headers={"Content-Type": "application/json"},
data=json.dumps(profiles)
)LBKS print(resp.json())
```LBKS- ์ด ๋ฐฉ๋ฒ์ ๋๋์ ํ๋กํ์ ์๋ํํ์ฌ ์ํฌํธํ ๋ ์ ์ฉํฉ๋๋ค
[์์ธํ ๋ณด๊ธฐ](https://docs.mixpanel.com/guides/playbooks/project-migration#optional-step-8-import-users) [Operators ์ค๋ช
](https://docs.mixpanel.com/docs/data-structure/user-profiles#operators)
3. ๋ฐ์ดํฐ ์จ์ดํ์ฐ์ค ์ปค๋ฅํฐ ์ฌ์ฉ
- Snowflake, BigQuery, Redshift, Databricks ๋ฑ์์ ์ง์ user profile ํ
์ด๋ธ์ ๋๊ธฐํํ ์ ์์ต๋๋ค.
- ์ด ๊ฒฝ์ฐ, ํ
์ด๋ธ์ primary key๊ฐ $distinct_id
์ ๋งค์นญ๋์ด์ผ ํ๋ฉฐ, ์ถ๊ฐ ์์ฑ ์ปฌ๋ผ์ ํจ๊ป ๋งคํํฉ๋๋ค.
์์ธํ ๋ณด๊ธฐ์ฐธ๊ณ : ์ํฌํธ ์ ๋ฐ๋์ $distinct_id
๊ฐ ์ด๋ฒคํธ์ ๋์ผํ๊ฒ ๋งค์นญ๋์ด์ผ ํ๋ฉฐ, ์ด๋ฏธ ์กด์ฌํ๋ ํ๋กํ์ ์
๋ฐ์ดํธ, ์๋ก์ด ํ๋กํ์ ์์ฑ๋ฉ๋๋ค.
CSV ์ํฌํธ, API, ์จ์ดํ์ฐ์ค ์ปค๋ฅํฐ ๋ชจ๋ Mixpanel ๊ณต์ ๋ฌธ์์์ ์์ธํ ์๋ดํ๊ณ ์์ต๋๋ค.
kapa.ai is still learning and improving, please let me know how I did by reacting below.
โน๏ธย Tip: Mention @kapa.ai in the thread for follow-ups or DM the app for 1-to-1 help.