I need output data in JSON array format to use with jQuery DataTables but my API from Apigility gives HAL+JSON. How can I convert it so that I can pass it from fetchAll method of API to AJAX URL of Datatables?
Here is what the HAL+JSON looks like:
{"_links":{"self":{"href":"http:\/\/parekh.com\/exportmanager\/courses"}},"_embedded":{"courses":[{"Module Title":"Preventing Harassment","Module ID":"HUR602","Module Language":"English"},{"Module Title":"Conflict","Module ID":"COM236","Module Language":"Dutch"},{"Module Title":"Workplace","Module ID":"HUR711","Module Language":"Dutch"}]},"total_items":3}