benecaster_find_audience_user_ids()
Resolves a broadcast audience slug to the WordPress user IDs it reaches — the public entry point for answering “who would this send go to?” without pulling anything out of the service container.
Built-in audiences:
-
paying— paying subscribers only, the same definition as
benecaster_count_paying_subscribers(): a token type core doesn’t exempt (PAYING_EXEMPT_TOKEN_TYPES,followertoday — a deny list, nottoken_type = 'subscriber') on a tier that isn’t free. Excludes followers and bridge members on a free tier; includes any other token type, including one an add-on defines, on a paid tier. -
followers— direct followers only. -
all— every active token holder for the show. -
tier:SLUG— active holders of one tier, e.g.tier:gold.
A tier: slug must match one of the show’s configured tier slugs exactly, and the match is case-sensitive. tier:Gold does not find gold.
tier:follower does not reach your followers. Follower tokens carry the tier slug follower, which is not a tier-map entry on a normal install, so it resolves empty. Use followers.
Anything else resolves to an empty array before the benecaster_broadcast_audience_user_ids filter fires, which is how an add-on defines an audience of its own — the callback receives an empty list and returns whatever it likes. The filter runs for built-in audiences too, so a callback can equally subtract from one: opt-outs, suppression lists, a test-group restriction.