Fixes for API and rate checking