That is an interrupt number, so should be the other first parameter you illustrate, the constant intteruotPin is probably not the right interrupt number.
The quoted above is safer and easier, as it takes care of looking up which interrupt number goes with the pin.
Otherwise you need to know and get right that pin 2 is interrupt 0 and pin 3 is interrupt 1.
Or is it the other way ‘round? Or different entirely on a different Arduino board type?
The call to digitalPinToInterrupt takes a pin number and returns for your convenience the number of the interrupt that is on that pin.