The cooperation was confirmed during the visit to Cambodia of Sihasak Phuangketkeow, Thai permanent secretary for foreign affairs.
Mr Sihasak, also acting foreign minister, is officially visiting Cambodia today and tomorrow.
He met Cambodian Deputy Prime Minister/Foreign Minister Hor Namhong on Tuesday.
At a press conference in Phnom Penh, Mr Sihasak said that Thailand's political situation is improving and progressing as the National Council for Peace and Order planned.
He gave assurances that sustainable democracy is in the making in Thailand and in the meantime the council maintains Thailand's existing agreements with Cambodia including those concerning bilateral cooperation in border areas.
"Regarding the regulation of alien workers, Thailand sees the importance of Cambodian, Myanmar and Lao workers who help drive the Thai economy, so it wants to legalize them so that they enjoy legal benefits and are not abused by brokers and human trafficking is prevented," Mr Sihasak said.
Mr Hor Namhong said Cambodia understood the situation in Thailand and would send its workers back to Thailand legally.
The Cambodian Ministry of Foreign Affairs had issued reference letters to back the visa applications of more than 10,000 workers from Phnom Penh who already entered Thailand for work, he said.
Mr Hor Namhong also asked Thailand to help 14 Cambodian nationals arrested for using fake visa stamps to enter Thailand. He said the 14 were victims of human trafficking.
Mr Sihasak and Mr Hor Namhong also discussed border area development including building a railway to link Thailand's Aranyaprathet district and Cambodia's Poipet and opening the Stung Bot-Nong Ian border crossing.
Mr Hor Namhong also said that Thai authorities could take legal action against the Cambodians who illegally fell trees on Thai soil.