-
-
Notifications
You must be signed in to change notification settings - Fork 32
Expand file tree
/
Copy pathapi.ts
More file actions
11776 lines (11218 loc) · 561 KB
/
api.ts
File metadata and controls
11776 lines (11218 loc) · 561 KB
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
// Copyright © 2025 Ory Corp
// SPDX-License-Identifier: Apache-2.0
/* tslint:disable */
/* eslint-disable */
/**
* Ory Identities API
* This is the API specification for Ory Identities with features such as registration, login, recovery, account verification, profile settings, password reset, identity management, session management, email and sms delivery, and more.
*
* The version of the OpenAPI document: 1.0.0
* Contact: office@ory.sh
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import { Configuration } from "./configuration"
import globalAxios, {
AxiosPromise,
AxiosInstance,
AxiosRequestConfig,
} from "axios"
// Some imports not used depending on template conditions
// @ts-ignore
import {
DUMMY_BASE_URL,
assertParamExists,
setApiKeyToObject,
setBasicAuthToObject,
setBearerAuthToObject,
setOAuthToObject,
setSearchParams,
serializeDataIfNeeded,
toPathString,
createRequestFunction,
} from "./common"
// @ts-ignore
import {
BASE_PATH,
COLLECTION_FORMATS,
RequestArgs,
BaseAPI,
RequiredError,
} from "./base"
/**
* The authenticator assurance level can be one of \"aal1\", \"aal2\", or \"aal3\". A higher number means that it is harder for an attacker to compromise the account. Generally, \"aal1\" implies that one authentication factor was used while AAL2 implies that two factors (e.g. password + TOTP) have been used. To learn more about these levels please head over to: https://www.ory.sh/kratos/docs/concepts/credentials
* @export
* @enum {string}
*/
export const AuthenticatorAssuranceLevel = {
Aal0: "aal0",
Aal1: "aal1",
Aal2: "aal2",
Aal3: "aal3",
} as const
export type AuthenticatorAssuranceLevel =
typeof AuthenticatorAssuranceLevel[keyof typeof AuthenticatorAssuranceLevel]
/**
* Patch identities response
* @export
* @interface BatchPatchIdentitiesResponse
*/
export interface BatchPatchIdentitiesResponse {
/**
* The patch responses for the individual identities.
* @type {Array<IdentityPatchResponse>}
* @memberof BatchPatchIdentitiesResponse
*/
identities?: Array<IdentityPatchResponse>
}
/**
* Control API consistency guarantees
* @export
* @interface ConsistencyRequestParameters
*/
export interface ConsistencyRequestParameters {
/**
* Read Consistency Level (preview) The read consistency level determines the consistency guarantee for reads: strong (slow): The read is guaranteed to return the most recent data committed at the start of the read. eventual (very fast): The result will return data that is about 4.8 seconds old. The default consistency guarantee can be changed in the Ory Network Console or using the Ory CLI with `ory patch project --replace \'/previews/default_read_consistency_level=\"strong\"\'`. Setting the default consistency level to `eventual` may cause regressions in the future as we add consistency controls to more APIs. Currently, the following APIs will be affected by this setting: `GET /admin/identities` This feature is in preview and only available in Ory Network. ConsistencyLevelUnset ConsistencyLevelUnset is the unset / default consistency level. strong ConsistencyLevelStrong ConsistencyLevelStrong is the strong consistency level. eventual ConsistencyLevelEventual ConsistencyLevelEventual is the eventual consistency level using follower read timestamps.
* @type {string}
* @memberof ConsistencyRequestParameters
*/
consistency?: ConsistencyRequestParametersConsistencyEnum
}
export const ConsistencyRequestParametersConsistencyEnum = {
Empty: "",
Strong: "strong",
Eventual: "eventual",
} as const
export type ConsistencyRequestParametersConsistencyEnum =
typeof ConsistencyRequestParametersConsistencyEnum[keyof typeof ConsistencyRequestParametersConsistencyEnum]
/**
* @type ContinueWith
* @export
*/
export type ContinueWith =
| ContinueWithRecoveryUi
| ContinueWithSetOrySessionToken
| ContinueWithSettingsUi
| ContinueWithVerificationUi
/**
* Indicates, that the UI flow could be continued by showing a recovery ui
* @export
* @interface ContinueWithRecoveryUi
*/
export interface ContinueWithRecoveryUi {
/**
* Action will always be `show_recovery_ui` show_recovery_ui ContinueWithActionShowRecoveryUIString
* @type {string}
* @memberof ContinueWithRecoveryUi
*/
action: ContinueWithRecoveryUiActionEnum
/**
*
* @type {ContinueWithRecoveryUiFlow}
* @memberof ContinueWithRecoveryUi
*/
flow: ContinueWithRecoveryUiFlow
}
export const ContinueWithRecoveryUiActionEnum = {
ShowRecoveryUi: "show_recovery_ui",
} as const
export type ContinueWithRecoveryUiActionEnum =
typeof ContinueWithRecoveryUiActionEnum[keyof typeof ContinueWithRecoveryUiActionEnum]
/**
*
* @export
* @interface ContinueWithRecoveryUiFlow
*/
export interface ContinueWithRecoveryUiFlow {
/**
* The ID of the recovery flow
* @type {string}
* @memberof ContinueWithRecoveryUiFlow
*/
id: string
/**
* The URL of the recovery flow
* @type {string}
* @memberof ContinueWithRecoveryUiFlow
*/
url?: string
}
/**
* Indicates that a session was issued, and the application should use this token for authenticated requests
* @export
* @interface ContinueWithSetOrySessionToken
*/
export interface ContinueWithSetOrySessionToken {
/**
* Action will always be `set_ory_session_token` set_ory_session_token ContinueWithActionSetOrySessionTokenString
* @type {string}
* @memberof ContinueWithSetOrySessionToken
*/
action: ContinueWithSetOrySessionTokenActionEnum
/**
* Token is the token of the session
* @type {string}
* @memberof ContinueWithSetOrySessionToken
*/
ory_session_token: string
}
export const ContinueWithSetOrySessionTokenActionEnum = {
SetOrySessionToken: "set_ory_session_token",
} as const
export type ContinueWithSetOrySessionTokenActionEnum =
typeof ContinueWithSetOrySessionTokenActionEnum[keyof typeof ContinueWithSetOrySessionTokenActionEnum]
/**
* Indicates, that the UI flow could be continued by showing a settings ui
* @export
* @interface ContinueWithSettingsUi
*/
export interface ContinueWithSettingsUi {
/**
* Action will always be `show_settings_ui` show_settings_ui ContinueWithActionShowSettingsUIString
* @type {string}
* @memberof ContinueWithSettingsUi
*/
action: ContinueWithSettingsUiActionEnum
/**
*
* @type {ContinueWithSettingsUiFlow}
* @memberof ContinueWithSettingsUi
*/
flow: ContinueWithSettingsUiFlow
}
export const ContinueWithSettingsUiActionEnum = {
ShowSettingsUi: "show_settings_ui",
} as const
export type ContinueWithSettingsUiActionEnum =
typeof ContinueWithSettingsUiActionEnum[keyof typeof ContinueWithSettingsUiActionEnum]
/**
*
* @export
* @interface ContinueWithSettingsUiFlow
*/
export interface ContinueWithSettingsUiFlow {
/**
* The ID of the settings flow
* @type {string}
* @memberof ContinueWithSettingsUiFlow
*/
id: string
}
/**
* Indicates, that the UI flow could be continued by showing a verification ui
* @export
* @interface ContinueWithVerificationUi
*/
export interface ContinueWithVerificationUi {
/**
* Action will always be `show_verification_ui` show_verification_ui ContinueWithActionShowVerificationUIString
* @type {string}
* @memberof ContinueWithVerificationUi
*/
action: ContinueWithVerificationUiActionEnum
/**
*
* @type {ContinueWithVerificationUiFlow}
* @memberof ContinueWithVerificationUi
*/
flow: ContinueWithVerificationUiFlow
}
export const ContinueWithVerificationUiActionEnum = {
ShowVerificationUi: "show_verification_ui",
} as const
export type ContinueWithVerificationUiActionEnum =
typeof ContinueWithVerificationUiActionEnum[keyof typeof ContinueWithVerificationUiActionEnum]
/**
*
* @export
* @interface ContinueWithVerificationUiFlow
*/
export interface ContinueWithVerificationUiFlow {
/**
* The ID of the verification flow
* @type {string}
* @memberof ContinueWithVerificationUiFlow
*/
id: string
/**
* The URL of the verification flow
* @type {string}
* @memberof ContinueWithVerificationUiFlow
*/
url?: string
/**
* The address that should be verified in this flow
* @type {string}
* @memberof ContinueWithVerificationUiFlow
*/
verifiable_address: string
}
/**
* A Message\'s Status
* @export
* @enum {string}
*/
export const CourierMessageStatus = {
Queued: "queued",
Sent: "sent",
Processing: "processing",
Abandoned: "abandoned",
} as const
export type CourierMessageStatus =
typeof CourierMessageStatus[keyof typeof CourierMessageStatus]
/**
* It can either be `email` or `phone`
* @export
* @enum {string}
*/
export const CourierMessageType = {
Email: "email",
Phone: "phone",
} as const
export type CourierMessageType =
typeof CourierMessageType[keyof typeof CourierMessageType]
/**
* Create Identity Body
* @export
* @interface CreateIdentityBody
*/
export interface CreateIdentityBody {
/**
*
* @type {IdentityWithCredentials}
* @memberof CreateIdentityBody
*/
credentials?: IdentityWithCredentials
/**
* Store metadata about the user which is only accessible through admin APIs such as `GET /admin/identities/<id>`.
* @type {any}
* @memberof CreateIdentityBody
*/
metadata_admin?: any
/**
* Store metadata about the identity which the identity itself can see when calling for example the session endpoint. Do not store sensitive information (e.g. credit score) about the identity in this field.
* @type {any}
* @memberof CreateIdentityBody
*/
metadata_public?: any
/**
* RecoveryAddresses contains all the addresses that can be used to recover an identity. Use this structure to import recovery addresses for an identity. Please keep in mind that the address needs to be represented in the Identity Schema or this field will be overwritten on the next identity update.
* @type {Array<RecoveryIdentityAddress>}
* @memberof CreateIdentityBody
*/
recovery_addresses?: Array<RecoveryIdentityAddress>
/**
* SchemaID is the ID of the JSON Schema to be used for validating the identity\'s traits.
* @type {string}
* @memberof CreateIdentityBody
*/
schema_id: string
/**
*
* @type {IdentityState}
* @memberof CreateIdentityBody
*/
state?: IdentityState
/**
* Traits represent an identity\'s traits. The identity is able to create, modify, and delete traits in a self-service manner. The input will always be validated against the JSON Schema defined in `schema_url`.
* @type {object}
* @memberof CreateIdentityBody
*/
traits: object
/**
* VerifiableAddresses contains all the addresses that can be verified by the user. Use this structure to import verified addresses for an identity. Please keep in mind that the address needs to be represented in the Identity Schema or this field will be overwritten on the next identity update.
* @type {Array<VerifiableIdentityAddress>}
* @memberof CreateIdentityBody
*/
verifiable_addresses?: Array<VerifiableIdentityAddress>
}
/**
* Create Recovery Code for Identity Request Body
* @export
* @interface CreateRecoveryCodeForIdentityBody
*/
export interface CreateRecoveryCodeForIdentityBody {
/**
* Code Expires In The recovery code will expire after that amount of time has passed. Defaults to the configuration value of `selfservice.methods.code.config.lifespan`.
* @type {string}
* @memberof CreateRecoveryCodeForIdentityBody
*/
expires_in?: string
/**
* Identity to Recover The identity\'s ID you wish to recover.
* @type {string}
* @memberof CreateRecoveryCodeForIdentityBody
*/
identity_id: string
}
/**
* Create Recovery Link for Identity Request Body
* @export
* @interface CreateRecoveryLinkForIdentityBody
*/
export interface CreateRecoveryLinkForIdentityBody {
/**
* Link Expires In The recovery link will expire after that amount of time has passed. Defaults to the configuration value of `selfservice.methods.code.config.lifespan`.
* @type {string}
* @memberof CreateRecoveryLinkForIdentityBody
*/
expires_in?: string
/**
* Identity to Recover The identity\'s ID you wish to recover.
* @type {string}
* @memberof CreateRecoveryLinkForIdentityBody
*/
identity_id: string
}
/**
* Deleted Session Count
* @export
* @interface DeleteMySessionsCount
*/
export interface DeleteMySessionsCount {
/**
* The number of sessions that were revoked.
* @type {number}
* @memberof DeleteMySessionsCount
*/
count?: number
}
/**
*
* @export
* @interface ErrorAuthenticatorAssuranceLevelNotSatisfied
*/
export interface ErrorAuthenticatorAssuranceLevelNotSatisfied {
/**
*
* @type {GenericError}
* @memberof ErrorAuthenticatorAssuranceLevelNotSatisfied
*/
error?: GenericError
/**
* Points to where to redirect the user to next.
* @type {string}
* @memberof ErrorAuthenticatorAssuranceLevelNotSatisfied
*/
redirect_browser_to?: string
}
/**
*
* @export
* @interface ErrorBrowserLocationChangeRequired
*/
export interface ErrorBrowserLocationChangeRequired {
/**
*
* @type {ErrorGeneric}
* @memberof ErrorBrowserLocationChangeRequired
*/
error?: ErrorGeneric
/**
* Points to where to redirect the user to next.
* @type {string}
* @memberof ErrorBrowserLocationChangeRequired
*/
redirect_browser_to?: string
}
/**
* Is sent when a flow is replaced by a different flow of the same class
* @export
* @interface ErrorFlowReplaced
*/
export interface ErrorFlowReplaced {
/**
*
* @type {GenericError}
* @memberof ErrorFlowReplaced
*/
error?: GenericError
/**
* The flow ID that should be used for the new flow as it contains the correct messages.
* @type {string}
* @memberof ErrorFlowReplaced
*/
use_flow_id?: string
}
/**
* The standard Ory JSON API error format.
* @export
* @interface ErrorGeneric
*/
export interface ErrorGeneric {
/**
*
* @type {GenericError}
* @memberof ErrorGeneric
*/
error: GenericError
}
/**
*
* @export
* @interface FlowError
*/
export interface FlowError {
/**
* CreatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof FlowError
*/
created_at?: string
/**
*
* @type {object}
* @memberof FlowError
*/
error?: object
/**
* ID of the error container.
* @type {string}
* @memberof FlowError
*/
id: string
/**
* UpdatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof FlowError
*/
updated_at?: string
}
/**
*
* @export
* @interface GenericError
*/
export interface GenericError {
/**
* The status code
* @type {number}
* @memberof GenericError
*/
code?: number
/**
* Debug information This field is often not exposed to protect against leaking sensitive information.
* @type {string}
* @memberof GenericError
*/
debug?: string
/**
* Further error details
* @type {object}
* @memberof GenericError
*/
details?: object
/**
* The error ID Useful when trying to identify various errors in application logic.
* @type {string}
* @memberof GenericError
*/
id?: string
/**
* Error message The error\'s message.
* @type {string}
* @memberof GenericError
*/
message: string
/**
* A human-readable reason for the error
* @type {string}
* @memberof GenericError
*/
reason?: string
/**
* The request ID The request ID is often exposed internally in order to trace errors across service architectures. This is often a UUID.
* @type {string}
* @memberof GenericError
*/
request?: string
/**
* The status description
* @type {string}
* @memberof GenericError
*/
status?: string
}
/**
*
* @export
* @interface HealthNotReadyStatus
*/
export interface HealthNotReadyStatus {
/**
* Errors contains a list of errors that caused the not ready status.
* @type {{ [key: string]: string; }}
* @memberof HealthNotReadyStatus
*/
errors?: { [key: string]: string }
}
/**
*
* @export
* @interface HealthStatus
*/
export interface HealthStatus {
/**
* Status always contains \"ok\".
* @type {string}
* @memberof HealthStatus
*/
status?: string
}
/**
* An [identity](https://www.ory.sh/docs/kratos/concepts/identity-user-model) represents a (human) user in Ory.
* @export
* @interface Identity
*/
export interface Identity {
/**
* CreatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof Identity
*/
created_at?: string
/**
* Credentials represents all credentials that can be used for authenticating this identity.
* @type {{ [key: string]: IdentityCredentials; }}
* @memberof Identity
*/
credentials?: { [key: string]: IdentityCredentials }
/**
* ID is the identity\'s unique identifier. The Identity ID can not be changed and can not be chosen. This ensures future compatibility and optimization for distributed stores such as CockroachDB.
* @type {string}
* @memberof Identity
*/
id: string
/**
* NullJSONRawMessage represents a json.RawMessage that works well with JSON, SQL, and Swagger and is NULLable-
* @type {any}
* @memberof Identity
*/
metadata_admin?: any | null
/**
* NullJSONRawMessage represents a json.RawMessage that works well with JSON, SQL, and Swagger and is NULLable-
* @type {any}
* @memberof Identity
*/
metadata_public?: any | null
/**
*
* @type {string}
* @memberof Identity
*/
organization_id?: string | null
/**
* RecoveryAddresses contains all the addresses that can be used to recover an identity.
* @type {Array<RecoveryIdentityAddress>}
* @memberof Identity
*/
recovery_addresses?: Array<RecoveryIdentityAddress>
/**
* SchemaID is the ID of the JSON Schema to be used for validating the identity\'s traits.
* @type {string}
* @memberof Identity
*/
schema_id: string
/**
* SchemaURL is the URL of the endpoint where the identity\'s traits schema can be fetched from. format: url
* @type {string}
* @memberof Identity
*/
schema_url: string
/**
*
* @type {IdentityState}
* @memberof Identity
*/
state?: IdentityState
/**
*
* @type {string}
* @memberof Identity
*/
state_changed_at?: string
/**
* Traits represent an identity\'s traits. The identity is able to create, modify, and delete traits in a self-service manner. The input will always be validated against the JSON Schema defined in `schema_url`.
* @type {any}
* @memberof Identity
*/
traits: any
/**
* UpdatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof Identity
*/
updated_at?: string
/**
* VerifiableAddresses contains all the addresses that can be verified by the user.
* @type {Array<VerifiableIdentityAddress>}
* @memberof Identity
*/
verifiable_addresses?: Array<VerifiableIdentityAddress>
}
/**
* Credentials represents a specific credential type
* @export
* @interface IdentityCredentials
*/
export interface IdentityCredentials {
/**
*
* @type {object}
* @memberof IdentityCredentials
*/
config?: object
/**
* CreatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof IdentityCredentials
*/
created_at?: string
/**
* Identifiers represents a list of unique identifiers this credential type matches.
* @type {Array<string>}
* @memberof IdentityCredentials
*/
identifiers?: Array<string>
/**
*
* @type {IdentityCredentialsType}
* @memberof IdentityCredentials
*/
type?: IdentityCredentialsType
/**
* UpdatedAt is a helper struct field for gobuffalo.pop.
* @type {string}
* @memberof IdentityCredentials
*/
updated_at?: string
/**
* Version refers to the version of the credential. Useful when changing the config schema.
* @type {number}
* @memberof IdentityCredentials
*/
version?: number
}
/**
* CredentialsCode represents a one time login/registration code
* @export
* @interface IdentityCredentialsCode
*/
export interface IdentityCredentialsCode {
/**
*
* @type {string}
* @memberof IdentityCredentialsCode
*/
address_type?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsCode
*/
used_at?: string | null
}
/**
*
* @export
* @interface IdentityCredentialsOidc
*/
export interface IdentityCredentialsOidc {
/**
*
* @type {Array<IdentityCredentialsOidcProvider>}
* @memberof IdentityCredentialsOidc
*/
providers?: Array<IdentityCredentialsOidcProvider>
}
/**
*
* @export
* @interface IdentityCredentialsOidcProvider
*/
export interface IdentityCredentialsOidcProvider {
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
initial_access_token?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
initial_id_token?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
initial_refresh_token?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
organization?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
provider?: string
/**
*
* @type {string}
* @memberof IdentityCredentialsOidcProvider
*/
subject?: string
}
/**
*
* @export
* @interface IdentityCredentialsPassword
*/
export interface IdentityCredentialsPassword {
/**
* HashedPassword is a hash-representation of the password.
* @type {string}
* @memberof IdentityCredentialsPassword
*/
hashed_password?: string
}
/**
* and so on.
* @export
* @enum {string}
*/
export const IdentityCredentialsType = {
Password: "password",
Totp: "totp",
Oidc: "oidc",
Webauthn: "webauthn",
LookupSecret: "lookup_secret",
Code: "code",
} as const
export type IdentityCredentialsType =
typeof IdentityCredentialsType[keyof typeof IdentityCredentialsType]
/**
* Payload for patching an identity
* @export
* @interface IdentityPatch
*/
export interface IdentityPatch {
/**
*
* @type {CreateIdentityBody}
* @memberof IdentityPatch
*/
create?: CreateIdentityBody
/**
* The ID of this patch. The patch ID is optional. If specified, the ID will be returned in the response, so consumers of this API can correlate the response with the patch.
* @type {string}
* @memberof IdentityPatch
*/
patch_id?: string
}
/**
* Response for a single identity patch
* @export
* @interface IdentityPatchResponse
*/
export interface IdentityPatchResponse {
/**
* The action for this specific patch create ActionCreate Create this identity.
* @type {string}
* @memberof IdentityPatchResponse
*/
action?: IdentityPatchResponseActionEnum
/**
* The identity ID payload of this patch
* @type {string}
* @memberof IdentityPatchResponse
*/
identity?: string
/**
* The ID of this patch response, if an ID was specified in the patch.
* @type {string}
* @memberof IdentityPatchResponse
*/
patch_id?: string
}
export const IdentityPatchResponseActionEnum = {
Create: "create",
} as const
export type IdentityPatchResponseActionEnum =
typeof IdentityPatchResponseActionEnum[keyof typeof IdentityPatchResponseActionEnum]
/**
* An Identity JSON Schema Container
* @export
* @interface IdentitySchemaContainer
*/
export interface IdentitySchemaContainer {
/**
* The ID of the Identity JSON Schema
* @type {string}
* @memberof IdentitySchemaContainer
*/
id?: string
/**
* The actual Identity JSON Schema
* @type {object}
* @memberof IdentitySchemaContainer
*/
schema?: object
}
/**
* The state can either be `active` or `inactive`.
* @export
* @enum {string}
*/
export const IdentityState = {
Active: "active",
Inactive: "inactive",
} as const
export type IdentityState = typeof IdentityState[keyof typeof IdentityState]
/**
* Create Identity and Import Credentials
* @export
* @interface IdentityWithCredentials
*/
export interface IdentityWithCredentials {
/**
*
* @type {IdentityWithCredentialsOidc}
* @memberof IdentityWithCredentials
*/
oidc?: IdentityWithCredentialsOidc
/**
*
* @type {IdentityWithCredentialsPassword}
* @memberof IdentityWithCredentials
*/
password?: IdentityWithCredentialsPassword
}
/**
* Create Identity and Import Social Sign In Credentials
* @export
* @interface IdentityWithCredentialsOidc
*/
export interface IdentityWithCredentialsOidc {
/**
*
* @type {IdentityWithCredentialsOidcConfig}
* @memberof IdentityWithCredentialsOidc
*/
config?: IdentityWithCredentialsOidcConfig
}
/**
*
* @export
* @interface IdentityWithCredentialsOidcConfig
*/
export interface IdentityWithCredentialsOidcConfig {
/**
*
* @type {IdentityWithCredentialsPasswordConfig}
* @memberof IdentityWithCredentialsOidcConfig
*/
config?: IdentityWithCredentialsPasswordConfig
/**
* A list of OpenID Connect Providers
* @type {Array<IdentityWithCredentialsOidcConfigProvider>}
* @memberof IdentityWithCredentialsOidcConfig
*/
providers?: Array<IdentityWithCredentialsOidcConfigProvider>
}
/**
* Create Identity and Import Social Sign In Credentials Configuration
* @export
* @interface IdentityWithCredentialsOidcConfigProvider
*/
export interface IdentityWithCredentialsOidcConfigProvider {
/**
* The OpenID Connect provider to link the subject to. Usually something like `google` or `github`.
* @type {string}
* @memberof IdentityWithCredentialsOidcConfigProvider
*/
provider: string
/**
* The subject (`sub`) of the OpenID Connect connection. Usually the `sub` field of the ID Token.
* @type {string}
* @memberof IdentityWithCredentialsOidcConfigProvider
*/
subject: string
}
/**
* Create Identity and Import Password Credentials
* @export
* @interface IdentityWithCredentialsPassword
*/
export interface IdentityWithCredentialsPassword {
/**
*
* @type {IdentityWithCredentialsPasswordConfig}
* @memberof IdentityWithCredentialsPassword
*/
config?: IdentityWithCredentialsPasswordConfig
}
/**
* Create Identity and Import Password Credentials Configuration