maintenance/interwiki.sql does not contain data for the iw_api column. Therefore, Interwiki::getAPI will always return null. I could write a script which populates the api endpoint data using the "EditURI" "really simple discovery" data, if we plan to implement the api column.
Since we still have a blank slate here, it might be more useful to store the script URL prefix, for example "http://de.wikibooks.org/w/", at least until there is an API to retrieve the other endpoints through queries to api.php.
Version: unspecified
Severity: normal