GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — ORISO-UserService/api/userservice.yaml at dev · OpenResilienceInitiative/ORISO-UserService

Expand file tree

/

userservice.yaml

Copy path
More file actions
More file actions

Latest commit

 

History

History
History
6381 lines (6308 loc) · 237 KB
/

userservice.yaml

Copy path

File metadata and controls

6381 lines (6308 loc) · 237 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
openapi: 3.0.1
info:
title: will be replaced
description: This information will be replaced by the SpringFox config information
version: 0.0.1
externalDocs:
description: Account inactivity lifecycle and platform administration API.
url: ./account-inactivity.yaml
paths:
/users/identity-suggestions:
post:
tags: [guest-identity-controller]
operationId: suggestGuestIdentities
summary: Read available guest names without creating or reserving an account
security: []
requestBody:
required: true
content:
application/json:
schema:
$ref: '#/components/schemas/GuestIdentitySuggestionRequest'
responses:
'200':
description: Distinct checked suggestions; availability is a snapshot, not a reservation
content:
application/json:
schema:
type: array
maxItems: 4
items:
$ref: '#/components/schemas/GuestIdentitySuggestion'
'400':
description: Invalid or unbounded request
'429':
description: Public request limit exceeded
'503':
description: Availability unknown or bounded generation attempts exhausted
/users/invitelinks/{token}/context:
get:
tags: [guest-identity-controller]
operationId: getGuestInvitationContext
summary: Read public invitation context without account creation or link mutation
security: []
parameters:
- name: token
in: path
required: true
schema: {type: string}
responses:
'200':
description: Public entry context; no credentials or administrative metadata
content:
application/json:
schema:
$ref: '#/components/schemas/GuestInvitationContext'
'400':
description: Inactive or expired invitation
'404':
description: Invitation not found
'410':
description: >-
A paused invitation returns {"reason":"INVITE_LINK_PAUSED"}.
A switched-off direct link returns {"reason":"DIRECT_LINK_INACTIVE"}.
An expired direct invitation, or a token replaced by "Neuen Link senden", returns
{"reason":"DIRECT_LINK_EXPIRED"} (ORISO-Frontend#2252).
/users/chat/{chatId}/invite-context:
get:
tags: [group-invite-context-controller]
operationId: getGroupInviteContext
summary: Read a Gesprächskreis invite's guest account mode before login (#1662)
description: >-
Public. For the holder of a Gesprächskreis invite link (group id, its Beratungsstelle and
the invite secret) only: the circle's guest account mode, capped by what the platform and
the circle's Träger allow now. Nothing else about the circle is returned. Refusals match
the registration with a group invite (reason GROUP_INVITE_INVALID).
security: []
parameters:
- name: chatId
in: path
required: true
schema: {type: integer, format: int64}
- name: agencyId
in: query
required: true
schema: {type: integer, format: int64}
- name: inviteToken
in: query
required: true
schema: {type: string}
responses:
'200':
description: The circle's guest account mode
content:
application/json:
schema:
type: object
required: [guestAccountMode]
properties:
guestAccountMode:
type: string
enum: [TEMPORARY, GUEST_CHOOSES, PERMANENT]
'400':
description: Unknown group, another Beratungsstelle's, or not a Gesprächskreis
'403':
description: Wrong or missing invite secret
/users/invitelinks/{token}/renewal-requests:
post:
tags: [direct-link-controller]
operationId: requestDirectInvitationRenewal
summary: 'Ask the counsellor for a new link of a direct invitation ("Neuen Link anfragen") [Authorization: Role: user]'
description: >-
ORISO-Frontend#2252. Only a person who already is in the invitation's conversation (an
invited person or the asker of the 1:1 it was created from) may ask; anybody else gets 404.
Works with an expired token and with a token that was replaced. The counsellor gets an
in-app notice (event type direct_invitation.renewal_requested, params linkId, sessionId).
Asking twice with the same token sends one notice.
security:
- Bearer: [ ]
parameters:
- name: token
in: path
required: true
schema: {type: string}
responses:
'204': {description: The counsellor was told (also when this person asked for this token before)}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: 'Unknown link, or the caller is not in its conversation'}
'409': {description: 'The link has no appointment, so it never expires and needs no renewal'}
'503': {description: 'The notice to the counsellor could not be stored; nothing was sent, try again'}
/users/invitelinks/{token}/staff-join:
post:
tags: [direct-link-controller]
operationId: joinDirectLinkCallAsCounsellor
summary: 'A signed-in counsellor who holds the link joins the running call of a direct invitation [Authorization: Role: consultant]'
description: >-
ORISO-Frontend#2356. The counsellor joins the call only, with their own account, also from
another Träger; the conversation, its history and its session id stay closed to them. The
conversation's counsellor lets them in like a guest: with "Anklopfen" on the answer is
WAITING with a knock, with it off (or once admitted) the answer is SEATED with the call
room. Repeating the request is the poll. A counsellor who is already in the conversation
(its counsellor, a supervisor, a member of its room) gets MEMBER with the session id.
Nothing is written while no call runs (CALL_NOT_RUNNING); an admission or a decline counts
for one call. A link without an appointment has no shared conversation (NO_SHARED_CALL).
The existing `/conversations` operation stays for advice seekers only.
security:
- Bearer: [ ]
parameters:
- name: token
in: path
required: true
schema: {type: string}
- name: waitingFor
in: query
required: false
description: >-
The knock the caller's page waits on. When that knock was withdrawn the answer is
REFUSED. A decline holds for the rest of the call either way; a new call takes a new
knock.
schema: {type: integer, format: int64}
responses:
'200':
description: The state of this visit
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkStaffJoinDTO'}
'400': {description: 'Not an audio or video counsellor direct link'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: 'Not a counsellor, removed from this call by a counsellor, or a room member from another Träger'}
'404': {description: 'Unknown token'}
'410': {description: 'The link is switched off, expired, or direct invitations were withdrawn'}
'502': {description: 'Matrix could not be asked; nothing is assumed, try again'}
delete:
tags: [direct-link-controller]
operationId: leaveDirectLinkCallWaitingAsCounsellor
summary: 'The counsellor leaves the waiting state: their open knocks through this link are cancelled [Authorization: Role: consultant]'
security:
- Bearer: [ ]
parameters:
- name: token
in: path
required: true
schema: {type: string}
responses:
'204': {description: 'No knock of the caller waits through this link any more'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: 'Not a counsellor'}
/users/invitelinks/{token}/conversations:
post:
tags: [direct-link-controller]
operationId: startDirectLinkConversation
summary: 'Open (or reopen) the caller''s own 1:1 conversation through a counsellor direct link [Authorization: Role: user]'
description: >-
Every person gets their own conversation with the link owner. It is assigned to the
counsellor directly (like the contact link) and never enters the enquiry inbox. A second
call by the same person returns the existing conversation. Audio and video links answer
admission KNOCK: the person waits until the counsellor admits them (ADR-029 §2). Let in
once: after an admission every later visit returns it (callAdmitted true) and opens no new
knock; after a decline the next visit knocks again.
A direct invitation with an appointment (ORISO-Frontend#2252) works differently: the first
person creates the shared appointment conversation and everybody after them joins that
same conversation (appointmentConversation true). An invitation created from an existing
1:1 adds the person to that 1:1. The chat works at once; for audio and video the call
admission (knock) starts only at callOpensAt (15 minutes before the start); before that
knockId is empty. With knock switched off the person is let in without knocking. The
access mode is enforced: GUESTS_ONLY refuses a person with a permanent account,
ACCOUNTS_ONLY refuses a temporary account (403 with reason).
security:
- Bearer: [ ]
parameters:
- name: token
in: path
required: true
schema: {type: string}
responses:
'200':
description: The caller already had a conversation through this counsellor and topic
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkConversationDTO'}
'201':
description: A new conversation was created
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkConversationDTO'}
'400': {description: 'Not a counsellor direct link'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: 'Direct invitations are not allowed here, the caller belongs to another Träger, or the access mode excludes the caller: body {"reason":"DIRECT_INVITATION_GUESTS_ONLY"} or {"reason":"DIRECT_INVITATION_ACCOUNTS_ONLY"}'}
'404': {description: Unknown link}
'409': {description: 'Invitation from a 1:1 whose room is not encrypted, so earlier messages would not stay private: body {"reason":"DIRECT_INVITATION_ROOM_NOT_ENCRYPTED"}'}
'410': {description: 'The link was switched off ({"reason":"DIRECT_LINK_INACTIVE"}), or it expired or was replaced ({"reason":"DIRECT_LINK_EXPIRED"})'}
'502': {description: 'The conversation room could not be created or joined'}
'503': {description: 'Matrix cannot tell whether the 1:1 is encrypted; nobody joins, try again'}
/users/call-knocks:
get:
tags: [direct-link-controller]
operationId: getPendingCallKnocks
summary: 'People waiting to be let into a call in one of the caller''s conversations, oldest first [Authorization: Role: consultant]'
description: >-
With sessionId or matrixRoomId only the knocks of that call; without either all of the
caller's waiting knocks (unchanged behaviour). Knocks through a call share link (#1487)
count as knocks of the call whose conversation room is matrixRoomId; a room without a 1:1
conversation (a group call) is accepted when a call ran in it and lists only those.
security:
- Bearer: [ ]
parameters:
- name: sessionId
in: query
required: false
description: The conversation of the current call.
schema: {type: integer, format: int64}
- name: matrixRoomId
in: query
required: false
description: The Matrix room of the current call (the conversation's room).
schema: {type: string}
responses:
'200':
description: Pending knocks of the last two hours
content:
application/json:
schema:
type: array
items: {$ref: '#/components/schemas/CallKnockDTO'}
'400': {description: sessionId and matrixRoomId name different conversations}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Caller is not a consultant}
/users/call-knocks/admit-all:
post:
tags: [direct-link-controller]
operationId: admitAllCallKnocks
summary: 'Let everybody in who is waiting for the caller''s current call [Authorization: Role: consultant]'
description: >-
Scoped to one call: sessionId or matrixRoomId is required, otherwise 400. Knocks in the
caller's other conversations stay waiting.
security:
- Bearer: [ ]
parameters:
- name: sessionId
in: query
required: false
description: The conversation of the current call.
schema: {type: integer, format: int64}
- name: matrixRoomId
in: query
required: false
description: The Matrix room of the current call (the conversation's room).
schema: {type: string}
responses:
'200':
description: The knocks that were admitted
content:
application/json:
schema:
type: array
items: {$ref: '#/components/schemas/CallKnockDTO'}
'400': {description: 'Neither sessionId nor matrixRoomId, or both naming different conversations'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Caller is not a consultant}
/users/call-knocks/{knockId}/admit:
post:
tags: [direct-link-controller]
operationId: admitCallKnock
summary: 'Let one person into the call (idempotent) [Authorization: Role: consultant]'
security:
- Bearer: [ ]
parameters:
- name: knockId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The admitted knock
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No knock on one of the caller's conversations with this id}
'409': {description: The knock was already declined or cancelled}
/users/call-knocks/{knockId}/decline:
post:
tags: [direct-link-controller]
operationId: declineCallKnock
summary: 'Do not let the person in (idempotent) [Authorization: Role: consultant]'
security:
- Bearer: [ ]
parameters:
- name: knockId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The declined knock
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No knock on one of the caller's conversations with this id}
'409': {description: The knock was already admitted or cancelled}
/users/call-knocks/mine:
get:
tags: [direct-link-controller]
operationId: getOwnCallKnockForSession
summary: 'The caller''s call admission in one of their conversations, on any device [Authorization: Role: user]'
description: >-
Let in once: returns the caller's ADMITTED knock in this conversation if there is one,
otherwise their latest knock there. ADMITTED means the person joins every later call in
this conversation directly, without knocking.
security:
- Bearer: [ ]
parameters:
- name: sessionId
in: query
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The admission, or the latest knock
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Caller is not a user}
'404': {description: The caller never knocked in this conversation}
/users/call-knocks/mine/{knockId}:
get:
tags: [direct-link-controller]
operationId: getOwnCallKnock
summary: 'The state of the caller''s own knock, for the waiting room [Authorization: Role: user]'
security:
- Bearer: [ ]
parameters:
- name: knockId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The knock
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No own knock with this id}
delete:
tags: [direct-link-controller]
operationId: cancelOwnCallKnock
summary: 'Stop waiting (idempotent) [Authorization: Role: user]'
security:
- Bearer: [ ]
parameters:
- name: knockId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The knock after cancelling
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No own knock with this id}
/users/chat/{chatId}/waiting:
put:
tags: [direct-link-controller]
operationId: waitInGroupChat
summary: 'Wait in a group''s waiting room until a moderator lets the caller in [Authorization: Role: user]'
description: 'ORISO-Frontend#2237. One open entry per person and group; calling again marks the person as still there (call it every few seconds while waiting, else the entry drops off the moderator''s list). A moderator in the group''s running call sees the entry in GET /users/call-knocks?matrixRoomId=<group room> and admits it there. Returns a fresh admission as it is. Admission grants nothing by itself: the caller then joins with PUT /users/chat/{chatId}/join. Stop waiting with DELETE /users/call-knocks/mine/{knockId}.'
security:
- Bearer: [ ]
parameters:
- name: chatId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'200':
description: The caller's waiting-room entry
content:
application/json:
schema: {$ref: '#/components/schemas/CallKnockDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: FORBIDDEN - no permission for this chat}
'404': {description: No such chat}
/users/live-chat-account/conversion:
get:
tags: [live-chat-conversion-controller]
operationId: getOwnLiveChatConversion
summary: 'Read the caller’s Live Chat conversion state [Authorization: Role: user]'
security:
- Bearer: []
responses:
'200':
description: The caller’s conversion state and pending intent; no credential verifier is exposed
content:
application/json:
schema:
type: object
required: [userId, username, state]
properties:
userId: {type: string}
username: {type: string}
state: {type: string, enum: [ELIGIBLE, ALREADY_REGISTERED, NOT_ELIGIBLE, FINISH_PENDING, ANONYMOUS_FINISHED, PROMOTION_PENDING, PROMOTED, CLEANUP_STARTED]}
intentId: {type: string, nullable: true}
finishedOrigin: {type: boolean}
'401': {description: Missing or invalid authentication}
'403': {description: Not an advice seeker}
post:
tags: [live-chat-conversion-controller]
operationId: convertOwnLiveChatAccount
summary: 'Establish durable credentials for the caller’s anonymous Live Chat identity [Authorization: Role: user]'
security:
- Bearer: []
requestBody:
required: true
content:
application/json:
schema:
type: object
required: [expectedUserId, intentId, password, recoveryKeySaved]
properties:
expectedUserId: {type: string}
intentId: {type: string, format: uuid}
password: {type: string, format: password, minLength: 16, writeOnly: true}
recoveryKeySaved: {type: boolean, enum: [true], description: User confirms that the existing recovery key has been saved}
responses:
'200':
description: The account was promoted; its login name is returned without changing its identity
content:
application/json:
schema:
type: object
required: [username]
properties:
username: {type: string}
'400': {description: Invalid request or no anonymous Live Chat}
'401': {description: Missing or invalid authentication}
'403': {description: Not an advice seeker}
'409': {description: Cleanup started or conversion intent conflicts}
'500': {description: Identity service failure; the pending claim remains protected for retry}
/users/temporary-account:
get:
tags: [direct-link-controller]
operationId: getOwnTemporaryAccount
summary: 'The caller''s own temporary account from a direct link: retention mode and answer (ADR-029 §5) [Authorization: Role: user]'
security:
- Bearer: [ ]
responses:
'200':
description: The temporary account
content:
application/json:
schema: {$ref: '#/components/schemas/TemporaryAccountDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: The caller has no direct-link temporary account}
/users/temporary-account/message-retention:
put:
tags: [direct-link-controller]
operationId: decideTemporaryAccountMessageRetention
summary: 'The guest''s once-per-conversation answer under GUEST_DECIDES: keep the messages or delete them with the account [Authorization: Role: user]'
security:
- Bearer: [ ]
requestBody:
required: true
content:
application/json:
schema: {$ref: '#/components/schemas/TemporaryAccountRetentionDecisionDTO'}
responses:
'200':
description: The temporary account with the answer
content:
application/json:
schema: {$ref: '#/components/schemas/TemporaryAccountDTO'}
'400': {description: keepMessages missing}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: The caller has no direct-link temporary account}
'409': {description: 'The platform mode does not ask the guest, or the guest already answered'}
/users/directlinks:
get:
tags: [direct-link-controller]
operationId: getOwnDirectLinks
summary: 'List the caller''s own direct links, newest first [Authorization: Role: consultant]'
security:
- Bearer: [ ]
responses:
'200':
description: The caller's direct links (switched-off ones included)
content:
application/json:
schema:
type: array
items: {$ref: '#/components/schemas/DirectLinkDTO'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Caller is not a consultant}
post:
tags: [direct-link-controller]
operationId: createDirectLink
summary: 'Create a direct link for chat, audio or video [Authorization: Role: consultant]'
security:
- Bearer: [ ]
requestBody:
required: true
content:
application/json:
schema: {$ref: '#/components/schemas/CreateDirectLinkDTO'}
responses:
'201':
description: The new link
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkDTO'}
'400': {description: 'Missing or invalid field, or agencyId needed because the caller works for several Beratungsstellen'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: 'Caller is not a consultant, not in the agency, or direct invitations are not allowed here'}
'404': {description: Unknown topic}
/users/directlinks/{linkId}:
patch:
tags: [direct-link-controller]
operationId: updateDirectLink
summary: 'Change name, topic, temporary flag or on/off of an own direct link; the medium is fixed [Authorization: Role: consultant]'
security:
- Bearer: [ ]
parameters:
- name: linkId
in: path
required: true
schema: {type: integer, format: int64}
requestBody:
required: true
content:
application/json:
schema: {$ref: '#/components/schemas/UpdateDirectLinkDTO'}
responses:
'200':
description: The changed link
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkDTO'}
'400': {description: Invalid field}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Switching on is not allowed here}
'404': {description: No own direct link with this id}
delete:
tags: [direct-link-controller]
operationId: deleteDirectLink
summary: 'Delete an own direct link; conversations started through it stay [Authorization: Role: consultant]'
description: >-
For a direct invitation with an appointment (ORISO-Frontend#2252) deleting ends access like
an expiry: guests leave the appointment conversation, which is archived, and everybody who
came into a 1:1 by the link leaves it. Switching the link off (PATCH active false) does the
same; switching it on again reopens the appointment conversation.
security:
- Bearer: [ ]
parameters:
- name: linkId
in: path
required: true
schema: {type: integer, format: int64}
responses:
'204': {description: Deleted}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No own direct link with this id}
/users/directlinks/{linkId}/renewal:
post:
tags: [direct-link-controller]
operationId: renewDirectInvitation
summary: 'Issue a new link for the same appointment ("Neuen Link senden") [Authorization: Role: consultant]'
description: >-
ORISO-Frontend#2252. The invitation gets a new token; the old token answers 410
DIRECT_LINK_EXPIRED from now on. Appointment, access mode, knock and the appointment
conversation stay. The new link is valid for validityAfterEndMinutes after the later of
the appointment end and now. An invitation that had expired is switched on again and its
archived appointment conversation is reopened. The new link is posted into the
conversation as a system notice ([SYSTEM_NOTIFICATION] with type DIRECT_INVITATION_RENEWED
and url) when the conversation exists.
security:
- Bearer: [ ]
parameters:
- name: linkId
in: path
required: true
schema: {type: integer, format: int64}
requestBody:
required: false
content:
application/json:
schema: {$ref: '#/components/schemas/RenewDirectInvitationDTO'}
responses:
'200':
description: The invitation with its new token and url
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkDTO'}
'400': {description: 'validityAfterEndMinutes outside 0..2880'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'404': {description: No own direct link with this id}
'409': {description: 'The link has no appointment (it never expires), or the new link would already be expired (validity 0 after the end)'}
/users/sessions/{sessionId}/direct-invitations:
post:
tags: [direct-link-controller]
operationId: createSessionDirectInvitation
summary: 'Invite more people by link into an existing 1:1 conversation, for an appointment ("Weitere Personen per Link einladen") [Authorization: Role: consultant]'
description: >-
ORISO-Frontend#2252. Binds a direct invitation to the conversation and to one of its
appointments: either an existing appointment (appointmentId, from POST
/users/sessions/{sessionId}/appointments) or a new one (appointment). People who open the
link join this conversation as invited members; they are removed when the invitation
expires, and the conversation itself is never archived by the expiry. They join as plain
members (invited by the counsellor): no room setting changes; earlier messages stay
readable only through the history-key transfer a person in the room approves. That needs
an encrypted 1:1; otherwise opening the link answers 409
DIRECT_INVITATION_ROOM_NOT_ENCRYPTED.
security:
- Bearer: [ ]
parameters:
- name: sessionId
in: path
required: true
schema: {type: integer, format: int64}
requestBody:
required: true
content:
application/json:
schema: {$ref: '#/components/schemas/CreateSessionDirectInvitationDTO'}
responses:
'201':
description: The new invitation
content:
application/json:
schema: {$ref: '#/components/schemas/DirectLinkDTO'}
'400': {description: 'Neither or both of appointmentId and appointment, invalid times, or validity outside 0..2880'}
'401': {description: UNAUTHORIZED - no/invalid Keycloak token}
'403': {description: Direct invitations are not allowed here}
'404': {description: 'No such conversation of the caller (same answer for another counsellor''s or another Träger''s), or no such appointment in it'}
'409': {description: 'The conversation is finished or archived, or the appointment is cancelled'}
/users/{username}:
get:
tags:
- user-controller
summary: Checks if a given user exists, provided a username
operationId: userExists
parameters:
- name: username
in: path
description: username
required: true
schema:
type: string
responses:
200:
description: OK - user exists
404:
description: NOT FOUND - user does not exist
/users/askers/new:
post:
tags:
- user-controller
summary: 'Register a user [Authorization: none]'
operationId: registerUser
requestBody:
content:
'application/json':
schema:
$ref: '#/components/schemas/UserDTO'
required: true
responses:
201:
description: CREATED - user was created successfully
400:
description: BAD REQUEST - invalid/incomplete request or body object, or X-Reason GROUP_INVITE_INVALID when a group invite link names an unknown group, a group of another agency or not a self-help group, or is combined with a consultant link
headers:
X-Reason:
schema:
type: string
example: GROUP_INVITE_INVALID
403:
description: FORBIDDEN - no/invalid CSRF token, or X-Reason GROUP_INVITE_INVALID when the group invite token is missing or wrong
headers:
X-Reason:
schema:
type: string
example: GROUP_INVITE_INVALID
409:
description: CONFLICT - invalid/unavailable username
500:
description: INTERNAL SERVER ERROR - server encountered unexpected condition
security:
- Bearer: [ ]
/users/askers/session/new:
post:
tags:
- user-controller
summary: 'Register a new session for an existing asker [Authorization: Role: user]'
operationId: registerNewSession
requestBody:
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationDto'
required: true
responses:
201:
description: CREATED - session was registered successfully
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationResponseDto'
400:
description: BAD REQUEST - invalid/incomplete request or body object
403:
description: FORBIDDEN - no/invalid role/authorization or CSRF token
409:
description: CONFLICT - user is already registered for provided topic
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationResponseDto'
500:
description: INTERNAL SERVER ERROR - server encountered unexpected condition
security:
- Bearer: [ ]
/users/askers/consultingType/new:
post:
tags:
- user-controller
summary: 'Register a new consulting type for an existing asker [Authorization: Role: user]'
operationId: registerNewConsultingType
requestBody:
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationDto'
required: true
responses:
201:
description: CREATED - session was registered successfully
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationResponseDto'
400:
description: BAD REQUEST - invalid/incomplete request or body object
403:
description: FORBIDDEN - no/invalid role/authorization or CSRF token
409:
description: CONFLICT - user is already registered for provided consulting type or to given consultant
content:
'application/json':
schema:
$ref: '#/components/schemas/NewRegistrationResponseDto'
500:
description: INTERNAL SERVER ERROR - server encountered unexpected condition
security:
- Bearer: [ ]
/users/sessions/{sessionId}/enquiry/permission:
get:
tags:
- user-controller
summary: 'Check whether the authenticated asker may send their first enquiry before submitting an encrypted Matrix event [Authorization: Role: user]'
operationId: checkEnquiryPermission
parameters:
- name: sessionId
in: path
required: true
schema:
type: integer
format: int64
responses:
204:
description: NO CONTENT - first enquiry may be sent; finalization checks permission again
headers:
Cache-Control:
schema:
type: string
example: no-store
400:
description: BAD REQUEST - session is missing, belongs to another asker, or is anonymous
401:
description: UNAUTHORIZED - no/invalid Keycloak token
403:
description: FORBIDDEN - invalid role or AVV does not permit new counselling
headers:
X-Reason:
schema:
type: string
example: DPA_NEW_COUNSELLING_NOT_ALLOWED
content:
application/json:
schema:
$ref: '#/components/schemas/DpaPolicyErrorDTO'
409:
description: CONFLICT - enquiry already written or session is no longer open for an enquiry
502:
description: BAD GATEWAY - AVV owner unavailable or response invalid
headers:
X-Reason:
schema:
type: string
example: DPA_POLICY_UNAVAILABLE
content:
application/json:
schema:
$ref: '#/components/schemas/DpaPolicyErrorDTO'
security:
- Bearer: [ ]
/users/sessions/{sessionId}/enquiry/new:
post:
tags:
- user-controller
summary: 'Create enquiry message for a user [Authorization: Role: user]'
operationId: createEnquiryMessage
parameters:
- name: sessionId
in: path
description: Session Id
required: true
schema:
type: integer
format: int64
requestBody:
content:
'application/json':
schema:
$ref: '#/components/schemas/EnquiryMessageDTO'
required: true
responses:
201:
description: CREATED - enquiry message has been created
content:
'application/json':
schema:
$ref: '#/components/schemas/CreateEnquiryMessageResponseDTO'
400:
description: BAD REQUEST - invalid/incomplete request or body object
401:
description: UNAUTHORIZED - no/invalid Keycloak token
403:
description: FORBIDDEN - no/invalid role/authorization or CSRF token
409:
description: CONFLICT - message already saved for enquiry
500:
description: INTERNAL SERVER ERROR - server encountered unexpected condition
security:
- Bearer: [ ]
/users/sessions/{sessionId}/data:
put:
tags:
- user-controller
summary: 'Update the (user) information of a session [Authorization: Role: user]'
operationId: updateSessionData
parameters:
- name: sessionId
in: path
description: session ID
required: true
schema:
type: integer
format: int64
requestBody:
content:
'application/json':
schema:
$ref: '#/components/schemas/SessionDataDTO'
required: true
responses:
200:
description: OK - successful operation
400:
description: BAD REQUEST - invalid/incomplete request or body object
401:
description: UNAUTHORIZED - no/invalid Keycloak token
403:
description: FORBIDDEN - no/invalid role/authorization or CSRF token
404:
description: NOT FOUND - Session not found
500:
description: INTERNAL SERVER ERROR - server encountered unexpected condition
security:
- Bearer: [ ]
/users/sessions/{sessionId}/rejection:
post:
tags:
- user-controller
summary: 'Reject a submitted ordinary agency enquiry [Authorization: Role: consultant]'
operationId: rejectEnquiry
parameters:
- name: sessionId
in: path
required: true
schema:
type: integer
format: int64
responses:
204:
description: NO CONTENT - rejected and protocol closure verified
401:
description: UNAUTHORIZED - no valid authentication
403:
description: FORBIDDEN - current agency authority required
404:
description: NOT FOUND - no accessible session
409:
description: CONFLICT - enquiry changed, already accepted, or other rejection actor
503:
description: SERVICE UNAVAILABLE - rejection saved, protocol closure remains pending
500:
description: INTERNAL SERVER ERROR - unexpected failure
security:
- Bearer: [ ]
/users/sessions/{sessionId}/further-counselling-recommendation:
post:
tags:
- user-controller
summary: 'Recommend further counselling on a topic (FE#1876) [Authorization: Role:
consultant]'
description: >-
Posts a FURTHER_COUNSELLING_RECOMMENDED system notice into the room. Only the assigned
counsellor of an accepted 1:1 conversation may call it. The notice carries no postcode
and no asker data.
operationId: recommendFurtherCounselling
parameters:
- name: sessionId
in: path
required: true
schema:
type: integer
format: int64
requestBody:
content:
application/json:
schema:
$ref: '#/components/schemas/FurtherCounsellingRecommendationDTO'
required: true
responses:
204:
description: NO CONTENT - notice posted
400:
description: BAD REQUEST - topic missing or unknown, or note longer than 1000 characters
401:
description: UNAUTHORIZED - no/invalid Keycloak token
403:
description: FORBIDDEN - caller is not the assigned counsellor
404:
description: NOT FOUND - session not found
409:
description: CONFLICT - session is no accepted 1:1 conversation (enquiry, group, archived)
500:
description: INTERNAL SERVER ERROR - the notice could not be posted
security:
- Bearer: [ ]
/users/askers/sessions/{sessionId}/end-duplicate:
put:
tags:
- user-controller
summary: 'End the newer of two accepted same-topic conversations (FE#1876) [Authorization:
Role: user]'
description: >-
Archives the session like the counsellor archive does and posts TOPIC_DUPLICATE_ENDED
View remainder of file in raw view
You are visitor 01402775 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.