Lactrans

Giant telepaths who keep a zoo

Huge, slug-like telepaths of Lactra VII, far more advanced than humans, who place visitors from other worlds in a zoo.

The Lactrans are enormous slug-like beings of Lactra VII who communicate telepathically. Their intellect is so far beyond human levels that they regard humans as primitive animals.
In The Eye of the Beholder, Kirk, Spock and McCoy searched the planet for a missing survey team and were captured to become exhibits in a Lactran zoo, alongside creatures from many worlds. A young Lactran befriended them, and the adults eventually recognized that the humans were intelligent and allowed them to leave.