@trinsic/api 0.6.0 → 0.6.2
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/dist/apis/AttachmentsApi.d.ts +53 -0
- package/dist/apis/AttachmentsApi.js +68 -0
- package/dist/apis/NetworkApi.d.ts +76 -0
- package/dist/apis/NetworkApi.js +104 -0
- package/dist/apis/SessionsApi.d.ts +193 -0
- package/dist/apis/SessionsApi.js +262 -0
- package/dist/apis/index.d.ts +3 -0
- package/dist/apis/index.js +21 -0
- package/dist/esm/apis/AttachmentsApi.d.ts +53 -0
- package/dist/esm/apis/AttachmentsApi.js +64 -0
- package/dist/esm/apis/NetworkApi.d.ts +76 -0
- package/dist/esm/apis/NetworkApi.js +100 -0
- package/dist/esm/apis/SessionsApi.d.ts +193 -0
- package/dist/esm/apis/SessionsApi.js +258 -0
- package/dist/esm/apis/index.d.ts +3 -0
- package/dist/esm/apis/index.js +5 -0
- package/dist/esm/index.d.ts +3 -0
- package/dist/esm/index.js +5 -0
- package/dist/esm/models/Address.d.ts +73 -0
- package/dist/esm/models/Address.js +52 -0
- package/dist/esm/models/Attachments.d.ts +51 -0
- package/dist/esm/models/Attachments.js +44 -0
- package/dist/esm/models/CancelSessionResponse.d.ts +32 -0
- package/dist/esm/models/CancelSessionResponse.js +41 -0
- package/dist/esm/models/CreateSessionRequest.d.ts +52 -0
- package/dist/esm/models/CreateSessionRequest.js +43 -0
- package/dist/esm/models/CreateSessionResponse.d.ts +43 -0
- package/dist/esm/models/CreateSessionResponse.js +43 -0
- package/dist/esm/models/DisclosedFields.d.ts +97 -0
- package/dist/esm/models/DisclosedFields.js +84 -0
- package/dist/esm/models/DisclosedFieldsRequest.d.ts +97 -0
- package/dist/esm/models/DisclosedFieldsRequest.js +60 -0
- package/dist/esm/models/DocumentData.d.ts +61 -0
- package/dist/esm/models/DocumentData.js +48 -0
- package/dist/esm/models/FailureMessage.d.ts +31 -0
- package/dist/esm/models/FailureMessage.js +40 -0
- package/dist/esm/models/GetAttachmentRequest.d.ts +31 -0
- package/dist/esm/models/GetAttachmentRequest.js +40 -0
- package/dist/esm/models/GetSessionResponse.d.ts +32 -0
- package/dist/esm/models/GetSessionResponse.js +41 -0
- package/dist/esm/models/GetSessionResultRequest.d.ts +31 -0
- package/dist/esm/models/GetSessionResultRequest.js +40 -0
- package/dist/esm/models/GetSessionResultResponse.d.ts +39 -0
- package/dist/esm/models/GetSessionResultResponse.js +44 -0
- package/dist/esm/models/IdentityData.d.ts +52 -0
- package/dist/esm/models/IdentityData.js +47 -0
- package/dist/esm/models/IdentityLookupResponse.d.ts +31 -0
- package/dist/esm/models/IdentityLookupResponse.js +40 -0
- package/dist/esm/models/ListProvidersResponse.d.ts +32 -0
- package/dist/esm/models/ListProvidersResponse.js +41 -0
- package/dist/esm/models/ListSessionsResponse.d.ts +44 -0
- package/dist/esm/models/ListSessionsResponse.js +49 -0
- package/dist/esm/models/OrderDirection.d.ts +24 -0
- package/dist/esm/models/OrderDirection.js +40 -0
- package/dist/esm/models/PersonData.d.ts +82 -0
- package/dist/esm/models/PersonData.js +55 -0
- package/dist/esm/models/ProviderInfo.d.ts +43 -0
- package/dist/esm/models/ProviderInfo.js +48 -0
- package/dist/esm/models/Session.d.ts +71 -0
- package/dist/esm/models/Session.js +66 -0
- package/dist/esm/models/SessionFailCode.d.ts +29 -0
- package/dist/esm/models/SessionFailCode.js +45 -0
- package/dist/esm/models/SessionOrdering.d.ts +25 -0
- package/dist/esm/models/SessionOrdering.js +41 -0
- package/dist/esm/models/SessionState.d.ts +28 -0
- package/dist/esm/models/SessionState.js +44 -0
- package/dist/esm/models/ValidationResult.d.ts +37 -0
- package/dist/esm/models/ValidationResult.js +41 -0
- package/dist/esm/models/Verification.d.ts +38 -0
- package/dist/esm/models/Verification.js +41 -0
- package/dist/esm/models/VerificationFailCode.d.ts +27 -0
- package/dist/esm/models/VerificationFailCode.js +43 -0
- package/dist/esm/models/index.d.ts +27 -0
- package/dist/esm/models/index.js +29 -0
- package/dist/esm/runtime.d.ts +181 -0
- package/dist/esm/runtime.js +326 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +21 -0
- package/dist/models/Address.d.ts +73 -0
- package/dist/models/Address.js +58 -0
- package/dist/models/Attachments.d.ts +51 -0
- package/dist/models/Attachments.js +50 -0
- package/dist/models/CancelSessionResponse.d.ts +32 -0
- package/dist/models/CancelSessionResponse.js +47 -0
- package/dist/models/CreateSessionRequest.d.ts +52 -0
- package/dist/models/CreateSessionRequest.js +49 -0
- package/dist/models/CreateSessionResponse.d.ts +43 -0
- package/dist/models/CreateSessionResponse.js +49 -0
- package/dist/models/DisclosedFields.d.ts +97 -0
- package/dist/models/DisclosedFields.js +90 -0
- package/dist/models/DisclosedFieldsRequest.d.ts +97 -0
- package/dist/models/DisclosedFieldsRequest.js +66 -0
- package/dist/models/DocumentData.d.ts +61 -0
- package/dist/models/DocumentData.js +54 -0
- package/dist/models/FailureMessage.d.ts +31 -0
- package/dist/models/FailureMessage.js +46 -0
- package/dist/models/GetAttachmentRequest.d.ts +31 -0
- package/dist/models/GetAttachmentRequest.js +46 -0
- package/dist/models/GetSessionResponse.d.ts +32 -0
- package/dist/models/GetSessionResponse.js +47 -0
- package/dist/models/GetSessionResultRequest.d.ts +31 -0
- package/dist/models/GetSessionResultRequest.js +46 -0
- package/dist/models/GetSessionResultResponse.d.ts +39 -0
- package/dist/models/GetSessionResultResponse.js +50 -0
- package/dist/models/IdentityData.d.ts +52 -0
- package/dist/models/IdentityData.js +53 -0
- package/dist/models/IdentityLookupResponse.d.ts +31 -0
- package/dist/models/IdentityLookupResponse.js +46 -0
- package/dist/models/ListProvidersResponse.d.ts +32 -0
- package/dist/models/ListProvidersResponse.js +47 -0
- package/dist/models/ListSessionsResponse.d.ts +44 -0
- package/dist/models/ListSessionsResponse.js +55 -0
- package/dist/models/OrderDirection.d.ts +24 -0
- package/dist/models/OrderDirection.js +47 -0
- package/dist/models/PersonData.d.ts +82 -0
- package/dist/models/PersonData.js +61 -0
- package/dist/models/ProviderInfo.d.ts +43 -0
- package/dist/models/ProviderInfo.js +54 -0
- package/dist/models/Session.d.ts +71 -0
- package/dist/models/Session.js +72 -0
- package/dist/models/SessionFailCode.d.ts +29 -0
- package/dist/models/SessionFailCode.js +52 -0
- package/dist/models/SessionOrdering.d.ts +25 -0
- package/dist/models/SessionOrdering.js +48 -0
- package/dist/models/SessionState.d.ts +28 -0
- package/dist/models/SessionState.js +51 -0
- package/dist/models/ValidationResult.d.ts +37 -0
- package/dist/models/ValidationResult.js +47 -0
- package/dist/models/Verification.d.ts +38 -0
- package/dist/models/Verification.js +47 -0
- package/dist/models/VerificationFailCode.d.ts +27 -0
- package/dist/models/VerificationFailCode.js +50 -0
- package/dist/models/index.d.ts +27 -0
- package/dist/models/index.js +45 -0
- package/dist/runtime.d.ts +181 -0
- package/dist/runtime.js +341 -0
- package/package.json +1 -1
|
@@ -0,0 +1,53 @@
|
|
|
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
|
+
import * as runtime from '../runtime';
|
|
13
|
+
import type { GetAttachmentRequest } from '../models/index';
|
|
14
|
+
export interface GetAttachmentOperationRequest {
|
|
15
|
+
getAttachmentRequest?: GetAttachmentRequest;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* AttachmentsApi - interface
|
|
19
|
+
*
|
|
20
|
+
* @export
|
|
21
|
+
* @interface AttachmentsApiInterface
|
|
22
|
+
*/
|
|
23
|
+
export interface AttachmentsApiInterface {
|
|
24
|
+
/**
|
|
25
|
+
* 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.
|
|
26
|
+
* @summary Get Attachment
|
|
27
|
+
* @param {GetAttachmentRequest} [getAttachmentRequest]
|
|
28
|
+
* @param {*} [options] Override http request option.
|
|
29
|
+
* @throws {RequiredError}
|
|
30
|
+
* @memberof AttachmentsApiInterface
|
|
31
|
+
*/
|
|
32
|
+
getAttachmentRaw(requestParameters: GetAttachmentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
33
|
+
/**
|
|
34
|
+
* 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.
|
|
35
|
+
* Get Attachment
|
|
36
|
+
*/
|
|
37
|
+
getAttachment(getAttachmentRequest?: GetAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
*
|
|
41
|
+
*/
|
|
42
|
+
export declare class AttachmentsApi extends runtime.BaseAPI implements AttachmentsApiInterface {
|
|
43
|
+
/**
|
|
44
|
+
* 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.
|
|
45
|
+
* Get Attachment
|
|
46
|
+
*/
|
|
47
|
+
getAttachmentRaw(requestParameters: GetAttachmentOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
48
|
+
/**
|
|
49
|
+
* 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.
|
|
50
|
+
* Get Attachment
|
|
51
|
+
*/
|
|
52
|
+
getAttachment(getAttachmentRequest?: GetAttachmentRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
53
|
+
}
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Connect API
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: v1
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
18
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
19
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
20
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
21
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.AttachmentsApi = void 0;
|
|
26
|
+
const runtime = require("../runtime");
|
|
27
|
+
const index_1 = require("../models/index");
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
class AttachmentsApi extends runtime.BaseAPI {
|
|
32
|
+
/**
|
|
33
|
+
* 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.
|
|
34
|
+
* Get Attachment
|
|
35
|
+
*/
|
|
36
|
+
getAttachmentRaw(requestParameters, initOverrides) {
|
|
37
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
+
const queryParameters = {};
|
|
39
|
+
const headerParameters = {};
|
|
40
|
+
headerParameters['Content-Type'] = 'application/json';
|
|
41
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
42
|
+
const token = this.configuration.accessToken;
|
|
43
|
+
const tokenString = yield token("Bearer", []);
|
|
44
|
+
if (tokenString) {
|
|
45
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
const response = yield this.request({
|
|
49
|
+
path: `/api/v1/attachments/attachment`,
|
|
50
|
+
method: 'POST',
|
|
51
|
+
headers: headerParameters,
|
|
52
|
+
query: queryParameters,
|
|
53
|
+
body: (0, index_1.GetAttachmentRequestToJSON)(requestParameters['getAttachmentRequest']),
|
|
54
|
+
}, initOverrides);
|
|
55
|
+
return new runtime.VoidApiResponse(response);
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
/**
|
|
59
|
+
* 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.
|
|
60
|
+
* Get Attachment
|
|
61
|
+
*/
|
|
62
|
+
getAttachment(getAttachmentRequest, initOverrides) {
|
|
63
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
64
|
+
yield this.getAttachmentRaw({ getAttachmentRequest: getAttachmentRequest }, initOverrides);
|
|
65
|
+
});
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
exports.AttachmentsApi = AttachmentsApi;
|
|
@@ -0,0 +1,76 @@
|
|
|
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
|
+
import * as runtime from '../runtime';
|
|
13
|
+
import type { IdentityLookupResponse, ListProvidersResponse } from '../models/index';
|
|
14
|
+
export interface IdentityLookupRequest {
|
|
15
|
+
phoneNumber: string;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* NetworkApi - interface
|
|
19
|
+
*
|
|
20
|
+
* @export
|
|
21
|
+
* @interface NetworkApiInterface
|
|
22
|
+
*/
|
|
23
|
+
export interface NetworkApiInterface {
|
|
24
|
+
/**
|
|
25
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
26
|
+
* @summary Lookup Identity
|
|
27
|
+
* @param {string} phoneNumber
|
|
28
|
+
* @param {*} [options] Override http request option.
|
|
29
|
+
* @throws {RequiredError}
|
|
30
|
+
* @memberof NetworkApiInterface
|
|
31
|
+
*/
|
|
32
|
+
identityLookupRaw(requestParameters: IdentityLookupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IdentityLookupResponse>>;
|
|
33
|
+
/**
|
|
34
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
35
|
+
* Lookup Identity
|
|
36
|
+
*/
|
|
37
|
+
identityLookup(phoneNumber: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IdentityLookupResponse>;
|
|
38
|
+
/**
|
|
39
|
+
* List all identity providers available for use
|
|
40
|
+
* @summary List Identity Providers
|
|
41
|
+
* @param {*} [options] Override http request option.
|
|
42
|
+
* @throws {RequiredError}
|
|
43
|
+
* @memberof NetworkApiInterface
|
|
44
|
+
*/
|
|
45
|
+
listProvidersRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListProvidersResponse>>;
|
|
46
|
+
/**
|
|
47
|
+
* List all identity providers available for use
|
|
48
|
+
* List Identity Providers
|
|
49
|
+
*/
|
|
50
|
+
listProviders(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListProvidersResponse>;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
*
|
|
54
|
+
*/
|
|
55
|
+
export declare class NetworkApi extends runtime.BaseAPI implements NetworkApiInterface {
|
|
56
|
+
/**
|
|
57
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
58
|
+
* Lookup Identity
|
|
59
|
+
*/
|
|
60
|
+
identityLookupRaw(requestParameters: IdentityLookupRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<IdentityLookupResponse>>;
|
|
61
|
+
/**
|
|
62
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
63
|
+
* Lookup Identity
|
|
64
|
+
*/
|
|
65
|
+
identityLookup(phoneNumber: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<IdentityLookupResponse>;
|
|
66
|
+
/**
|
|
67
|
+
* List all identity providers available for use
|
|
68
|
+
* List Identity Providers
|
|
69
|
+
*/
|
|
70
|
+
listProvidersRaw(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListProvidersResponse>>;
|
|
71
|
+
/**
|
|
72
|
+
* List all identity providers available for use
|
|
73
|
+
* List Identity Providers
|
|
74
|
+
*/
|
|
75
|
+
listProviders(initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListProvidersResponse>;
|
|
76
|
+
}
|
|
@@ -0,0 +1,104 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/* tslint:disable */
|
|
3
|
+
/* eslint-disable */
|
|
4
|
+
/**
|
|
5
|
+
* Connect API
|
|
6
|
+
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
|
7
|
+
*
|
|
8
|
+
* The version of the OpenAPI document: v1
|
|
9
|
+
*
|
|
10
|
+
*
|
|
11
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
12
|
+
* https://openapi-generator.tech
|
|
13
|
+
* Do not edit the class manually.
|
|
14
|
+
*/
|
|
15
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
16
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
17
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
18
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
19
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
20
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
21
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
22
|
+
});
|
|
23
|
+
};
|
|
24
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
|
+
exports.NetworkApi = void 0;
|
|
26
|
+
const runtime = require("../runtime");
|
|
27
|
+
const index_1 = require("../models/index");
|
|
28
|
+
/**
|
|
29
|
+
*
|
|
30
|
+
*/
|
|
31
|
+
class NetworkApi extends runtime.BaseAPI {
|
|
32
|
+
/**
|
|
33
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
34
|
+
* Lookup Identity
|
|
35
|
+
*/
|
|
36
|
+
identityLookupRaw(requestParameters, initOverrides) {
|
|
37
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
38
|
+
if (requestParameters['phoneNumber'] == null) {
|
|
39
|
+
throw new runtime.RequiredError('phoneNumber', 'Required parameter "phoneNumber" was null or undefined when calling identityLookup().');
|
|
40
|
+
}
|
|
41
|
+
const queryParameters = {};
|
|
42
|
+
const headerParameters = {};
|
|
43
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
44
|
+
const token = this.configuration.accessToken;
|
|
45
|
+
const tokenString = yield token("Bearer", []);
|
|
46
|
+
if (tokenString) {
|
|
47
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
const response = yield this.request({
|
|
51
|
+
path: `/api/v1/network/identities/{phoneNumber}`.replace(`{${"phoneNumber"}}`, encodeURIComponent(String(requestParameters['phoneNumber']))),
|
|
52
|
+
method: 'GET',
|
|
53
|
+
headers: headerParameters,
|
|
54
|
+
query: queryParameters,
|
|
55
|
+
}, initOverrides);
|
|
56
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.IdentityLookupResponseFromJSON)(jsonValue));
|
|
57
|
+
});
|
|
58
|
+
}
|
|
59
|
+
/**
|
|
60
|
+
* Query the availability of an identity in the Trinsic Network by phone number
|
|
61
|
+
* Lookup Identity
|
|
62
|
+
*/
|
|
63
|
+
identityLookup(phoneNumber, initOverrides) {
|
|
64
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
65
|
+
const response = yield this.identityLookupRaw({ phoneNumber: phoneNumber }, initOverrides);
|
|
66
|
+
return yield response.value();
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
/**
|
|
70
|
+
* List all identity providers available for use
|
|
71
|
+
* List Identity Providers
|
|
72
|
+
*/
|
|
73
|
+
listProvidersRaw(initOverrides) {
|
|
74
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
75
|
+
const queryParameters = {};
|
|
76
|
+
const headerParameters = {};
|
|
77
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
78
|
+
const token = this.configuration.accessToken;
|
|
79
|
+
const tokenString = yield token("Bearer", []);
|
|
80
|
+
if (tokenString) {
|
|
81
|
+
headerParameters["Authorization"] = `Bearer ${tokenString}`;
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
const response = yield this.request({
|
|
85
|
+
path: `/api/v1/network/providers`,
|
|
86
|
+
method: 'GET',
|
|
87
|
+
headers: headerParameters,
|
|
88
|
+
query: queryParameters,
|
|
89
|
+
}, initOverrides);
|
|
90
|
+
return new runtime.JSONApiResponse(response, (jsonValue) => (0, index_1.ListProvidersResponseFromJSON)(jsonValue));
|
|
91
|
+
});
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* List all identity providers available for use
|
|
95
|
+
* List Identity Providers
|
|
96
|
+
*/
|
|
97
|
+
listProviders(initOverrides) {
|
|
98
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
99
|
+
const response = yield this.listProvidersRaw(initOverrides);
|
|
100
|
+
return yield response.value();
|
|
101
|
+
});
|
|
102
|
+
}
|
|
103
|
+
}
|
|
104
|
+
exports.NetworkApi = NetworkApi;
|
|
@@ -0,0 +1,193 @@
|
|
|
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
|
+
import * as runtime from '../runtime';
|
|
13
|
+
import type { CancelSessionResponse, CreateSessionRequest, CreateSessionResponse, GetSessionResponse, GetSessionResultRequest, GetSessionResultResponse, ListSessionsResponse, OrderDirection, SessionOrdering } from '../models/index';
|
|
14
|
+
export interface CancelSessionRequest {
|
|
15
|
+
sessionId: string;
|
|
16
|
+
}
|
|
17
|
+
export interface CreateSessionOperationRequest {
|
|
18
|
+
createSessionRequest?: CreateSessionRequest;
|
|
19
|
+
}
|
|
20
|
+
export interface GetSessionRequest {
|
|
21
|
+
sessionId: string;
|
|
22
|
+
}
|
|
23
|
+
export interface GetSessionResultOperationRequest {
|
|
24
|
+
sessionId: string;
|
|
25
|
+
getSessionResultRequest?: GetSessionResultRequest;
|
|
26
|
+
}
|
|
27
|
+
export interface ListSessionsRequest {
|
|
28
|
+
orderBy?: SessionOrdering;
|
|
29
|
+
orderDirection?: OrderDirection;
|
|
30
|
+
pageSize?: number;
|
|
31
|
+
page?: number;
|
|
32
|
+
}
|
|
33
|
+
export interface RedactSessionRequest {
|
|
34
|
+
sessionId: string;
|
|
35
|
+
}
|
|
36
|
+
/**
|
|
37
|
+
* SessionsApi - interface
|
|
38
|
+
*
|
|
39
|
+
* @export
|
|
40
|
+
* @interface SessionsApiInterface
|
|
41
|
+
*/
|
|
42
|
+
export interface SessionsApiInterface {
|
|
43
|
+
/**
|
|
44
|
+
* Cancel a Session by its ID
|
|
45
|
+
* @summary Cancel Session
|
|
46
|
+
* @param {string} sessionId
|
|
47
|
+
* @param {*} [options] Override http request option.
|
|
48
|
+
* @throws {RequiredError}
|
|
49
|
+
* @memberof SessionsApiInterface
|
|
50
|
+
*/
|
|
51
|
+
cancelSessionRaw(requestParameters: CancelSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CancelSessionResponse>>;
|
|
52
|
+
/**
|
|
53
|
+
* Cancel a Session by its ID
|
|
54
|
+
* Cancel Session
|
|
55
|
+
*/
|
|
56
|
+
cancelSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CancelSessionResponse>;
|
|
57
|
+
/**
|
|
58
|
+
* Create a Session to verify a user\'s identity
|
|
59
|
+
* @summary Create Session
|
|
60
|
+
* @param {CreateSessionRequest} [createSessionRequest]
|
|
61
|
+
* @param {*} [options] Override http request option.
|
|
62
|
+
* @throws {RequiredError}
|
|
63
|
+
* @memberof SessionsApiInterface
|
|
64
|
+
*/
|
|
65
|
+
createSessionRaw(requestParameters: CreateSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateSessionResponse>>;
|
|
66
|
+
/**
|
|
67
|
+
* Create a Session to verify a user\'s identity
|
|
68
|
+
* Create Session
|
|
69
|
+
*/
|
|
70
|
+
createSession(createSessionRequest?: CreateSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateSessionResponse>;
|
|
71
|
+
/**
|
|
72
|
+
* Get a Session by its ID
|
|
73
|
+
* @summary Get Session
|
|
74
|
+
* @param {string} sessionId
|
|
75
|
+
* @param {*} [options] Override http request option.
|
|
76
|
+
* @throws {RequiredError}
|
|
77
|
+
* @memberof SessionsApiInterface
|
|
78
|
+
*/
|
|
79
|
+
getSessionRaw(requestParameters: GetSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResponse>>;
|
|
80
|
+
/**
|
|
81
|
+
* Get a Session by its ID
|
|
82
|
+
* Get Session
|
|
83
|
+
*/
|
|
84
|
+
getSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResponse>;
|
|
85
|
+
/**
|
|
86
|
+
*
|
|
87
|
+
* @summary Get Session Results
|
|
88
|
+
* @param {string} sessionId
|
|
89
|
+
* @param {GetSessionResultRequest} [getSessionResultRequest]
|
|
90
|
+
* @param {*} [options] Override http request option.
|
|
91
|
+
* @throws {RequiredError}
|
|
92
|
+
* @memberof SessionsApiInterface
|
|
93
|
+
*/
|
|
94
|
+
getSessionResultRaw(requestParameters: GetSessionResultOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResultResponse>>;
|
|
95
|
+
/**
|
|
96
|
+
* Get Session Results
|
|
97
|
+
*/
|
|
98
|
+
getSessionResult(sessionId: string, getSessionResultRequest?: GetSessionResultRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<GetSessionResultResponse>;
|
|
99
|
+
/**
|
|
100
|
+
* List Sessions created by your account
|
|
101
|
+
* @summary List Sessions
|
|
102
|
+
* @param {SessionOrdering} [orderBy] The field by which sessions should be ordered
|
|
103
|
+
* @param {OrderDirection} [orderDirection]
|
|
104
|
+
* @param {number} [pageSize] The number of items to return per page -- must be between `1` and `50`
|
|
105
|
+
* @param {number} [page] The page number to return -- starts at `1`
|
|
106
|
+
* @param {*} [options] Override http request option.
|
|
107
|
+
* @throws {RequiredError}
|
|
108
|
+
* @memberof SessionsApiInterface
|
|
109
|
+
*/
|
|
110
|
+
listSessionsRaw(requestParameters: ListSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListSessionsResponse>>;
|
|
111
|
+
/**
|
|
112
|
+
* List Sessions created by your account
|
|
113
|
+
* List Sessions
|
|
114
|
+
*/
|
|
115
|
+
listSessions(orderBy?: SessionOrdering, orderDirection?: OrderDirection, pageSize?: number, page?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListSessionsResponse>;
|
|
116
|
+
/**
|
|
117
|
+
* Redact a Session, removing all identity data from Trinsic\'s servers. Every application has a redaction period that dictates how long we will hold on to your users\' PII data. Once a session falls outside the redaction cutoff date, all PII will automatically be removed from that session. You can utilize this endpoint to redact a session immediately. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
118
|
+
* @summary Redact Session
|
|
119
|
+
* @param {string} sessionId
|
|
120
|
+
* @param {*} [options] Override http request option.
|
|
121
|
+
* @throws {RequiredError}
|
|
122
|
+
* @memberof SessionsApiInterface
|
|
123
|
+
*/
|
|
124
|
+
redactSessionRaw(requestParameters: RedactSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
125
|
+
/**
|
|
126
|
+
* Redact a Session, removing all identity data from Trinsic\'s servers. Every application has a redaction period that dictates how long we will hold on to your users\' PII data. Once a session falls outside the redaction cutoff date, all PII will automatically be removed from that session. You can utilize this endpoint to redact a session immediately. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
127
|
+
* Redact Session
|
|
128
|
+
*/
|
|
129
|
+
redactSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
130
|
+
}
|
|
131
|
+
/**
|
|
132
|
+
*
|
|
133
|
+
*/
|
|
134
|
+
export declare class SessionsApi extends runtime.BaseAPI implements SessionsApiInterface {
|
|
135
|
+
/**
|
|
136
|
+
* Cancel a Session by its ID
|
|
137
|
+
* Cancel Session
|
|
138
|
+
*/
|
|
139
|
+
cancelSessionRaw(requestParameters: CancelSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CancelSessionResponse>>;
|
|
140
|
+
/**
|
|
141
|
+
* Cancel a Session by its ID
|
|
142
|
+
* Cancel Session
|
|
143
|
+
*/
|
|
144
|
+
cancelSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CancelSessionResponse>;
|
|
145
|
+
/**
|
|
146
|
+
* Create a Session to verify a user\'s identity
|
|
147
|
+
* Create Session
|
|
148
|
+
*/
|
|
149
|
+
createSessionRaw(requestParameters: CreateSessionOperationRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<CreateSessionResponse>>;
|
|
150
|
+
/**
|
|
151
|
+
* Create a Session to verify a user\'s identity
|
|
152
|
+
* Create Session
|
|
153
|
+
*/
|
|
154
|
+
createSession(createSessionRequest?: CreateSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<CreateSessionResponse>;
|
|
155
|
+
/**
|
|
156
|
+
* Get a Session by its ID
|
|
157
|
+
* Get Session
|
|
158
|
+
*/
|
|
159
|
+
getSessionRaw(requestParameters: GetSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<GetSessionResponse>>;
|
|
160
|
+
/**
|
|
161
|
+
* Get a Session by its ID
|
|
162
|
+
* Get Session
|
|
163
|
+
*/
|
|
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>;
|
|
173
|
+
/**
|
|
174
|
+
* List Sessions created by your account
|
|
175
|
+
* List Sessions
|
|
176
|
+
*/
|
|
177
|
+
listSessionsRaw(requestParameters: ListSessionsRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<ListSessionsResponse>>;
|
|
178
|
+
/**
|
|
179
|
+
* List Sessions created by your account
|
|
180
|
+
* List Sessions
|
|
181
|
+
*/
|
|
182
|
+
listSessions(orderBy?: SessionOrdering, orderDirection?: OrderDirection, pageSize?: number, page?: number, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<ListSessionsResponse>;
|
|
183
|
+
/**
|
|
184
|
+
* Redact a Session, removing all identity data from Trinsic\'s servers. Every application has a redaction period that dictates how long we will hold on to your users\' PII data. Once a session falls outside the redaction cutoff date, all PII will automatically be removed from that session. You can utilize this endpoint to redact a session immediately. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
185
|
+
* Redact Session
|
|
186
|
+
*/
|
|
187
|
+
redactSessionRaw(requestParameters: RedactSessionRequest, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<void>>;
|
|
188
|
+
/**
|
|
189
|
+
* Redact a Session, removing all identity data from Trinsic\'s servers. Every application has a redaction period that dictates how long we will hold on to your users\' PII data. Once a session falls outside the redaction cutoff date, all PII will automatically be removed from that session. You can utilize this endpoint to redact a session immediately. Identity data that a user has chosen to save in their passkey-protected wallet will not be deleted.
|
|
190
|
+
* Redact Session
|
|
191
|
+
*/
|
|
192
|
+
redactSession(sessionId: string, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<void>;
|
|
193
|
+
}
|