Add java API and integration tests