Hi all, is it possible to retrieve the jobs list for a rest GP service with ArcGIS Javascript API?
Thanks,Naty
Solved! Go to Solution.
@NatashaManzuiga - No, it's not possible to retrieve a job list using the ArcGIS API for JavaScript.
The server does not provide this sort of metadata - https://developers.arcgis.com/rest/services-reference/gp-task.htm
This isn't exposed in the JavaScript API, but you might be able to use the GP Server jobs query endpoint as described here https://developers.arcgis.com/rest/enterprise-administration/server/query-jobs.htm
You'd need to manually check that using esri/request or fetch in your workflow.
@NatashaManzuiga - No, it's not possible to retrieve a job list using the ArcGIS API for JavaScript.
The server does not provide this sort of metadata - https://developers.arcgis.com/rest/services-reference/gp-task.htm
So I can just see the jobs list in arcgis/admin...
Ok...anyway maybe you can help me in this:
In a simple webpage I created to submit a job I just need to prevent the submit if the GP is executing another job.
Can I do this somehow?
Thanks,
Naty
This isn't exposed in the JavaScript API, but you might be able to use the GP Server jobs query endpoint as described here https://developers.arcgis.com/rest/enterprise-administration/server/query-jobs.htm
You'd need to manually check that using esri/request or fetch in your workflow.