Skip to content

Commit 5380899

Browse files
committed
updates OAS
1 parent 6d8c770 commit 5380899

File tree

2 files changed

+30
-11
lines changed
  • packages/models-library/src/models_library/api_schemas_webserver
  • services/web/server/src/simcore_service_webserver/api/v0

2 files changed

+30
-11
lines changed

packages/models-library/src/models_library/api_schemas_webserver/groups.py

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -286,14 +286,24 @@ class GroupUserAdd(InputSchema):
286286
"""
287287

288288
uid: UserID | None = None
289-
email: LowerCaseEmailStr | None = None
289+
email: Annotated[
290+
LowerCaseEmailStr | None,
291+
Field(
292+
description="Accessible only if the user has opted to share their email in privacy settings"
293+
),
294+
] = None
290295

291296
_check_uid_or_email = model_validator(mode="after")(
292297
create__check_only_one_is_set__root_validator(["uid", "email"])
293298
)
294299

295300
model_config = ConfigDict(
296-
json_schema_extra={"examples": [{"uid": 42}, {"email": "[email protected]"}]}
301+
json_schema_extra={
302+
"examples": [
303+
{"uid": 42},
304+
{"email": "[email protected]"},
305+
]
306+
}
297307
)
298308

299309

services/web/server/src/simcore_service_webserver/api/v0/openapi.yaml

Lines changed: 18 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -9917,6 +9917,8 @@ components:
99179917
format: email
99189918
- type: 'null'
99199919
title: Email
9920+
description: Accessible only if the user has opted to share their email
9921+
in privacy settings
99209922
type: object
99219923
title: GroupUserAdd
99229924
description: "Identify the user with either `email` or `uid` \u2014 only one."
@@ -9928,41 +9930,48 @@ components:
99289930
- type: 'null'
99299931
title: Id
99309932
description: the user id
9933+
userName:
9934+
type: string
9935+
maxLength: 100
9936+
minLength: 1
9937+
title: Username
9938+
gid:
9939+
anyOf:
9940+
- type: string
9941+
- type: 'null'
9942+
title: Gid
9943+
description: the user primary gid
99319944
login:
99329945
anyOf:
99339946
- type: string
99349947
format: email
99359948
- type: 'null'
99369949
title: Login
9937-
description: the user login email
9950+
description: the user's email, if privacy settings allows
99389951
first_name:
99399952
anyOf:
99409953
- type: string
99419954
- type: 'null'
99429955
title: First Name
9943-
description: the user first name
9956+
description: If privacy settings allows
99449957
last_name:
99459958
anyOf:
99469959
- type: string
99479960
- type: 'null'
99489961
title: Last Name
9949-
description: the user last name
9962+
description: If privacy settings allows
99509963
gravatar_id:
99519964
anyOf:
99529965
- type: string
99539966
- type: 'null'
99549967
title: Gravatar Id
99559968
description: the user gravatar id hash
9956-
gid:
9957-
anyOf:
9958-
- type: string
9959-
- type: 'null'
9960-
title: Gid
9961-
description: the user primary gid
9969+
deprecated: true
99629970
accessRights:
99639971
$ref: '#/components/schemas/GroupAccessRights'
99649972
type: object
99659973
required:
9974+
- userName
99669975
- accessRights
99679976
title: GroupUserGet
99689977
example:

0 commit comments

Comments
 (0)