TORONTO – Blue Springs High School graduate Nick Tepesch got a rude awakening on his return to the major leagues Wednesday.

Todd Frazier homered and had three RBIs, Gary Sanchez and Didi Gregorius also went deep and the Yankees overcame a shaky start by Masahiro Tanaka to beat the Toronto Blue Jays 11-5 on Wednesday night.

After being called up Wednesday and making his first start for Toronto in place of Cesar Valdez, who has an injured right shoulder, Tepesch allowed five runs and eight hits in 4 1/3 innings. The former Blue Springs and University of Missouri standout walked one and struck out four but gave up three home runs.

"They took advantage of some pitches I left over the plate," Tepesch said.

Toronto optioned LHP Matt Demody to Triple-A Buffalo to make room for Tepesch, while SS Troy Tulowitzki (right ankle) was transferred to the 60-day DL to open a spot on the 40-man roster.

The Blue Jays had purchased Tepesch from the Minnesota Twins on July 24. Tepesch, now 0-2 in the majors this season, was 1-0 with a 3.00 ERA in three games at Triple-A Buffalo.

Tepesch had one game in the majors with the Twins this season, allowing one run in 1 2/3 innings for a 5.40 ERA. He was 0-1 with an 11.25 ERA in one game with the Los Angeles Dodgers in 2016 and was 9-19 with a 4.69 ERA for his career, including two seasons with the Texas Rangers.

Rookie Garrett Cooper had four hits for the Yankees, who had not scored in double figures since a 13-4 win at Houston on June 30. New York's 17 hits were one shy of its season high, set June 10 against Baltimore.

"We needed that," Frazier said. "That was a good win for us, a good offensive outburst. Hopefully, we build on that."

Frazier, who entered in a 5-for-33 slide, went back-to-back with Sanchez in the second, hit a two-run double in the fifth, then added a leadoff single in the eighth for his first three-hit game since the Yankees acquired him from the Chicago White Sox last month. He was hit on the left elbow by a pitch in his final plate appearance and, at Girardi's suggestion, sat out the bottom of the ninth.

"Hopefully, tomorrow it'll be just fine," Frazier said.

Cooper was not in the original starting lineup but replaced Clint Frazier, who felt tightness in his oblique during batting practice and is scheduled for an MRI on Thursday.

"I've been feeling it for a few days," Clint Frazier said. "I want to make sure everything is all right before I keep going."

Gregorius hit his 18th homer in a third, a two-out drive off Tepesch (0-2).

"When our offense was really going good, that's what we were doing, we were getting production from everyone," manager Joe Girardi said. "That's good to see."

Tanaka walked a season-high five in four-plus innings, allowing three runs – two earned – and two hits. He left two batters into the fifth after Jose Bautista homered and Josh Donaldson walked. Chad Green (2-0) struck out three straight for the Yankees, who remained four games behind AL East-leading Boston.

Aaron Judge drew his 82nd walk, breaking Charlie Keller's 1939 Yankees rookie record. Boston's Ted Williams holds the major league record with 107 in 1939.

Judge went 0 for 4 and struck out in the eighth, extending his club record streak of games with at least one strikeout to 26. Judge was the only New York starter without a hit.

"The strikeouts don't worry me," Girardi said. "The productivity is what you want. As long as he remains productive and he's getting on base and hitting home runs, you can live with it."