ide-backend (
https://github.com/fpco/ide-backend) provides a JSON layer (
https://github.com/commercialhaskell/stack-ide). I haven't tried it, since it requires stack and it's asking me to install the latest GHC 7.10.2 (sorry, I just wanted to have a look at the API, not reinstall a complete Haskell stack again), but maybe there are some good ideas there.
But before talking about API, shouldn't we talk about why we have ghc-mod and ide-backend? Can we merge them, or be clear what are their differences and when/why we should use one and not the other? We don't have fragmentation at the compiler level itself (with the dominance of GHC) but we seem to have some at the "nicer API on top of GHC" level.
Or maybe, should we have something in GHC itself, something like a GHC service that we could talk to via JSON or something, without having to use the complex, changing with each release GHC API, and have that part of GHC instead of having another tool to install?
My 2 cents,
JP