I got told by someone that if you have had Minecraft Java edition since two years ago (2017) that you were eligible to get Minecraft Windows 10 version for free. I didn't know if this is accurate but I've been told this by many people who have the version now.
That is the case, at the moment you will need to contact mojang support to get a bedrock code
https://help.minecraft.net/hc/en-us/requests/new