Skip to content

[GOOWOO-180] Enhance plugin architecture to support YouTube Videos #2986

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

Open
wants to merge 5 commits into
base: feature/GOOWOO-172-pmax-assets-improvements
Choose a base branch
from

Conversation

ankitrox
Copy link
Collaborator

@ankitrox ankitrox commented Jun 26, 2025

Changes proposed in this Pull Request:

Closes https://linear.app/a8c/issue/GOOWOO-180/enhance-plugin-architecture-to-support-youtube-videos

Replace this with a good description of your changes & reasoning.

Screenshots:

Screenshot 2025-06-27 at 12 31 01 PM

Detailed test instructions

  1. Create a campaign in Dashboard by clicking Add campaign button. You can also create a campaign directly in Google ads account for this testing.

  2. Add the asset using Create button in Google ads dashboard. Create a video asset by following all the given guidelines.

Screenshot 2025-06-27 at 12 10 09 PM
  1. Create an asset group and add that video asset to the asset group. Note that it takes some time ~20 minutes to get that video eligible in the asset group.

  2. Import the postman collection added in slack pinned folder. Adjust the environment variables for GLA environment.

  3. Use GET:ads-asset-groups collection to retrieve the assets for that asset groups, you should be able to see the youtube_video there.

  4. Use All Endpoints collection and ensure that for wc/gla/ads/campaigns/asset-group/{id} endpoint, for field_type argument, youtube_video is available in schema.

Additional details:

Changelog entry

@github-actions github-actions bot added type: enhancement The issue is a request for an enhancement. changelog: add A new feature, function, or functionality was added. labels Jun 26, 2025
Copy link

codecov bot commented Jun 26, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 66.2%. Comparing base (39781c4) to head (83d9cbe).
Report is 90 commits behind head on feature/GOOWOO-172-pmax-assets-improvements.

Additional details and impacted files

Impacted file tree graph

@@                               Coverage Diff                               @@
##             feature/GOOWOO-172-pmax-assets-improvements   #2986     +/-   ##
===============================================================================
- Coverage                                           66.2%   66.2%   -0.1%     
- Complexity                                          4814    4823      +9     
===============================================================================
  Files                                                490     491      +1     
  Lines                                              20446   20522     +76     
===============================================================================
+ Hits                                               13542   13579     +37     
- Misses                                              6904    6943     +39     
Flag Coverage Δ
php-unit-tests 66.2% <100.0%> (-0.1%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
src/API/Google/AdsAsset.php 95.5% <100.0%> (+0.3%) ⬆️
src/API/Google/AdsAssetGroupAsset.php 85.5% <100.0%> (+0.7%) ⬆️
src/API/Google/Query/AdsAssetGroupAssetQuery.php 100.0% <100.0%> (ø)
.../API/Site/Controllers/Ads/AssetGroupController.php 100.0% <100.0%> (ø)

... and 2 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@joemcgill joemcgill added changelog: none Skip changelog entry for this PR and removed changelog: add A new feature, function, or functionality was added. labels Jun 27, 2025
Copy link
Collaborator

@joemcgill joemcgill left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks like it will do the trick, @ankitrox. Approving with one suggestion.

@@ -107,7 +108,7 @@ public function get_assets_by_asset_group_ids( array $asset_groups_ids, array $f
$asset_group_assets = [];
$asset_results = ( new AdsAssetGroupAssetQuery() )
->set_client( $this->client, $this->options->get_ads_id() )
->add_columns( [ 'asset_group.id' ] )
->add_columns( [ 'asset_group.id', 'asset.youtube_video_asset.youtube_video_id' ] )
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Rather than adding this column to both places where the AdsAssetGroupAssetQuery is used, consider adding it as a default column, here:

$this->columns( [ 'asset.id', 'asset.name', 'asset.type', 'asset.text_asset.text', 'asset.image_asset.full_size.url', 'asset.call_to_action_asset.call_to_action', 'asset_group_asset.field_type' ] );

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @joemcgill , this looks like a proper place to add this new column. Made that change as per suggestion.

'asset_group.id',
'asset_group.path1',
'asset_group.path2',
'asset.youtube_video_asset.youtube_video_id',
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above

Copy link
Collaborator

@joemcgill joemcgill left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, @ankitrox

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
changelog: none Skip changelog entry for this PR type: enhancement The issue is a request for an enhancement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants