Don't do UI stuff in contents API module
Add Contents.api_url convenience function