openapi-cli4ai 0.4.0__tar.gz → 0.5.1__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (49) hide show
  1. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/dependabot.yml +1 -1
  2. openapi_cli4ai-0.5.1/.github/workflows/ci.yml +48 -0
  3. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/workflows/codeql.yml +3 -3
  4. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/workflows/publish.yml +5 -5
  5. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.gitignore +8 -0
  6. openapi_cli4ai-0.5.1/.pre-commit-config.yaml +7 -0
  7. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/CHANGELOG.md +35 -0
  8. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/PKG-INFO +2 -2
  9. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/pyproject.toml +25 -2
  10. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/src/openapi_cli4ai/cli.py +976 -343
  11. openapi_cli4ai-0.5.1/tests/__init__.py +0 -0
  12. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/conftest.py +0 -4
  13. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_auth.py +1 -1
  14. openapi_cli4ai-0.5.1/tests/test_auth_flow_security.py +265 -0
  15. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_auth_flows.py +16 -17
  16. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_caching.py +86 -4
  17. openapi_cli4ai-0.5.1/tests/test_cli_commands.py +455 -0
  18. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_commands.py +29 -10
  19. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_coverage_gaps.py +5 -4
  20. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_device_flow.py +7 -8
  21. openapi_cli4ai-0.5.1/tests/test_error_handling.py +180 -0
  22. openapi_cli4ai-0.5.1/tests/test_features.py +313 -0
  23. openapi_cli4ai-0.5.1/tests/test_foundation.py +101 -0
  24. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_oidc.py +1 -1
  25. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_run_command.py +85 -0
  26. openapi_cli4ai-0.5.1/tests/test_schema_composition.py +349 -0
  27. openapi_cli4ai-0.5.1/tests/test_security.py +740 -0
  28. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_sse_streaming.py +2 -2
  29. openapi_cli4ai-0.5.1/tests/test_v040_hardening.py +279 -0
  30. openapi_cli4ai-0.5.1/uv.lock +704 -0
  31. openapi_cli4ai-0.4.0/.github/workflows/ci.yml +0 -36
  32. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/CODEOWNERS +0 -0
  33. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/ISSUE_TEMPLATE/bug_report.md +0 -0
  34. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/ISSUE_TEMPLATE/feature_request.md +0 -0
  35. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/.github/release.yml +0 -0
  36. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/CONTRIBUTING.md +0 -0
  37. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/LICENSE +0 -0
  38. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/README.md +0 -0
  39. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/SECURITY.md +0 -0
  40. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/demo.gif +0 -0
  41. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/examples/profiles.toml.example +0 -0
  42. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/openapi-cli4ai +0 -0
  43. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/src/openapi_cli4ai/__init__.py +0 -0
  44. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/src/openapi_cli4ai/__main__.py +0 -0
  45. /openapi_cli4ai-0.4.0/tests/__init__.py → /openapi_cli4ai-0.5.1/src/openapi_cli4ai/py.typed +0 -0
  46. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/fixtures/petstore_spec.json +0 -0
  47. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_integration.py +0 -0
  48. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_profile_management.py +0 -0
  49. {openapi_cli4ai-0.4.0 → openapi_cli4ai-0.5.1}/tests/test_spec_parsing.py +0 -0
@@ -10,7 +10,7 @@ updates:
10
10
  actions:
11
11
  patterns: ["*"]
12
12
 
13
- - package-ecosystem: "pip"
13
+ - package-ecosystem: "uv"
14
14
  directory: "/"
15
15
  schedule:
16
16
  interval: "weekly"
@@ -0,0 +1,48 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ permissions:
10
+ contents: read
11
+
12
+ jobs:
13
+ test:
14
+ runs-on: ubuntu-latest
15
+ strategy:
16
+ matrix:
17
+ python-version: ["3.11", "3.12", "3.13"]
18
+ steps:
19
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
20
+ - uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
21
+ with:
22
+ enable-cache: true
23
+ - name: Set up Python ${{ matrix.python-version }}
24
+ run: uv python install ${{ matrix.python-version }}
25
+ - name: Sync dependencies
26
+ run: uv sync --locked --python ${{ matrix.python-version }}
27
+ - name: Run unit tests with coverage
28
+ run: uv run --python ${{ matrix.python-version }} pytest tests/ -m "not integration" -v --cov=openapi_cli4ai --cov-report=term-missing
29
+
30
+ lint:
31
+ runs-on: ubuntu-latest
32
+ steps:
33
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
34
+ - uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
35
+ - name: Ruff check
36
+ run: uvx ruff check .
37
+ - name: Ruff format check
38
+ run: uvx ruff format --check .
39
+
40
+ typecheck:
41
+ runs-on: ubuntu-latest
42
+ steps:
43
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
44
+ - uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
45
+ - name: Sync dependencies
46
+ run: uv sync --locked
47
+ - name: Run mypy
48
+ run: uv run mypy src/openapi_cli4ai/ --ignore-missing-imports
@@ -16,8 +16,8 @@ jobs:
16
16
  analyze:
17
17
  runs-on: ubuntu-latest
18
18
  steps:
19
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
20
- - uses: github/codeql-action/init@38697555549f1db7851b81482ff19f1fa5c4fedc # v4.34.1
19
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
20
+ - uses: github/codeql-action/init@54f647b7e1bb85c95cddabcd46b0c578ec92bc1a # v4.36.3
21
21
  with:
22
22
  languages: python
23
- - uses: github/codeql-action/analyze@38697555549f1db7851b81482ff19f1fa5c4fedc # v4.34.1
23
+ - uses: github/codeql-action/analyze@54f647b7e1bb85c95cddabcd46b0c578ec92bc1a # v4.36.3
@@ -13,12 +13,12 @@ jobs:
13
13
  permissions:
14
14
  contents: read
15
15
  steps:
16
- - uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
17
- - uses: astral-sh/setup-uv@37802adc94f370d6bfd71619e3f0bf239e1f3b78 # v7.6.0
16
+ - uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0
17
+ - uses: astral-sh/setup-uv@fac544c07dec837d0ccb6301d7b5580bf5edae39 # v8.2.0
18
18
  - name: Build sdist and wheel
19
19
  run: uv build
20
20
  - name: Upload artifacts
21
- uses: actions/upload-artifact@bbbca2ddaa5d8feaa63e36b76fdaad77386f024f # v7.0.0
21
+ uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7.0.1
22
22
  with:
23
23
  name: dist
24
24
  path: dist/
@@ -42,8 +42,8 @@ jobs:
42
42
  name: dist
43
43
  path: dist/
44
44
  - name: Generate attestations
45
- uses: actions/attest-build-provenance@a2bbfa25375fe432b6a289bc6b6cd05ecd0c4c32 # v4.1.0
45
+ uses: actions/attest-build-provenance@0f67c3f4856b2e3261c31976d6725780e5e4c373 # v4.1.1
46
46
  with:
47
47
  subject-path: dist/*
48
48
  - name: Publish to PyPI
49
- uses: pypa/gh-action-pypi-publish@release/v1
49
+ uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # v1.14.0
@@ -41,3 +41,11 @@ profiles.yaml
41
41
  .pytest_cache/
42
42
  .coverage
43
43
  htmlcov/
44
+
45
+ # Project-specific
46
+ CLAUDE.md
47
+ graphify-out/
48
+
49
+ # Claude Code
50
+ .claude/settings.json
51
+ .mcp.json
@@ -0,0 +1,7 @@
1
+ repos:
2
+ - repo: https://github.com/astral-sh/ruff-pre-commit
3
+ rev: 971923581912ef60a6b70dbf0c3e9a39563c9d47 # v0.11.4
4
+ hooks:
5
+ - id: ruff
6
+ args: [--fix]
7
+ - id: ruff-format
@@ -4,6 +4,41 @@ All notable changes to this project will be documented in this file.
4
4
 
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/).
6
6
 
7
+ ## [0.5.1] - 2026-07-04
8
+
9
+ ### Fixed
10
+
11
+ - Ingest YAML OpenAPI specs served as `application/vnd.oai.openapi` (e.g. Codecov's schema endpoint), with a YAML fallback when a body advertised as JSON fails to decode (#22)
12
+ - `--version` now derives from installed package metadata instead of a hardcoded literal that had drifted from the real version (#22)
13
+
14
+ ### Changed
15
+
16
+ - Commit `uv.lock` and use `uv sync --locked` in CI for reproducible builds; Dependabot now updates the lockfile via the `uv` ecosystem (#20)
17
+ - Dependency updates: `typer` 0.26 (with test adjustments for its vendored `click`), plus the python-deps and GitHub Actions groups (#21, #19, #16)
18
+
19
+ ## [0.5.0] - 2026-04-21
20
+
21
+ ### Added
22
+
23
+ - `--force-login` flag to bypass cached tokens (#9)
24
+ - Non-interactive `init` flags for scripted profile creation (#9)
25
+ - Security hardening across CLI surfaces (#10)
26
+ - OpenAPI spec composition support (#10)
27
+ - `py.typed` marker for downstream type checkers (#13)
28
+
29
+ ### Changed
30
+
31
+ - SHA-pinned publish workflow and simplified CI (#13)
32
+ - Dependency updates: `rich` (#12), GitHub Actions group (#11)
33
+
34
+ ## [0.4.0] - 2026-04-15
35
+
36
+ ### Added
37
+
38
+ - OIDC Device Flow auth type for headless/SSH environments
39
+ - Token exchange and auto-discovery of OIDC endpoints
40
+ - Token injection from environment for CI use cases
41
+
7
42
  ## [0.3.0] - 2026-03-28
8
43
 
9
44
  ### Added
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: openapi-cli4ai
3
- Version: 0.4.0
3
+ Version: 0.5.1
4
4
  Summary: Turn any REST API with an OpenAPI spec into an AI-ready CLI
5
5
  Project-URL: Homepage, https://github.com/dbgorilla/openapi-cli4ai
6
6
  Project-URL: Repository, https://github.com/dbgorilla/openapi-cli4ai
@@ -21,7 +21,7 @@ Requires-Python: >=3.11
21
21
  Requires-Dist: httpx<1,>=0.28
22
22
  Requires-Dist: python-dotenv<2,>=1.0
23
23
  Requires-Dist: pyyaml<7,>=6
24
- Requires-Dist: rich<15,>=13
24
+ Requires-Dist: rich<16,>=13
25
25
  Requires-Dist: tomli-w<2,>=1.0
26
26
  Requires-Dist: typer<1,>=0.24
27
27
  Description-Content-Type: text/markdown
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "openapi-cli4ai"
7
- version = "0.4.0"
7
+ version = "0.5.1"
8
8
  description = "Turn any REST API with an OpenAPI spec into an AI-ready CLI"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -26,7 +26,7 @@ classifiers = [
26
26
  dependencies = [
27
27
  "typer>=0.24,<1",
28
28
  "httpx>=0.28,<1",
29
- "rich>=13,<15",
29
+ "rich>=13,<16",
30
30
  "pyyaml>=6,<7",
31
31
  "python-dotenv>=1.0,<2",
32
32
  "tomli-w>=1.0,<2",
@@ -40,6 +40,15 @@ Issues = "https://github.com/dbgorilla/openapi-cli4ai/issues"
40
40
  [project.scripts]
41
41
  openapi-cli4ai = "openapi_cli4ai.cli:app"
42
42
 
43
+ [dependency-groups]
44
+ dev = [
45
+ "pytest>=8",
46
+ "pytest-cov>=5",
47
+ "click>=8,<9",
48
+ "mypy>=1.10,<3",
49
+ "types-PyYAML>=6,<7",
50
+ ]
51
+
43
52
  [tool.hatch.build.targets.wheel]
44
53
  packages = ["src/openapi_cli4ai"]
45
54
 
@@ -50,3 +59,17 @@ target-version = "py311"
50
59
  [tool.pytest.ini_options]
51
60
  testpaths = ["tests"]
52
61
  markers = ["integration: live API tests (may be slow)"]
62
+
63
+ [tool.mypy]
64
+ python_version = "3.11"
65
+ warn_return_any = false
66
+ warn_unused_configs = true
67
+ disallow_untyped_defs = false
68
+ check_untyped_defs = true
69
+
70
+ [tool.coverage.run]
71
+ source = ["openapi_cli4ai"]
72
+
73
+ [tool.coverage.report]
74
+ show_missing = true
75
+ skip_empty = true