Post

2 followers Follow
0
Avatar

Custom Panel Clarizen Data API Call for non-related data.

I am trying to create a custom page on a Project Level and I would like to get some Data stored in Clarizen that isn't directly related to the Project.

The data I would like to get is the List of Job Titles in the system. What API call can use. I've been trying with JSONObjects in the Data(JSON Format) box but not sure that is correct.

What is the call to get non-related data stored within Clarizen?

Darren Answered

Please sign in to leave a comment.

3 comments

0
Avatar

You can perform an API query using Javascript in the Custom Panel. The format is the same as the REST API query (https://api.clarizen.com/V2.0/services/data/Query). Below is a code fragment which queries all the job titles and print out the each of them in your JS console.

queryString = "Select Name from JobTitle ";

API.Objects.query(queryString, function(qResults) {
if (qResults != null && qResults.length > 0) {
qResults.forEach(function(jt) { console.log(JSON.stringify(jt)) });
}
});

Ricky Leung 0 votes
Comment actions Permalink
0
Avatar

Thank you Ricky, is there anywhere that the API.Object functions are documented?

Darren 0 votes
Comment actions Permalink
0
Avatar

There is no detail documentation about this object at the moment. But feel free to post here if you have any questions.

Ricky Leung 0 votes
Comment actions Permalink