rundeck.importJobs("test.xml", FileType.XML );
It throws the following exception.
Exception in thread "main" org.rundeck.api.RundeckApiException: Invalid HTTP response 'HTTP/1.1 405 Method Not Allowed' for https://<rundeck-server>/api/9/jobs/import?format=xml
at org.rundeck.api.ApiCall.execute(ApiCall.java:266)
at org.rundeck.api.ApiCall.execute(ApiCall.java:199)
at org.rundeck.api.ApiCall.post(ApiCall.java:168)
at org.rundeck.api.RundeckClient.importJobs(RundeckClient.java:646)
at org.rundeck.api.RundeckClient.importJobs(RundeckClient.java:565)
at org.rundeck.api.RundeckClient.importJobs(RundeckClient.java:520)
I am seeing the following response when I try to access the api(api/9/jobs/import) via browser
Problem accessing /grails/scheduledExecution/apiJobsImport.dispatch. Reason:
METHOD_NOT_ALLOWED
Powered by Jetty://
Rundeck version is 1.6.1
Rundeck api java client - 9.0
Kindly assist in getting this issue resolved
Regards
Ranjeeth