-
Notifications
You must be signed in to change notification settings - Fork 293
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Implement Analytics 4 conversion events REST data point #6348
Comments
This LGTM for the most part. The main thing missing is a corresponding addition to As for the tests, this would be good to add although coverage for data points like this has always been very minimal. The work @techanvil is doing on the tests for the I'll add this missing detail to the IB and bump the estimate to unblock this, then it should be good to go 👍 |
IB ✅ |
…rsion-events Add REST datapoint for GA4 conversion events
@nfmohit unless you have any objections, I do not feel that this is a |
Absolutely no objection from my side, thank you @wpdarren! |
Feature Description
Similar to the Analytics
goals
REST endpoint, a new endpoint should be created for Analytics 4 calledconversion-events
(as goals no longer exists in GA4, but instead has conversion events)Do not alter or remove anything below. The following sections will be managed by moderators only.
Acceptance criteria
GET:conversion-events
should be added to theAnalytics_4
module class.Implementation Brief
includes/Modules/Analytics_4.php
,GET:conversion-events
to the array inget_datapoint_definitions
and the service should beanalyticsadmin
.create_data_request
, add the case for the new datapoint where a list of conversion events is returned for a property.listPropertiesConversionEvents
method of$this->get_service( 'analyticsadmin' )->properties_conversionEvents
passing the property ID as parameter.parse_data_response
to return only the list of conversion events rather than the full responseTest Coverage
conversion-events
REST endpoint. See the existing tests for the GA4report
datapoint for a good starting point.QA Brief
QA:Eng
GA4_PROPERTY_ID
with your GA4 property ID):GET
request is made to the/modules/analytics-4/data/conversion-events?propertyID=GA4_PROPERTY_ID
.200
response with an array of objects, each object being a conversion event. Example:Changelog entry
The text was updated successfully, but these errors were encountered: