added some precautions against rate limiting