From 68ca4ebcf0811f5637c2ea962b0b80cc0f42d528 Mon Sep 17 00:00:00 2001 From: Mykhaylo Date: Thu, 14 Jul 2022 13:01:51 +0200 Subject: [PATCH 1/2] [CST-6108] updated eperson rest contract with new validation password rules --- epersons.md | 1 + 1 file changed, 1 insertion(+) diff --git a/epersons.md b/epersons.md index d84996cc..2c53d4b2 100644 --- a/epersons.md +++ b/epersons.md @@ -253,6 +253,7 @@ Status codes: * 201 Created - if the operation succeed * 400 Bad Request - if the email address didn't match the token or already exists. If the token doesn't exist or is expired * 401 Unauthorized - if the token doesn't allow you to create this account +* 422 Unprocessable Entity - If password validation is enabled and the password of respects the rules configured in the regular expression ## Linked entities ### Groups From 10852fd594229bc01ec42c46207c2768d3a7404a Mon Sep 17 00:00:00 2001 From: Mykhaylo Date: Wed, 21 Sep 2022 11:39:06 +0200 Subject: [PATCH 2/2] update eperson rest contract --- epersons.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/epersons.md b/epersons.md index 2c53d4b2..6fd57c6c 100644 --- a/epersons.md +++ b/epersons.md @@ -171,6 +171,9 @@ the replace operation `[{ "op": "add", "path": "/password", "value": "newpasswor ```json "password": "newpassword", ``` +Status codes: +* 422 Unprocessable Entity - If the provided password not respects the rules configured in the regular expression + NOTE: The new password is currently returned after an update but this could be revisited later, see [#30](https://github.com/DSpace/Rest7Contract/issues/30) ## Create new EPerson (requires admin permissions) @@ -253,7 +256,7 @@ Status codes: * 201 Created - if the operation succeed * 400 Bad Request - if the email address didn't match the token or already exists. If the token doesn't exist or is expired * 401 Unauthorized - if the token doesn't allow you to create this account -* 422 Unprocessable Entity - If password validation is enabled and the password of respects the rules configured in the regular expression +* 422 Unprocessable Entity - If the provided password not respects the rules configured in the regular expression ## Linked entities ### Groups