Not a drop-in for XURK1KSMM12
The XURK1KSMM12 shares the same XU family name but is a different sensor: rectangular metal housing, diffuse sensing, M12 connector, NPN/PNP output. The XUM2APCNM8 is miniature plastic, thru-beam only, with different dimensions (12 mm wide vs 31 mm wide). If your BOM or panel was spec'd around the XURK1KSMM12, expect rewiring and a new mounting plan – not a simple swap.
