Commit f1cfdef
feat(api): API endpoint for language-specific project translation download (#17204)
* added the multi download functionality with tests
* Add regex filter for project language file downloads
Introduces a 'filter' query parameter to the project language file API endpoint, allowing users to filter components by slug using a regular expression. Includes validation for invalid regex patterns and corresponding tests to ensure correct filtering and error handling.
* added test for no translations for requested language
* Draft One of API doc
* Initial draft of api documentation
* Initial commit to test
* Drafted API documentation in api.rst
* Updated changes.rst
* Added new versionchanged number in api.rst
* Updated api.rst documentation to reflect error codes
* Updated changes.rst to reflect that API endpoint generates a ZIP file
* final touchups to api docs
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* fixed typo
* chore(docs): update OpenAPI schema
* Update docs/api.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update weblate/api/views.py
Co-authored-by: Michal Čihař <michal@cihar.com>
* Update docs/api.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update docs/api.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update docs/api.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Update docs/changes.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Refactor component filtering in API views and tests for improved clarity and functionality
* created helper attach_component and updated filter_invalid test
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* removed reimport of data_dir
* fix: write file bytes from the fixture path instead of string path
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Replaced old api.rst file
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* Update docs/api.rst
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
* Addressing Co-Pilot comment about adding 200 OK note in api.rst
* Updated syntax of error and success notes in api.rst
* Small fixes to error and success notes in api.rst
* [pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
* added an explicit OpenAPI parameter definition for language_code
* updated release notes to point to correct endpoint
* redone zip contents and path filter test; added new unsupported file format test
* chore(docs): update OpenAPI schema
* Update changelog
* Apply suggestion from @nijel
---------
Co-authored-by: Edison Dao <164945428+cmukdao@users.noreply.github.com>
Co-authored-by: ZhuHengjin <HengjinZhu@iCloud.com>
Co-authored-by: Edison <kdao@andrew.cmu.edu>
Co-authored-by: aditi-agni <aditiagni1@gmail.com>
Co-authored-by: aditi <152739362+aditi-agni@users.noreply.github.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
Co-authored-by: pre-commit-ci-lite[bot] <117423508+pre-commit-ci-lite[bot]@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Michal Čihař <michal@cihar.com>
Co-authored-by: Edison <edictory@LAPTOP-8DAPF4PK>
Co-authored-by: Michal Čihař <michal@weblate.org>1 parent 87f612b commit f1cfdef
File tree
5 files changed
+581
-2
lines changed- docs
- specs
- weblate/api
5 files changed
+581
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1329 | 1329 | | |
1330 | 1330 | | |
1331 | 1331 | | |
| 1332 | + | |
| 1333 | + | |
| 1334 | + | |
| 1335 | + | |
| 1336 | + | |
| 1337 | + | |
| 1338 | + | |
| 1339 | + | |
| 1340 | + | |
| 1341 | + | |
| 1342 | + | |
| 1343 | + | |
| 1344 | + | |
| 1345 | + | |
| 1346 | + | |
| 1347 | + | |
| 1348 | + | |
| 1349 | + | |
| 1350 | + | |
| 1351 | + | |
| 1352 | + | |
| 1353 | + | |
1332 | 1354 | | |
1333 | 1355 | | |
1334 | 1356 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
8 | 10 | | |
9 | 11 | | |
10 | 12 | | |
| |||
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
0 commit comments