"Rio can hold his head high, leaving on a great note here," Heat coach Erik Spoelstra said. "He'll always be remembered as a two-time champion point guard here in Miami, welcomed in Miami from here on out."
In his eighth NBA season, Chalmers has career averages of 8.8 points and 3.8 assists per game in 525 games. He ranks second in team history in steals, third in assists, fourth in games played and fourth in 3-pointers made.
"This is an tough day for myself and the organization in trading Mario Chalmers and James Ennis," Heat president Pat Riley said. "Mario was a part of two championships with us and Ennis is a solid young player, but it is part of the business and it was a move necessary to make because of our crowded backcourt."
The 33-year-old Udrih is averaging 5.9 points and 3.3 assists in eight games this season. He has averaged 8.7 points in 756 career games.
The 21-year-old Stokes has played in 21 games in two seasons with averages of 2.7 points and 1.7 rebounds.
The 25-year-old Ennis played in 65 career games for the Heat and averaged 4.8 points and 2.7 rebounds.