Re: 1 - see http://jenkins-ci.361315.n4.nabble.com/quot-wipe-out-current-workspace-quot-via-REST-API-td4687766.html for suggestions on how to find the most useful functions.

Re: 2 - The comments on the Jenkins wiki page mentioned by Robin Rosenberg contain several examples of Python code to handle authentication. I don't have experience using VbScript but I imagine you could do it there, too.

Regards,
Eric


On 3/6/2014 3:01 PM, Andrew Sumner wrote:
Couple of questions:

1. Where can I find a list of functions I can call?

eg I found toggleOffline while searching the internet, I don't think its strictly an api method, but where can I find documentation for this and other methods?

2. Having a problem authenticating with Jenkins using vbscript, how do I do this? I've tried many different ways but nothing I tried worked.

url = "http://jenkins/<node name>/toggleOffline?offlineMessage=Rebooting"

    With CreateObject("MSXML2.XMLHTTP")
        .open "GET", url, False
        .send

        responseText = .responseText
        statusText = .statusText
        status = .status
    End With

    If status <> 200 Then
        ' Call not successful - quit
        WScript.Echo("Status: " & status & " - " & statusText)
        WScript.Echo(responseText)
        WScript.Quit(2)
    End If

    WScript.Echo("Response: " & responseText)

--
You received this message because you are subscribed to the Google Groups "Jenkins Users" group. To unsubscribe from this group and stop receiving emails from it, send an email to jenkinsci-users+unsubscr...@googlegroups.com <mailto:jenkinsci-users+unsubscr...@googlegroups.com>.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "Jenkins 
Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to jenkinsci-users+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to