PHP logging

EventLogging::logEvent( 'HelpPanel', 18973214, $event );

extension.json setup for JavaScript logging

{
	"attributes": {
		"EventLogging": {
			"Schemas": {
				"HelpPanel": 18973214
			}
		}
	}
}

JavaScript logging

mw.track( 'event.HelpPanel', { /* ... */ } );

Schema:HelpPanel

From Meta, a Wikimedia project coordination wiki
Revision 18973214
Jump to navigation Jump to search
description"Logs interactions with the help panel displayed to new editors by the GrowthExperiments extension"
properties
action
type"string"
requiredtrue
enum
"impression"
"open"
"close"
"review"
"back-home"
"link-click"
"enter-question-text"
"submit-attempt"
"submit-success"
"submit-failure"
"cog-open"
"cog-close"
"search"
"search-focus"
description"Action the user took: - impression: Help button is shown to user - open: User opens panel - close: User closes panel - review: User advances from the home panel to the question review panel - back-home: User goes back from the question review panel to the home panel - link-click: User clicks a link in the panel - enter-question-text: User enters text into the question field - submit-attempt: User clicks the button to submit their question - submit-success: Question is successfully submitted - submit-failure: Question submission fails - cog-open: User opens the cog menu - cog-close: User closes the cog menu - search: User searches help content - search-focus: User focuses the search input"
action_data
type"string"
description"Additional data for certain actions: For action=link-click: symbolic name of the link being clicked For action=submit-success: revision ID of the edit adding the question"
user_id
type"integer"
requiredtrue
description"The user id."
user_editcount
type"integer"
requiredtrue
description"The total number of edits of the user."
editor_interface
type"string"
enum
"visualeditor"
"wikitext-2017"
"wikitext"
"reading"
"homepage_help"
"homepage_mentorship"
"other"
requiredtrue
description"The editor interface through which the user is attempting to edit the page."
is_mobile
type"boolean"
requiredtrue
description"Whether the mobile site is being used."
page_id
type"integer"
requiredtrue
description"ID of the page the user is attempting to edit."
page_title
type"string"
requiredtrue
description"Full title of the page the user is attempting to edit, including namespace (wgPageName format). This is needed to log edit activity on redlinks, as pageId is not available."
page_ns
type"integer"
requiredtrue
description"Namespace ID of the page the user is attempting to edit."
user_can_edit
type"boolean"
requiredtrue
description"Whether the user is allowed to edit the page. This will be false if e.g. the page is protected or the user is blocked."
page_protection
type"string"
description"For protected pages, the permission level required to create, edit, or move the page. Unset for unprotected pages."
session_token
type"string"
requiredtrue
description"Session token that survives across pages (mw.user.sessionId()), but not browser restarts, used in deterministic user bucketing. This will only be set for client-side (JavaScript-generated) events, for server-side events the value will be an empty string."
help_panel_session_id
type"string"
requiredtrue
description"One-time token per page load. This is like page_token and has the same behavior, but it isn't obtained through getPageViewToken(), so its value is different."