1.2 Add Work Hours

post /rest/shdsd-Timesheet/3/worklog/{action}

API Documentation

Create and Submit Work Log.

Media type

  • application/json

Path parameters

Parameter

Type

Description

Required

Parameter

Type

Description

Required

action

String

submit:After submitting work hours, it enters a pending review status;

save:After saving work hours, it enters an unsubmitted status;

Required

Request example

{ "issueId": "10338", "memo":"Complete the functional design", "author":"bruce", "startDate": "2024-07-24", "timeWorkedStr":"8h" }

Request BODY Details

Parameter

Type

Description

Required

Default Value

Parameter

Type

Description

Required

Default Value

issueId

Number

Work log issue ID

Required

 

memo

String

Remarks text of the work log. Is it required to comply with global configuration.

Not required

 

author

String

Username of the owner of the work log

Required

 

startDate

String

Start time of the work log in the format yyyy-MM-dd

Required

 

endDate

String

End time of the work log in the format yyyy-MM-dd

Not required

<When left blank, it will be the same as startDate>

timeWorkedStr

String

Time spent (For example:2h, 1h 30m, 30m)

Required

 

remainingEstimateStr

String

Remaining estimated time (For example:2h, 1h 30m, 30m)

Not required

<Automatically calculate when left blank>

isIncludeHoliday

boolean

Does the period from the start date to the end date include non-working days

Not required

false

workLogType

String

Work type of the work log

Not required

<Default processing when left blank>

auditor

String

Reviewer of the work log

Not required

<Default processing when left blank>

runAs

String

A single username, executing this work hour entry on behalf of this user.

Not required

<Same as author when left blank>

Return Example

{ "msg": "ok" }