For 5e, that appears to be one of the things that they left out. Previous editions had limitations as noted below, so this is one of the things that will be up to the DM to decide as necessary.
2nd edition time limit: 10 minutes (1 turn)
Only one creature can be drawn forth at a time. It alone exists until it is slain, until one turn has elapsed, or until it is ordered back into the bag of tricks. At that point, the creature vanishes. Only then can another animal be brought forth. Up to 10 creatures can be drawn from the bag each week.
3rd edition time limit: 10 minutes
Bag of Tricks: This small sack appears normal and empty. However, anyone reaching into the bag feels a small, fuzzy ball. If the ball is removed and tossed up to 20 feet away, it turns into an animal. The animal serves the character who drew it from the bag for 10 minutes (or until slain or ordered back into the bag)
3.5 (Same as 3rd edition)
4th edition time limit: 5 minutes or encounter length
Bag of Tricks
These small leather bags come in a variety of colors, gray being the most common. You can use a bag of tricks to conjure an obedient beast. You must spend a healing surge to activate the bag’s power, and you gain no other benefit for spending the healing surge.
When you use a bag of tricks to conjure a creature, it appears in an unoccupied space within 5 squares of you; the space must be large enough to contain the creature without squeezing. The creature obeys only you, responding to commands spoken in any language. The creature remains until the end of the encounter or for 5 minutes
Note, that in the absence of orders (one would presume continual), the animal summoned will wander off and do what is natural to it. So you could game it several ways to prevent the character from having an army of baboons or similar.