Log time

Log hours on an issue or a project with an activity and a comment.

POST https://cotlet.dev/api/v1/redmine/times

write

Creates a time entry for the signed-in account and returns it. Pass issue_id or project_id. Hours are decimals, so 0.25 is 15 minutes. The activity is required unless the instance has a default; the comment is 255 characters at most. log_time runs without asking first: it reaches no one and is corrected with update_time_entry.

Parameters

Parameters: log_time
NameTypeDescription
issue_id integer integer Issue to log on. Give this or project_id.
project_id integer integer Project to log on when no issue applies.
hours number required number Decimal hours, e.g. 1.5.
activity_id integer integer Activity ID from list_issue_options. Required unless the instance has a default activity.
spent_on date date Day worked, YYYY-MM-DD. Default: today.
comments string string Short description, 255 characters at most.

Request

cURL
curl -X POST https://cotlet.dev/api/v1/redmine/times \
  -H "Authorization: Bearer $COTLET_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"issue_id":4821,"hours":1.5,"activity_id":9,"spent_on":"2026-10-15","comments":"Reproduced the login loop and patched the session check"}'
Python
result = client.call("redmine", "log_time", {"issue_id":4821,"hours":1.5,"activity_id":9,"spent_on":"2026-10-15","comments":"Reproduced the login loop and patched the session check"})
Node.js
const result = await cotlet.call('redmine', 'log_time', {"issue_id":4821,"hours":1.5,"activity_id":9,"spent_on":"2026-10-15","comments":"Reproduced the login loop and patched the session check"});
CLI
cotlet call redmine log_time --data '{"issue_id":4821,"hours":1.5,"activity_id":9,"spent_on":"2026-10-15","comments":"Reproduced the login loop and patched the session check"}'

Example response

JSON

{
  "time_entry_id": 18433,
  "project": "Billing portal",
  "issue_id": 4821,
  "user": "Dana Whitfield",
  "activity": "Development",
  "hours": 1.5,
  "spent_on": "2026-10-15",
  "comments": "Reproduced the login loop and patched the session check"
}

Sign in once. Your agent does the rest.

Sign up and add the apps you need. Free 7-day trial with 2,000 credits, no card needed.