zulip/zerver/openapi
Lauryn Menard ebfe9637c8 subscribe-unsubscribe: Improve error response for unexpected users.
Updates the API error response when there is an unknown or
deactivated user in the `principals` parameter for either the
`/api/subscribe` or `/api/unsubscribe` endpoints. We now use
the `access_user_by_email` and `access_user_by_id` code paths,
which return an HTTP response of 400 and a "BAD_REQUEST" code.

Previously, an HTTP response of 403 was returned with a special
"UNAUTHORIZED_PRINCIPAL" code in the error response. This code
was not documented in the API documentation and is removed as
a potential JsonableError code with these changes.

Fixes #26593.
2023-08-31 13:48:39 -07:00
..
__init__.py openapi: Add missing __init__.py; fix type errors hidden by its absence. 2021-07-05 12:20:39 -07:00
curl_param_value_generators.py openapi: Pass required arguments to select_related call. 2023-08-10 17:35:43 -07:00
javascript_examples.js message-type: Add support for "direct" as value for type parameter. 2023-04-18 12:29:33 -07:00
javascript_examples.py python: Replace universal_newlines with text. 2022-01-23 22:16:01 -08:00
markdown_extension.py ruff: Fix PERF401 Use a list comprehension to create a transformed list. 2023-08-07 17:23:55 -07:00
openapi.py ruff: Fix SIM118 Use `k not in d` instead of `k not in d.keys()`. 2023-07-24 10:39:28 -07:00
python_examples.py linkifier: Support reordering linkifiers. 2023-08-14 15:21:48 -07:00
test_curl_examples.py ruff: Fix PERF401 Use a list comprehension to create a transformed list. 2023-08-07 17:23:55 -07:00
testing.yaml test_openapi: Make testing.yml a full conformant specification. 2022-01-13 14:34:11 -08:00
zulip.yaml subscribe-unsubscribe: Improve error response for unexpected users. 2023-08-31 13:48:39 -07:00