@trinsic/api 0.3.0 → 0.4.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-generator/FILES +3 -3
- package/.openapi-generator/VERSION +1 -1
- package/README.md +2 -2
- package/dist/apis/AttachmentsApi.d.ts +13 -10
- package/dist/apis/AttachmentsApi.js +7 -5
- package/dist/apis/NetworkApi.d.ts +10 -4
- package/dist/apis/NetworkApi.js +4 -0
- package/dist/apis/SessionsApi.d.ts +45 -30
- package/dist/apis/SessionsApi.js +30 -20
- package/dist/esm/apis/AttachmentsApi.d.ts +13 -10
- package/dist/esm/apis/AttachmentsApi.js +8 -6
- package/dist/esm/apis/NetworkApi.d.ts +10 -4
- package/dist/esm/apis/NetworkApi.js +4 -0
- package/dist/esm/apis/SessionsApi.d.ts +45 -30
- package/dist/esm/apis/SessionsApi.js +31 -21
- package/dist/esm/models/GetAttachmentRequest.d.ts +31 -0
- package/dist/esm/models/{ExchangeAttachmentAccessKeyRequest.js → GetAttachmentRequest.js} +6 -6
- package/dist/esm/models/GetSessionResultRequest.d.ts +31 -0
- package/dist/esm/models/{ExchangeResultsKeyRequest.js → GetSessionResultRequest.js} +6 -6
- package/dist/esm/models/GetSessionResultResponse.d.ts +39 -0
- package/dist/esm/models/{ExchangeResultsKeyResponse.js → GetSessionResultResponse.js} +6 -6
- package/dist/esm/models/index.d.ts +3 -3
- package/dist/esm/models/index.js +3 -3
- package/dist/models/GetAttachmentRequest.d.ts +31 -0
- package/dist/models/{ExchangeAttachmentAccessKeyRequest.js → GetAttachmentRequest.js} +10 -10
- package/dist/models/GetSessionResultRequest.d.ts +31 -0
- package/dist/models/{ExchangeResultsKeyRequest.js → GetSessionResultRequest.js} +10 -10
- package/dist/models/GetSessionResultResponse.d.ts +39 -0
- package/dist/models/{ExchangeResultsKeyResponse.js → GetSessionResultResponse.js} +10 -10
- package/dist/models/index.d.ts +3 -3
- package/dist/models/index.js +3 -3
- package/package.json +1 -1
- package/src/apis/AttachmentsApi.ts +18 -15
- package/src/apis/NetworkApi.ts +10 -4
- package/src/apis/SessionsApi.ts +63 -48
- package/src/models/{ExchangeAttachmentAccessKeyRequest.ts → GetAttachmentRequest.ts} +9 -9
- package/src/models/{ExchangeResultsKeyRequest.ts → GetSessionResultRequest.ts} +9 -9
- package/src/models/{ExchangeResultsKeyResponse.ts → GetSessionResultResponse.ts} +10 -10
- package/src/models/OrderDirection.ts +1 -1
- package/src/models/Session.ts +2 -0
- package/src/models/SessionFailCode.ts +1 -1
- package/src/models/SessionOrdering.ts +1 -1
- package/src/models/SessionState.ts +1 -1
- package/src/models/Verification.ts +2 -0
- package/src/models/VerificationFailCode.ts +1 -1
- package/src/models/index.ts +3 -3
- package/dist/esm/models/ExchangeAttachmentAccessKeyRequest.d.ts +0 -31
- package/dist/esm/models/ExchangeResultsKeyRequest.d.ts +0 -31
- package/dist/esm/models/ExchangeResultsKeyResponse.d.ts +0 -39
- package/dist/models/ExchangeAttachmentAccessKeyRequest.d.ts +0 -31
- package/dist/models/ExchangeResultsKeyRequest.d.ts +0 -31
- package/dist/models/ExchangeResultsKeyResponse.d.ts +0 -39
|
@@ -21,15 +21,16 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import {
|
|
24
|
+
import { GetAttachmentRequestToJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
28
28
|
export class AttachmentsApi extends runtime.BaseAPI {
|
|
29
29
|
/**
|
|
30
30
|
* Exchange an Attachment Access Key (from `IdentityData.Attachments`) for the raw contents of the attachment. Use this API to fetch document (front, back, portrait) or other (selfie) images from a verification, if relevant. In some cases, attachments may not be immediately available after a verification is completed. If so, this endpoint will return an HTTP 202 code, and you should try again later.
|
|
31
|
+
* Get Attachment
|
|
31
32
|
*/
|
|
32
|
-
|
|
33
|
+
getAttachmentRaw(requestParameters, initOverrides) {
|
|
33
34
|
return __awaiter(this, void 0, void 0, function* () {
|
|
34
35
|
const queryParameters = {};
|
|
35
36
|
const headerParameters = {};
|
|
@@ -42,21 +43,22 @@ export class AttachmentsApi extends runtime.BaseAPI {
|
|
|
42
43
|
}
|
|
43
44
|
}
|
|
44
45
|
const response = yield this.request({
|
|
45
|
-
path: `/api/v1/attachments/
|
|
46
|
+
path: `/api/v1/attachments/attachment`,
|
|
46
47
|
method: 'POST',
|
|
47
48
|
headers: headerParameters,
|
|
48
49
|
query: queryParameters,
|
|
49
|
-
body:
|
|
50
|
+
body: GetAttachmentRequestToJSON(requestParameters['getAttachmentRequest']),
|
|
50
51
|
}, initOverrides);
|
|
51
52
|
return new runtime.VoidApiResponse(response);
|
|
52
53
|
});
|
|
53
54
|
}
|
|
54
55
|
/**
|
|
55
56
|
* Exchange an Attachment Access Key (from `IdentityData.Attachments`) for the raw contents of the attachment. Use this API to fetch document (front, back, portrait) or other (selfie) images from a verification, if relevant. In some cases, attachments may not be immediately available after a verification is completed. If so, this endpoint will return an HTTP 202 code, and you should try again later.
|
|
57
|
+
* Get Attachment
|
|
56
58
|
*/
|
|
57
|
-
|
|
59
|
+
getAttachment(getAttachmentRequest, initOverrides) {
|
|
58
60
|
return __awaiter(this, void 0, void 0, function* () {
|
|
59
|
-
yield this.
|
|
61
|
+
yield this.getAttachmentRaw({ getAttachmentRequest: getAttachmentRequest }, initOverrides);
|
|
60
62
|
});
|
|
61
63
|
}
|
|
62
64
|
}
|
|
@@ -22,8 +22,8 @@ export interface IdentityLookupRequest {
|
|
|
22
22
|
*/
|
|
23
23
|
export interface NetworkApiInterface {
|
|
24
24
|
/**
|
|
25
|
-
*
|
|
26
|
-
* @summary
|
|
25
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
26
|
+
* @summary Lookup Identity
|
|
27
27
|
* @param {string} phoneNumber
|
|
28
28
|
* @param {*} [options] Override http request option.
|
|
29
29
|
* @throws {RequiredError}
|
|
@@ -32,11 +32,12 @@ export interface NetworkApiInterface {
|
|
|
32
32
|
identityLookupRaw(requestParameters: IdentityLookupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IdentityLookupResponse>>;
|
|
33
33
|
/**
|
|
34
34
|
* Query the availability of an identity in the Trinsic Network by phone number
|
|
35
|
+
* Lookup Identity
|
|
35
36
|
*/
|
|
36
37
|
identityLookup(phoneNumber: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IdentityLookupResponse>;
|
|
37
38
|
/**
|
|
38
|
-
*
|
|
39
|
-
* @summary List
|
|
39
|
+
* List all identity providers available for use
|
|
40
|
+
* @summary List Identity Providers
|
|
40
41
|
* @param {*} [options] Override http request option.
|
|
41
42
|
* @throws {RequiredError}
|
|
42
43
|
* @memberof NetworkApiInterface
|
|
@@ -44,6 +45,7 @@ export interface NetworkApiInterface {
|
|
|
44
45
|
listProvidersRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListProvidersResponse>>;
|
|
45
46
|
/**
|
|
46
47
|
* List all identity providers available for use
|
|
48
|
+
* List Identity Providers
|
|
47
49
|
*/
|
|
48
50
|
listProviders(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListProvidersResponse>;
|
|
49
51
|
}
|
|
@@ -53,18 +55,22 @@ export interface NetworkApiInterface {
|
|
|
53
55
|
export declare class NetworkApi extends runtime.BaseAPI implements NetworkApiInterface {
|
|
54
56
|
/**
|
|
55
57
|
* Query the availability of an identity in the Trinsic Network by phone number
|
|
58
|
+
* Lookup Identity
|
|
56
59
|
*/
|
|
57
60
|
identityLookupRaw(requestParameters: IdentityLookupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IdentityLookupResponse>>;
|
|
58
61
|
/**
|
|
59
62
|
* Query the availability of an identity in the Trinsic Network by phone number
|
|
63
|
+
* Lookup Identity
|
|
60
64
|
*/
|
|
61
65
|
identityLookup(phoneNumber: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IdentityLookupResponse>;
|
|
62
66
|
/**
|
|
63
67
|
* List all identity providers available for use
|
|
68
|
+
* List Identity Providers
|
|
64
69
|
*/
|
|
65
70
|
listProvidersRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListProvidersResponse>>;
|
|
66
71
|
/**
|
|
67
72
|
* List all identity providers available for use
|
|
73
|
+
* List Identity Providers
|
|
68
74
|
*/
|
|
69
75
|
listProviders(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListProvidersResponse>;
|
|
70
76
|
}
|
|
@@ -28,6 +28,7 @@ import { IdentityLookupResponseFromJSON, ListProvidersResponseFromJSON, } from '
|
|
|
28
28
|
export class NetworkApi extends runtime.BaseAPI {
|
|
29
29
|
/**
|
|
30
30
|
* Query the availability of an identity in the Trinsic Network by phone number
|
|
31
|
+
* Lookup Identity
|
|
31
32
|
*/
|
|
32
33
|
identityLookupRaw(requestParameters, initOverrides) {
|
|
33
34
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -54,6 +55,7 @@ export class NetworkApi extends runtime.BaseAPI {
|
|
|
54
55
|
}
|
|
55
56
|
/**
|
|
56
57
|
* Query the availability of an identity in the Trinsic Network by phone number
|
|
58
|
+
* Lookup Identity
|
|
57
59
|
*/
|
|
58
60
|
identityLookup(phoneNumber, initOverrides) {
|
|
59
61
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -63,6 +65,7 @@ export class NetworkApi extends runtime.BaseAPI {
|
|
|
63
65
|
}
|
|
64
66
|
/**
|
|
65
67
|
* List all identity providers available for use
|
|
68
|
+
* List Identity Providers
|
|
66
69
|
*/
|
|
67
70
|
listProvidersRaw(initOverrides) {
|
|
68
71
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -86,6 +89,7 @@ export class NetworkApi extends runtime.BaseAPI {
|
|
|
86
89
|
}
|
|
87
90
|
/**
|
|
88
91
|
* List all identity providers available for use
|
|
92
|
+
* List Identity Providers
|
|
89
93
|
*/
|
|
90
94
|
listProviders(initOverrides) {
|
|
91
95
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -10,19 +10,19 @@
|
|
|
10
10
|
* Do not edit the class manually.
|
|
11
11
|
*/
|
|
12
12
|
import * as runtime from '../runtime';
|
|
13
|
-
import type { CancelSessionResponse, CreateSessionRequest, CreateSessionResponse,
|
|
13
|
+
import type { CancelSessionResponse, CreateSessionRequest, CreateSessionResponse, GetSessionResponse, GetSessionResultRequest, GetSessionResultResponse, ListSessionsResponse, OrderDirection, SessionOrdering } from '../models/index';
|
|
14
14
|
export interface CancelSessionRequest {
|
|
15
15
|
sessionId: string;
|
|
16
16
|
}
|
|
17
17
|
export interface CreateSessionOperationRequest {
|
|
18
18
|
createSessionRequest?: CreateSessionRequest;
|
|
19
19
|
}
|
|
20
|
-
export interface
|
|
20
|
+
export interface GetSessionRequest {
|
|
21
21
|
sessionId: string;
|
|
22
|
-
exchangeResultsKeyRequest?: ExchangeResultsKeyRequest;
|
|
23
22
|
}
|
|
24
|
-
export interface
|
|
23
|
+
export interface GetSessionResultOperationRequest {
|
|
25
24
|
sessionId: string;
|
|
25
|
+
getSessionResultRequest?: GetSessionResultRequest;
|
|
26
26
|
}
|
|
27
27
|
export interface ListSessionsRequest {
|
|
28
28
|
orderBy?: SessionOrdering;
|
|
@@ -41,8 +41,8 @@ export interface RedactSessionRequest {
|
|
|
41
41
|
*/
|
|
42
42
|
export interface SessionsApiInterface {
|
|
43
43
|
/**
|
|
44
|
-
*
|
|
45
|
-
* @summary Cancel
|
|
44
|
+
* Cancel a Session by its ID
|
|
45
|
+
* @summary Cancel Session
|
|
46
46
|
* @param {string} sessionId
|
|
47
47
|
* @param {*} [options] Override http request option.
|
|
48
48
|
* @throws {RequiredError}
|
|
@@ -51,11 +51,12 @@ export interface SessionsApiInterface {
|
|
|
51
51
|
cancelSessionRaw(requestParameters: CancelSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CancelSessionResponse>>;
|
|
52
52
|
/**
|
|
53
53
|
* Cancel a Session by its ID
|
|
54
|
+
* Cancel Session
|
|
54
55
|
*/
|
|
55
56
|
cancelSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CancelSessionResponse>;
|
|
56
57
|
/**
|
|
57
|
-
*
|
|
58
|
-
* @summary Create
|
|
58
|
+
* Create a Session to verify a user\'s identity
|
|
59
|
+
* @summary Create Session
|
|
59
60
|
* @param {CreateSessionRequest} [createSessionRequest]
|
|
60
61
|
* @param {*} [options] Override http request option.
|
|
61
62
|
* @throws {RequiredError}
|
|
@@ -64,38 +65,40 @@ export interface SessionsApiInterface {
|
|
|
64
65
|
createSessionRaw(requestParameters: CreateSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateSessionResponse>>;
|
|
65
66
|
/**
|
|
66
67
|
* Create a Session to verify a user\'s identity
|
|
68
|
+
* Create Session
|
|
67
69
|
*/
|
|
68
70
|
createSession(createSessionRequest?: CreateSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateSessionResponse>;
|
|
69
71
|
/**
|
|
70
|
-
*
|
|
71
|
-
* @summary
|
|
72
|
+
* Get a Session by its ID
|
|
73
|
+
* @summary Get Session
|
|
72
74
|
* @param {string} sessionId
|
|
73
|
-
* @param {ExchangeResultsKeyRequest} [exchangeResultsKeyRequest]
|
|
74
75
|
* @param {*} [options] Override http request option.
|
|
75
76
|
* @throws {RequiredError}
|
|
76
77
|
* @memberof SessionsApiInterface
|
|
77
78
|
*/
|
|
78
|
-
|
|
79
|
+
getSessionRaw(requestParameters: GetSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResponse>>;
|
|
79
80
|
/**
|
|
80
|
-
*
|
|
81
|
+
* Get a Session by its ID
|
|
82
|
+
* Get Session
|
|
81
83
|
*/
|
|
82
|
-
|
|
84
|
+
getSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResponse>;
|
|
83
85
|
/**
|
|
84
86
|
*
|
|
85
|
-
* @summary Get
|
|
87
|
+
* @summary Get Session Results
|
|
86
88
|
* @param {string} sessionId
|
|
89
|
+
* @param {GetSessionResultRequest} [getSessionResultRequest]
|
|
87
90
|
* @param {*} [options] Override http request option.
|
|
88
91
|
* @throws {RequiredError}
|
|
89
92
|
* @memberof SessionsApiInterface
|
|
90
93
|
*/
|
|
91
|
-
|
|
94
|
+
getSessionResultRaw(requestParameters: GetSessionResultOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResultResponse>>;
|
|
92
95
|
/**
|
|
93
|
-
* Get
|
|
96
|
+
* Get Session Results
|
|
94
97
|
*/
|
|
95
|
-
|
|
98
|
+
getSessionResult(sessionId: string, getSessionResultRequest?: GetSessionResultRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResultResponse>;
|
|
96
99
|
/**
|
|
97
|
-
*
|
|
98
|
-
* @summary List Sessions
|
|
100
|
+
* List Sessions created by your account
|
|
101
|
+
* @summary List Sessions
|
|
99
102
|
* @param {SessionOrdering} [orderBy] The field by which sessions should be ordered
|
|
100
103
|
* @param {OrderDirection} [orderDirection]
|
|
101
104
|
* @param {number} [pageSize] The number of items to return per page -- must be between `1` and `50`
|
|
@@ -107,11 +110,12 @@ export interface SessionsApiInterface {
|
|
|
107
110
|
listSessionsRaw(requestParameters: ListSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListSessionsResponse>>;
|
|
108
111
|
/**
|
|
109
112
|
* List Sessions created by your account
|
|
113
|
+
* List Sessions
|
|
110
114
|
*/
|
|
111
115
|
listSessions(orderBy?: SessionOrdering, orderDirection?: OrderDirection, pageSize?: number, page?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListSessionsResponse>;
|
|
112
116
|
/**
|
|
113
|
-
*
|
|
114
|
-
* @summary Redact
|
|
117
|
+
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
118
|
+
* @summary Redact Session
|
|
115
119
|
* @param {string} sessionId
|
|
116
120
|
* @param {*} [options] Override http request option.
|
|
117
121
|
* @throws {RequiredError}
|
|
@@ -120,6 +124,7 @@ export interface SessionsApiInterface {
|
|
|
120
124
|
redactSessionRaw(requestParameters: RedactSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
121
125
|
/**
|
|
122
126
|
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
127
|
+
* Redact Session
|
|
123
128
|
*/
|
|
124
129
|
redactSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
125
130
|
}
|
|
@@ -129,50 +134,60 @@ export interface SessionsApiInterface {
|
|
|
129
134
|
export declare class SessionsApi extends runtime.BaseAPI implements SessionsApiInterface {
|
|
130
135
|
/**
|
|
131
136
|
* Cancel a Session by its ID
|
|
137
|
+
* Cancel Session
|
|
132
138
|
*/
|
|
133
139
|
cancelSessionRaw(requestParameters: CancelSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CancelSessionResponse>>;
|
|
134
140
|
/**
|
|
135
141
|
* Cancel a Session by its ID
|
|
142
|
+
* Cancel Session
|
|
136
143
|
*/
|
|
137
144
|
cancelSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CancelSessionResponse>;
|
|
138
145
|
/**
|
|
139
146
|
* Create a Session to verify a user\'s identity
|
|
147
|
+
* Create Session
|
|
140
148
|
*/
|
|
141
149
|
createSessionRaw(requestParameters: CreateSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateSessionResponse>>;
|
|
142
150
|
/**
|
|
143
151
|
* Create a Session to verify a user\'s identity
|
|
152
|
+
* Create Session
|
|
144
153
|
*/
|
|
145
154
|
createSession(createSessionRequest?: CreateSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateSessionResponse>;
|
|
146
|
-
/**
|
|
147
|
-
* Exchange a Results Access Key for Identity Data
|
|
148
|
-
*/
|
|
149
|
-
exchangeResultsKeyRaw(requestParameters: ExchangeResultsKeyOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ExchangeResultsKeyResponse>>;
|
|
150
|
-
/**
|
|
151
|
-
* Exchange a Results Access Key for Identity Data
|
|
152
|
-
*/
|
|
153
|
-
exchangeResultsKey(sessionId: string, exchangeResultsKeyRequest?: ExchangeResultsKeyRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ExchangeResultsKeyResponse>;
|
|
154
155
|
/**
|
|
155
156
|
* Get a Session by its ID
|
|
157
|
+
* Get Session
|
|
156
158
|
*/
|
|
157
159
|
getSessionRaw(requestParameters: GetSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResponse>>;
|
|
158
160
|
/**
|
|
159
161
|
* Get a Session by its ID
|
|
162
|
+
* Get Session
|
|
160
163
|
*/
|
|
161
164
|
getSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResponse>;
|
|
165
|
+
/**
|
|
166
|
+
* Get Session Results
|
|
167
|
+
*/
|
|
168
|
+
getSessionResultRaw(requestParameters: GetSessionResultOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResultResponse>>;
|
|
169
|
+
/**
|
|
170
|
+
* Get Session Results
|
|
171
|
+
*/
|
|
172
|
+
getSessionResult(sessionId: string, getSessionResultRequest?: GetSessionResultRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResultResponse>;
|
|
162
173
|
/**
|
|
163
174
|
* List Sessions created by your account
|
|
175
|
+
* List Sessions
|
|
164
176
|
*/
|
|
165
177
|
listSessionsRaw(requestParameters: ListSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListSessionsResponse>>;
|
|
166
178
|
/**
|
|
167
179
|
* List Sessions created by your account
|
|
180
|
+
* List Sessions
|
|
168
181
|
*/
|
|
169
182
|
listSessions(orderBy?: SessionOrdering, orderDirection?: OrderDirection, pageSize?: number, page?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListSessionsResponse>;
|
|
170
183
|
/**
|
|
171
184
|
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
185
|
+
* Redact Session
|
|
172
186
|
*/
|
|
173
187
|
redactSessionRaw(requestParameters: RedactSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
174
188
|
/**
|
|
175
189
|
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
190
|
+
* Redact Session
|
|
176
191
|
*/
|
|
177
192
|
redactSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
178
193
|
}
|
|
@@ -21,13 +21,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
21
21
|
});
|
|
22
22
|
};
|
|
23
23
|
import * as runtime from '../runtime';
|
|
24
|
-
import { CancelSessionResponseFromJSON, CreateSessionRequestToJSON, CreateSessionResponseFromJSON,
|
|
24
|
+
import { CancelSessionResponseFromJSON, CreateSessionRequestToJSON, CreateSessionResponseFromJSON, GetSessionResponseFromJSON, GetSessionResultRequestToJSON, GetSessionResultResponseFromJSON, ListSessionsResponseFromJSON, } from '../models/index';
|
|
25
25
|
/**
|
|
26
26
|
*
|
|
27
27
|
*/
|
|
28
28
|
export class SessionsApi extends runtime.BaseAPI {
|
|
29
29
|
/**
|
|
30
30
|
* Cancel a Session by its ID
|
|
31
|
+
* Cancel Session
|
|
31
32
|
*/
|
|
32
33
|
cancelSessionRaw(requestParameters, initOverrides) {
|
|
33
34
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -54,6 +55,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
54
55
|
}
|
|
55
56
|
/**
|
|
56
57
|
* Cancel a Session by its ID
|
|
58
|
+
* Cancel Session
|
|
57
59
|
*/
|
|
58
60
|
cancelSession(sessionId, initOverrides) {
|
|
59
61
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -63,6 +65,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
63
65
|
}
|
|
64
66
|
/**
|
|
65
67
|
* Create a Session to verify a user\'s identity
|
|
68
|
+
* Create Session
|
|
66
69
|
*/
|
|
67
70
|
createSessionRaw(requestParameters, initOverrides) {
|
|
68
71
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -88,6 +91,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
88
91
|
}
|
|
89
92
|
/**
|
|
90
93
|
* Create a Session to verify a user\'s identity
|
|
94
|
+
* Create Session
|
|
91
95
|
*/
|
|
92
96
|
createSession(createSessionRequest, initOverrides) {
|
|
93
97
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -96,16 +100,16 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
96
100
|
});
|
|
97
101
|
}
|
|
98
102
|
/**
|
|
99
|
-
*
|
|
103
|
+
* Get a Session by its ID
|
|
104
|
+
* Get Session
|
|
100
105
|
*/
|
|
101
|
-
|
|
106
|
+
getSessionRaw(requestParameters, initOverrides) {
|
|
102
107
|
return __awaiter(this, void 0, void 0, function* () {
|
|
103
108
|
if (requestParameters['sessionId'] == null) {
|
|
104
|
-
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling
|
|
109
|
+
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling getSession().');
|
|
105
110
|
}
|
|
106
111
|
const queryParameters = {};
|
|
107
112
|
const headerParameters = {};
|
|
108
|
-
headerParameters['Content-Type'] = 'application/json';
|
|
109
113
|
if (this.configuration && this.configuration.accessToken) {
|
|
110
114
|
const token = this.configuration.accessToken;
|
|
111
115
|
const tokenString = yield token("Bearer", []);
|
|
@@ -114,34 +118,35 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
114
118
|
}
|
|
115
119
|
}
|
|
116
120
|
const response = yield this.request({
|
|
117
|
-
path: `/api/v1/sessions/{sessionId}
|
|
118
|
-
method: '
|
|
121
|
+
path: `/api/v1/sessions/{sessionId}`.replace(`{${"sessionId"}}`, encodeURIComponent(String(requestParameters['sessionId']))),
|
|
122
|
+
method: 'GET',
|
|
119
123
|
headers: headerParameters,
|
|
120
124
|
query: queryParameters,
|
|
121
|
-
body: ExchangeResultsKeyRequestToJSON(requestParameters['exchangeResultsKeyRequest']),
|
|
122
125
|
}, initOverrides);
|
|
123
|
-
return new runtime.JSONApiResponse(response, (jsonValue) =>
|
|
126
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetSessionResponseFromJSON(jsonValue));
|
|
124
127
|
});
|
|
125
128
|
}
|
|
126
129
|
/**
|
|
127
|
-
*
|
|
130
|
+
* Get a Session by its ID
|
|
131
|
+
* Get Session
|
|
128
132
|
*/
|
|
129
|
-
|
|
133
|
+
getSession(sessionId, initOverrides) {
|
|
130
134
|
return __awaiter(this, void 0, void 0, function* () {
|
|
131
|
-
const response = yield this.
|
|
135
|
+
const response = yield this.getSessionRaw({ sessionId: sessionId }, initOverrides);
|
|
132
136
|
return yield response.value();
|
|
133
137
|
});
|
|
134
138
|
}
|
|
135
139
|
/**
|
|
136
|
-
* Get
|
|
140
|
+
* Get Session Results
|
|
137
141
|
*/
|
|
138
|
-
|
|
142
|
+
getSessionResultRaw(requestParameters, initOverrides) {
|
|
139
143
|
return __awaiter(this, void 0, void 0, function* () {
|
|
140
144
|
if (requestParameters['sessionId'] == null) {
|
|
141
|
-
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling
|
|
145
|
+
throw new runtime.RequiredError('sessionId', 'Required parameter "sessionId" was null or undefined when calling getSessionResult().');
|
|
142
146
|
}
|
|
143
147
|
const queryParameters = {};
|
|
144
148
|
const headerParameters = {};
|
|
149
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
145
150
|
if (this.configuration && this.configuration.accessToken) {
|
|
146
151
|
const token = this.configuration.accessToken;
|
|
147
152
|
const tokenString = yield token("Bearer", []);
|
|
@@ -150,25 +155,27 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
150
155
|
}
|
|
151
156
|
}
|
|
152
157
|
const response = yield this.request({
|
|
153
|
-
path: `/api/v1/sessions/{sessionId}`.replace(`{${"sessionId"}}`, encodeURIComponent(String(requestParameters['sessionId']))),
|
|
154
|
-
method: '
|
|
158
|
+
path: `/api/v1/sessions/{sessionId}/results`.replace(`{${"sessionId"}}`, encodeURIComponent(String(requestParameters['sessionId']))),
|
|
159
|
+
method: 'POST',
|
|
155
160
|
headers: headerParameters,
|
|
156
161
|
query: queryParameters,
|
|
162
|
+
body: GetSessionResultRequestToJSON(requestParameters['getSessionResultRequest']),
|
|
157
163
|
}, initOverrides);
|
|
158
|
-
return new runtime.JSONApiResponse(response, (jsonValue) =>
|
|
164
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => GetSessionResultResponseFromJSON(jsonValue));
|
|
159
165
|
});
|
|
160
166
|
}
|
|
161
167
|
/**
|
|
162
|
-
* Get
|
|
168
|
+
* Get Session Results
|
|
163
169
|
*/
|
|
164
|
-
|
|
170
|
+
getSessionResult(sessionId, getSessionResultRequest, initOverrides) {
|
|
165
171
|
return __awaiter(this, void 0, void 0, function* () {
|
|
166
|
-
const response = yield this.
|
|
172
|
+
const response = yield this.getSessionResultRaw({ sessionId: sessionId, getSessionResultRequest: getSessionResultRequest }, initOverrides);
|
|
167
173
|
return yield response.value();
|
|
168
174
|
});
|
|
169
175
|
}
|
|
170
176
|
/**
|
|
171
177
|
* List Sessions created by your account
|
|
178
|
+
* List Sessions
|
|
172
179
|
*/
|
|
173
180
|
listSessionsRaw(requestParameters, initOverrides) {
|
|
174
181
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -204,6 +211,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
204
211
|
}
|
|
205
212
|
/**
|
|
206
213
|
* List Sessions created by your account
|
|
214
|
+
* List Sessions
|
|
207
215
|
*/
|
|
208
216
|
listSessions(orderBy, orderDirection, pageSize, page, initOverrides) {
|
|
209
217
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -213,6 +221,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
213
221
|
}
|
|
214
222
|
/**
|
|
215
223
|
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
224
|
+
* Redact Session
|
|
216
225
|
*/
|
|
217
226
|
redactSessionRaw(requestParameters, initOverrides) {
|
|
218
227
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -239,6 +248,7 @@ export class SessionsApi extends runtime.BaseAPI {
|
|
|
239
248
|
}
|
|
240
249
|
/**
|
|
241
250
|
* Redact a Session, removing all identity data from Trinsic\'s servers. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
251
|
+
* Redact Session
|
|
242
252
|
*/
|
|
243
253
|
redactSession(sessionId, initOverrides) {
|
|
244
254
|
return __awaiter(this, void 0, void 0, function* () {
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Connect API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: v1
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetAttachmentRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface GetAttachmentRequest {
|
|
18
|
+
/**
|
|
19
|
+
* The Attachment Access Key to exchange for the raw file contents of the related Attachment
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof GetAttachmentRequest
|
|
22
|
+
*/
|
|
23
|
+
attachmentAccessKey: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the GetAttachmentRequest interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfGetAttachmentRequest(value: object): value is GetAttachmentRequest;
|
|
29
|
+
export declare function GetAttachmentRequestFromJSON(json: any): GetAttachmentRequest;
|
|
30
|
+
export declare function GetAttachmentRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetAttachmentRequest;
|
|
31
|
+
export declare function GetAttachmentRequestToJSON(value?: GetAttachmentRequest | null): any;
|
|
@@ -12,17 +12,17 @@
|
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
14
|
/**
|
|
15
|
-
* Check if a given object implements the
|
|
15
|
+
* Check if a given object implements the GetAttachmentRequest interface.
|
|
16
16
|
*/
|
|
17
|
-
export function
|
|
17
|
+
export function instanceOfGetAttachmentRequest(value) {
|
|
18
18
|
if (!('attachmentAccessKey' in value) || value['attachmentAccessKey'] === undefined)
|
|
19
19
|
return false;
|
|
20
20
|
return true;
|
|
21
21
|
}
|
|
22
|
-
export function
|
|
23
|
-
return
|
|
22
|
+
export function GetAttachmentRequestFromJSON(json) {
|
|
23
|
+
return GetAttachmentRequestFromJSONTyped(json, false);
|
|
24
24
|
}
|
|
25
|
-
export function
|
|
25
|
+
export function GetAttachmentRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
26
26
|
if (json == null) {
|
|
27
27
|
return json;
|
|
28
28
|
}
|
|
@@ -30,7 +30,7 @@ export function ExchangeAttachmentAccessKeyRequestFromJSONTyped(json, ignoreDisc
|
|
|
30
30
|
'attachmentAccessKey': json['attachmentAccessKey'],
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
|
-
export function
|
|
33
|
+
export function GetAttachmentRequestToJSON(value) {
|
|
34
34
|
if (value == null) {
|
|
35
35
|
return value;
|
|
36
36
|
}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Connect API
|
|
3
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: v1
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
/**
|
|
13
|
+
*
|
|
14
|
+
* @export
|
|
15
|
+
* @interface GetSessionResultRequest
|
|
16
|
+
*/
|
|
17
|
+
export interface GetSessionResultRequest {
|
|
18
|
+
/**
|
|
19
|
+
* The Results Access Key to exchange
|
|
20
|
+
* @type {string}
|
|
21
|
+
* @memberof GetSessionResultRequest
|
|
22
|
+
*/
|
|
23
|
+
resultsAccessKey: string;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Check if a given object implements the GetSessionResultRequest interface.
|
|
27
|
+
*/
|
|
28
|
+
export declare function instanceOfGetSessionResultRequest(value: object): value is GetSessionResultRequest;
|
|
29
|
+
export declare function GetSessionResultRequestFromJSON(json: any): GetSessionResultRequest;
|
|
30
|
+
export declare function GetSessionResultRequestFromJSONTyped(json: any, ignoreDiscriminator: boolean): GetSessionResultRequest;
|
|
31
|
+
export declare function GetSessionResultRequestToJSON(value?: GetSessionResultRequest | null): any;
|
|
@@ -12,17 +12,17 @@
|
|
|
12
12
|
* Do not edit the class manually.
|
|
13
13
|
*/
|
|
14
14
|
/**
|
|
15
|
-
* Check if a given object implements the
|
|
15
|
+
* Check if a given object implements the GetSessionResultRequest interface.
|
|
16
16
|
*/
|
|
17
|
-
export function
|
|
17
|
+
export function instanceOfGetSessionResultRequest(value) {
|
|
18
18
|
if (!('resultsAccessKey' in value) || value['resultsAccessKey'] === undefined)
|
|
19
19
|
return false;
|
|
20
20
|
return true;
|
|
21
21
|
}
|
|
22
|
-
export function
|
|
23
|
-
return
|
|
22
|
+
export function GetSessionResultRequestFromJSON(json) {
|
|
23
|
+
return GetSessionResultRequestFromJSONTyped(json, false);
|
|
24
24
|
}
|
|
25
|
-
export function
|
|
25
|
+
export function GetSessionResultRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
26
26
|
if (json == null) {
|
|
27
27
|
return json;
|
|
28
28
|
}
|
|
@@ -30,7 +30,7 @@ export function ExchangeResultsKeyRequestFromJSONTyped(json, ignoreDiscriminator
|
|
|
30
30
|
'resultsAccessKey': json['resultsAccessKey'],
|
|
31
31
|
};
|
|
32
32
|
}
|
|
33
|
-
export function
|
|
33
|
+
export function GetSessionResultRequestToJSON(value) {
|
|
34
34
|
if (value == null) {
|
|
35
35
|
return value;
|
|
36
36
|
}
|