functional REST API