Tuesday's attack on DusitD2 hotel complex on 14 Riverside Drive was retaliation for US President Donald Trump's decision to declare Jerusalem the capital city of Israel, al Shabaab has said.
SITE Intelligence Group, an NGO that specialises in tracking and analysing global extremist groups, said the jihadists presented a detailed report on the attack through its media unit al-Mujahideen Movement.
However, SITE did not reveal the details of the report apart from mentioning that al-Qaeda leader Ayman al-Zawahiri ordered the attack.
The report said Zawahiri directed the militants to target "Western and Zionist" interests in response to Trump's announcement.
The death toll from the terror attack rose to 21 on Wednesday after police said five more bodies were discovered in the complex.
A police officer, who was injured, succumbed to injuries in hospital.
The conflict between Israelis and Palestinians over the control of Jerusalem began the mid 20th century.
It has been referred to as the world's "most intractable conflict". Israel has occupied the West Bank and Gaza Strip for 52 years.
By Trump recognising Jerusalem as Israel's capital, he insinuated that Israel had sovereignty over the disputed city.
Al-Qaeda-linked al Shabaab is known to attack the interests of any country that is deemed to have infringed on the rights or freedoms of an Islamic state.
Trump announced the US' recognition of Jerusalem as Israel's capital on December 6, 2017. He ordered the relocation of the US embassy from Tel Aviv to Jerusalem.
Israel Prime Minister Benjamin Netanyahu welcomed the decision.
Trump's announcement ignited demonstrations throughout the West Bank and Gaza Strip.
Other protests were also held in Iran, Jordan, Tunisia, Somalia, Yemen, Malaysia and Indonesia, and outside the US embassy in Berlin.
The majority of world leaders rejected Trump's decision.
Britain, France, Sweden, Italy and Japan were among 14 of the 15 countries which criticised the decision at an emergency meeting convened by the United Nations Security Council on December 7, 2017.
On December 8, then US Secretary of State Rex Tillerson clarified that Trump's statement "did not indicate the final status on Jerusalem".
He said the final status, including the borders, will be left to Israel and Palestine to negotiate and decide.
Palestinian officials said the announcement disqualified America from peace talks, while Hamas called for a new intifada following Trump's declaration.
Intifada is an Arabic word that means to tremor, shiver, or shudder.
Hamas is a Palestinian Islamist fundamentalist organisation which has been the de facto governing authority of the Gaza Strip since its takeover of the area in 2007.
It is regarded as a terrorist organisation by several countries including the US and some European countries.