Skip to content

Instrument Pendo Track Events#45

Open
novus-by-dhruv[bot] wants to merge 1 commit into
masterfrom
pendo-track-events-v2pdp
Open

Instrument Pendo Track Events#45
novus-by-dhruv[bot] wants to merge 1 commit into
masterfrom
pendo-track-events-v2pdp

Conversation

@novus-by-dhruv

Copy link
Copy Markdown

Summary

Adds Pendo Track Event instrumentation across 24 user interaction points in the CourseHive application. These client-side pendo.track() calls capture key business events—authentication, course/skill search, content creation, voting, pinning, and notification management—that aren't automatically tracked as Feature clicks or Page loads.

Changes

  • Added user_signup_completed track event in login.component.ts after successful registration and pendo.identify, with userId, rollNo, department, programme, year, and emailDomain metadata
  • Added user_login_completed track event in login.component.ts after successful login and profile fetch, with userId, rollNo, karmaPoints, and notificationCount metadata
  • Added password_reset_requested track event in login.component.ts after password reset email is sent, with emailDomain metadata
  • Added push_notification_subscribed track event in login.component.ts after push subscription is saved to server, with userId, browserName, deviceType, and subscriptionTag metadata
  • Added email_verification_sent track event in verify-email.component.ts after verification email dispatch, with email and source metadata
  • Added course_search_executed track event in search.component.ts inside the searchCouseByName subscription, with query, searchType, resultsCount, and maxResultsDisplayed metadata
  • Added skill_search_executed track event in skill-search.component.ts inside the searchSkill subscription, with query and resultsCount metadata
  • Added course_added track event in add-acourse.component.ts after successful course creation, with courseId, courseName, instructorName, and credits metadata
  • Added course_review_submitted track event in course-details.component.ts after ReviewCourse resolves, with courseId, reviewLength, reviewerId, and reviewerRollNo metadata
  • Added content_uploaded track event in course-details.component.ts after UploadContent resolves, with courseId, courseName, documentType, fileName, uploaderId, and uploaderRollNo metadata
  • Added question_asked track event in course-details.component.ts after AskAQuestion resolves, with courseId, questionLength, askerId, and askerRollNo metadata
  • Added answer_submitted track event in course-details.component.ts after AnswerAQuestion resolves, with courseId, questionId, answerLength, answererId, and answererRollNo metadata
  • Added answer_deleted track event in course-details.component.ts after deleteAnswer resolves, with courseId, questionId, answerId, and userId metadata
  • Added document_downloaded track event in course-details.component.ts before opening the document URL, with documentUrl, courseId, and source metadata
  • Added review_voted track event across all 6 review vote branches (upvote, downvote, reverse_upvote, reverse_downvote, switch_to_upvote, switch_to_downvote) in course-details.component.ts with courseId, reviewId, voteAction, voterId, and reviewAuthorId metadata
  • Added content_voted track event across all 6 content vote branches in course-details.component.ts with courseId, contentId, documentType, voteAction, voterId, and contentUploaderId metadata
  • Added course_pinned track event in course-details.component.ts after savePinnedCourses resolves, with courseId, courseName, userId, and source metadata
  • Added course_unpinned track event in course-details.component.ts after removeCourseFromMyPinnedCourses resolves, with courseId, userId, and source metadata
  • Added course_review_deleted track event in myprofile.component.ts after deleteReview resolves, with courseId, reviewId, and userId metadata
  • Added content_deleted track event in myprofile.component.ts after deleteContent resolves, with courseId, contentId, documentType, and userId metadata
  • Added skill_added_to_profile track event in myprofile.component.ts after addSkillInStudentData resolves, with skillId, skillName, expertiseLevel, description, and userId metadata
  • Added skill_removed_from_profile track event in myprofile.component.ts after removeSkillFromMySkills resolves, with skillId, skillName, and userId metadata
  • Added notifications_cleared track event in myprofile.component.ts before clearing the notifications array, with userId and notificationCount metadata
  • Added skill_pinned_from_details track event in skill-details.component.ts after addSkillInStudentData resolves, with skillId, skillName, userId, and studentCount metadata

Notes

  • All 24 events are client-side pendo.track() calls since the codebase is an Angular SPA running in the browser
  • Track events are placed inside success callbacks (.then()) to ensure they only fire on successful operations, not on failures
  • The review_voted and content_voted events use a voteAction property to distinguish between upvote, downvote, reverse, and switch actions across all 6 code branches each
  • The notifications_cleared event captures the count before clearing the array so the pre-clear count is preserved
  • String metadata values (documentUrl, description) are truncated with .substring() to stay within Pendo's 512-byte property limit
  • The pendo global is assumed to be available since pendo.identify() calls already exist throughout the codebase

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