The current gem version of jira4r (0.3.0) is out of date. There is a more up to date version here.
I have just cloned it to create my own gem of the source (jira4r-jh). Once a more up to date version of jira4r get’s released I will remove this one.
Detailed usage of the SOAP APIs can be found here
The usage is fairly straightforward but here are few examples to get you started.
client = Jira4R::JiraTool.new(2,your_jira_url) # 2 => jira soap api version, jira_url => base url
client.login(jira_username, jira_password)
worklog = Jira4R::V2::RemoteWorklog.new
worklog.startDate = JDate.today.to_s
worklog.timeSpent = '1h'
client.addWorklogAndAutoAdjustRemainingEstimate(your_jira_issue, worklog)
(Also see, addWorklogAndRetainRemainingEstimate and addWorklogWithNewRemainingEstimate)
If you use custom fields, you’ll first need to create a RemoteField object:
remote_field = Jira4R::V2::RemoteFieldValue.new
remote_field.id = "your_custom_field_id"
remote_field.values = "new_value"
client.updateIssue(your_jira_issue, [remote_field])