The New York Yankees have acquired Didi Gregorius in a three-team deal with the Arizona Diamondbacks and Detroit Tigers.

Shane Greene was traded from the Yankees to Detroit, while Arizona received Robbie Ray and minor league infielder Domingo Leyba from the Tigers.

Gregorius hit .226 with six homers and 27 RBIs in 80 games with the Diamondbacks in 2014.

In addition to Gregorius, 24, the Yankees have Brendan Ryan at shortstop as they look to replace Derek Jeter.