indiek-api 0.17.0__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 (47) hide show
  1. indiek_api-0.17.0/.gitignore +6 -0
  2. indiek_api-0.17.0/CHANGELOG.md +192 -0
  3. indiek_api-0.17.0/LICENSE +201 -0
  4. indiek_api-0.17.0/PKG-INFO +343 -0
  5. indiek_api-0.17.0/README.md +322 -0
  6. indiek_api-0.17.0/indiek_api/__init__.py +3 -0
  7. indiek_api-0.17.0/indiek_api/__main__.py +3 -0
  8. indiek_api-0.17.0/indiek_api/app.py +409 -0
  9. indiek_api-0.17.0/indiek_api/archive_service.py +294 -0
  10. indiek_api-0.17.0/indiek_api/errors.py +173 -0
  11. indiek_api-0.17.0/indiek_api/identity.py +123 -0
  12. indiek_api-0.17.0/indiek_api/providers.py +59 -0
  13. indiek_api-0.17.0/indiek_api/schemas.py +208 -0
  14. indiek_api-0.17.0/indiek_api/security.py +251 -0
  15. indiek_api-0.17.0/indiek_api/settings.py +69 -0
  16. indiek_api-0.17.0/indiek_api/workspaces.py +192 -0
  17. indiek_api-0.17.0/pyproject.toml +56 -0
  18. indiek_api-0.17.0/tests/conftest.py +173 -0
  19. indiek_api-0.17.0/tests/fixtures/build_demo_archive.sh +48 -0
  20. indiek_api-0.17.0/tests/fixtures/demo_archive/MANIFEST.json +1171 -0
  21. indiek_api-0.17.0/tests/fixtures/demo_archive/SPEC.md +605 -0
  22. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/11/a8/11a80941fece5f6fd480b76d7015870858bd42d11cc46b55b2417d76be13f17c +0 -0
  23. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/18/53/1853ac3ef763440e6fa1e68cfcdf5ec55214b7bbc93cd8b34a832e5690ba9ec9 +1 -0
  24. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/1a/a1/1aa1d991d8773a2881368de5de01ad7c16ad74ad8b6ccfcec065b52882d58803 +1 -0
  25. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/57/28/57288bce85e8af9225997774724090492bf5b2fa0c78e5359cd945b23103d292 +1 -0
  26. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/6d/f4/6df47bb83389b44722616d623a376b0ce767c3cd35907e8d359b1e7f70130ef3 +1 -0
  27. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/6e/69/6e695ac6706d6c41b9b20c4229caf026588b7453124ecc3797d45e5059384f1d +1 -0
  28. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/71/a0/71a0b54b349d9f8a95d6bb621386c3cb939b0a711dbf4e746e3031c38b4104f5 +1 -0
  29. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/83/7a/837a9bf57d25b2132dfd8b137c689a189894bdeaad049858b61fb171eaa48670 +1 -0
  30. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/89/4d/894dfdf532a4f1ec9c485cc3040f68c99d6ab2be89aea0581991ffb3e0beef56 +1 -0
  31. indiek_api-0.17.0/tests/fixtures/demo_archive/blobs/sha256/92/3b/923b4b90ea64343e4a1cc2386c52fb2c0d197b0673cffbf1197169c27c8e4eb9 +1 -0
  32. indiek_api-0.17.0/tests/fixtures/demo_archive/events/2026/10/21/events.ndjson +12 -0
  33. indiek_api-0.17.0/tests/fixtures/demo_archive/meta/events/2026/10/21/events.ndjson +6 -0
  34. indiek_api-0.17.0/tests/fixtures/demo_archive/test_vectors.json +318 -0
  35. indiek_api-0.17.0/tests/fixtures/demo_sources/Proof.md +1 -0
  36. indiek_api-0.17.0/tests/fixtures/demo_sources/andtext.txt +1 -0
  37. indiek_api-0.17.0/tests/fixtures/demo_sources/atiffimage.tiff +0 -0
  38. indiek_api-0.17.0/tests/fixtures/demo_sources/diagram.png +0 -0
  39. indiek_api-0.17.0/tests/fixtures/demo_sources/statement.txt +1 -0
  40. indiek_api-0.17.0/tests/test_api.py +370 -0
  41. indiek_api-0.17.0/tests/test_archive_service.py +219 -0
  42. indiek_api-0.17.0/tests/test_cli_parity.py +291 -0
  43. indiek_api-0.17.0/tests/test_desktop_seams.py +211 -0
  44. indiek_api-0.17.0/tests/test_errors.py +41 -0
  45. indiek_api-0.17.0/tests/test_identity.py +196 -0
  46. indiek_api-0.17.0/tests/test_security.py +275 -0
  47. indiek_api-0.17.0/tests/test_write_lock.py +60 -0
@@ -0,0 +1,6 @@
1
+ *code-workspace
2
+ .env*
3
+ __pycache__
4
+ .venv/
5
+ .ruff_cache/
6
+ .pytest_cache/
@@ -0,0 +1,192 @@
1
+ # Changelog
2
+
3
+ ## Unreleased
4
+
5
+ Standalone repository, ready for PyPI as `indiek-api` (DESKTOP:REPO-SPLIT-1). No version bump yet:
6
+ the owner releases `indiek-api` **1.0.0** on PyPI together with the first packaged desktop app.
7
+
8
+ ## 0.17.0 — 2026-11-01
9
+
10
+ ### Changed
11
+ - `indiek` now comes from PyPI (`indiek[keychain]>=1.3.0`, pinned in `uv.lock`) instead of the
12
+ sibling `../public_archive` path source, so a fresh clone of this repo installs on its own.
13
+ Unreleased library work: `uv run --with-editable ../public_archive …` (README section 1).
14
+ - README: links to the `indiek` library point to PyPI instead of workspace-relative paths.
15
+
16
+ ### Added
17
+ - Desktop shell seams (DESKTOP:REPO-SPLIT-3, owner decisions 2026-10-30; the Tauri webview opens
18
+ the UI served here, so the frontend needs no change):
19
+ - `--handshake`: one JSON line `{"indiek_api", "port", "launch_url"}` on stdout, no browser;
20
+ all logs, including uvicorn's access log, go to stderr.
21
+ - `--exit-on-stdin-eof`: the server stops when its parent closes stdin.
22
+ - `GET /health` also returns `api_version`.
23
+ - Reuse seams (DESKTOP:REUSE-SEAMS): new `indiek_api/providers.py` with the `WorkspaceProvider`,
24
+ `Signer` and `KeyManager` protocols; `create_app(settings, *, workspaces=None, signer=None)`.
25
+ Defaults unchanged (`WorkspaceRegistry`, `KeyProvider`). The `/api/identity/*` routes are
26
+ mounted only when the signer is a `KeyManager` (moved into `_add_identity_routes`).
27
+ - Tests: `tests/test_desktop_seams.py` (7, one runs the real server as a subprocess).
28
+ Suite: 138 passed.
29
+ - Packaging metadata in `pyproject.toml`: hatchling build backend, Apache-2.0 license + `LICENSE`
30
+ file, classifiers, project URLs (stub `github.com/indiek/fastAPI`, not on GitHub yet), console
31
+ script `indiek-api` (same as `python -m indiek_api`). The sdist uses an explicit allow-list so
32
+ local files such as `.env*` are never shipped.
33
+ - CI: `.github/workflows/checks.yml` (ruff + pytest on every push and pull request) and
34
+ `.github/workflows/release-and-publish.yml` (on a version tag pushed by the owner: lint, test,
35
+ `uv build`, GitHub Release, PyPI trusted publishing).
36
+ - README: "Support IndieK" section with GitHub Sponsors (`indiek` org) and Ko-fi (`indiek_sponsoring`) links (FOSSDOCS:DONATION-INSTRUCTIONS).
37
+
38
+ ## 0.16.0 — 2026-10-25
39
+
40
+ Signing identity for the desktop app (DESKTOP:KEY-ONBOARDING); requires `indiek[keychain]>=1.3.0`.
41
+
42
+ ### Added
43
+ - `indiek_api/identity.py`: `KeyProvider`, the API's signing seam (DESKTOP:REUSE-SEAMS):
44
+ `IK_AUTHOR_PRIVATE_KEY` (re-read on every call) wins, else the OS-keychain key via
45
+ `indiek.keys`, read once and cached (no keychain prompt per write), refreshed after every
46
+ identity change. All write routes sign through it.
47
+ - Routes: `GET /api/identity`, `POST /api/identity/generate`, `POST /api/identity/import`
48
+ (`seed_hex` or encrypted `backup` + `password`), `POST /api/identity/backup` (encrypted file
49
+ download, `Cache-Control: no-store`). The plaintext seed is never returned; the "exactly one
50
+ source" check lives in the route so validation errors never echo a secret.
51
+ - Error codes: `409 key_exists`, `422 invalid_key`, `422 invalid_backup`, `422 weak_password`,
52
+ `503 keychain_unavailable`.
53
+ - Tests: `tests/test_identity.py` (13); autouse in-memory keychain + minimal Argon2id cost in
54
+ `conftest.py`. 130 passed.
55
+
56
+ ### Changed
57
+ - `Settings.author()` / `author_or_none()` removed (replaced by `KeyProvider`).
58
+ - `503 author_key_missing` message now points to the app's Author key dialog.
59
+
60
+ ## 0.15.0 — 2026-10-25
61
+
62
+ Access control for the local API (DESKTOP:LOCALHOST-TOKEN). Design, threats and owner decisions:
63
+ `project_management/Design.md`, cybersecurity section.
64
+
65
+ ### Added
66
+ - `indiek_api/security.py`: `AccessControlMiddleware` (pure ASGI). Loopback `Host` only
67
+ (`400 invalid_host`); per-launch token on every `/api/*` route, as `Authorization: Bearer` or
68
+ the HttpOnly SameSite=Strict cookie `ik_session_<port>` (`401 unauthorized`); writes also need
69
+ `X-IndieK-Request: 1` (`403 missing_request_header`). Tokens compared with `hmac.compare_digest`.
70
+ - `GET /api/session?token=…`: single-use launch token → session cookie, `303 → /`
71
+ (`Cache-Control: no-store`, `Referrer-Policy: no-referrer`).
72
+ - Strict `Content-Security-Policy` on every response, `script-src 'self'` + the SHA-256 of each
73
+ inline script of the static UI computed at startup (11 in today's build); sandboxed policy for
74
+ blobs; `X-Content-Type-Options: nosniff`. `INDIEK_API_CSP_REPORT_ONLY=1` for debugging.
75
+ - Launcher: `python -m indiek_api` binds a random free port, prints the launch URL and opens it
76
+ in the default browser; `--no-browser` / `INDIEK_API_OPEN_BROWSER=0` disable the auto-open.
77
+ - `INDIEK_API_TOKEN`: fixed, reusable token for development and tests (≥ 16 characters).
78
+ - Tests: `tests/test_security.py` (26, incl. a check of the real `next build` output when
79
+ present); the shared client now authenticates like the UI (`api_client()`, `TEST_TOKEN`). 117 passed.
80
+
81
+ ### Changed
82
+ - Default port: random (was 8000); `INDIEK_API_PORT` still fixes it.
83
+ - **Breaking for other clients**: every `/api/*` call needs the token; writes need the header.
84
+
85
+ ## 0.14.0 — 2026-10-25
86
+
87
+ Follows `indiek` 1.2.0 (SDK2:WRITE-LOCK); now requires `indiek>=1.2.0`.
88
+
89
+ ### Added
90
+ - `409 archive_locked`: the SDK's new `ArchiveLockedError` (another process, e.g. the `ik`
91
+ CLI, held `<archive>/.ik.lock` for more than 10 s) is mapped by type
92
+ (`ArchiveLockedAPIError`). It used to fall through to `422 archive_rule`.
93
+ - Writes from the API and from `ik` on the same archive no longer fork the log: the SDK
94
+ serialises them across processes (the in-process `threading.RLock` only covered the API's
95
+ own threads). No route or service change was needed.
96
+ - Tests: mapping case in `tests/test_errors.py`; new `tests/test_write_lock.py` (a write
97
+ while another process holds the lock → 409, archive unchanged, reads still work, next
98
+ write succeeds). 91 passed.
99
+
100
+ ## 0.13.0 — 2026-10-22
101
+
102
+ Follows `indiek` 1.1.0 and the format 3.1.
103
+
104
+ ### Added
105
+ - Edges without content (indiek format 3.1): `POST …/edges` accepts `content` omitted or
106
+ `null`; `PUT …/edges/{id}` without `content` (or `null`) removes an edge's content, and a
107
+ later `PUT` with text restores it. An empty string is still `422`.
108
+ - `EdgeOut.resource_type` in `GET …/graph`: `"managed"`, or `"none"` for an edge without
109
+ content (whose `content`, `media_type` and `blob_hash` are `null`). The web UI ignores it
110
+ for now (`src/lib/types.ts` not updated; WebUI out of scope).
111
+ - Tests: content-less edges (create, supersede both ways, events stamped `3.1`), edge
112
+ `resource_type`, and a `local_file` `.pdf` node (detected as
113
+ `application/pdf; profile=pdfa` by indiek 1.1.0; no API change was needed).
114
+
115
+ ## 0.12.0 — 2026-10-21
116
+
117
+ ### Changed
118
+ - `POST /api/workspaces` only registers IndieK archives (a folder holding
119
+ `MANIFEST.json`, `events/` or `meta/events/`). A folder that is not an archive but
120
+ has exactly one archive subfolder (e.g. a git repo with the archive in `kg/`)
121
+ registers that subfolder; with several it answers `409 ambiguous_archive` plus a
122
+ `candidates` list; with none `422 not_an_archive`. Nothing is written in either case
123
+ (previously any existing folder was accepted as an empty archive).
124
+
125
+ ### Added
126
+ - `POST /api/workspaces {path, create: true}` initialises a new archive (MANIFEST.json,
127
+ SPEC.md via the SDK) in a folder that is empty apart from hidden entries such as
128
+ `.git`; a missing folder is created when its parent exists (`404` "Parent folder
129
+ does not exist" otherwise, nothing created), listing the configured author if `IK_AUTHOR_PRIVATE_KEY` is set;
130
+ `409 folder_not_empty` otherwise.
131
+ - Error responses may carry extra fields (`IndieKAPIError.extra()`).
132
+
133
+ ## 0.11.0 — 2026-10-21
134
+
135
+ ### Changed
136
+ - Ported to the `indiek` SDK facade (`indiek.Archive`, `indiek.Author`): the API no
137
+ longer imports the legacy `indiek.blob` / `create_*` / `set_tag` modules, which
138
+ were removed upstream. Archives must use format `3.0`; any other version answers
139
+ `409 archive_integrity`.
140
+ - Archives are opened at the SDK's default `incremental` verification level, backed
141
+ by the per-machine verification cache (`IK_CACHE_DIR`, outside the archive).
142
+ - SDK errors are mapped by exception type instead of message substrings:
143
+ `AuthorshipError` → 403 `forbidden`, `UnknownItemError` → 404 `item_not_found`,
144
+ `IntegrityError` → 409 `archive_integrity`, other rule/validation errors → 422
145
+ `archive_rule`.
146
+ - `PUT …/edges/{id}` with the ID of a node (and vice versa) now answers 404
147
+ `item_not_found` (was 422): the ID does not name an item of that kind.
148
+ - `ArchiveService.write(author, operation)` passes an `indiek.Archive` to
149
+ `operation`; `ArchiveService.create()` and `.index()` are gone (SDK writes return
150
+ the new item's UUID). `Settings.author()` replaces `Settings.author_credentials()`.
151
+
152
+ ### Tests
153
+ - Demo fixture rebuilt in format 3.0 by `tests/fixtures/build_demo_archive.sh`
154
+ (drives the `ik` CLI from `tests/fixtures/demo_sources/`, throwaway key).
155
+ - Tests isolate the SDK verification cache per test (`IK_CACHE_DIR` under `tmp_path`).
156
+ - New `tests/test_errors.py` for the error mapping.
157
+
158
+ ## 0.10.0 — 2026-10-12
159
+
160
+ ### Changed (breaking)
161
+ - Code moved into the `indiek_api` package; run with `uv run python -m indiek_api`.
162
+ - All archive routes are scoped as `/api/workspaces/{workspace_id}/…`; the
163
+ `network_id` query parameter is gone and `network_id` is now `workspace_id`.
164
+ - `GET …/graph` returns nodes, edges **and** tags in one payload (replaces `/api/tags`),
165
+ with `e{n}`/`m{n}` aliases, tag kinds and a `revised` flag for superseded items.
166
+ - Write endpoints return the created item as `{id, alias}`; tag assignment returns
167
+ the target's tags.
168
+ - Errors are `{"detail", "code"}` with deliberate status codes (404 / 403 / 409 / 422 / 503).
169
+
170
+ ### Added
171
+ - Local-folder workspaces edited in place, persisted in `~/.indiek/workspaces.json`;
172
+ `DELETE /api/workspaces/{id}` forgets a folder without touching its files.
173
+ - Settings via `INDIEK_API_*` variables; optional serving of the built web UI at `/`.
174
+ - Test suite (pytest + TestClient) on throwaway archives and a CLI-built demo archive.
175
+ - `uri` and `local_file` nodes via `POST …/nodes` (`resource_type`, default `managed`).
176
+ - `PUT …/edges/{id}` supersedes an edge's text (endpoints never change).
177
+ - `GET …/events`: base and meta event logs in log order (the `ik read` equivalent).
178
+ - `created_at` / `updated_at` on nodes, edges and tags; edges carry their text as `content`.
179
+
180
+ ### Fixed
181
+ - The API could not be installed: it depended on `ik`, renamed `indiek` upstream.
182
+ - A tampered or corrupt archive was shown as an empty graph (and cached); it now
183
+ answers `409 archive_integrity` with the library's message.
184
+ - Concurrent writes could fork the event chain; writes are serialised per workspace.
185
+ - The archive is re-verified when its event logs change on disk (CLI or `git pull`).
186
+ - `python main.py` listened on `0.0.0.0`; the server now binds `127.0.0.1` only.
187
+ - Tag creation accepted an empty description, which the CLI forbids.
188
+
189
+ ### Removed
190
+ - URL and ZIP-upload workspaces and the `.workspaces/` cache folder.
191
+ - Dependencies `networkx`, `pillow`, `starlette` (direct), `python-multipart`.
192
+ - No GraphML export: the UI works from the live API, not from `ik export` files.
@@ -0,0 +1,201 @@
1
+ Apache License
2
+ Version 2.0, January 2004
3
+ http://www.apache.org/licenses/
4
+
5
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6
+
7
+ 1. Definitions.
8
+
9
+ "License" shall mean the terms and conditions for use, reproduction,
10
+ and distribution as defined by Sections 1 through 9 of this document.
11
+
12
+ "Licensor" shall mean the copyright owner or entity authorized by
13
+ the copyright owner that is granting the License.
14
+
15
+ "Legal Entity" shall mean the union of the acting entity and all
16
+ other entities that control, are controlled by, or are under common
17
+ control with that entity. For the purposes of this definition,
18
+ "control" means (i) the power, direct or indirect, to cause the
19
+ direction or management of such entity, whether by contract or
20
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
21
+ outstanding shares, or (iii) beneficial ownership of such entity.
22
+
23
+ "You" (or "Your") shall mean an individual or Legal Entity
24
+ exercising permissions granted by this License.
25
+
26
+ "Source" form shall mean the preferred form for making modifications,
27
+ including but not limited to software source code, documentation
28
+ source, and configuration files.
29
+
30
+ "Object" form shall mean any form resulting from mechanical
31
+ transformation or translation of a Source form, including but
32
+ not limited to compiled object code, generated documentation,
33
+ and conversions to other media types.
34
+
35
+ "Work" shall mean the work of authorship, whether in Source or
36
+ Object form, made available under the License, as indicated by a
37
+ copyright notice that is included in or attached to the work
38
+ (an example is provided in the Appendix below).
39
+
40
+ "Derivative Works" shall mean any work, whether in Source or Object
41
+ form, that is based on (or derived from) the Work and for which the
42
+ editorial revisions, annotations, elaborations, or other modifications
43
+ represent, as a whole, an original work of authorship. For the purposes
44
+ of this License, Derivative Works shall not include works that remain
45
+ separable from, or merely link (or bind by name) to the interfaces of,
46
+ the Work and Derivative Works thereof.
47
+
48
+ "Contribution" shall mean any work of authorship, including
49
+ the original version of the Work and any modifications or additions
50
+ to that Work or Derivative Works thereof, that is intentionally
51
+ submitted to Licensor for inclusion in the Work by the copyright owner
52
+ or by an individual or Legal Entity authorized to submit on behalf of
53
+ the copyright owner. For the purposes of this definition, "submitted"
54
+ means any form of electronic, verbal, or written communication sent
55
+ to the Licensor or its representatives, including but not limited to
56
+ communication on electronic mailing lists, source code control systems,
57
+ and issue tracking systems that are managed by, or on behalf of, the
58
+ Licensor for the purpose of discussing and improving the Work, but
59
+ excluding communication that is conspicuously marked or otherwise
60
+ designated in writing by the copyright owner as "Not a Contribution."
61
+
62
+ "Contributor" shall mean Licensor and any individual or Legal Entity
63
+ on behalf of whom a Contribution has been received by Licensor and
64
+ subsequently incorporated within the Work.
65
+
66
+ 2. Grant of Copyright License. Subject to the terms and conditions of
67
+ this License, each Contributor hereby grants to You a perpetual,
68
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69
+ copyright license to reproduce, prepare Derivative Works of,
70
+ publicly display, publicly perform, sublicense, and distribute the
71
+ Work and such Derivative Works in Source or Object form.
72
+
73
+ 3. Grant of Patent License. Subject to the terms and conditions of
74
+ this License, each Contributor hereby grants to You a perpetual,
75
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76
+ (except as stated in this section) patent license to make, have made,
77
+ use, offer to sell, sell, import, and otherwise transfer the Work,
78
+ where such license applies only to those patent claims licensable
79
+ by such Contributor that are necessarily infringed by their
80
+ Contribution(s) alone or by combination of their Contribution(s)
81
+ with the Work to which such Contribution(s) was submitted. If You
82
+ institute patent litigation against any entity (including a
83
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
84
+ or a Contribution incorporated within the Work constitutes direct
85
+ or contributory patent infringement, then any patent licenses
86
+ granted to You under this License for that Work shall terminate
87
+ as of the date such litigation is filed.
88
+
89
+ 4. Redistribution. You may reproduce and distribute copies of the
90
+ Work or Derivative Works thereof in any medium, with or without
91
+ modifications, and in Source or Object form, provided that You
92
+ meet the following conditions:
93
+
94
+ (a) You must give any other recipients of the Work or
95
+ Derivative Works a copy of this License; and
96
+
97
+ (b) You must cause any modified files to carry prominent notices
98
+ stating that You changed the files; and
99
+
100
+ (c) You must retain, in the Source form of any Derivative Works
101
+ that You distribute, all copyright, patent, trademark, and
102
+ attribution notices from the Source form of the Work,
103
+ excluding those notices that do not pertain to any part of
104
+ the Derivative Works; and
105
+
106
+ (d) If the Work includes a "NOTICE" text file as part of its
107
+ distribution, then any Derivative Works that You distribute must
108
+ include a readable copy of the attribution notices contained
109
+ within such NOTICE file, excluding those notices that do not
110
+ pertain to any part of the Derivative Works, in at least one
111
+ of the following places: within a NOTICE text file distributed
112
+ as part of the Derivative Works; within the Source form or
113
+ documentation, if provided along with the Derivative Works; or,
114
+ within a display generated by the Derivative Works, if and
115
+ wherever such third-party notices normally appear. The contents
116
+ of the NOTICE file are for informational purposes only and
117
+ do not modify the License. You may add Your own attribution
118
+ notices within Derivative Works that You distribute, alongside
119
+ or as an addendum to the NOTICE text from the Work, provided
120
+ that such additional attribution notices cannot be construed
121
+ as modifying the License.
122
+
123
+ You may add Your own copyright statement to Your modifications and
124
+ may provide additional or different license terms and conditions
125
+ for use, reproduction, or distribution of Your modifications, or
126
+ for any such Derivative Works as a whole, provided Your use,
127
+ reproduction, and distribution of the Work otherwise complies with
128
+ the conditions stated in this License.
129
+
130
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
131
+ any Contribution intentionally submitted for inclusion in the Work
132
+ by You to the Licensor shall be under the terms and conditions of
133
+ this License, without any additional terms or conditions.
134
+ Notwithstanding the above, nothing herein shall supersede or modify
135
+ the terms of any separate license agreement you may have executed
136
+ with Licensor regarding such Contributions.
137
+
138
+ 6. Trademarks. This License does not grant permission to use the trade
139
+ names, trademarks, service marks, or product names of the Licensor,
140
+ except as required for reasonable and customary use in describing the
141
+ origin of the Work and reproducing the content of the NOTICE file.
142
+
143
+ 7. Disclaimer of Warranty. Unless required by applicable law or
144
+ agreed to in writing, Licensor provides the Work (and each
145
+ Contributor provides its Contributions) on an "AS IS" BASIS,
146
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147
+ implied, including, without limitation, any warranties or conditions
148
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149
+ PARTICULAR PURPOSE. You are solely responsible for determining the
150
+ appropriateness of using or redistributing the Work and assume any
151
+ risks associated with Your exercise of permissions under this License.
152
+
153
+ 8. Limitation of Liability. In no event and under no legal theory,
154
+ whether in tort (including negligence), contract, or otherwise,
155
+ unless required by applicable law (such as deliberate and grossly
156
+ negligent acts) or agreed to in writing, shall any Contributor be
157
+ liable to You for damages, including any direct, indirect, special,
158
+ incidental, or consequential damages of any character arising as a
159
+ result of this License or out of the use or inability to use the
160
+ Work (including but not limited to damages for loss of goodwill,
161
+ work stoppage, computer failure or malfunction, or any and all
162
+ other commercial damages or losses), even if such Contributor
163
+ has been advised of the possibility of such damages.
164
+
165
+ 9. Accepting Warranty or Additional Liability. While redistributing
166
+ the Work or Derivative Works thereof, You may choose to offer,
167
+ and charge a fee for, acceptance of support, warranty, indemnity,
168
+ or other liability obligations and/or rights consistent with this
169
+ License. However, in accepting such obligations, You may act only
170
+ on Your own behalf and on Your sole responsibility, not on behalf
171
+ of any other Contributor, and only if You agree to indemnify,
172
+ defend, and hold each Contributor harmless for any liability
173
+ incurred by, or claims asserted against, such Contributor by reason
174
+ of your accepting any such warranty or additional liability.
175
+
176
+ END OF TERMS AND CONDITIONS
177
+
178
+ APPENDIX: How to apply the Apache License to your work.
179
+
180
+ To apply the Apache License to your work, attach the following
181
+ boilerplate notice, with the fields enclosed by brackets "[]"
182
+ replaced with your own identifying information. (Don't include
183
+ the brackets!) The text should be enclosed in the appropriate
184
+ comment syntax for the file format. We also recommend that a
185
+ file or class name and description of purpose be included on the
186
+ same "printed page" as the copyright notice for easier
187
+ identification within third-party archives.
188
+
189
+ Copyright 2026 Adrian Ernesto Radillo
190
+
191
+ Licensed under the Apache License, Version 2.0 (the "License");
192
+ you may not use this file except in compliance with the License.
193
+ You may obtain a copy of the License at
194
+
195
+ http://www.apache.org/licenses/LICENSE-2.0
196
+
197
+ Unless required by applicable law or agreed to in writing, software
198
+ distributed under the License is distributed on an "AS IS" BASIS,
199
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
200
+ See the License for the specific language governing permissions and
201
+ limitations under the License.