The answer is more aggressively copyleft licensing (AGPL, and others).
If APIs are copyrightable that's a very unfortunate thing, but it would also make it possible to protect FOSS IP much more aggressively. Mongo wouldn't be getting destroyed by Amazon, for example.