More I think about it, the more I think it's a good idea, and right up my alley.
Like an ActivityPub framework, made for web devs, not users. Due to the nature of AP, it would have to be configuration-over-convention (more like Django than Flask), but theoretically it could do all the heavy lifting between client-server and server-fediverse APIs.
Devs would have to do a bunch of config to say "this server will map these APIs in this way," but a lot is going to be boilerplate and mappings with transformer callbacks and the like, right? It would reduce the work for new implementations, and reduce idiosyncratic client-server-fediverse implementations.