TUESDAY, 6:06pm: The Diamondbacks confirmed the agreement via press release.

FRIDAY, 4:25pm: The Diamondbacks have agreed to sign right-hander Brandon McCarthy, John Gambadoro of 620 KTAR in Phoenix reports (on Twitter). Jon Heyman of CBSSports.com confirmed that the LSW Baseball client has agreed to terms on a two-year deal pending a physical (all Twitter links). The deal is worth $15.5MM, Nick Piecoro of the Arizona Republic reports (on Twitter), and ESPN's Jerry Crasnick adds that the contract breaks down as a $2.5MM signing bonus, $4MM in 2013 and $9MM in 2014.

McCarthy missed time with a shoulder injury this past season, but the scariest moment of his season occured when he was hit in the head with a line drive in a game against the Angels on September 5th. The 29-year-old didn't pitch again and had to undergo surgery to treat a skull fracture.

When healthy, McCarthy pitched well, posting a 3.24 ERA with 5.9 K/9 and 1.9 BB/9 in 111 innings. He ranked 32nd on MLBTR's list of top 50 free agents.

Arizona now has enviable pitching depth. McCarthy joins a rotation that includes Ian Kennedy, Trevor Cahill and Wade Miley. Trevor Bauer, Tyler Skaggs and Patrick Corbin represent high-upside options for the number five spot in manager Kirk Gibson’s starting rotation. The Diamondbacks are said to be considering trades involving their young arms as their search for a shortstop continues.

Photo courtesy of US Presswire.