List of Slaves connected to master - Hudson

vpram86 picture vpram86 · Jul 8, 2010 · Viewed 15.2k times · Source

Is there a way to find it programatically? I need this as part of an automated run; So this would be very helpful if there is an existing remote API call which can give this.

Answer

jey burrows picture jey burrows · Jul 21, 2010

You don't need to parse the HTML - most of the Hudson pages can be turned into API calls by adding URL suffix, e.g. make GET calls to:

http://hudson:8080/computer/api/json

Switch the JSON for either XML or Python if you prefer these over JSON.

If you use just the API suffix, you'll get a short generic help page on the API.