simulate-new-user
यह क्या करती है
यह स्किल किसी वेब पेज पर पहली बार आने वाले विज़िटरों की नकली विज़िट भेजती है और जाँचती है कि कौन-से PostHog इवेंट चलते हैं। यह उन डेवलपर के लिए है जिन्हें नए विज़िटरों के लिए ट्रैकिंग चालू होने का सबूत चाहिए।
कब इस्तेमाल करें
- ✓जब आप पक्का करना चाहें कि पहली बार आने वाले विज़िटरों के पेजव्यू ट्रैक हो रहे हैं।
- ✓जब आपने कोई ट्रैकिंग बदलाव डिप्लॉय किया हो और उसे टेस्ट करना चाहें।
- ✓जब लोग बताएँ कि नए यूज़र के इवेंट दिखाई नहीं दे रहे।
Skill का लिंक
https://github.com/PostHog/posthog/blob/master/tools/traffic-sim/skills/simulate-new-user/SKILL.mdइसे कॉपी करके अपने AI (Claude, ChatGPT या Cursor) में पेस्ट करें और निर्देशों का पालन करने को कहें।
कैसे इस्तेमाल करें
सबसे आसान तरीका: मैसेज कॉपी करके अपने AI में पेस्ट करें। वह skill पढ़कर निर्देशों का पालन करेगा।
पेस्ट करने के लिए तैयार मैसेज
Claude Code, Codex या Cursor के लिए: प्रोजेक्ट फ़ोल्डर में चलाएँ और skill इंस्टॉल हो जाएगी।
SKILL.md डाउनलोड करें और अपने एजेंट के skills फ़ोल्डर में रखें।
AI से क्या माँगें: उदाहरण
“कृपया हमारे प्राइसिंग पेज पर कुछ टेस्ट विज़िट नए विज़िटर की तरह भेजिए और बताइए कि PostHog उन्हें दर्ज करता है या नहीं।”
हर हफ़्ते 5 नई skills, 1 मिनट में पढ़ें।
यह कैसे काम करती है
एजेंट पेज को कई बार खोलता है, हर बार एक नए ब्राउज़र में जिसमें कोई सेव कुकी न हो, थोड़ा स्क्रॉल करता है, और बताता है कि PostHog को कौन-से इवेंट मिले। जब पेजव्यू कैप्चर हो जाए, तो विज़िट सत्यापित मानी जाती है।
तकनीकी सामग्री (मूल SKILL.md)
लेखक का मूल टेक्स्ट, अंग्रेज़ी में, सीधे GitHub से।
Simulate new-user traffic
Drives a fresh browser context for each visit (no cookies, no localStorage), goes to the given URL, scrolls a bit, and reports which PostHog events fired. Each visit looks to PostHog like a brand-new anonymous visitor.
When to use
- Confirm
$pageviewfires on the first visit (no cookies present). - Confirm an anonymous
distinct_idis generated and a PostHog request is sent within a few seconds of page load. - Reproduce "events not showing up for new users" reports.
How to invoke
Call the simulate_new_user MCP tool with:
url(required) — the page to visit, e.g.https://example.com/pricing.visits(default3) — number of fresh-context visits.interval(default5.0) — seconds between visits.posthog_host(defaulthttps://us.i.posthog.com) — set tohttps://eu.i.posthog.comfor the EU cloud, or your self-hosted host (e.g.https://ph.example.com).
Each visit takes ~10s of Playwright time plus the interval, so plan accordingly.
Interpreting the result
The tool returns a structured summary:
{
"run_id": "a1b2c3d4",
"scenario": "new-user",
"total_visits": 3,
"posthog_requests": 6,
"posthog_requests_ok": 6,
"events_by_type": { "$pageview": 3, "$autocapture": 3 },
"pageviews": 3,
"errors": [],
"verified": true,
}
verified: truemeans at least one$pageviewwas captured per visit and no errors occurred — the new-user flow works.verified: falsewithpageviews: 0means PostHog isn't firing pageviews. Runcheck_posthog_loadingnext to see whether the snippet is even loaded.posthog_requests_ok < posthog_requestsmeans PostHog returned non-2xx responses. Check the project's ingestion limits and api_host configuration.
अक्सर पूछे जाने वाले सवाल
हर बार नया ब्राउज़र क्यों इस्तेमाल होता है?
इससे हर विज़िट PostHog को एक नए गुमनाम विज़िटर जैसी दिखती है।
एक टेस्ट में कितना समय लगता है?
हर विज़िट में लगभग दस सेकंड लगते हैं, और विज़िटों के बीच का इंतज़ार अलग। इसलिए कुछ विज़िट में थोड़ा समय लगता है।
क्या मैं EU PostHog क्लाउड की जाँच कर सकता हूँ?
हाँ। यह स्किल EU क्लाउड या आपके सेल्फ़-होस्टेड PostHog पते पर विज़िट भेज सकती है।
जानकारी
लेखक का मूल विवरण
Send synthetic first-time-visitor traffic to a URL and confirm that PostHog $pageview events fire. Use when a customer wants to verify that anonymous visitor tracking works, after deploying instrumentation changes, or when debugging "events not arriving" reports.
repo: PostHog/posthog
लोकप्रियता
- GitHub स्टार
- 41k
- रैंकिंग में स्थान
- #6986
- लाइसेंस
- —
- अपडेट की गई
- 2/11/2026
कमेंट
- …
इस repository की और skills
depot-ci
41kयह आपके एजेंट को Depot CI वर्कफ़्लो सेट अप करने, चलाने और माइग्रेट करने में मदद करती है, साथ ही रन के लॉग पढ़ने में।
depot-container-builds
41kयह आपके एजेंट को Depot के रिमोट बिल्डर पर Docker इमेज बनाने में मदद करती है, जिसमें मल्टी-प्लेटफ़ॉर्म इमेज और बिल्ड सुधार शामिल हैं।
depot-github-runners
41kयह आपके एजेंट को GitHub Actions जॉब Depot के मैनेज्ड रनर पर ले जाने, रनर का साइज़ और लेबल चुनने, और रनर सेटअप की समस्याएँ ठीक करने में मदद करती है।
editing-agents-md
41kयह आपके एजेंट को तय करने में मदद करती है कि कोई नियम AGENTS.md या CLAUDE.md में जाए या नहीं, और उसे ऐसे लिखे कि फ़ाइल भारी न हो।
मिलती-जुलती skills
test-driven-development
311kयह आपके एजेंट को किसी भी फ़ीचर या सुधार से पहले पहले असफल होने वाला टेस्ट लिखना, उसे असफल होते देखना, फिर पास करने वाला सबसे छोटा कोड लिखना सिखाती है।
verification-before-completion
311kयह आपके एजेंट को किसी काम, सुधार या build के पूरा या पास होने का दावा करने से पहले असली जांच चलाकर उसका आउटपुट पढ़ना सिखाती है।
migrate-to-shoehorn
310kआपकी टेस्ट फ़ाइलों में जोखिम भरे type casts की जगह shoehorn लाइब्रेरी लगाती है, ताकि टेस्ट अधूरे डेटा से भी type checks पास कर सकें।