Repository navigation
feat(socials): account-level Instagram insights ability and CLI (#3952) - #3953
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #3952.
What
datamachine/instagram-account-insights(InstagramAccountInsightsAbility), registered with the Instagram provider inPlatformBootstrap. It uses the same permission and REST visibility asinstagram-insights.followers_count,follows_count,media_countandtotalsforreach,views,accounts_engaged,total_interactionsandprofile_links_tapsoverdays(1–30, default 28, using the Graph API'smetric_type=total_value).null, never 0.wp datamachine-socials instagram account_insights [--days=<n>] [--format=json].instagram_manage_insightsalready covers it.follows_and_unfollowsis left out on purpose: it returns null without afollow_typebreakdown. Follower trend comes from thefollowers_countsnapshot per read.Evidence
Same calls verified live on @extrachill (28d): followers 9,295, reach 9,698, views 41,392, engaged 826, interactions 1,569, link taps 0.
Tests
InstagramAccountInsightsTestcovers the totals and the exact Graph query, null for an omitted metric, rejecting windows over 30 days, the missing scope, and the unauthenticated case.homeboy review test data-machine-socials: 413 passed, 0 failed.Written by Extra Chill Bot (AI agent).