Nairobi, Kenya (CNN) -- Somalia praised Kenya Wednesday, thanking it for helping battle the Islamic extremist group Al-Shabaab, in an apparent effort to heal tensions sparked by the Somali president's criticism of Kenya earlier this week.
"Kenya and Somalia have a long history of friendship and cooperation, and that continues today," the Somali government said in what it called a "clarification statement."
It thanked Kenya for working together with the Somali transitional government "to stabilize Somalia" and for training a "good number of Somali soldiers as well as hosting (a) huge number of Somali refugees."
On Monday, Somali President Sharif Ahmed spoke out against Kenya's military incursion into his country, saying the African neighbor overstepped its bounds.
"To send forces into Somalia is not allowed by the government and the civilians," Ahmed said. He also called Kenya's actions "not good."
Wednesday's "clarification statement" did not clearly address the question of Kenyan troops entering Somalia. It said the two nations "share the attitude that Al-Shabaab constitutes a common enemy to both countries" and that "the territorial integrity of both Somalia and Kenya should be respected."
In order to "evolve a common security strategy, we agreed with our brothers" in the Kenyan government to cooperate in "coordinated security and military operations" spearheaded by Somali soldiers trained by Kenya, the statement said. There will also be "cooperation and collaboration in sharing and exchange of information that is relevant to the fight against cross-border crimes and operations."
Kenyan forces entered Somalia on October 15 in a strike on Al-Shabaab, a Somali militant group that Kenya blames for the recent kidnappings of foreigners from northern Kenya.
The Kenyan forces are ultimately seeking to take the Somali port city of Kismayo, described by the United Nations as a key stronghold and source of cash for Al-Shabaab. The United Nations estimates the group collects up to $50 million a year from businesses in Kismayo, about half of its annual income.
Kenyan officials declared self-defense justifies crossing the border with Somalia, saying a recent spate of kidnappings threatened its security and constituted an attack.
"If you are attacked by an enemy, you have to pursue that enemy through hot pursuit and to try (to) hit wherever that enemy is," Kenyan Defense Minister Yusuf Haji said in a news conference Sunday.
Somalia's frail Transitional Federal Government, aided by forces from the African Union, has itself been fighting Al-Shabaab militants in the capital, Mogadishu, and reported last week that they had largely pushed the group out of that city.
Katya Thomas, a press officer with the U.S. Embassy in Kenya, said the United States "did not encourage the Kenyan government to act nor did Kenya seek our views. We note that Kenya has a right to defend itself against threats to its security and its citizens."
"The United States has supported Kenyan efforts to improve its ability to monitor and control often porous land and maritime borders and territory exploited by terrorists and illicit traffickers, particularly along its border with Somalia," Thomas said.
CNN's David McKenzie and Christabelle Fombu contributed to this report.