API Scalability / Management

The two biggest challenges APIs face is having no one using them, and having everyone using them. How do you manage hundreds of thousands to millions of users, how do you ensure unique access tokens and keys, or know what endpoints are actually being used – and by whom? Beyond just managing the users, how do you predict spikes and dips within usage to allow you to scale up and down intelligently, and what type of infrastructure do you need to support dynamic scaling to prevent downtime and self-healing within your infrastructure?