Skip to content

odoo-work-cli clock list

NAME

odoo-work-cli-clock-list - List attendance records of a day or week

SYNOPSIS

odoo-work-cli clock list [--date YYYY-MM-DD | --week YYYY-Www] [--json | --format FORMAT]

DESCRIPTION

List the attendance records of a day (--date, default today) or an ISO week (--week YYYY-Www) with ID, check-in, check-out and duration.

Records are attributed to the day of their check-in. A record that crosses midnight is listed on its check-in day and shows the check-out date. Use it before 'clock edit' to see what is already recorded.

--date and --week together are a validation error.

OPTIONS

--date YYYY-MM-DD

Day to list, YYYY-MM-DD.

string; optional; default: today

--week YYYY-Www

ISO week to list, YYYY-Www.

string; optional

GLOBAL OPTIONS

--format FORMAT

Output FORMAT: table, json or jsonl.

one of table, json, jsonl; optional; default: table

--json

Shorthand for --format json.

flag; optional

--backend BACKEND

BACKEND: odoo or fake (offline, made-up data; env ODOO_WORK_CLI_BACKEND).

string; optional; default: odoo; env: ODOO_WORK_CLI_BACKEND

--config FILE

Read only the config FILE (skip discovery).

string; optional

-h, --help
Print the help of the command and exit.

OUTPUT

The columns ID, Check In, Check Out (with the date if it is on a later day, --:-- while running) and Duration (H:MM, "(running)" for a running record), then the total; or "No attendance records."

With --json an array of attendance records, oldest first, [] if there are none.

Fields of attendance.schema.json:

id
integer
employee_id
integer or null
employee
string or null
check_in
string (RFC 3339 timestamp)
check_out
string (RFC 3339 timestamp) or null
running
boolean
worked_hours
number
worked_minutes
integer

ENVIRONMENT

ODOO_URL
Odoo server URL; overrides url from the config files.
ODOO_DATABASE
Odoo database name; overrides database.
ODOO_USERNAME
Odoo login, usually an e-mail address; overrides username.
ODOO_PASSWORD
Odoo API key, used for XML-RPC. Despite the name, not the login password.
ODOO_WEB_PASSWORD
Odoo login password, used for the web session of clock in and clock out.
ODOO_TOTP_SECRET
TOTP secret (base32 or otpauth:// URL) for accounts with two-factor authentication.
ODOO_OP_TIMEOUT
Timeout of the 1Password call that resolves [op_secrets], a Go duration; default 5s.
ODOO_WORK_CLI_NO_OP
If 1, true, yes or on, [op_secrets] is ignored and the 1Password CLI is never called.
ODOO_WORK_CLI_BACKEND
Backend, odoo (default) or fake; --backend overrides it.
ODOO_WORK_CLI_FAKE_STATE
State file of the fake backend; default odoo-work-cli-fake-state.json in the temporary directory.
XDG_CONFIG_HOME
Base directory of the global config file; default ~/.config.

FILES

~/.config/odoo-work-cli/config.toml
Global configuration ($XDG_CONFIG_HOME/odoo-work-cli/config.toml if XDG_CONFIG_HOME is set). Created by odoo-work-cli config install.
.odoo-work-cli.toml
Configuration of a directory tree. Every such file from the filesystem root down to the current directory is merged over the global file, the deepest last. --config FILE loads only FILE instead.
$TMPDIR/odoo-work-cli-fake-state.json
State of the fake backend (--backend fake); ODOO_WORK_CLI_FAKE_STATE sets another path. Delete it to start over with the seed data.

EXIT STATUS

0 on success, 1 on any error, including usage errors. With --json or --format json|jsonl the error is printed on standard output as one JSON object, {"error": {"kind": KIND, "message": TEXT}}, and nothing on standard error; otherwise as "Error: TEXT" on standard error, after usage errors followed by the usage.

Error kinds this command can fail with:

auth
Authentication failed: wrong API key or login password, TOTP rejected.
validation
Invalid input: unknown flag, bad argument, malformed date, time or hours, a time in the future, an unknown project.
network
Odoo cannot be reached: DNS, connection refused, timeout, TLS.
config
The local configuration is missing or invalid.
secrets_locked
1Password is locked or unreachable, so op:// references could not be resolved.
internal
Anything else: an unexpected Odoo response or a bug.

EXAMPLES

A week, with the total:

$ odoo-work-cli clock list --week 2026-W14
ID      Check In         Check Out        Duration
------- ---------------- ---------------- --------
4601    2026-03-30 08:30 16:45            8:15
4602    2026-03-31 08:15 16:30            8:15
4603    2026-04-01 08:20 16:20            8:00
4604    2026-04-02 08:00 15:00            7:00

Total: 31:30

One day as JSON:

$ odoo-work-cli clock list --date 2026-04-08 --json
[
  {
    "id": 4606,
    "employee_id": 7,
    "employee": "Alex Demo",
    "check_in": "2026-04-08T08:30:00+02:00",
    "check_out": "2026-04-08T12:00:00+02:00",
    "running": false,
    "worked_hours": 3.5,
    "worked_minutes": 210
  },
  {
    "id": 4607,
    "employee_id": 7,
    "employee": "Alex Demo",
    "check_in": "2026-04-08T12:30:00+02:00",
    "check_out": "2026-04-08T17:00:00+02:00",
    "running": false,
    "worked_hours": 4.5,
    "worked_minutes": 270
  }
]

SEE ALSO