What does log_work do?
An agent doesn't need to look up IDs before logging. It calls log_work directly with a description and whatever else it knows. Half5 finds the client, project and activity, or asks a question when it isn't sure.
The entry arrives as ‘Not approved yet’ in your name. That keeps control with you or your approver, even when the agent filled in the work. How to connect an agent is in Logging hours with Claude, ChatGPT or Cursor.
Which fields does the agent send?
Only the description is required. The rest helps Half5 choose the right client and duration. When a field is missing, Half5 doesn't fill it in by guessing.
| Field | Required | What it is |
|---|---|---|
description | Yes | One line of 3 to 500 characters a client could read, in your language, with no file or class names. It may end up on an invoice. |
date | No | today, yesterday or a date (YYYY-MM-DD). Leaving it out means today. |
minutes | No | Duration in minutes, 1 to 1,440. Left out when the duration isn't known. |
start_time, end_time | No | Start and end time as HH:MM. |
customer, project, activity | No | Name, trade name or reference. A project also implies its client. |
repository | No | Git remote, owner/repo or the folder name. Never a full local path. |
branch, commit_subjects | No | The branch and up to 10 commit subjects, as extra hints for client and project. |
session_id | No | The agent's session ID, only if it actually knows it. |
What are the possible outcomes?
Every call ends in one of four statuses. Each one asks something different of the agent.
| Outcome | What it means | What the agent does |
|---|---|---|
created | The entry is saved, as not approved yet. | Tells you in one sentence what was logged and why on that client. |
preview | A dry run: this is what would be logged. Nothing is saved. | Shows you the proposal. |
needs_confirmation | Half5 isn't sure, for example about the client, or the duration is missing (‘How long did you work on this?’ with a proposed duration). | Asks you the question and only logs after your choice, with exactly the chosen option. |
duplicate | The same work is already logged. | Doesn't log it again. |
Without a duration, Half5 saves nothing. The proposal runs, for example, from the end of your last entry today until now; you confirm or adjust it.
How does Half5 pick the client and project?
Client first, then the project within that client. Half5 weighs the hints it has and only logs straight away when one client is clearly the best match. Otherwise the agent asks you to choose from your recent client and project combinations.
- What you name. A named client or project beats everything.
- Your repository memory. Half5 remembers per user which repository belongs to which client, learned from entries you confirmed or moved.
- The repository name. Compared with your clients' (trade) names, labels and e-mail domains, and with project names.
- Your own history. Earlier descriptions that mention the repository, branch or a ticket number, and clients you log on recently and often.
- The description, branch and commits. As an extra hint, not as the decision.
How does repository memory work?
The memory is yours. When you log through an agent, move such an entry to another client, or register agent work in the desktop app, Half5 remembers which repository belongs to which client. Next time the agent doesn't have to ask.
If the description clearly names a different client than your memory, Half5 doesn't log blindly: the agent asks which of the two it is. With the organisation setting ‘Learn from colleagues’, Half5 can also suggest a client a colleague logged the same repository on. That stays a suggestion; the agent always asks first and your own memory comes first.
Which tools are there besides log_work?
The server offers five tools. All of them only work on your own hours, with the clients, projects and activities you're allowed to see in your organisation.
| Tool | What it does | Limits |
|---|---|---|
log_work | Log work | New entries arrive as not approved yet |
search_customers_projects | Search clients, projects and activities by name, trade name, label or e-mail domain | Read-only; not needed before log_work |
list_entries | List your own entries with daily totals | Read-only; up to 31 days at a time |
update_entry | Change one of your entries | Only entries not yet approved, and only at your request |
delete_entry | Delete one of your entries | Only entries not yet approved, after confirmation |
Once an entry is approved, the agent can no longer change it. You do that in Half5 itself.
How Half5 does it
Under Settings → ‘Linked agents’ you see each connection's client name, whether it's verified, when it was last used and what it may do (view hours, log hours). ‘Disconnect’ revokes its access.
The same page lists your repository memory. You clear a single link with ‘Forget …’, or start over with ‘Forget all’. What happens to this data is in Privacy with AI agents. For R&D projects under the Dutch WBSO, Half5 has no dedicated WBSO export; how to set it up is in WBSO hours with software.
Frequently asked questions
Does the agent need to call search_customers_projects before logging?
No. log_work finds the client and project itself. The search tool is meant for questions like ‘which projects does this client have?’ or for names that are ambiguous.
What happens if the agent sends the same entry twice?
Half5 recognises the same entry and returns duplicate instead of creating a second registration. The agent shouldn't log it again.
Does the agent send my code or file names?
It shouldn't. The server explicitly tells agents never to send file paths or code; the description is one line a client could read, and the repository is sent only as a name.
Can a colleague's memory decide which client my hours go to?
No. A colleague's memory gives a suggestion at most, and only when ‘Learn from colleagues’ is switched on. The agent then asks you first.
Can the agent still change approved hours?
No. update_entry and delete_entry only work on your own entries that aren't approved yet. Approved hours are changed in Half5.