Required environment variables
How you set this may vary depending on your distribution, in NixOS I did set these in a global way. But this, surprisingly to me wasn't enough to make them apply all the way through to systemd user services.
So I had to add the following to command to run before I log into sway:
systemctl --user import-environment
It may be fine to start it after sway is launched as well, it probably just has to be executed before you attempt to do any screen sharing. This command also accepts specific environment variables to be imported.
Don't worry if they don't run at this point. They should be started by socket activation when you start sharing your screen.