Dual boot bluetooth pairing

In other distros I can do as described in the arch wiki to use bluetooth devices without re-pairing them when I change OS. Basically I need to manually write a key in /var/lib/bluetooth/[BT-Adapter-MAC-address]/[device-MAC-address].

Assuming I already have a pairing key and already know the mac addresses of my adapter and devices, how do I do this in NixOS?