@polaris-auth/client 0.6.1 → 0.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/openapi.json CHANGED
@@ -2,7 +2,7 @@
2
2
  "openapi": "3.1.0",
3
3
  "info": {
4
4
  "title": "Polaris for PHP",
5
- "version": "0.6.1",
5
+ "version": "0.7.0",
6
6
  "description": "Self-hosted authentication, MFA, organizations and RBAC."
7
7
  },
8
8
  "paths": {
@@ -14922,6 +14922,2094 @@
14922
14922
  }
14923
14923
  }
14924
14924
  }
14925
+ },
14926
+ "/email-otp/reset-password": {
14927
+ "post": {
14928
+ "operationId": "post_passwordless_EmailOtpResetPasswordEndpoint",
14929
+ "summary": "Reset the password with an email code",
14930
+ "tags": [
14931
+ "passwordless"
14932
+ ],
14933
+ "x-polaris-effect": "write",
14934
+ "x-polaris-receipt": true,
14935
+ "x-polaris-plugin": "passwordless",
14936
+ "x-polaris-rate-limit": "token_consume",
14937
+ "requestBody": {
14938
+ "required": true,
14939
+ "content": {
14940
+ "application/json": {
14941
+ "schema": {
14942
+ "type": "object",
14943
+ "properties": {
14944
+ "email": {
14945
+ "type": "string",
14946
+ "format": "email",
14947
+ "maxLength": 320
14948
+ },
14949
+ "code": {
14950
+ "type": "string",
14951
+ "format": "password",
14952
+ "x-polaris-sensitive": true
14953
+ },
14954
+ "password": {
14955
+ "type": "string",
14956
+ "format": "password",
14957
+ "x-polaris-sensitive": true
14958
+ }
14959
+ },
14960
+ "required": [
14961
+ "email",
14962
+ "code",
14963
+ "password"
14964
+ ]
14965
+ }
14966
+ }
14967
+ }
14968
+ },
14969
+ "responses": {
14970
+ "200": {
14971
+ "description": "Success",
14972
+ "content": {
14973
+ "application/json": {
14974
+ "schema": {
14975
+ "type": "object",
14976
+ "properties": {
14977
+ "data": {
14978
+ "type": "object",
14979
+ "properties": {
14980
+ "status": {
14981
+ "type": "string"
14982
+ }
14983
+ },
14984
+ "required": [
14985
+ "status"
14986
+ ]
14987
+ }
14988
+ },
14989
+ "required": [
14990
+ "data"
14991
+ ]
14992
+ },
14993
+ "example": {
14994
+ "data": {
14995
+ "status": "password_reset"
14996
+ }
14997
+ }
14998
+ }
14999
+ }
15000
+ },
15001
+ "422": {
15002
+ "description": "passwordless_code_invalid | passwordless_invalid_input | passwordless_password_invalid",
15003
+ "content": {
15004
+ "application/problem+json": {
15005
+ "schema": {
15006
+ "$ref": "#/components/schemas/Problem"
15007
+ }
15008
+ }
15009
+ }
15010
+ }
15011
+ }
15012
+ }
15013
+ },
15014
+ "/email-otp/send": {
15015
+ "post": {
15016
+ "operationId": "post_passwordless_EmailOtpSendEndpoint",
15017
+ "summary": "Send an email code",
15018
+ "tags": [
15019
+ "passwordless"
15020
+ ],
15021
+ "x-polaris-effect": "write",
15022
+ "x-polaris-receipt": false,
15023
+ "x-polaris-plugin": "passwordless",
15024
+ "x-polaris-rate-limit": "mfa_send",
15025
+ "requestBody": {
15026
+ "required": true,
15027
+ "content": {
15028
+ "application/json": {
15029
+ "schema": {
15030
+ "type": "object",
15031
+ "properties": {
15032
+ "email": {
15033
+ "type": "string",
15034
+ "format": "email",
15035
+ "maxLength": 320
15036
+ },
15037
+ "purpose": {
15038
+ "type": "string",
15039
+ "enum": [
15040
+ "sign-in",
15041
+ "verify-email",
15042
+ "reset-password"
15043
+ ]
15044
+ }
15045
+ },
15046
+ "required": [
15047
+ "email"
15048
+ ]
15049
+ }
15050
+ }
15051
+ }
15052
+ },
15053
+ "responses": {
15054
+ "202": {
15055
+ "description": "Success",
15056
+ "content": {
15057
+ "application/json": {
15058
+ "schema": {
15059
+ "type": "object",
15060
+ "properties": {
15061
+ "data": {
15062
+ "type": "object",
15063
+ "properties": {
15064
+ "status": {
15065
+ "type": "string"
15066
+ }
15067
+ },
15068
+ "required": [
15069
+ "status"
15070
+ ]
15071
+ }
15072
+ },
15073
+ "required": [
15074
+ "data"
15075
+ ]
15076
+ },
15077
+ "example": {
15078
+ "data": {
15079
+ "status": "sent"
15080
+ }
15081
+ }
15082
+ }
15083
+ }
15084
+ },
15085
+ "422": {
15086
+ "description": "passwordless_invalid_input",
15087
+ "content": {
15088
+ "application/problem+json": {
15089
+ "schema": {
15090
+ "$ref": "#/components/schemas/Problem"
15091
+ }
15092
+ }
15093
+ }
15094
+ }
15095
+ }
15096
+ }
15097
+ },
15098
+ "/email-otp/verify-email": {
15099
+ "post": {
15100
+ "operationId": "post_passwordless_EmailOtpVerifyEmailEndpoint",
15101
+ "summary": "Verify the email with a code",
15102
+ "tags": [
15103
+ "passwordless"
15104
+ ],
15105
+ "x-polaris-effect": "write",
15106
+ "x-polaris-receipt": true,
15107
+ "x-polaris-plugin": "passwordless",
15108
+ "x-polaris-rate-limit": "token_consume",
15109
+ "requestBody": {
15110
+ "required": true,
15111
+ "content": {
15112
+ "application/json": {
15113
+ "schema": {
15114
+ "type": "object",
15115
+ "properties": {
15116
+ "email": {
15117
+ "type": "string",
15118
+ "format": "email",
15119
+ "maxLength": 320
15120
+ },
15121
+ "code": {
15122
+ "type": "string",
15123
+ "format": "password",
15124
+ "x-polaris-sensitive": true
15125
+ }
15126
+ },
15127
+ "required": [
15128
+ "email",
15129
+ "code"
15130
+ ]
15131
+ }
15132
+ }
15133
+ }
15134
+ },
15135
+ "responses": {
15136
+ "200": {
15137
+ "description": "Success",
15138
+ "content": {
15139
+ "application/json": {
15140
+ "schema": {
15141
+ "type": "object",
15142
+ "properties": {
15143
+ "data": {
15144
+ "type": "object",
15145
+ "properties": {
15146
+ "status": {
15147
+ "type": "string"
15148
+ }
15149
+ },
15150
+ "required": [
15151
+ "status"
15152
+ ]
15153
+ }
15154
+ },
15155
+ "required": [
15156
+ "data"
15157
+ ]
15158
+ },
15159
+ "example": {
15160
+ "data": {
15161
+ "status": "verified"
15162
+ }
15163
+ }
15164
+ }
15165
+ }
15166
+ },
15167
+ "422": {
15168
+ "description": "passwordless_code_invalid | passwordless_invalid_input",
15169
+ "content": {
15170
+ "application/problem+json": {
15171
+ "schema": {
15172
+ "$ref": "#/components/schemas/Problem"
15173
+ }
15174
+ }
15175
+ }
15176
+ }
15177
+ }
15178
+ }
15179
+ },
15180
+ "/email-otp/verify": {
15181
+ "post": {
15182
+ "operationId": "post_passwordless_EmailOtpVerifyEndpoint",
15183
+ "summary": "Sign in with an email code",
15184
+ "tags": [
15185
+ "passwordless"
15186
+ ],
15187
+ "x-polaris-effect": "write",
15188
+ "x-polaris-receipt": true,
15189
+ "x-polaris-plugin": "passwordless",
15190
+ "x-polaris-rate-limit": "token_consume",
15191
+ "requestBody": {
15192
+ "required": true,
15193
+ "content": {
15194
+ "application/json": {
15195
+ "schema": {
15196
+ "type": "object",
15197
+ "properties": {
15198
+ "email": {
15199
+ "type": "string",
15200
+ "format": "email",
15201
+ "maxLength": 320
15202
+ },
15203
+ "code": {
15204
+ "type": "string",
15205
+ "format": "password",
15206
+ "x-polaris-sensitive": true
15207
+ }
15208
+ },
15209
+ "required": [
15210
+ "email",
15211
+ "code"
15212
+ ]
15213
+ }
15214
+ }
15215
+ }
15216
+ },
15217
+ "responses": {
15218
+ "200": {
15219
+ "description": "Success",
15220
+ "content": {
15221
+ "application/json": {
15222
+ "schema": {
15223
+ "type": "object",
15224
+ "properties": {
15225
+ "data": {
15226
+ "type": "object",
15227
+ "properties": {
15228
+ "access_token": {
15229
+ "type": "string"
15230
+ },
15231
+ "token_type": {
15232
+ "type": "string"
15233
+ },
15234
+ "expires_in": {
15235
+ "type": "integer"
15236
+ },
15237
+ "refresh_token": {
15238
+ "type": "string"
15239
+ },
15240
+ "user": {
15241
+ "type": "object",
15242
+ "properties": {
15243
+ "id": {
15244
+ "type": "string"
15245
+ },
15246
+ "email": {
15247
+ "type": "string"
15248
+ },
15249
+ "email_verified": {
15250
+ "type": "boolean"
15251
+ }
15252
+ },
15253
+ "required": [
15254
+ "id",
15255
+ "email",
15256
+ "email_verified"
15257
+ ]
15258
+ }
15259
+ },
15260
+ "required": [
15261
+ "access_token",
15262
+ "token_type",
15263
+ "expires_in",
15264
+ "refresh_token",
15265
+ "user"
15266
+ ]
15267
+ }
15268
+ },
15269
+ "required": [
15270
+ "data"
15271
+ ]
15272
+ },
15273
+ "example": {
15274
+ "data": {
15275
+ "access_token": "<jwt>",
15276
+ "token_type": "Bearer",
15277
+ "expires_in": 900,
15278
+ "refresh_token": "<opaque>",
15279
+ "user": {
15280
+ "id": "018f...",
15281
+ "email": "ada@example.com",
15282
+ "email_verified": true
15283
+ }
15284
+ }
15285
+ }
15286
+ }
15287
+ }
15288
+ },
15289
+ "403": {
15290
+ "description": "passwordless_account_disabled",
15291
+ "content": {
15292
+ "application/problem+json": {
15293
+ "schema": {
15294
+ "$ref": "#/components/schemas/Problem"
15295
+ }
15296
+ }
15297
+ }
15298
+ },
15299
+ "422": {
15300
+ "description": "passwordless_code_invalid | passwordless_invalid_input",
15301
+ "content": {
15302
+ "application/problem+json": {
15303
+ "schema": {
15304
+ "$ref": "#/components/schemas/Problem"
15305
+ }
15306
+ }
15307
+ }
15308
+ }
15309
+ }
15310
+ }
15311
+ },
15312
+ "/magic-link/exchange": {
15313
+ "post": {
15314
+ "operationId": "post_passwordless_MagicLinkExchangeEndpoint",
15315
+ "summary": "Exchange the magic link's code for the session",
15316
+ "tags": [
15317
+ "passwordless"
15318
+ ],
15319
+ "x-polaris-effect": "write",
15320
+ "x-polaris-receipt": false,
15321
+ "x-polaris-plugin": "passwordless",
15322
+ "x-polaris-rate-limit": "token_consume",
15323
+ "requestBody": {
15324
+ "required": true,
15325
+ "content": {
15326
+ "application/json": {
15327
+ "schema": {
15328
+ "type": "object",
15329
+ "properties": {
15330
+ "code": {
15331
+ "type": "string",
15332
+ "format": "password",
15333
+ "x-polaris-sensitive": true
15334
+ }
15335
+ },
15336
+ "required": [
15337
+ "code"
15338
+ ]
15339
+ }
15340
+ }
15341
+ }
15342
+ },
15343
+ "responses": {
15344
+ "200": {
15345
+ "description": "Success",
15346
+ "content": {
15347
+ "application/json": {
15348
+ "schema": {
15349
+ "type": "object",
15350
+ "properties": {
15351
+ "data": {
15352
+ "type": "object",
15353
+ "properties": {
15354
+ "access_token": {
15355
+ "type": "string"
15356
+ },
15357
+ "token_type": {
15358
+ "type": "string"
15359
+ },
15360
+ "expires_in": {
15361
+ "type": "integer"
15362
+ },
15363
+ "refresh_token": {
15364
+ "type": "string"
15365
+ },
15366
+ "user": {
15367
+ "type": "object",
15368
+ "properties": {
15369
+ "id": {
15370
+ "type": "string"
15371
+ },
15372
+ "email": {
15373
+ "type": "string"
15374
+ },
15375
+ "email_verified": {
15376
+ "type": "boolean"
15377
+ }
15378
+ },
15379
+ "required": [
15380
+ "id",
15381
+ "email",
15382
+ "email_verified"
15383
+ ]
15384
+ }
15385
+ },
15386
+ "required": [
15387
+ "access_token",
15388
+ "token_type",
15389
+ "expires_in",
15390
+ "refresh_token",
15391
+ "user"
15392
+ ]
15393
+ }
15394
+ },
15395
+ "required": [
15396
+ "data"
15397
+ ]
15398
+ },
15399
+ "example": {
15400
+ "data": {
15401
+ "access_token": "<jwt>",
15402
+ "token_type": "Bearer",
15403
+ "expires_in": 900,
15404
+ "refresh_token": "<opaque>",
15405
+ "user": {
15406
+ "id": "018f...",
15407
+ "email": "ada@example.com",
15408
+ "email_verified": true
15409
+ }
15410
+ }
15411
+ }
15412
+ }
15413
+ }
15414
+ },
15415
+ "422": {
15416
+ "description": "passwordless_invalid_input | passwordless_token_invalid",
15417
+ "content": {
15418
+ "application/problem+json": {
15419
+ "schema": {
15420
+ "$ref": "#/components/schemas/Problem"
15421
+ }
15422
+ }
15423
+ }
15424
+ }
15425
+ }
15426
+ }
15427
+ },
15428
+ "/magic-link/send": {
15429
+ "post": {
15430
+ "operationId": "post_passwordless_MagicLinkSendEndpoint",
15431
+ "summary": "Send a magic link",
15432
+ "tags": [
15433
+ "passwordless"
15434
+ ],
15435
+ "x-polaris-effect": "write",
15436
+ "x-polaris-receipt": false,
15437
+ "x-polaris-plugin": "passwordless",
15438
+ "x-polaris-rate-limit": "mfa_send",
15439
+ "requestBody": {
15440
+ "required": true,
15441
+ "content": {
15442
+ "application/json": {
15443
+ "schema": {
15444
+ "type": "object",
15445
+ "properties": {
15446
+ "email": {
15447
+ "type": "string",
15448
+ "format": "email",
15449
+ "maxLength": 320
15450
+ },
15451
+ "redirect_uri": {
15452
+ "type": "string"
15453
+ }
15454
+ },
15455
+ "required": [
15456
+ "email"
15457
+ ]
15458
+ }
15459
+ }
15460
+ }
15461
+ },
15462
+ "responses": {
15463
+ "202": {
15464
+ "description": "Success",
15465
+ "content": {
15466
+ "application/json": {
15467
+ "schema": {
15468
+ "type": "object",
15469
+ "properties": {
15470
+ "data": {
15471
+ "type": "object",
15472
+ "properties": {
15473
+ "status": {
15474
+ "type": "string"
15475
+ }
15476
+ },
15477
+ "required": [
15478
+ "status"
15479
+ ]
15480
+ }
15481
+ },
15482
+ "required": [
15483
+ "data"
15484
+ ]
15485
+ },
15486
+ "example": {
15487
+ "data": {
15488
+ "status": "sent"
15489
+ }
15490
+ }
15491
+ }
15492
+ }
15493
+ },
15494
+ "422": {
15495
+ "description": "passwordless_invalid_input | passwordless_redirect_not_allowed",
15496
+ "content": {
15497
+ "application/problem+json": {
15498
+ "schema": {
15499
+ "$ref": "#/components/schemas/Problem"
15500
+ }
15501
+ }
15502
+ }
15503
+ }
15504
+ }
15505
+ }
15506
+ },
15507
+ "/magic-link/verify": {
15508
+ "get": {
15509
+ "operationId": "get_passwordless_MagicLinkVerifyEndpoint",
15510
+ "summary": "Open a magic link",
15511
+ "tags": [
15512
+ "passwordless"
15513
+ ],
15514
+ "x-polaris-effect": "write",
15515
+ "x-polaris-receipt": false,
15516
+ "x-polaris-plugin": "passwordless",
15517
+ "x-polaris-rate-limit": "token_consume",
15518
+ "parameters": [
15519
+ {
15520
+ "name": "token",
15521
+ "in": "query",
15522
+ "required": true,
15523
+ "schema": {
15524
+ "type": "string",
15525
+ "format": "password",
15526
+ "x-polaris-sensitive": true
15527
+ }
15528
+ }
15529
+ ],
15530
+ "responses": {
15531
+ "302": {
15532
+ "description": "Success",
15533
+ "content": {
15534
+ "application/json": {
15535
+ "schema": {
15536
+ "type": "array",
15537
+ "items": []
15538
+ },
15539
+ "example": []
15540
+ }
15541
+ }
15542
+ },
15543
+ "403": {
15544
+ "description": "passwordless_account_disabled",
15545
+ "content": {
15546
+ "application/problem+json": {
15547
+ "schema": {
15548
+ "$ref": "#/components/schemas/Problem"
15549
+ }
15550
+ }
15551
+ }
15552
+ },
15553
+ "422": {
15554
+ "description": "passwordless_invalid_input | passwordless_token_invalid",
15555
+ "content": {
15556
+ "application/problem+json": {
15557
+ "schema": {
15558
+ "$ref": "#/components/schemas/Problem"
15559
+ }
15560
+ }
15561
+ }
15562
+ }
15563
+ }
15564
+ }
15565
+ },
15566
+ "/one-time-token/generate": {
15567
+ "post": {
15568
+ "operationId": "post_passwordless_OneTimeTokenGenerateEndpoint",
15569
+ "summary": "Generate a one-time token",
15570
+ "tags": [
15571
+ "passwordless"
15572
+ ],
15573
+ "x-polaris-effect": "write",
15574
+ "x-polaris-receipt": true,
15575
+ "x-polaris-plugin": "passwordless",
15576
+ "security": [
15577
+ {
15578
+ "bearerAuth": []
15579
+ }
15580
+ ],
15581
+ "responses": {
15582
+ "201": {
15583
+ "description": "Success",
15584
+ "content": {
15585
+ "application/json": {
15586
+ "schema": {
15587
+ "type": "object",
15588
+ "properties": {
15589
+ "data": {
15590
+ "type": "object",
15591
+ "properties": {
15592
+ "token": {
15593
+ "type": "string"
15594
+ },
15595
+ "expires_in": {
15596
+ "type": "integer"
15597
+ }
15598
+ },
15599
+ "required": [
15600
+ "token",
15601
+ "expires_in"
15602
+ ]
15603
+ }
15604
+ },
15605
+ "required": [
15606
+ "data"
15607
+ ]
15608
+ },
15609
+ "example": {
15610
+ "data": {
15611
+ "token": "<opaque>",
15612
+ "expires_in": 180
15613
+ }
15614
+ }
15615
+ }
15616
+ }
15617
+ },
15618
+ "401": {
15619
+ "description": "unauthorized",
15620
+ "content": {
15621
+ "application/problem+json": {
15622
+ "schema": {
15623
+ "$ref": "#/components/schemas/Problem"
15624
+ }
15625
+ }
15626
+ }
15627
+ },
15628
+ "403": {
15629
+ "description": "passwordless_session_required",
15630
+ "content": {
15631
+ "application/problem+json": {
15632
+ "schema": {
15633
+ "$ref": "#/components/schemas/Problem"
15634
+ }
15635
+ }
15636
+ }
15637
+ }
15638
+ }
15639
+ }
15640
+ },
15641
+ "/one-time-token/verify": {
15642
+ "post": {
15643
+ "operationId": "post_passwordless_OneTimeTokenVerifyEndpoint",
15644
+ "summary": "Sign in with a one-time token",
15645
+ "tags": [
15646
+ "passwordless"
15647
+ ],
15648
+ "x-polaris-effect": "write",
15649
+ "x-polaris-receipt": true,
15650
+ "x-polaris-plugin": "passwordless",
15651
+ "x-polaris-rate-limit": "token_consume",
15652
+ "requestBody": {
15653
+ "required": true,
15654
+ "content": {
15655
+ "application/json": {
15656
+ "schema": {
15657
+ "type": "object",
15658
+ "properties": {
15659
+ "token": {
15660
+ "type": "string",
15661
+ "format": "password",
15662
+ "x-polaris-sensitive": true
15663
+ }
15664
+ },
15665
+ "required": [
15666
+ "token"
15667
+ ]
15668
+ }
15669
+ }
15670
+ }
15671
+ },
15672
+ "responses": {
15673
+ "200": {
15674
+ "description": "Success",
15675
+ "content": {
15676
+ "application/json": {
15677
+ "schema": {
15678
+ "type": "object",
15679
+ "properties": {
15680
+ "data": {
15681
+ "type": "object",
15682
+ "properties": {
15683
+ "access_token": {
15684
+ "type": "string"
15685
+ },
15686
+ "token_type": {
15687
+ "type": "string"
15688
+ },
15689
+ "expires_in": {
15690
+ "type": "integer"
15691
+ },
15692
+ "refresh_token": {
15693
+ "type": "string"
15694
+ },
15695
+ "user": {
15696
+ "type": "object",
15697
+ "properties": {
15698
+ "id": {
15699
+ "type": "string"
15700
+ },
15701
+ "email": {
15702
+ "type": "string"
15703
+ },
15704
+ "email_verified": {
15705
+ "type": "boolean"
15706
+ }
15707
+ },
15708
+ "required": [
15709
+ "id",
15710
+ "email",
15711
+ "email_verified"
15712
+ ]
15713
+ }
15714
+ },
15715
+ "required": [
15716
+ "access_token",
15717
+ "token_type",
15718
+ "expires_in",
15719
+ "refresh_token",
15720
+ "user"
15721
+ ]
15722
+ }
15723
+ },
15724
+ "required": [
15725
+ "data"
15726
+ ]
15727
+ },
15728
+ "example": {
15729
+ "data": {
15730
+ "access_token": "<jwt>",
15731
+ "token_type": "Bearer",
15732
+ "expires_in": 900,
15733
+ "refresh_token": "<opaque>",
15734
+ "user": {
15735
+ "id": "018f...",
15736
+ "email": "ada@example.com",
15737
+ "email_verified": true
15738
+ }
15739
+ }
15740
+ }
15741
+ }
15742
+ }
15743
+ },
15744
+ "422": {
15745
+ "description": "passwordless_invalid_input | passwordless_token_invalid",
15746
+ "content": {
15747
+ "application/problem+json": {
15748
+ "schema": {
15749
+ "$ref": "#/components/schemas/Problem"
15750
+ }
15751
+ }
15752
+ }
15753
+ }
15754
+ }
15755
+ }
15756
+ },
15757
+ "/phone/add": {
15758
+ "post": {
15759
+ "operationId": "post_passwordless_PhoneAddEndpoint",
15760
+ "summary": "Add a phone number",
15761
+ "tags": [
15762
+ "passwordless"
15763
+ ],
15764
+ "x-polaris-effect": "write",
15765
+ "x-polaris-receipt": false,
15766
+ "x-polaris-plugin": "passwordless",
15767
+ "x-polaris-rate-limit": "mfa_send",
15768
+ "x-polaris-step-up": true,
15769
+ "security": [
15770
+ {
15771
+ "bearerAuth": []
15772
+ }
15773
+ ],
15774
+ "requestBody": {
15775
+ "required": true,
15776
+ "content": {
15777
+ "application/json": {
15778
+ "schema": {
15779
+ "type": "object",
15780
+ "properties": {
15781
+ "phone": {
15782
+ "type": "string",
15783
+ "maxLength": 32
15784
+ }
15785
+ },
15786
+ "required": [
15787
+ "phone"
15788
+ ]
15789
+ }
15790
+ }
15791
+ }
15792
+ },
15793
+ "responses": {
15794
+ "202": {
15795
+ "description": "Success",
15796
+ "content": {
15797
+ "application/json": {
15798
+ "schema": {
15799
+ "type": "object",
15800
+ "properties": {
15801
+ "data": {
15802
+ "type": "object",
15803
+ "properties": {
15804
+ "status": {
15805
+ "type": "string"
15806
+ }
15807
+ },
15808
+ "required": [
15809
+ "status"
15810
+ ]
15811
+ }
15812
+ },
15813
+ "required": [
15814
+ "data"
15815
+ ]
15816
+ },
15817
+ "example": {
15818
+ "data": {
15819
+ "status": "sent"
15820
+ }
15821
+ }
15822
+ }
15823
+ }
15824
+ },
15825
+ "401": {
15826
+ "description": "unauthorized | step_up_required",
15827
+ "content": {
15828
+ "application/problem+json": {
15829
+ "schema": {
15830
+ "$ref": "#/components/schemas/Problem"
15831
+ }
15832
+ }
15833
+ }
15834
+ },
15835
+ "422": {
15836
+ "description": "passwordless_invalid_input",
15837
+ "content": {
15838
+ "application/problem+json": {
15839
+ "schema": {
15840
+ "$ref": "#/components/schemas/Problem"
15841
+ }
15842
+ }
15843
+ }
15844
+ }
15845
+ }
15846
+ }
15847
+ },
15848
+ "/phone/confirm": {
15849
+ "post": {
15850
+ "operationId": "post_passwordless_PhoneConfirmEndpoint",
15851
+ "summary": "Confirm a phone number",
15852
+ "tags": [
15853
+ "passwordless"
15854
+ ],
15855
+ "x-polaris-effect": "write",
15856
+ "x-polaris-receipt": true,
15857
+ "x-polaris-plugin": "passwordless",
15858
+ "x-polaris-rate-limit": "token_consume",
15859
+ "x-polaris-step-up": true,
15860
+ "security": [
15861
+ {
15862
+ "bearerAuth": []
15863
+ }
15864
+ ],
15865
+ "requestBody": {
15866
+ "required": true,
15867
+ "content": {
15868
+ "application/json": {
15869
+ "schema": {
15870
+ "type": "object",
15871
+ "properties": {
15872
+ "phone": {
15873
+ "type": "string",
15874
+ "maxLength": 32
15875
+ },
15876
+ "code": {
15877
+ "type": "string",
15878
+ "format": "password",
15879
+ "x-polaris-sensitive": true
15880
+ }
15881
+ },
15882
+ "required": [
15883
+ "phone",
15884
+ "code"
15885
+ ]
15886
+ }
15887
+ }
15888
+ }
15889
+ },
15890
+ "responses": {
15891
+ "200": {
15892
+ "description": "Success",
15893
+ "content": {
15894
+ "application/json": {
15895
+ "schema": {
15896
+ "type": "object",
15897
+ "properties": {
15898
+ "data": {
15899
+ "type": "object",
15900
+ "properties": {
15901
+ "phone": {
15902
+ "type": "string"
15903
+ },
15904
+ "verified": {
15905
+ "type": "boolean"
15906
+ }
15907
+ },
15908
+ "required": [
15909
+ "phone",
15910
+ "verified"
15911
+ ]
15912
+ }
15913
+ },
15914
+ "required": [
15915
+ "data"
15916
+ ]
15917
+ },
15918
+ "example": {
15919
+ "data": {
15920
+ "phone": "+15551234567",
15921
+ "verified": true
15922
+ }
15923
+ }
15924
+ }
15925
+ }
15926
+ },
15927
+ "401": {
15928
+ "description": "unauthorized | step_up_required",
15929
+ "content": {
15930
+ "application/problem+json": {
15931
+ "schema": {
15932
+ "$ref": "#/components/schemas/Problem"
15933
+ }
15934
+ }
15935
+ }
15936
+ },
15937
+ "409": {
15938
+ "description": "passwordless_phone_taken",
15939
+ "content": {
15940
+ "application/problem+json": {
15941
+ "schema": {
15942
+ "$ref": "#/components/schemas/Problem"
15943
+ }
15944
+ }
15945
+ }
15946
+ },
15947
+ "422": {
15948
+ "description": "passwordless_code_invalid | passwordless_invalid_input",
15949
+ "content": {
15950
+ "application/problem+json": {
15951
+ "schema": {
15952
+ "$ref": "#/components/schemas/Problem"
15953
+ }
15954
+ }
15955
+ }
15956
+ }
15957
+ }
15958
+ }
15959
+ },
15960
+ "/phone/send": {
15961
+ "post": {
15962
+ "operationId": "post_passwordless_PhoneSendEndpoint",
15963
+ "summary": "Send a phone sign-in code",
15964
+ "tags": [
15965
+ "passwordless"
15966
+ ],
15967
+ "x-polaris-effect": "write",
15968
+ "x-polaris-receipt": false,
15969
+ "x-polaris-plugin": "passwordless",
15970
+ "x-polaris-rate-limit": "mfa_send",
15971
+ "requestBody": {
15972
+ "required": true,
15973
+ "content": {
15974
+ "application/json": {
15975
+ "schema": {
15976
+ "type": "object",
15977
+ "properties": {
15978
+ "phone": {
15979
+ "type": "string",
15980
+ "maxLength": 32
15981
+ }
15982
+ },
15983
+ "required": [
15984
+ "phone"
15985
+ ]
15986
+ }
15987
+ }
15988
+ }
15989
+ },
15990
+ "responses": {
15991
+ "202": {
15992
+ "description": "Success",
15993
+ "content": {
15994
+ "application/json": {
15995
+ "schema": {
15996
+ "type": "object",
15997
+ "properties": {
15998
+ "data": {
15999
+ "type": "object",
16000
+ "properties": {
16001
+ "status": {
16002
+ "type": "string"
16003
+ }
16004
+ },
16005
+ "required": [
16006
+ "status"
16007
+ ]
16008
+ }
16009
+ },
16010
+ "required": [
16011
+ "data"
16012
+ ]
16013
+ },
16014
+ "example": {
16015
+ "data": {
16016
+ "status": "sent"
16017
+ }
16018
+ }
16019
+ }
16020
+ }
16021
+ },
16022
+ "422": {
16023
+ "description": "passwordless_invalid_input",
16024
+ "content": {
16025
+ "application/problem+json": {
16026
+ "schema": {
16027
+ "$ref": "#/components/schemas/Problem"
16028
+ }
16029
+ }
16030
+ }
16031
+ }
16032
+ }
16033
+ }
16034
+ },
16035
+ "/phone/verify": {
16036
+ "post": {
16037
+ "operationId": "post_passwordless_PhoneVerifyEndpoint",
16038
+ "summary": "Sign in with a phone code",
16039
+ "tags": [
16040
+ "passwordless"
16041
+ ],
16042
+ "x-polaris-effect": "write",
16043
+ "x-polaris-receipt": true,
16044
+ "x-polaris-plugin": "passwordless",
16045
+ "x-polaris-rate-limit": "token_consume",
16046
+ "requestBody": {
16047
+ "required": true,
16048
+ "content": {
16049
+ "application/json": {
16050
+ "schema": {
16051
+ "type": "object",
16052
+ "properties": {
16053
+ "phone": {
16054
+ "type": "string",
16055
+ "maxLength": 32
16056
+ },
16057
+ "code": {
16058
+ "type": "string",
16059
+ "format": "password",
16060
+ "x-polaris-sensitive": true
16061
+ }
16062
+ },
16063
+ "required": [
16064
+ "phone",
16065
+ "code"
16066
+ ]
16067
+ }
16068
+ }
16069
+ }
16070
+ },
16071
+ "responses": {
16072
+ "200": {
16073
+ "description": "Success",
16074
+ "content": {
16075
+ "application/json": {
16076
+ "schema": {
16077
+ "type": "object",
16078
+ "properties": {
16079
+ "data": {
16080
+ "type": "object",
16081
+ "properties": {
16082
+ "access_token": {
16083
+ "type": "string"
16084
+ },
16085
+ "token_type": {
16086
+ "type": "string"
16087
+ },
16088
+ "expires_in": {
16089
+ "type": "integer"
16090
+ },
16091
+ "refresh_token": {
16092
+ "type": "string"
16093
+ },
16094
+ "user": {
16095
+ "type": "object",
16096
+ "properties": {
16097
+ "id": {
16098
+ "type": "string"
16099
+ },
16100
+ "email": {
16101
+ "type": "string"
16102
+ },
16103
+ "email_verified": {
16104
+ "type": "boolean"
16105
+ }
16106
+ },
16107
+ "required": [
16108
+ "id",
16109
+ "email",
16110
+ "email_verified"
16111
+ ]
16112
+ }
16113
+ },
16114
+ "required": [
16115
+ "access_token",
16116
+ "token_type",
16117
+ "expires_in",
16118
+ "refresh_token",
16119
+ "user"
16120
+ ]
16121
+ }
16122
+ },
16123
+ "required": [
16124
+ "data"
16125
+ ]
16126
+ },
16127
+ "example": {
16128
+ "data": {
16129
+ "access_token": "<jwt>",
16130
+ "token_type": "Bearer",
16131
+ "expires_in": 900,
16132
+ "refresh_token": "<opaque>",
16133
+ "user": {
16134
+ "id": "018f...",
16135
+ "email": "ada@example.com",
16136
+ "email_verified": true
16137
+ }
16138
+ }
16139
+ }
16140
+ }
16141
+ }
16142
+ },
16143
+ "403": {
16144
+ "description": "passwordless_account_disabled",
16145
+ "content": {
16146
+ "application/problem+json": {
16147
+ "schema": {
16148
+ "$ref": "#/components/schemas/Problem"
16149
+ }
16150
+ }
16151
+ }
16152
+ },
16153
+ "422": {
16154
+ "description": "passwordless_code_invalid | passwordless_invalid_input",
16155
+ "content": {
16156
+ "application/problem+json": {
16157
+ "schema": {
16158
+ "$ref": "#/components/schemas/Problem"
16159
+ }
16160
+ }
16161
+ }
16162
+ }
16163
+ }
16164
+ }
16165
+ },
16166
+ "/username/sign-in": {
16167
+ "post": {
16168
+ "operationId": "post_username_SignInEndpoint",
16169
+ "summary": "Sign in with a username and a password",
16170
+ "tags": [
16171
+ "username"
16172
+ ],
16173
+ "x-polaris-effect": "write",
16174
+ "x-polaris-receipt": true,
16175
+ "x-polaris-plugin": "username",
16176
+ "x-polaris-rate-limit": "login",
16177
+ "requestBody": {
16178
+ "required": true,
16179
+ "content": {
16180
+ "application/json": {
16181
+ "schema": {
16182
+ "type": "object",
16183
+ "properties": {
16184
+ "username": {
16185
+ "type": "string",
16186
+ "maxLength": 320
16187
+ },
16188
+ "password": {
16189
+ "type": "string",
16190
+ "format": "password",
16191
+ "x-polaris-sensitive": true
16192
+ }
16193
+ },
16194
+ "required": [
16195
+ "username",
16196
+ "password"
16197
+ ]
16198
+ }
16199
+ }
16200
+ }
16201
+ },
16202
+ "responses": {
16203
+ "200": {
16204
+ "description": "Success",
16205
+ "content": {
16206
+ "application/json": {
16207
+ "schema": {
16208
+ "type": "object",
16209
+ "properties": {
16210
+ "data": {
16211
+ "type": "object",
16212
+ "properties": {
16213
+ "access_token": {
16214
+ "type": "string"
16215
+ },
16216
+ "token_type": {
16217
+ "type": "string"
16218
+ },
16219
+ "expires_in": {
16220
+ "type": "integer"
16221
+ },
16222
+ "refresh_token": {
16223
+ "type": "string"
16224
+ },
16225
+ "user": {
16226
+ "type": "object",
16227
+ "properties": {
16228
+ "id": {
16229
+ "type": "string"
16230
+ },
16231
+ "email": {
16232
+ "type": "string"
16233
+ },
16234
+ "email_verified": {
16235
+ "type": "boolean"
16236
+ }
16237
+ },
16238
+ "required": [
16239
+ "id",
16240
+ "email",
16241
+ "email_verified"
16242
+ ]
16243
+ }
16244
+ },
16245
+ "required": [
16246
+ "access_token",
16247
+ "token_type",
16248
+ "expires_in",
16249
+ "refresh_token",
16250
+ "user"
16251
+ ]
16252
+ }
16253
+ },
16254
+ "required": [
16255
+ "data"
16256
+ ]
16257
+ },
16258
+ "example": {
16259
+ "data": {
16260
+ "access_token": "<jwt>",
16261
+ "token_type": "Bearer",
16262
+ "expires_in": 900,
16263
+ "refresh_token": "<opaque>",
16264
+ "user": {
16265
+ "id": "018f...",
16266
+ "email": "ada@example.com",
16267
+ "email_verified": true
16268
+ }
16269
+ }
16270
+ }
16271
+ }
16272
+ }
16273
+ },
16274
+ "401": {
16275
+ "description": "username_invalid_credentials",
16276
+ "content": {
16277
+ "application/problem+json": {
16278
+ "schema": {
16279
+ "$ref": "#/components/schemas/Problem"
16280
+ }
16281
+ }
16282
+ }
16283
+ },
16284
+ "403": {
16285
+ "description": "username_email_unverified | username_account_disabled",
16286
+ "content": {
16287
+ "application/problem+json": {
16288
+ "schema": {
16289
+ "$ref": "#/components/schemas/Problem"
16290
+ }
16291
+ }
16292
+ }
16293
+ },
16294
+ "422": {
16295
+ "description": "username_invalid_input",
16296
+ "content": {
16297
+ "application/problem+json": {
16298
+ "schema": {
16299
+ "$ref": "#/components/schemas/Problem"
16300
+ }
16301
+ }
16302
+ }
16303
+ }
16304
+ }
16305
+ }
16306
+ },
16307
+ "/username": {
16308
+ "patch": {
16309
+ "operationId": "patch_username_UpdateEndpoint",
16310
+ "summary": "Set or change your username",
16311
+ "tags": [
16312
+ "username"
16313
+ ],
16314
+ "x-polaris-effect": "write",
16315
+ "x-polaris-receipt": true,
16316
+ "x-polaris-plugin": "username",
16317
+ "security": [
16318
+ {
16319
+ "bearerAuth": []
16320
+ }
16321
+ ],
16322
+ "requestBody": {
16323
+ "required": true,
16324
+ "content": {
16325
+ "application/json": {
16326
+ "schema": {
16327
+ "type": "object",
16328
+ "properties": {
16329
+ "username": {
16330
+ "type": "string",
16331
+ "maxLength": 64
16332
+ },
16333
+ "display_username": {
16334
+ "type": "string",
16335
+ "maxLength": 64
16336
+ }
16337
+ },
16338
+ "required": [
16339
+ "username"
16340
+ ]
16341
+ }
16342
+ }
16343
+ }
16344
+ },
16345
+ "responses": {
16346
+ "200": {
16347
+ "description": "Success",
16348
+ "content": {
16349
+ "application/json": {
16350
+ "schema": {
16351
+ "type": "object",
16352
+ "properties": {
16353
+ "data": {
16354
+ "type": "object",
16355
+ "properties": {
16356
+ "username": {
16357
+ "type": "string"
16358
+ },
16359
+ "display_username": {
16360
+ "type": "string"
16361
+ }
16362
+ },
16363
+ "required": [
16364
+ "username",
16365
+ "display_username"
16366
+ ]
16367
+ }
16368
+ },
16369
+ "required": [
16370
+ "data"
16371
+ ]
16372
+ },
16373
+ "example": {
16374
+ "data": {
16375
+ "username": "ada.lovelace",
16376
+ "display_username": "Ada.Lovelace"
16377
+ }
16378
+ }
16379
+ }
16380
+ }
16381
+ },
16382
+ "401": {
16383
+ "description": "unauthorized",
16384
+ "content": {
16385
+ "application/problem+json": {
16386
+ "schema": {
16387
+ "$ref": "#/components/schemas/Problem"
16388
+ }
16389
+ }
16390
+ }
16391
+ },
16392
+ "409": {
16393
+ "description": "username_taken",
16394
+ "content": {
16395
+ "application/problem+json": {
16396
+ "schema": {
16397
+ "$ref": "#/components/schemas/Problem"
16398
+ }
16399
+ }
16400
+ }
16401
+ },
16402
+ "422": {
16403
+ "description": "username_invalid",
16404
+ "content": {
16405
+ "application/problem+json": {
16406
+ "schema": {
16407
+ "$ref": "#/components/schemas/Problem"
16408
+ }
16409
+ }
16410
+ }
16411
+ }
16412
+ }
16413
+ }
16414
+ },
16415
+ "/anonymous/convert": {
16416
+ "post": {
16417
+ "operationId": "post_anonymous_ConvertEndpoint",
16418
+ "summary": "Convert the guest into an account",
16419
+ "tags": [
16420
+ "anonymous"
16421
+ ],
16422
+ "x-polaris-effect": "write",
16423
+ "x-polaris-receipt": true,
16424
+ "x-polaris-plugin": "anonymous",
16425
+ "security": [
16426
+ {
16427
+ "bearerAuth": []
16428
+ }
16429
+ ],
16430
+ "requestBody": {
16431
+ "required": true,
16432
+ "content": {
16433
+ "application/json": {
16434
+ "schema": {
16435
+ "type": "object",
16436
+ "properties": {
16437
+ "access_token": {
16438
+ "type": "string",
16439
+ "format": "password",
16440
+ "x-polaris-sensitive": true
16441
+ }
16442
+ },
16443
+ "required": [
16444
+ "access_token"
16445
+ ]
16446
+ }
16447
+ }
16448
+ }
16449
+ },
16450
+ "responses": {
16451
+ "200": {
16452
+ "description": "Success",
16453
+ "content": {
16454
+ "application/json": {
16455
+ "schema": {
16456
+ "type": "object",
16457
+ "properties": {
16458
+ "data": {
16459
+ "type": "object",
16460
+ "properties": {
16461
+ "guest_id": {
16462
+ "type": "string"
16463
+ },
16464
+ "user_id": {
16465
+ "type": "string"
16466
+ },
16467
+ "status": {
16468
+ "type": "string"
16469
+ }
16470
+ },
16471
+ "required": [
16472
+ "guest_id",
16473
+ "user_id",
16474
+ "status"
16475
+ ]
16476
+ }
16477
+ },
16478
+ "required": [
16479
+ "data"
16480
+ ]
16481
+ },
16482
+ "example": {
16483
+ "data": {
16484
+ "guest_id": "018f...",
16485
+ "user_id": "018f...",
16486
+ "status": "converted"
16487
+ }
16488
+ }
16489
+ }
16490
+ }
16491
+ },
16492
+ "401": {
16493
+ "description": "unauthorized",
16494
+ "content": {
16495
+ "application/problem+json": {
16496
+ "schema": {
16497
+ "$ref": "#/components/schemas/Problem"
16498
+ }
16499
+ }
16500
+ }
16501
+ },
16502
+ "403": {
16503
+ "description": "anonymous_not_a_guest",
16504
+ "content": {
16505
+ "application/problem+json": {
16506
+ "schema": {
16507
+ "$ref": "#/components/schemas/Problem"
16508
+ }
16509
+ }
16510
+ }
16511
+ },
16512
+ "422": {
16513
+ "description": "anonymous_invalid_input | anonymous_token_invalid",
16514
+ "content": {
16515
+ "application/problem+json": {
16516
+ "schema": {
16517
+ "$ref": "#/components/schemas/Problem"
16518
+ }
16519
+ }
16520
+ }
16521
+ }
16522
+ }
16523
+ }
16524
+ },
16525
+ "/anonymous/sign-in": {
16526
+ "post": {
16527
+ "operationId": "post_anonymous_SignInEndpoint",
16528
+ "summary": "Sign in as a guest",
16529
+ "tags": [
16530
+ "anonymous"
16531
+ ],
16532
+ "x-polaris-effect": "write",
16533
+ "x-polaris-receipt": true,
16534
+ "x-polaris-plugin": "anonymous",
16535
+ "x-polaris-rate-limit": "register",
16536
+ "responses": {
16537
+ "201": {
16538
+ "description": "Success",
16539
+ "content": {
16540
+ "application/json": {
16541
+ "schema": {
16542
+ "type": "object",
16543
+ "properties": {
16544
+ "data": {
16545
+ "type": "object",
16546
+ "properties": {
16547
+ "access_token": {
16548
+ "type": "string"
16549
+ },
16550
+ "token_type": {
16551
+ "type": "string"
16552
+ },
16553
+ "expires_in": {
16554
+ "type": "integer"
16555
+ },
16556
+ "refresh_token": {
16557
+ "type": "string"
16558
+ },
16559
+ "user": {
16560
+ "type": "object",
16561
+ "properties": {
16562
+ "id": {
16563
+ "type": "string"
16564
+ },
16565
+ "email": {
16566
+ "type": "string"
16567
+ },
16568
+ "email_verified": {
16569
+ "type": "boolean"
16570
+ }
16571
+ },
16572
+ "required": [
16573
+ "id",
16574
+ "email",
16575
+ "email_verified"
16576
+ ]
16577
+ }
16578
+ },
16579
+ "required": [
16580
+ "access_token",
16581
+ "token_type",
16582
+ "expires_in",
16583
+ "refresh_token",
16584
+ "user"
16585
+ ]
16586
+ }
16587
+ },
16588
+ "required": [
16589
+ "data"
16590
+ ]
16591
+ },
16592
+ "example": {
16593
+ "data": {
16594
+ "access_token": "<jwt>",
16595
+ "token_type": "Bearer",
16596
+ "expires_in": 900,
16597
+ "refresh_token": "<opaque>",
16598
+ "user": {
16599
+ "id": "018f...",
16600
+ "email": "018f...@anonymous.invalid",
16601
+ "email_verified": false
16602
+ }
16603
+ }
16604
+ }
16605
+ }
16606
+ }
16607
+ }
16608
+ }
16609
+ }
16610
+ },
16611
+ "/multi-session/last-method": {
16612
+ "get": {
16613
+ "operationId": "get_multi-session_LastMethodEndpoint",
16614
+ "summary": "Read the device's last sign-in method",
16615
+ "tags": [
16616
+ "multi-session"
16617
+ ],
16618
+ "x-polaris-effect": "read",
16619
+ "x-polaris-receipt": false,
16620
+ "x-polaris-plugin": "multi-session",
16621
+ "responses": {
16622
+ "200": {
16623
+ "description": "Success",
16624
+ "content": {
16625
+ "application/json": {
16626
+ "schema": {
16627
+ "type": "object",
16628
+ "properties": {
16629
+ "data": {
16630
+ "type": "object",
16631
+ "properties": {
16632
+ "last_method": {
16633
+ "type": "string"
16634
+ }
16635
+ },
16636
+ "required": [
16637
+ "last_method"
16638
+ ]
16639
+ }
16640
+ },
16641
+ "required": [
16642
+ "data"
16643
+ ]
16644
+ },
16645
+ "example": {
16646
+ "data": {
16647
+ "last_method": "magic_link"
16648
+ }
16649
+ }
16650
+ }
16651
+ }
16652
+ }
16653
+ }
16654
+ }
16655
+ },
16656
+ "/multi-session/list": {
16657
+ "get": {
16658
+ "operationId": "get_multi-session_ListEndpoint",
16659
+ "summary": "List the accounts signed in on this device",
16660
+ "tags": [
16661
+ "multi-session"
16662
+ ],
16663
+ "x-polaris-effect": "read",
16664
+ "x-polaris-receipt": false,
16665
+ "x-polaris-plugin": "multi-session",
16666
+ "security": [
16667
+ {
16668
+ "bearerAuth": []
16669
+ }
16670
+ ],
16671
+ "responses": {
16672
+ "200": {
16673
+ "description": "Success",
16674
+ "content": {
16675
+ "application/json": {
16676
+ "schema": {
16677
+ "type": "object",
16678
+ "properties": {
16679
+ "data": {
16680
+ "type": "array",
16681
+ "items": {
16682
+ "type": "object",
16683
+ "properties": {
16684
+ "session_id": {
16685
+ "type": "string"
16686
+ },
16687
+ "user": {
16688
+ "type": "object",
16689
+ "properties": {
16690
+ "id": {
16691
+ "type": "string"
16692
+ },
16693
+ "email": {
16694
+ "type": "string"
16695
+ },
16696
+ "display_name": {
16697
+ "type": "string"
16698
+ }
16699
+ },
16700
+ "required": [
16701
+ "id",
16702
+ "email",
16703
+ "display_name"
16704
+ ]
16705
+ },
16706
+ "last_method": {
16707
+ "type": "string"
16708
+ },
16709
+ "signed_in_at": {
16710
+ "type": "string"
16711
+ },
16712
+ "last_seen": {
16713
+ "type": "string"
16714
+ },
16715
+ "current": {
16716
+ "type": "boolean"
16717
+ }
16718
+ },
16719
+ "required": [
16720
+ "session_id",
16721
+ "user",
16722
+ "last_method",
16723
+ "signed_in_at",
16724
+ "last_seen",
16725
+ "current"
16726
+ ]
16727
+ }
16728
+ }
16729
+ },
16730
+ "required": [
16731
+ "data"
16732
+ ]
16733
+ },
16734
+ "example": {
16735
+ "data": [
16736
+ {
16737
+ "session_id": "018f...",
16738
+ "user": {
16739
+ "id": "018f...",
16740
+ "email": "ada@example.com",
16741
+ "display_name": "Ada"
16742
+ },
16743
+ "last_method": "magic_link",
16744
+ "signed_in_at": "2026-10-09T10:00:00+00:00",
16745
+ "last_seen": "2026-10-09T10:05:00+00:00",
16746
+ "current": true
16747
+ }
16748
+ ]
16749
+ }
16750
+ }
16751
+ }
16752
+ },
16753
+ "401": {
16754
+ "description": "unauthorized",
16755
+ "content": {
16756
+ "application/problem+json": {
16757
+ "schema": {
16758
+ "$ref": "#/components/schemas/Problem"
16759
+ }
16760
+ }
16761
+ }
16762
+ },
16763
+ "403": {
16764
+ "description": "multi_session_device_unknown",
16765
+ "content": {
16766
+ "application/problem+json": {
16767
+ "schema": {
16768
+ "$ref": "#/components/schemas/Problem"
16769
+ }
16770
+ }
16771
+ }
16772
+ }
16773
+ }
16774
+ }
16775
+ },
16776
+ "/multi-session/{sessionId}": {
16777
+ "delete": {
16778
+ "operationId": "delete_multi-session_RevokeEndpoint",
16779
+ "summary": "Sign one account out of this device",
16780
+ "tags": [
16781
+ "multi-session"
16782
+ ],
16783
+ "x-polaris-effect": "destructive",
16784
+ "x-polaris-receipt": true,
16785
+ "x-polaris-plugin": "multi-session",
16786
+ "security": [
16787
+ {
16788
+ "bearerAuth": []
16789
+ }
16790
+ ],
16791
+ "parameters": [
16792
+ {
16793
+ "name": "sessionId",
16794
+ "in": "path",
16795
+ "required": true,
16796
+ "schema": {
16797
+ "type": "string"
16798
+ }
16799
+ }
16800
+ ],
16801
+ "responses": {
16802
+ "200": {
16803
+ "description": "Success",
16804
+ "content": {
16805
+ "application/json": {
16806
+ "schema": {
16807
+ "type": "object",
16808
+ "properties": {
16809
+ "data": {
16810
+ "type": "object",
16811
+ "properties": {
16812
+ "status": {
16813
+ "type": "string"
16814
+ }
16815
+ },
16816
+ "required": [
16817
+ "status"
16818
+ ]
16819
+ }
16820
+ },
16821
+ "required": [
16822
+ "data"
16823
+ ]
16824
+ },
16825
+ "example": {
16826
+ "data": {
16827
+ "status": "revoked"
16828
+ }
16829
+ }
16830
+ }
16831
+ }
16832
+ },
16833
+ "401": {
16834
+ "description": "unauthorized",
16835
+ "content": {
16836
+ "application/problem+json": {
16837
+ "schema": {
16838
+ "$ref": "#/components/schemas/Problem"
16839
+ }
16840
+ }
16841
+ }
16842
+ },
16843
+ "403": {
16844
+ "description": "multi_session_device_unknown",
16845
+ "content": {
16846
+ "application/problem+json": {
16847
+ "schema": {
16848
+ "$ref": "#/components/schemas/Problem"
16849
+ }
16850
+ }
16851
+ }
16852
+ },
16853
+ "404": {
16854
+ "description": "multi_session_session_not_found",
16855
+ "content": {
16856
+ "application/problem+json": {
16857
+ "schema": {
16858
+ "$ref": "#/components/schemas/Problem"
16859
+ }
16860
+ }
16861
+ }
16862
+ }
16863
+ }
16864
+ }
16865
+ },
16866
+ "/multi-session/switch": {
16867
+ "post": {
16868
+ "operationId": "post_multi-session_SwitchEndpoint",
16869
+ "summary": "Switch to another account signed in on this device",
16870
+ "tags": [
16871
+ "multi-session"
16872
+ ],
16873
+ "x-polaris-effect": "write",
16874
+ "x-polaris-receipt": true,
16875
+ "x-polaris-plugin": "multi-session",
16876
+ "security": [
16877
+ {
16878
+ "bearerAuth": []
16879
+ }
16880
+ ],
16881
+ "requestBody": {
16882
+ "required": true,
16883
+ "content": {
16884
+ "application/json": {
16885
+ "schema": {
16886
+ "type": "object",
16887
+ "properties": {
16888
+ "session_id": {
16889
+ "type": "string"
16890
+ }
16891
+ },
16892
+ "required": [
16893
+ "session_id"
16894
+ ]
16895
+ }
16896
+ }
16897
+ }
16898
+ },
16899
+ "responses": {
16900
+ "200": {
16901
+ "description": "Success",
16902
+ "content": {
16903
+ "application/json": {
16904
+ "schema": {
16905
+ "type": "object",
16906
+ "properties": {
16907
+ "data": {
16908
+ "type": "object",
16909
+ "properties": {
16910
+ "access_token": {
16911
+ "type": "string"
16912
+ },
16913
+ "token_type": {
16914
+ "type": "string"
16915
+ },
16916
+ "expires_in": {
16917
+ "type": "integer"
16918
+ },
16919
+ "refresh_token": {
16920
+ "type": "string"
16921
+ },
16922
+ "user": {
16923
+ "type": "object",
16924
+ "properties": {
16925
+ "id": {
16926
+ "type": "string"
16927
+ },
16928
+ "email": {
16929
+ "type": "string"
16930
+ },
16931
+ "email_verified": {
16932
+ "type": "boolean"
16933
+ }
16934
+ },
16935
+ "required": [
16936
+ "id",
16937
+ "email",
16938
+ "email_verified"
16939
+ ]
16940
+ }
16941
+ },
16942
+ "required": [
16943
+ "access_token",
16944
+ "token_type",
16945
+ "expires_in",
16946
+ "refresh_token",
16947
+ "user"
16948
+ ]
16949
+ }
16950
+ },
16951
+ "required": [
16952
+ "data"
16953
+ ]
16954
+ },
16955
+ "example": {
16956
+ "data": {
16957
+ "access_token": "<jwt>",
16958
+ "token_type": "Bearer",
16959
+ "expires_in": 900,
16960
+ "refresh_token": "<opaque>",
16961
+ "user": {
16962
+ "id": "018f...",
16963
+ "email": "grace@example.com",
16964
+ "email_verified": true
16965
+ }
16966
+ }
16967
+ }
16968
+ }
16969
+ }
16970
+ },
16971
+ "401": {
16972
+ "description": "unauthorized",
16973
+ "content": {
16974
+ "application/problem+json": {
16975
+ "schema": {
16976
+ "$ref": "#/components/schemas/Problem"
16977
+ }
16978
+ }
16979
+ }
16980
+ },
16981
+ "403": {
16982
+ "description": "multi_session_device_unknown",
16983
+ "content": {
16984
+ "application/problem+json": {
16985
+ "schema": {
16986
+ "$ref": "#/components/schemas/Problem"
16987
+ }
16988
+ }
16989
+ }
16990
+ },
16991
+ "404": {
16992
+ "description": "multi_session_session_not_found",
16993
+ "content": {
16994
+ "application/problem+json": {
16995
+ "schema": {
16996
+ "$ref": "#/components/schemas/Problem"
16997
+ }
16998
+ }
16999
+ }
17000
+ },
17001
+ "422": {
17002
+ "description": "multi_session_invalid_input",
17003
+ "content": {
17004
+ "application/problem+json": {
17005
+ "schema": {
17006
+ "$ref": "#/components/schemas/Problem"
17007
+ }
17008
+ }
17009
+ }
17010
+ }
17011
+ }
17012
+ }
14925
17013
  }
14926
17014
  },
14927
17015
  "components": {