Login to your admin console with an Office 365 admin account
Head to admin/Lync
Then head to Organisation / External Communications
You have 3 options, Off completely (no federation), on except for blocked (open with option of blocking), on only for allowed (closed federation on a per domain basis)
Note, “Public IM connectivity” controls your connectivity to federate with Skype users.
Bonus, you can also customise your meeting invites in this control panel