Skip to content

Instantly share code, notes, and snippets.

@stupergenius
Last active December 25, 2015 15:09
Show Gist options
  • Save stupergenius/6996315 to your computer and use it in GitHub Desktop.
Save stupergenius/6996315 to your computer and use it in GitHub Desktop.
Prints a list of non-complete tasks from ActiveCollab API.
var apiUrl = 'http://my.chepri.com/public/api.php';
var authToken = 'Your Auth Token';
var projectSlug = 'project-slug-or-id';
$.getJSON(apiUrl + '?auth_api_token=' + authToken + '&path_info=/projects/' + projectSlug + '/tasks', null, function (response) {
for (var i in response) {
var task = response[i];
if (!task.is_complete) {
console.log(task.task_id + ': ' + task.name);
}
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment