Skip to content

Commit 39ba3b7

Browse files
committed
feat(hooks): modernize hooks implementation
- Based on Django REST Framework - Exposed in OpenAPI - Dropped years deprecated endpoints
1 parent 8e31b40 commit 39ba3b7

10 files changed

Lines changed: 12288 additions & 11453 deletions

File tree

docs/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ update-schemas:
4040
@cp $$(uv run --no-sync ../scripts/get-schemas-dir.py)/schemas/* specs/schemas/
4141

4242
update-openapi:
43-
@WEBLATE_HIDE_VERSION=1 uv run --no-sync ../manage.py spectacular --skip-checks --fail-on-warn --validate --urlconf="weblate.api.urls" > specs/openapi.yaml
43+
@WEBLATE_HIDE_VERSION=1 uv run --no-sync ../manage.py spectacular --skip-checks --fail-on-warn --validate > specs/openapi.yaml
4444

4545
update-po: $(wildcard locales/*/LC_MESSAGES/docs.po)
4646

docs/api.rst

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2845,8 +2845,7 @@ update individual repositories; see
28452845
Please use :http:post:`/api/components/(string:project)/(string:component)/repository/`
28462846
instead which works properly with authentication for ACL limited projects.
28472847

2848-
Triggers update of a component (pulling from VCS and scanning for
2849-
translation changes).
2848+
.. versionremoved:: 5.14
28502849

28512850
.. http:get:: /hooks/update/(string:project)/
28522851
@@ -2855,8 +2854,7 @@ update individual repositories; see
28552854
Please use :http:post:`/api/projects/(string:project)/repository/`
28562855
instead which works properly with authentication for ACL limited projects.
28572856

2858-
Triggers update of all components in a project (pulling from VCS and
2859-
scanning for translation changes).
2857+
.. versionremoved:: 5.14
28602858

28612859
.. http:post:: /hooks/github/
28622860

docs/changes.rst

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,10 @@ Weblate 5.14
1212
.. rubric:: Improvements
1313

1414
* New global permissions have been added to control viewing teams, users and roles without edit rights, see :ref:`privileges`.
15-
15+
* :ref:`hooks` improvements.
16+
* Now follows :ref:`api-errors`.
17+
* Available in the OpenAPI.
18+
* Dropped long-deprecated endpoints.
1619
* :ref:`date-search`.
1720
* Last changed loookup in :ref:`search-strings`.
1821

@@ -24,6 +27,7 @@ Weblate 5.14
2427
.. rubric:: Compatibility
2528

2629
* The default attributes for :ref:`saml-auth` in Docker container now matches non-Docker defaults.
30+
* Dropped long-deprecated :http:get:`/hooks/update/(string:project)/(string:component)/` and :http:get:`/hooks/update/(string:project)/`.
2731

2832
.. rubric:: Upgrading
2933

0 commit comments

Comments
 (0)