I printed it in PLA with 0.2mm layer height and 15% infill , any other material should work.
Place two 10x2mm round magnets in the center of both parts and fix them with superglue.
The author marked this model as their own original creation.