By TIM REYNOLDS, Associated Press

MIAMI (AP) -- Ray Allen lingered on the court for a bit after his Boston Celtics lost Game 7 of the Eastern Conference finals to the Miami Heat last month, shaking hands and offering congratulations.

A few minutes later, Allen made a vow about his future.

"There's still a lot of basketball left in my legs," he said.

The Heat apparently were listening, apparently agree - and will soon officially welcome Allen to their club.

Check out the best reactions on Twitter (story continues below):

Loading Slideshow...
  • Micky Arison

  • Craig Kwasniewski

  • Eliot Shorr-Parks

  • Hardwood Paroxysm

  • netw3rk

  • miamirankings.com

  • Rizzmiggizz

  • Bruce Arthur

  • Darius Soriano

  • Adrian Wojnarowski

  • Alex Kennedy

  • Azam

  • FakePatRiley

  • Michael Cugno

  • NBC 6 Sports

  • Kirk Goldsberry

  • Myles Brown

  • FakePatRiley

  • netw3rk

  • Adrian Wojnarowski

  • netw3rk

  • KeLLy KeLLs

  • Dwyane Wade

  • LeBron James

Allen told the Heat on Friday night that he intends to accept their contract offer and leave Boston after five seasons, even though the Celtics could have paid him about twice as much as the reigning NBA champions will be able to next season. Miami could only offer Allen the mini mid-level, worth about $3 million a year.

Heat owner Micky Arison tweeted the news just after 9:30 p.m. Friday, or about 2:30 a.m. Saturday in Europe, where Arison has been for several days.

"I was just woken up with great news," Arison wrote. "Welcome to the family." Arison ended the tweet by making mention of Allen's jersey No. 20, but didn't mention the NBA's leading 3-point shooter by name. No matter - Allen's agent, James Tanner, confirmed the plan to The Associated Press moments later.

A person briefed on details of the decision told the AP that Arison got the word from team president Pat Riley, who made Allen the team's top free-agent priority - especially in recent days. Allen, who will be 37 this month, arrived in Miami on Thursday for a visit, went to dinner with Riley, coach Erik Spoelstra, team executive Alonzo Mourning and others Thursday night, then left Friday to presumably decide his future.

Hours later, the choice was known. Allen, who made a career-best 45 percent of his 3-point attempts this past season, cannot officially sign until Wednesday because of the league's moratorium.

"HeatNation continues to grow," Heat guard Dwyane Wade wrote on Twitter late Friday night. And Heat forward LeBron James, the league's reigning MVP and Finals MVP, added "please welcome our newest teammate Ray Allen" with the hashtag of "Wow."

It's the latest free-agency coup for Riley.

During the blockbuster summer of 2010, the Heat convinced James, Wade and Chris Bosh all to take less money than they could have gotten elsewhere in that offseason, so there would be enough room left to add players like Udonis Haslem and Mike Miller (who both also took smaller contracts) and Mario Chalmers. Then last summer, Shane Battier accepted a deal that will pay him $3 million annually.

The approach clearly worked.

Next fall, the Heat will raise a championship banner, and Allen will be with them for the title defense.

Wade and James both were involved on some level in the recruitment of Allen. James took to Twitter and Facebook in recent days to let his millions of followers know how much he wanted to see Allen in a Heat uniform, and Wade tweeted on Wednesday that the next day - the one where Allen was visiting - would be a big one for the franchise.

In the end, it appeared that the biggest push - again - came from Riley, who said before free agency started that Miami had identified "five or six" clear targets to add to the roster. He never specifically said Allen, and given how James was letting the secret out on Twitter anyway, Riley didn't have to say anything else.

New Orleans Hornets guard Jarrett Jack asked his followers in a tweet about an hour after the Allen story broke if he was "wrong for thinking ray allen is a traitor" for signing with Miami. Even NFL stars were reacting Friday night. Philadelphia Eagles quarterback Michael Vick used the following hashtags on Twitter to describe his reaction to Allen's decision: "loaded," "finalpiece" and "notfair."

There are probably more than a few people in Boston who would agree.

Miami is still hoping to add at least one more piece through free agency, and is expected to meet this weekend with Marcus Camby (who would most likely have to be acquired through a sign-and-trade if he was to wind up with the Heat) and Rashard Lewis.

Earlier this week, the Celtics reportedly agreed on a $15 million, three-year deal with shooting guard Jason Terry. But Boston also wanted to keep Allen, with general manager Danny Ainge quoted in recent days saying "we really want Ray to come back. Time will tell."

Allen has made an NBA-record 2,718 3-pointers. He was mentioned in some trade possibilities this past season - a deal was nearly struck with Memphis - and Allen eventually lost his starting job to Avery Bradley. Allen needed surgery earlier this offseason to remove bone spurs from his right ankle, though he said when the Celtics were ousted from the playoffs by the Heat for the second straight year that his playing days were not over.

"It's hard to say what can happen, what may happen," Allen said after Game 7 of the East finals this year.

He said those words in Miami. Not even a month later, Allen - who helped the Celtics win the 2008 NBA title - decided to join the Heat.

Follow Tim Reynolds on Twitter.

Heat owner Micky Arison tweeted the news just after 9:30 p.m., or about 2:30 a.m. Saturday in Europe, where Arison has been for several days.

"I was just woken up with great news," Arison wrote. "Welcome to the family." Arison ended the tweet by making mention of Allen's jersey No. 20, and didn't mention the NBA's leading 3-point shooter by name.

A person briefed on details of the decision told The Associated Press that Arison got the word from Heat President Pat Riley, who made Allen the team's top free-agent priority - especially in recent days. Allen, who will be 37 this month, arrived in Miami on Thursday for a visit, went to dinner with Riley, coach Erik Spoelstra, team executive Alonzo Mourning and others Thursday night, then left Friday to presumably decide his future.

Hours later, the choice was made. Allen's agent, James Tanner, confirmed the decision to the AP not long after Arison's tweet.

Allen, who made a career-best 45 percent of his 3-point attempts this past season cannot officially sign until Wednesday because of the league's moratorium.

Allen becomes the latest player to be sold by Riley on the notion of sacrifice since the blockbuster summer of 2010. The Heat convinced LeBron James, Dwyane Wade and Chris Bosh all to take less money than they could have made elsewhere in that offseason, so there would be enough room left to add players like Udonis Haslem, Mario Chalmers and Mike Miller. Then last summer, Shane Battier accepted a deal that will pay him $3 million annually.,

The approach clearly worked. Next fall, the Heat will raise a championship banner, and Allen will be with them for the title defense.

"HeatNation continues to grow," Wade wrote on Twitter late Friday night. And James added, "please welcome our newest teammate Ray Allen" with the added hashtag of "Wow."

Wade and James both were involved on some level in the recruitment of Allen. James took to Twitter and Facebook in recent days to let his millions of followers know how much he wanted to see Allen in a Heat uniform, and Wade tweeted on Wednesday that the next day - the one where Allen was visiting - would be a big one for the franchise.

In the end, it appeared that the biggest push - again - came from Riley, who said before free agency started that Miami had identified "five or six" clear targets to add to the roster.

He never specifically said Allen, and given how James was letting the secret out on Twitter anyway, Riley didn't have to say anything else.

New Orleans Hornets guard Jarrett Jack asked his followers in a tweet about an hour after the Allen story broke if he was "wrong for thinking ray allen is a traitor" for signing with Miami. Even NFL stars were reacting Friday night. Philadelphia Eagles quarterback Michael Vick used the following hashtags on Twitter to describe his reaction to Allen's decision: "loaded," "finalpiece" and "notfair."

There's probably more than a few people in Boston who would agree.

Miami is still hoping to add at least one more piece through free agency, and is expected to meet this weekend with Marcus Camby and Rashard Lewis.

Allen was mentioned in some trade possibilities this past season, and eventually lost his starting job to Avery Bradley. Allen needed surgery earlier this offseason to remove bone spurs from his right ankle, though said when the Celtics were ousted from the playoffs by the Heat for the second straight year that his playing days were not over.

"There's still a lot of basketball left in my legs," Allen said in Miami not long after the Celtics dropped Game 7 of the Eastern Conference finals to the Heat. "I know that for sure. So it's hard to say what can happen, what may happen."

Not even a month later, Allen - who helped the Celtics win the 2008 NBA title - decided to join Miami.

Earlier this week, the Celtics reportedly agreed on a $15 million, three-year deal with shooting guard Jason Terry. But Boston also wanted to keep Allen, with general manager Danny Ainge quoted in recent days saying "we really want Ray to come back. Time will tell."

Miami wanted Allen because of its ongoing quest to keep surrounding James, Wade and Bosh with shooters who extend defenses and therefore create room around the basket for the "Big Three" to attack. That approach worked perfectly for Miami in the playoffs - the Heat were 9-1 when making at least eight 3-pointers in playoff games (7-6 otherwise), and they hit 14 in the finals-clincher over Oklahoma City.

Allen has made an NBA-record 2,718 3-pointers.

___

Earlier on HuffPost:

Loading Slideshow...
  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Players of the Miami Heat wave to fans during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat players ride in double-decker buses during a parade in Miami, Monday, June 25, 2012 in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder. (AP Photo/Wilfredo Lee)

  • Miami Heat' fans cheer during a parade in Miami, Monday, June 25, 2012 in celebration of the Heat winning the NBA Finals basketball championship against the Oklahoma City Thunder. (AP Photo/Wilfredo Lee)

  • Burnie

    Miami Heat mascot Burnie waves a flag from a fire truck during a parade in Miami, Monday, June 25, 2012 in celebration of the Heat winning the NBA Finals basketball championship against the Oklahoma City Thunder. (AP Photo/Wilfredo Lee)

  • Shane Battier

    Miami Heat's Shane Battier bangs on a pan as he rides atop a double-decker bus during a parade in Miami, Monday, June 25, 2012 in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder. (AP Photo/Wilfredo Lee)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans gather before a victory parade during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Kristal Tamayo, Eddie Quintana, Nikki Quintana, Dwyane Wade, Chris Bosh, LeBron James

  • Bayside Marketplace

    Miami Heat fans line the streets in front of Bayside Marketplace next to the American Airlines Arena where the Heat play, for a parade, Monday, June 25, 2012 in celebration of the Heat winning the NBA Finals basketball championship against the Oklahoma City Thunder, in Miami. (AP Photo/Wilfredo Lee)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Mike Miller of the Miami Heat waves to the crowd during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Lebron James of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Miami Heat players, coaches and supporters are seen as they arrive on double decker buses for the start of a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat shows off his championship t-shirt as he rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as Miami Heat players pass by in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: The President of the Miami Heat Pat Riley rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as Miami Heat players pass by in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Lebron James of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwayne Wade of the Miami Heat looks on during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as Miami Heat players pass by in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as Miami Heat players pass by in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • The Miami Heat basketball NBA Championship parade passes fans in Miami, Monday, June 25, 2012. (AP Photo/The Miami Herald, Tessa Lighty)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as the Miami Heat pass by in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Dwyane Wade of the Miami Heat rides in a victory parade through the streets during a celebration for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. The Heat beat the Oklahoma Thunder to win the NBA title. (Photo by Joe Raedle/Getty Images)

  • LeBron James

    Miami Heat's LeBron James, center, looks out from a double decker bus during a parade in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder, Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • People take photographs as confetti falls on the Miami Heat NBA Finals basketball championship parade Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • LeBron James

    Miami Heat's LeBron James, center, waves from a doubledecker bus during a parade through downtown in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder, Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • Dwyane Wade

    Miami Heat's Dwyane Wade waves from a doubledecker bus during a parade downtown in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder, Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • Fans cheer as buses carrying Miami Heat players pass by during a parade in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder, Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • LeBron James

  • Norris Cole

    Miami Heat's Norris Cole, second from left, waves from a doublenamdecker bus during a parade in celebration of winning the NBA Finals basketball championship against the Oklahoma City Thunder, Monday, June 25, 2012, in Miami. (AP Photo/Lynne Sladky)

  • LeBron James

  • Miami Heat fans line the streets in downtown Miami for a parade, Monday, June 25, 2012 in celebration of the Heat winning the NBA Finals basketball championship against the Oklahoma City Thunder. (AP Photo/Wilfredo Lee)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Chris Bosh of the Miami Heat waves to the crowd during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans gather during a celebration for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans gather during a celebration for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans gather during a celebration for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: A fan takes a picture as the buses pass during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer as the buses pass during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Fans cheer during a celebration parade for the 2012 NBA Champion Miami Heat on June 25, 2012 in Miami, Florida. (Photo by Sarah Glenn/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: LeBron James #6 of the Miami Heat celebrates during a rally for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Dwyane Wade

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Udonis Haslem #40 of the Miami Heat looks on during a rally for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Miami Heat Victory Parade And Rally

    MIAMI, FL - JUNE 25: Chris Bosh #1 of the Miami Heat talks to the crowd during a rally for the 2012 NBA Champion Miami Heat at American Airlines Arena on June 25, 2012 in Miami, Florida. (Photo by Mike Ehrmann/Getty Images)

  • Miami Heat fans celebrate the NBA Championship with the team at the arena in Miami, Monday, June 25, 2012.(AP Photo/J Pat Carter)