Skip to content

feat(audience-sdk): add tracking_authorization_changed event (SDK-332)#772

Merged
nattb8 merged 1 commit into
mainfrom
feat/sdk-332-tracking-authorization-changed
May 11, 2026
Merged

feat(audience-sdk): add tracking_authorization_changed event (SDK-332)#772
nattb8 merged 1 commit into
mainfrom
feat/sdk-332-tracking-authorization-changed

Conversation

@nattb8
Copy link
Copy Markdown
Collaborator

@nattb8 nattb8 commented May 11, 2026

Summary

game_launch fires once per Init(), so any ATT status change mid-session or via iOS Settings (which restarts the app) is invisible to backends until the next launch. A dedicated tracking_authorization_changed event fills that gap, firing whenever the persisted last-known ATT status differs from the current one.

  • Fires at Init (covers iOS Settings flips — the app restarts, Init detects the change against the persisted baseline) and after RequestTrackingAuthorizationAsync resolves
  • Properties: previousStatus, newStatus, idfa (authorized + Full consent only, per SDK-331 tier rules)
  • Last-observed status persisted to imtbl_audience/att_status; first observation seeds the baseline silently — game_launch already captures initial state

Test plan

  • First launch: no tracking_authorization_changed event; game_launch carries attStatus
  • RequestTrackingAuthorizationAsync → grant: event fires with previousStatus/newStatus/idfa (Full consent)
  • Settings flip (disable ATT → re-enable): event fires on next launch via Init
  • Anonymous consent: event fires on authorized transition but no idfa
  • EnableMobileAttribution = false or consent None: no event
  • All existing tests pass (317/317)

🤖 Generated with Claude Code

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@nattb8 nattb8 requested review from a team as code owners May 11, 2026 02:44
@nattb8 nattb8 enabled auto-merge May 11, 2026 04:54
@nattb8 nattb8 merged commit f76632e into main May 11, 2026
65 of 67 checks passed
@nattb8 nattb8 deleted the feat/sdk-332-tracking-authorization-changed branch May 11, 2026 05:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants