Skip to content

Instrument Pendo Track Events#114

Open
novus-by-pendo[bot] wants to merge 1 commit into
mainfrom
pendo-track-events-m63no
Open

Instrument Pendo Track Events#114
novus-by-pendo[bot] wants to merge 1 commit into
mainfrom
pendo-track-events-m63no

Conversation

@novus-by-pendo

Copy link
Copy Markdown

Summary

Adds Pendo Track Event instrumentation across 6 files to capture 8 key user interactions: sign-up, login, profile update, chat message sent, smart command usage, chat creation, chat deletion, and chat search. All events use client-side window.pendo?.track() calls with relevant metadata properties for segmentation and analytics.

Changes

  • Added user_signed_up track event in signUp.tsx onSuccess callback with oauthProvider, hasFirstName, and hasEmail properties
  • Added user_logged_in track event in login.tsx onSuccess callback with oauthProvider property
  • Added user_profile_updated track event in userDetails.tsx onSuccess callback with updatedFirstName, updatedLastName, updatedEmail, and isInitialProfileSetup properties
  • Added chat_message_sent track event in chat.tsx sendMessageMutation onSuccess with chatId, isCommand, hasUrl, messageLength, and currentPageUrl properties
  • Added smart_command_used track event in chat.tsx handleMessageSubmit when a slash command is selected, with commandName, commandValue, and searchQuery properties
  • Added chat_created track event in chatList.tsx createNewChatMutation onSuccess with totalChatCount and chatId properties
  • Added chat_deleted track event in chatListItem.tsx deleteChatMutation onSuccess with remainingChatCount, deletedChatId, and wasActiveChat properties
  • Added chat_search_executed track event in chatList.tsx search useEffect with searchTerm, resultsCount, and totalChats properties
  • Added oauthProvider state variable to signUp.tsx and login.tsx to track which OAuth provider was used across the async mutation flow

Notes

  • All track events use optional chaining (window.pendo?.track()) to safely handle cases where the Pendo agent may not be loaded
  • The oauthProvider is captured via React state set at the start of each OAuth handler, before the async mutation fires, ensuring the correct provider is available in the onSuccess callback
  • The chat_search_executed event fires on every searchTerm change when non-empty — consider adding debouncing in a follow-up if search volume is high

Generated by Novus.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants