added Application for Jersey 2 and updated api calls