REST API

    If you want to use the REST API to log work on behalf of a user, you can use the plugin REST API:

    curl --location 'localhost:8080/rest/logwork-as-another-user/2.0/logwork' \
    --header 'Content-Type: application/json' \
    --header 'Authorization: Basic XXXXXXX' \
    --data '{"user":"test","adjustEstimate":"auto", "comment": "REST API test", "issueId": "SCRUM-10", "timeSpent": "1h"}'
    

    This API is authenticated and you should use POST as the method for the request.

    The data to be sent is a JSON object with the following parameters:

    ParameterTypeDescription
    userStringUser name for which to log work
    timeSpentStringTime to log
    startDateStringDate for the log
    adjustEstimateStringauto | leave | setto | reduceby
    adjustEstimateValueStringValue to use in conjunction with adjustEstimate
    commentStringComment for the log
    commentRoleVisibilityLevelStringRole to view this log
    issueIdStringID for the issue