Can't call API in c9 workspace



Hi, I have created an API in and am now trying to call it from a javascript file. I am able to get it to work using postman but I am unable to make an AJAX request to it. I have already made my Application URL public so that wasn’t the issue. Here is my code that calls it:
url: ‘’,
error: function(jqXHR, textStatus, errorThrown) {
alert(‘error’ + jqXHR + " " + textStatus + " " + errorThrown);
dataType: ‘json’,
success: function(data) {
type: ‘GET’

I have made datatype json and jsonp with neither working. Every time I call the API, the error function is called and the success function is never called.

Any help on how to solve my problem is appreciated.