In the screenshot you posted, you obscured the integration’s actual name (for privacy). Whatever it is, that’s the name you should use in the integration_entities() function.
{{ states.media_player
| rejectattr('entity_id', 'in', integration_entities('The Name You Obscured In Your Screenshot'))
| map(attribute='entity_id')
| list
}}
For example, if I use Wemo it works but not if I use Belkin WeMo.
thats a good hint, but the folder name from hacs integration works well too. But for all other integrations it must be the name, your way is really better to understand!
here is a code example that work.
|rejectattr('entity_id', 'in', integration_entities('[LG] webOS TV UM7050PLA'))