An agent of the Fish and Wildlife Service, disguised in a gorilla suit and placed in a cage, helped capture a Mexican zoo official who was trying to smuggle primates from Miami to Mexico, a Federal prosecutor said today.

The arrest of the 57-year-old suspect, Victor Bernal, director of zoos and parks for the Mexican state of Mexico, occurred Monday at an airport in the Miami suburb of Opa-Locka and was confirmed today in an interview with the prosecutor, Dan Gelber, an assistant United States attorney.

Mr. Gelber said that in an undercover operation that began three weeks ago, Mr. Bernal and two Mexican middlemen had been shown real gorillas, orangutans and chimpanzees at zoos in the Miami area and had been told that the animals could be smuggled to Mexico.

As a result, the authorities said, Mr. Bernal's agency last Friday transferred $92,500 to the account of an animal dealer who was working for the Government as an informer. One animal sought in exchange, a gorilla, was to be delivered to Mr. Bernal at the Opa-Locka airport on Monday, Mr. Gelber said.