Skip to main content

CLI for interacting with the KitchenOwl API.

Project description

kitchenowl-cli

Command-line client for KitchenOwl's /api endpoints, covering auth, household, recipe, shopping list, and user workflows.

Supported CLI surface

  • kitchenowl auth [login|logout|status|signup] — JWT login with refresh, logout and signup helpers.
  • kitchenowl config [show|set-default-household|server-settings] — manage stored tokens/default household and inspect read-only server flags from /api/health.
  • kitchenowl household [list|use|get|create|update|delete] and kitchenowl household member [list|add|remove].
  • kitchenowl recipe [list|get|add|edit|delete] with JSON/YAML payload support and flag-based editors, including ingredients management.
  • kitchenowl shoppinglist [list|create|delete|items|add-item|add-item-by-name|suggested|remove-item] plus the dedicated remove-item command to mark items done.
  • kitchenowl user [list|get|search|create|update|delete] for admins.
  • run_cli_e2e.sh script exercises login, household creation, lists, recipes, planner, expenses, and optionally house cleanup.

Install

Recommended for normal usage (installs globally via pipx):

pipx install kitchenowl-cli

The installed command is:

kitchenowl --help

For local development / modifying this CLI:

cd kitchenowl-cli
python3 -m pip install -e .

Publish to PyPI via GitHub Actions

This repository includes .github/workflows/publish.yml for Trusted Publishing.

One-time setup:

  • In PyPI, create a Trusted Publisher for this GitHub repository and workflow file.
  • In GitHub, keep the repository public and allow Actions to run.

Release flow:

git tag v0.1.1
git push origin v0.1.1

Then create a GitHub Release for that tag (or publish from the Releases UI).
When the release is published, the workflow builds and uploads kitchenowl-cli to PyPI.

Quick start examples

kitchenowl auth login --server https://your-kitchenowl.example.com
# tip: both https://host and https://host/api are accepted
kitchenowl config server-settings
kitchenowl household list
kitchenowl household member list --household-id 42
kitchenowl household member add 17 --household-id 42 --admin
kitchenowl shoppinglist create "Weekly List" --household-id 42
kitchenowl shoppinglist add-item-by-name 12 Milk --description "2L"
kitchenowl shoppinglist remove-item 12 456 -y
kitchenowl recipe add --name "Tomato Soup" --description "Simple soup" --household-id 42 --yields 2 --time 25 --ingredient "Tomatoes|6 pcs|false" --ingredient "Salt|1 tsp|false"
kitchenowl recipe edit 123 --description "Updated" --ingredient "Basil|a handful|true"
kitchenowl recipe delete 123
kitchenowl user list
kitchenowl auth signup --username newuser --name "New User"

auth login / auth signup will always ask for the server URL when --server is not provided, using your last saved server as the default.

Read-only server settings

Inspect the public read-only settings exposed by the server health endpoint (works without login if you pass --server):

kitchenowl config server-settings --server https://your-kitchenowl.example.com
kitchenowl config server-settings --json

This currently shows:

  • open_registration
  • email_mandatory
  • oidc_provider
  • privacy_policy (if configured)
  • terms (if configured)

File-based recipe editing

kitchenowl recipe add --household-id 1 --from-file recipe.yml
kitchenowl recipe edit 42 --from-file recipe.yml

Example recipe.yml:

name: Tomato Soup
description: Simple soup
time: 25
cook_time: 20
prep_time: 5
yields: 2
visibility: 0
source: ""
items:
  - name: Blend
    description: Blend until smooth
    optional: false
ingredients:
  - name: Tomatoes
    description: 6 pcs
    optional: false
  - name: Salt
    description: 1 tsp
    optional: false
tags:
  - soup
  - vegetarian

What’s not implemented yet

  • Planner CLI commands (beyond the end-to-end script that calls /planner/recipe).
  • Expense management (create/edit/delete categories or entries) via CLI wrappers.
  • Shopping list item bulk operations (remove multiple items at once) and the planner suggestion refresh endpoints.
  • More advanced user workflows (password resets, token management, server admin tooling) are still API-only.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

kitchenowl_cli-0.1.6.tar.gz (15.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

kitchenowl_cli-0.1.6-py3-none-any.whl (18.6 kB view details)

Uploaded Python 3

File details

Details for the file kitchenowl_cli-0.1.6.tar.gz.

File metadata

  • Download URL: kitchenowl_cli-0.1.6.tar.gz
  • Upload date:
  • Size: 15.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for kitchenowl_cli-0.1.6.tar.gz
Algorithm Hash digest
SHA256 34205abde82a636dddd903f94871670a02c076f37991be322ce11228976d6892
MD5 45eed5c84b15da3a43b42a9f12e90fa0
BLAKE2b-256 20b6570545bbfdb02bbfc0a344922f0e82908632976c6e5107650b52d8348941

See more details on using hashes here.

Provenance

The following attestation bundles were made for kitchenowl_cli-0.1.6.tar.gz:

Publisher: publish.yml on apetersson/kitchenowl-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file kitchenowl_cli-0.1.6-py3-none-any.whl.

File metadata

  • Download URL: kitchenowl_cli-0.1.6-py3-none-any.whl
  • Upload date:
  • Size: 18.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for kitchenowl_cli-0.1.6-py3-none-any.whl
Algorithm Hash digest
SHA256 b8463b0d01f4e0fd336e42035f16e6b090e3f78dd73a181dd25fb24d75f2fb7b
MD5 7e8a3454ed706165617d96544e492c59
BLAKE2b-256 903d6d0be0cc23fc70381afdefcb63c7d186ce27c1b2db7113940fe8f21c412a

See more details on using hashes here.

Provenance

The following attestation bundles were made for kitchenowl_cli-0.1.6-py3-none-any.whl:

Publisher: publish.yml on apetersson/kitchenowl-cli

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page