If it is criminal detention, the longest time for a gang to commit a crime is one month. At this time, the police should apply to the procuratorate for approval of arrest.
Public security detention for up to fifteen days.
If your friend is detained for a criminal case, it means that the police have conclusive evidence. Now you can hire a lawyer. They will meet at the detention center, find out the reasons for detention and then apply for bail pending trial.