Snap interview question

Design a rate limiter for a system API.