@knowledge-stack/ksapi 1.23.5 → 1.25.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 +130 -4
- package/.openapi-generator/VERSION +1 -1
- package/README.md +282 -28
- package/dist/apis/AuthApi.d.ts +117 -0
- package/dist/apis/AuthApi.js +137 -47
- package/dist/apis/ChunkLineagesApi.d.ts +38 -0
- package/dist/apis/ChunkLineagesApi.js +42 -15
- package/dist/apis/ChunksApi.d.ts +161 -5
- package/dist/apis/ChunksApi.js +168 -31
- package/dist/apis/DefaultApi.d.ts +20 -0
- package/dist/apis/DefaultApi.js +28 -10
- package/dist/apis/DocumentVersionsApi.d.ts +99 -9
- package/dist/apis/DocumentVersionsApi.js +100 -37
- package/dist/apis/DocumentsApi.d.ts +80 -0
- package/dist/apis/DocumentsApi.js +84 -30
- package/dist/apis/FoldersApi.d.ts +92 -9
- package/dist/apis/FoldersApi.js +86 -32
- package/dist/apis/InvitesApi.d.ts +51 -0
- package/dist/apis/InvitesApi.js +56 -20
- package/dist/apis/PathPartsApi.d.ts +140 -1
- package/dist/apis/PathPartsApi.js +141 -20
- package/dist/apis/SectionsApi.d.ts +49 -0
- package/dist/apis/SectionsApi.js +56 -20
- package/dist/apis/TagsApi.d.ts +62 -0
- package/dist/apis/TagsApi.js +70 -25
- package/dist/apis/TenantsApi.d.ts +103 -0
- package/dist/apis/TenantsApi.js +112 -40
- package/dist/apis/ThreadMessagesApi.d.ts +41 -0
- package/dist/apis/ThreadMessagesApi.js +42 -15
- package/dist/apis/ThreadsApi.d.ts +77 -0
- package/dist/apis/ThreadsApi.js +84 -30
- package/dist/apis/UserPermissionsApi.d.ts +54 -0
- package/dist/apis/UserPermissionsApi.js +56 -20
- package/dist/apis/UsersApi.d.ts +23 -0
- package/dist/apis/UsersApi.js +28 -10
- package/dist/apis/WorkflowsApi.d.ts +38 -0
- package/dist/apis/WorkflowsApi.js +42 -15
- package/dist/esm/apis/AuthApi.d.ts +117 -0
- package/dist/esm/apis/AuthApi.js +137 -47
- package/dist/esm/apis/ChunkLineagesApi.d.ts +38 -0
- package/dist/esm/apis/ChunkLineagesApi.js +42 -15
- package/dist/esm/apis/ChunksApi.d.ts +161 -5
- package/dist/esm/apis/ChunksApi.js +169 -32
- package/dist/esm/apis/DefaultApi.d.ts +20 -0
- package/dist/esm/apis/DefaultApi.js +28 -10
- package/dist/esm/apis/DocumentVersionsApi.d.ts +99 -9
- package/dist/esm/apis/DocumentVersionsApi.js +101 -38
- package/dist/esm/apis/DocumentsApi.d.ts +80 -0
- package/dist/esm/apis/DocumentsApi.js +84 -30
- package/dist/esm/apis/FoldersApi.d.ts +92 -9
- package/dist/esm/apis/FoldersApi.js +87 -33
- package/dist/esm/apis/InvitesApi.d.ts +51 -0
- package/dist/esm/apis/InvitesApi.js +56 -20
- package/dist/esm/apis/PathPartsApi.d.ts +140 -1
- package/dist/esm/apis/PathPartsApi.js +142 -21
- package/dist/esm/apis/SectionsApi.d.ts +49 -0
- package/dist/esm/apis/SectionsApi.js +56 -20
- package/dist/esm/apis/TagsApi.d.ts +62 -0
- package/dist/esm/apis/TagsApi.js +70 -25
- package/dist/esm/apis/TenantsApi.d.ts +103 -0
- package/dist/esm/apis/TenantsApi.js +112 -40
- package/dist/esm/apis/ThreadMessagesApi.d.ts +41 -0
- package/dist/esm/apis/ThreadMessagesApi.js +42 -15
- package/dist/esm/apis/ThreadsApi.d.ts +77 -0
- package/dist/esm/apis/ThreadsApi.js +84 -30
- package/dist/esm/apis/UserPermissionsApi.d.ts +54 -0
- package/dist/esm/apis/UserPermissionsApi.js +56 -20
- package/dist/esm/apis/UsersApi.d.ts +23 -0
- package/dist/esm/apis/UsersApi.js +28 -10
- package/dist/esm/apis/WorkflowsApi.d.ts +38 -0
- package/dist/esm/apis/WorkflowsApi.js +42 -15
- package/dist/esm/models/ChunkBulkResponse.d.ts +139 -0
- package/dist/esm/models/ChunkBulkResponse.js +100 -0
- package/dist/esm/models/{DocumentContentPathPart.d.ts → ChunkContentItem.d.ts} +37 -40
- package/dist/esm/models/{DocumentContentPathPart.js → ChunkContentItem.js} +19 -16
- package/dist/esm/models/ChunkSearchRequest.d.ts +14 -2
- package/dist/esm/models/ChunkSearchRequest.js +6 -2
- package/dist/esm/models/DocumentResponse.d.ts +13 -0
- package/dist/esm/models/DocumentResponse.js +10 -0
- package/dist/esm/models/FolderResponse.d.ts +13 -0
- package/dist/esm/models/FolderResponse.js +10 -0
- package/dist/esm/models/FolderResponseOrDocumentResponse.d.ts +27 -0
- package/dist/esm/models/FolderResponseOrDocumentResponse.js +47 -0
- package/dist/esm/models/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.js +70 -0
- package/dist/esm/models/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.d.ts +66 -0
- package/dist/esm/models/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.js +70 -0
- package/dist/esm/models/SectionContentItem.d.ts +114 -0
- package/dist/esm/models/SectionContentItem.js +88 -0
- package/dist/esm/models/SectionContentItemOrChunkContentItem.d.ts +27 -0
- package/dist/esm/models/SectionContentItemOrChunkContentItem.js +47 -0
- package/dist/esm/models/SubtreeChunkGroup.d.ts +62 -0
- package/dist/esm/models/SubtreeChunkGroup.js +52 -0
- package/dist/esm/models/SubtreeChunksResponse.d.ts +48 -0
- package/dist/esm/models/SubtreeChunksResponse.js +45 -0
- package/dist/esm/models/VersionChunkIdsResponse.d.ts +47 -0
- package/dist/esm/models/VersionChunkIdsResponse.js +44 -0
- package/dist/esm/models/index.d.ts +10 -4
- package/dist/esm/models/index.js +10 -4
- package/dist/models/ChunkBulkResponse.d.ts +139 -0
- package/dist/models/ChunkBulkResponse.js +108 -0
- package/dist/models/{DocumentContentPathPart.d.ts → ChunkContentItem.d.ts} +37 -40
- package/dist/models/{DocumentContentPathPart.js → ChunkContentItem.js} +25 -22
- package/dist/models/ChunkSearchRequest.d.ts +14 -2
- package/dist/models/ChunkSearchRequest.js +6 -2
- package/dist/models/DocumentResponse.d.ts +13 -0
- package/dist/models/DocumentResponse.js +11 -1
- package/dist/models/FolderResponse.d.ts +13 -0
- package/dist/models/FolderResponse.js +11 -1
- package/dist/models/FolderResponseOrDocumentResponse.d.ts +27 -0
- package/dist/models/FolderResponseOrDocumentResponse.js +53 -0
- package/dist/models/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.d.ts +66 -0
- package/dist/models/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.js +78 -0
- package/dist/models/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.d.ts +66 -0
- package/dist/models/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.js +78 -0
- package/dist/models/SectionContentItem.d.ts +114 -0
- package/dist/models/SectionContentItem.js +96 -0
- package/dist/models/SectionContentItemOrChunkContentItem.d.ts +27 -0
- package/dist/models/SectionContentItemOrChunkContentItem.js +53 -0
- package/dist/models/SubtreeChunkGroup.d.ts +62 -0
- package/dist/models/SubtreeChunkGroup.js +60 -0
- package/dist/models/SubtreeChunksResponse.d.ts +48 -0
- package/dist/models/SubtreeChunksResponse.js +53 -0
- package/dist/models/VersionChunkIdsResponse.d.ts +47 -0
- package/dist/models/VersionChunkIdsResponse.js +52 -0
- package/dist/models/index.d.ts +10 -4
- package/dist/models/index.js +10 -4
- package/docs/AuthApi.md +707 -0
- package/docs/BulkTagRequest.md +35 -0
- package/docs/ChunkBulkResponse.md +65 -0
- package/docs/ChunkContentItem.md +59 -0
- package/docs/ChunkLineageResponse.md +41 -0
- package/docs/ChunkLineagesApi.md +230 -0
- package/docs/ChunkMetadataInput.md +37 -0
- package/docs/ChunkMetadataOutput.md +37 -0
- package/docs/ChunkResponse.md +63 -0
- package/docs/ChunkSearchRequest.md +51 -0
- package/docs/ChunkType.md +33 -0
- package/docs/ChunksApi.md +590 -0
- package/docs/ClearVersionContentsResponse.md +35 -0
- package/docs/CreateChunkLineageRequest.md +37 -0
- package/docs/CreateChunkRequest.md +43 -0
- package/docs/CreateDocumentRequest.md +41 -0
- package/docs/CreateFolderRequest.md +37 -0
- package/docs/CreatePasswordUserRequest.md +36 -0
- package/docs/CreatePermissionRequest.md +40 -0
- package/docs/CreateSectionRequest.md +41 -0
- package/docs/CreateTagRequest.md +39 -0
- package/docs/CreateTenantRequest.md +37 -0
- package/docs/CreateThreadMessageRequest.md +37 -0
- package/docs/CreateThreadRequest.md +37 -0
- package/docs/DefaultApi.md +128 -0
- package/docs/DocumentOrigin.md +33 -0
- package/docs/DocumentResponse.md +63 -0
- package/docs/DocumentType.md +33 -0
- package/docs/DocumentVersionMetadata.md +47 -0
- package/docs/DocumentVersionMetadataUpdate.md +47 -0
- package/docs/DocumentVersionResponse.md +57 -0
- package/docs/DocumentVersionsApi.md +530 -0
- package/docs/DocumentsApi.md +464 -0
- package/docs/EmailSentResponse.md +34 -0
- package/docs/EmailVerificationRequest.md +34 -0
- package/docs/EmbeddingModel.md +33 -0
- package/docs/FolderResponse.md +55 -0
- package/docs/FolderResponseOrDocumentResponse.md +62 -0
- package/docs/FoldersApi.md +473 -0
- package/docs/HTTPValidationError.md +34 -0
- package/docs/HealthCheckResponse.md +36 -0
- package/docs/IdpType.md +33 -0
- package/docs/IngestDocumentResponse.md +39 -0
- package/docs/InviteResponse.md +53 -0
- package/docs/InviteStatus.md +32 -0
- package/docs/InviteUserRequest.md +38 -0
- package/docs/InvitesApi.md +305 -0
- package/docs/LineageEdgeResponse.md +37 -0
- package/docs/LineageGraphResponse.md +37 -0
- package/docs/LineageNodeResponse.md +47 -0
- package/docs/LocationInner.md +32 -0
- package/docs/MessageRole.md +33 -0
- package/docs/OAuth2Config.md +41 -0
- package/docs/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.md +40 -0
- package/docs/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.md +40 -0
- package/docs/PaginatedResponseDocumentResponse.md +40 -0
- package/docs/PaginatedResponseDocumentVersionResponse.md +40 -0
- package/docs/PaginatedResponseFolderResponse.md +40 -0
- package/docs/PaginatedResponseInviteResponse.md +40 -0
- package/docs/PaginatedResponsePathPartResponse.md +40 -0
- package/docs/PaginatedResponsePermissionResponse.md +40 -0
- package/docs/PaginatedResponseTagResponse.md +40 -0
- package/docs/PaginatedResponseTenantResponse.md +40 -0
- package/docs/PaginatedResponseTenantUserResponse.md +40 -0
- package/docs/PaginatedResponseThreadMessageResponse.md +40 -0
- package/docs/PaginatedResponseThreadResponse.md +40 -0
- package/docs/PaginatedResponseWorkflowSummaryResponse.md +40 -0
- package/docs/PartType.md +33 -0
- package/docs/PasswordResetRequest.md +36 -0
- package/docs/PasswordResetWithTokenRequest.md +36 -0
- package/docs/PathOrder.md +33 -0
- package/docs/PathPartResponse.md +53 -0
- package/docs/PathPartTagsResponse.md +35 -0
- package/docs/PathPartsApi.md +461 -0
- package/docs/PermissionCapability.md +33 -0
- package/docs/PermissionResponse.md +48 -0
- package/docs/PipelineState.md +45 -0
- package/docs/PipelineStatus.md +33 -0
- package/docs/Polygon.md +41 -0
- package/docs/PolygonReference.md +37 -0
- package/docs/RootResponse.md +36 -0
- package/docs/ScoredChunkResponse.md +65 -0
- package/docs/SectionContentItem.md +55 -0
- package/docs/SectionContentItemOrChunkContentItem.md +60 -0
- package/docs/SectionResponse.md +57 -0
- package/docs/SectionsApi.md +299 -0
- package/docs/SignInRequest.md +38 -0
- package/docs/SubtreeChunkGroup.md +39 -0
- package/docs/SubtreeChunksResponse.md +35 -0
- package/docs/TagResponse.md +47 -0
- package/docs/TagsApi.md +374 -0
- package/docs/TenantResponse.md +39 -0
- package/docs/TenantUserEditRequest.md +35 -0
- package/docs/TenantUserResponse.md +43 -0
- package/docs/TenantUserRole.md +33 -0
- package/docs/TenantsApi.md +605 -0
- package/docs/ThreadMessageResponse.md +53 -0
- package/docs/ThreadMessagesApi.md +239 -0
- package/docs/ThreadResponse.md +49 -0
- package/docs/ThreadsApi.md +455 -0
- package/docs/UpdateChunkContentRequest.md +37 -0
- package/docs/UpdateChunkMetadataRequest.md +35 -0
- package/docs/UpdateDocumentRequest.md +39 -0
- package/docs/UpdateFolderRequest.md +37 -0
- package/docs/UpdatePermissionRequest.md +36 -0
- package/docs/UpdateSectionRequest.md +41 -0
- package/docs/UpdateTagRequest.md +39 -0
- package/docs/UpdateTenantRequest.md +37 -0
- package/docs/UpdateThreadRequest.md +37 -0
- package/docs/UpdateUserRequest.md +34 -0
- package/docs/UserPermissionsApi.md +314 -0
- package/docs/UserResponse.md +44 -0
- package/docs/UsersApi.md +149 -0
- package/docs/ValidationError.md +42 -0
- package/docs/VersionChunkIdsResponse.md +35 -0
- package/docs/WorkflowAction.md +33 -0
- package/docs/WorkflowActionResponse.md +39 -0
- package/docs/WorkflowDetailResponse.md +63 -0
- package/docs/WorkflowSummaryResponse.md +49 -0
- package/docs/WorkflowsApi.md +230 -0
- package/package.json +1 -1
- package/src/apis/AuthApi.ts +214 -47
- package/src/apis/ChunkLineagesApi.ts +68 -15
- package/src/apis/ChunksApi.ts +298 -33
- package/src/apis/DefaultApi.ts +40 -10
- package/src/apis/DocumentVersionsApi.ts +170 -45
- package/src/apis/DocumentsApi.ts +140 -30
- package/src/apis/FoldersApi.ts +153 -40
- package/src/apis/InvitesApi.ts +91 -20
- package/src/apis/PathPartsApi.ts +260 -20
- package/src/apis/SectionsApi.ts +89 -20
- package/src/apis/TagsApi.ts +112 -25
- package/src/apis/TenantsApi.ts +183 -40
- package/src/apis/ThreadMessagesApi.ts +71 -15
- package/src/apis/ThreadsApi.ts +137 -30
- package/src/apis/UserPermissionsApi.ts +94 -20
- package/src/apis/UsersApi.ts +43 -10
- package/src/apis/WorkflowsApi.ts +68 -15
- package/src/models/ChunkBulkResponse.ts +232 -0
- package/src/models/{DocumentContentPathPart.ts → ChunkContentItem.ts} +43 -53
- package/src/models/ChunkSearchRequest.ts +20 -4
- package/src/models/DocumentResponse.ts +17 -0
- package/src/models/FolderResponse.ts +19 -0
- package/src/models/FolderResponseOrDocumentResponse.ts +72 -0
- package/src/models/PaginatedResponseAnnotatedUnionFolderResponseDocumentResponseDiscriminator.ts +130 -0
- package/src/models/PaginatedResponseAnnotatedUnionSectionContentItemChunkContentItemDiscriminator.ts +130 -0
- package/src/models/SectionContentItem.ts +182 -0
- package/src/models/SectionContentItemOrChunkContentItem.ts +72 -0
- package/src/models/SubtreeChunkGroup.ts +104 -0
- package/src/models/SubtreeChunksResponse.ts +91 -0
- package/src/models/VersionChunkIdsResponse.ts +83 -0
- package/src/models/index.ts +10 -4
- package/dist/esm/models/FolderDocumentResponse.d.ts +0 -157
- package/dist/esm/models/FolderDocumentResponse.js +0 -99
- package/dist/esm/models/PaginatedResponseDocumentContentPathPart.d.ts +0 -66
- package/dist/esm/models/PaginatedResponseDocumentContentPathPart.js +0 -70
- package/dist/esm/models/PaginatedResponseFolderDocumentResponse.d.ts +0 -66
- package/dist/esm/models/PaginatedResponseFolderDocumentResponse.js +0 -70
- package/dist/models/FolderDocumentResponse.d.ts +0 -157
- package/dist/models/FolderDocumentResponse.js +0 -107
- package/dist/models/PaginatedResponseDocumentContentPathPart.d.ts +0 -66
- package/dist/models/PaginatedResponseDocumentContentPathPart.js +0 -78
- package/dist/models/PaginatedResponseFolderDocumentResponse.d.ts +0 -66
- package/dist/models/PaginatedResponseFolderDocumentResponse.js +0 -78
- package/src/models/FolderDocumentResponse.ts +0 -267
- package/src/models/PaginatedResponseDocumentContentPathPart.ts +0 -130
- package/src/models/PaginatedResponseFolderDocumentResponse.ts +0 -130
package/docs/AuthApi.md
ADDED
|
@@ -0,0 +1,707 @@
|
|
|
1
|
+
# AuthApi
|
|
2
|
+
|
|
3
|
+
All URIs are relative to *http://localhost:8000*
|
|
4
|
+
|
|
5
|
+
| Method | HTTP request | Description |
|
|
6
|
+
|------------- | ------------- | -------------|
|
|
7
|
+
| [**createPasswordUser**](AuthApi.md#createpassworduseroperation) | **POST** /v1/auth/pw/user | Create Password User Handler |
|
|
8
|
+
| [**initiateSso**](AuthApi.md#initiatesso) | **POST** /v1/auth/sso/initiate | Initiate Sso Handler |
|
|
9
|
+
| [**oauth2Callback**](AuthApi.md#oauth2callback) | **GET** /v1/auth/sso/oauth2/callback | Oauth2 Callback Handler |
|
|
10
|
+
| [**pwEmailVerification**](AuthApi.md#pwemailverification) | **POST** /v1/auth/pw/email_verification | Pw Email Verification Handler |
|
|
11
|
+
| [**pwSignin**](AuthApi.md#pwsignin) | **POST** /v1/auth/pw/signin | Signin Handler |
|
|
12
|
+
| [**refreshUat**](AuthApi.md#refreshuat) | **POST** /v1/auth/uat | Refresh Uat Handler |
|
|
13
|
+
| [**resetPassword**](AuthApi.md#resetpassword) | **POST** /v1/auth/pw/reset | Reset Password Handler |
|
|
14
|
+
| [**resetPasswordWithToken**](AuthApi.md#resetpasswordwithtoken) | **POST** /v1/auth/pw/reset_with_token | Reset Password With Token Handler |
|
|
15
|
+
| [**sendPwResetEmail**](AuthApi.md#sendpwresetemail) | **POST** /v1/auth/pw/send_reset_email | Send Pw Reset Email Handler |
|
|
16
|
+
| [**signout**](AuthApi.md#signout) | **POST** /v1/auth/signout | Signout Handler |
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
## createPasswordUser
|
|
21
|
+
|
|
22
|
+
> UserResponse createPasswordUser(createPasswordUserRequest)
|
|
23
|
+
|
|
24
|
+
Create Password User Handler
|
|
25
|
+
|
|
26
|
+
### Example
|
|
27
|
+
|
|
28
|
+
```ts
|
|
29
|
+
import {
|
|
30
|
+
Configuration,
|
|
31
|
+
AuthApi,
|
|
32
|
+
} from '@knowledge-stack/ksapi';
|
|
33
|
+
import type { CreatePasswordUserOperationRequest } from '@knowledge-stack/ksapi';
|
|
34
|
+
|
|
35
|
+
async function example() {
|
|
36
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
37
|
+
const api = new AuthApi();
|
|
38
|
+
|
|
39
|
+
const body = {
|
|
40
|
+
// CreatePasswordUserRequest
|
|
41
|
+
createPasswordUserRequest: ...,
|
|
42
|
+
} satisfies CreatePasswordUserOperationRequest;
|
|
43
|
+
|
|
44
|
+
try {
|
|
45
|
+
const data = await api.createPasswordUser(body);
|
|
46
|
+
console.log(data);
|
|
47
|
+
} catch (error) {
|
|
48
|
+
console.error(error);
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
|
|
52
|
+
// Run the test
|
|
53
|
+
example().catch(console.error);
|
|
54
|
+
```
|
|
55
|
+
|
|
56
|
+
### Parameters
|
|
57
|
+
|
|
58
|
+
|
|
59
|
+
| Name | Type | Description | Notes |
|
|
60
|
+
|------------- | ------------- | ------------- | -------------|
|
|
61
|
+
| **createPasswordUserRequest** | [CreatePasswordUserRequest](CreatePasswordUserRequest.md) | | |
|
|
62
|
+
|
|
63
|
+
### Return type
|
|
64
|
+
|
|
65
|
+
[**UserResponse**](UserResponse.md)
|
|
66
|
+
|
|
67
|
+
### Authorization
|
|
68
|
+
|
|
69
|
+
No authorization required
|
|
70
|
+
|
|
71
|
+
### HTTP request headers
|
|
72
|
+
|
|
73
|
+
- **Content-Type**: `application/json`
|
|
74
|
+
- **Accept**: `application/json`
|
|
75
|
+
|
|
76
|
+
|
|
77
|
+
### HTTP response details
|
|
78
|
+
| Status code | Description | Response headers |
|
|
79
|
+
|-------------|-------------|------------------|
|
|
80
|
+
| **201** | Successful Response | - |
|
|
81
|
+
| **422** | Validation Error | - |
|
|
82
|
+
|
|
83
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
## initiateSso
|
|
87
|
+
|
|
88
|
+
> any initiateSso(provider, tenantId)
|
|
89
|
+
|
|
90
|
+
Initiate Sso Handler
|
|
91
|
+
|
|
92
|
+
Initiate SSO with the given provider and tenant ID.
|
|
93
|
+
|
|
94
|
+
### Example
|
|
95
|
+
|
|
96
|
+
```ts
|
|
97
|
+
import {
|
|
98
|
+
Configuration,
|
|
99
|
+
AuthApi,
|
|
100
|
+
} from '@knowledge-stack/ksapi';
|
|
101
|
+
import type { InitiateSsoRequest } from '@knowledge-stack/ksapi';
|
|
102
|
+
|
|
103
|
+
async function example() {
|
|
104
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
105
|
+
const api = new AuthApi();
|
|
106
|
+
|
|
107
|
+
const body = {
|
|
108
|
+
// IdpType | Provider to initiate SSO with
|
|
109
|
+
provider: ...,
|
|
110
|
+
// string | Tenant ID to initiate SSO with (optional)
|
|
111
|
+
tenantId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
|
|
112
|
+
} satisfies InitiateSsoRequest;
|
|
113
|
+
|
|
114
|
+
try {
|
|
115
|
+
const data = await api.initiateSso(body);
|
|
116
|
+
console.log(data);
|
|
117
|
+
} catch (error) {
|
|
118
|
+
console.error(error);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
|
|
122
|
+
// Run the test
|
|
123
|
+
example().catch(console.error);
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
### Parameters
|
|
127
|
+
|
|
128
|
+
|
|
129
|
+
| Name | Type | Description | Notes |
|
|
130
|
+
|------------- | ------------- | ------------- | -------------|
|
|
131
|
+
| **provider** | `IdpType` | Provider to initiate SSO with | [Defaults to `undefined`] [Enum: PASSWORD, GOOGLE, TENANT] |
|
|
132
|
+
| **tenantId** | `string` | Tenant ID to initiate SSO with | [Optional] [Defaults to `undefined`] |
|
|
133
|
+
|
|
134
|
+
### Return type
|
|
135
|
+
|
|
136
|
+
**any**
|
|
137
|
+
|
|
138
|
+
### Authorization
|
|
139
|
+
|
|
140
|
+
No authorization required
|
|
141
|
+
|
|
142
|
+
### HTTP request headers
|
|
143
|
+
|
|
144
|
+
- **Content-Type**: Not defined
|
|
145
|
+
- **Accept**: `application/json`
|
|
146
|
+
|
|
147
|
+
|
|
148
|
+
### HTTP response details
|
|
149
|
+
| Status code | Description | Response headers |
|
|
150
|
+
|-------------|-------------|------------------|
|
|
151
|
+
| **200** | Successful Response | - |
|
|
152
|
+
| **422** | Validation Error | - |
|
|
153
|
+
|
|
154
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
155
|
+
|
|
156
|
+
|
|
157
|
+
## oauth2Callback
|
|
158
|
+
|
|
159
|
+
> UserResponse oauth2Callback(provider, code, state, error, errorDescription, tenantId)
|
|
160
|
+
|
|
161
|
+
Oauth2 Callback Handler
|
|
162
|
+
|
|
163
|
+
Handle OAuth2 callback from the given OAuth client.
|
|
164
|
+
|
|
165
|
+
### Example
|
|
166
|
+
|
|
167
|
+
```ts
|
|
168
|
+
import {
|
|
169
|
+
Configuration,
|
|
170
|
+
AuthApi,
|
|
171
|
+
} from '@knowledge-stack/ksapi';
|
|
172
|
+
import type { Oauth2CallbackRequest } from '@knowledge-stack/ksapi';
|
|
173
|
+
|
|
174
|
+
async function example() {
|
|
175
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
176
|
+
const api = new AuthApi();
|
|
177
|
+
|
|
178
|
+
const body = {
|
|
179
|
+
// IdpType | Provider to initiate SSO with
|
|
180
|
+
provider: ...,
|
|
181
|
+
// string | Authorization code from provider (optional)
|
|
182
|
+
code: code_example,
|
|
183
|
+
// string | State parameter for CSRF protection (optional)
|
|
184
|
+
state: state_example,
|
|
185
|
+
// string | Error code if authorization failed (optional)
|
|
186
|
+
error: error_example,
|
|
187
|
+
// string | Error description (optional)
|
|
188
|
+
errorDescription: errorDescription_example,
|
|
189
|
+
// string | Tenant ID to initiate SSO with (optional)
|
|
190
|
+
tenantId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
|
|
191
|
+
} satisfies Oauth2CallbackRequest;
|
|
192
|
+
|
|
193
|
+
try {
|
|
194
|
+
const data = await api.oauth2Callback(body);
|
|
195
|
+
console.log(data);
|
|
196
|
+
} catch (error) {
|
|
197
|
+
console.error(error);
|
|
198
|
+
}
|
|
199
|
+
}
|
|
200
|
+
|
|
201
|
+
// Run the test
|
|
202
|
+
example().catch(console.error);
|
|
203
|
+
```
|
|
204
|
+
|
|
205
|
+
### Parameters
|
|
206
|
+
|
|
207
|
+
|
|
208
|
+
| Name | Type | Description | Notes |
|
|
209
|
+
|------------- | ------------- | ------------- | -------------|
|
|
210
|
+
| **provider** | `IdpType` | Provider to initiate SSO with | [Defaults to `undefined`] [Enum: PASSWORD, GOOGLE, TENANT] |
|
|
211
|
+
| **code** | `string` | Authorization code from provider | [Optional] [Defaults to `undefined`] |
|
|
212
|
+
| **state** | `string` | State parameter for CSRF protection | [Optional] [Defaults to `undefined`] |
|
|
213
|
+
| **error** | `string` | Error code if authorization failed | [Optional] [Defaults to `undefined`] |
|
|
214
|
+
| **errorDescription** | `string` | Error description | [Optional] [Defaults to `undefined`] |
|
|
215
|
+
| **tenantId** | `string` | Tenant ID to initiate SSO with | [Optional] [Defaults to `undefined`] |
|
|
216
|
+
|
|
217
|
+
### Return type
|
|
218
|
+
|
|
219
|
+
[**UserResponse**](UserResponse.md)
|
|
220
|
+
|
|
221
|
+
### Authorization
|
|
222
|
+
|
|
223
|
+
No authorization required
|
|
224
|
+
|
|
225
|
+
### HTTP request headers
|
|
226
|
+
|
|
227
|
+
- **Content-Type**: Not defined
|
|
228
|
+
- **Accept**: `application/json`
|
|
229
|
+
|
|
230
|
+
|
|
231
|
+
### HTTP response details
|
|
232
|
+
| Status code | Description | Response headers |
|
|
233
|
+
|-------------|-------------|------------------|
|
|
234
|
+
| **200** | Successful Response | - |
|
|
235
|
+
| **422** | Validation Error | - |
|
|
236
|
+
|
|
237
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
238
|
+
|
|
239
|
+
|
|
240
|
+
## pwEmailVerification
|
|
241
|
+
|
|
242
|
+
> EmailSentResponse pwEmailVerification(emailVerificationRequest)
|
|
243
|
+
|
|
244
|
+
Pw Email Verification Handler
|
|
245
|
+
|
|
246
|
+
Send password user email verification email. This endpoint is the first step in the password user creation process. The user receives an email with a link to create their account.
|
|
247
|
+
|
|
248
|
+
### Example
|
|
249
|
+
|
|
250
|
+
```ts
|
|
251
|
+
import {
|
|
252
|
+
Configuration,
|
|
253
|
+
AuthApi,
|
|
254
|
+
} from '@knowledge-stack/ksapi';
|
|
255
|
+
import type { PwEmailVerificationRequest } from '@knowledge-stack/ksapi';
|
|
256
|
+
|
|
257
|
+
async function example() {
|
|
258
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
259
|
+
const api = new AuthApi();
|
|
260
|
+
|
|
261
|
+
const body = {
|
|
262
|
+
// EmailVerificationRequest
|
|
263
|
+
emailVerificationRequest: ...,
|
|
264
|
+
} satisfies PwEmailVerificationRequest;
|
|
265
|
+
|
|
266
|
+
try {
|
|
267
|
+
const data = await api.pwEmailVerification(body);
|
|
268
|
+
console.log(data);
|
|
269
|
+
} catch (error) {
|
|
270
|
+
console.error(error);
|
|
271
|
+
}
|
|
272
|
+
}
|
|
273
|
+
|
|
274
|
+
// Run the test
|
|
275
|
+
example().catch(console.error);
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
### Parameters
|
|
279
|
+
|
|
280
|
+
|
|
281
|
+
| Name | Type | Description | Notes |
|
|
282
|
+
|------------- | ------------- | ------------- | -------------|
|
|
283
|
+
| **emailVerificationRequest** | [EmailVerificationRequest](EmailVerificationRequest.md) | | |
|
|
284
|
+
|
|
285
|
+
### Return type
|
|
286
|
+
|
|
287
|
+
[**EmailSentResponse**](EmailSentResponse.md)
|
|
288
|
+
|
|
289
|
+
### Authorization
|
|
290
|
+
|
|
291
|
+
No authorization required
|
|
292
|
+
|
|
293
|
+
### HTTP request headers
|
|
294
|
+
|
|
295
|
+
- **Content-Type**: `application/json`
|
|
296
|
+
- **Accept**: `application/json`
|
|
297
|
+
|
|
298
|
+
|
|
299
|
+
### HTTP response details
|
|
300
|
+
| Status code | Description | Response headers |
|
|
301
|
+
|-------------|-------------|------------------|
|
|
302
|
+
| **200** | Successful Response | - |
|
|
303
|
+
| **422** | Validation Error | - |
|
|
304
|
+
|
|
305
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
306
|
+
|
|
307
|
+
|
|
308
|
+
## pwSignin
|
|
309
|
+
|
|
310
|
+
> UserResponse pwSignin(signInRequest)
|
|
311
|
+
|
|
312
|
+
Signin Handler
|
|
313
|
+
|
|
314
|
+
Validate password credentials and redirect to callback. This endpoint validates the user\'s credentials and stores the user ID in the session, then redirects to /auth/callback?method=pw to maintain consistency with OAuth flows.
|
|
315
|
+
|
|
316
|
+
### Example
|
|
317
|
+
|
|
318
|
+
```ts
|
|
319
|
+
import {
|
|
320
|
+
Configuration,
|
|
321
|
+
AuthApi,
|
|
322
|
+
} from '@knowledge-stack/ksapi';
|
|
323
|
+
import type { PwSigninRequest } from '@knowledge-stack/ksapi';
|
|
324
|
+
|
|
325
|
+
async function example() {
|
|
326
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
327
|
+
const api = new AuthApi();
|
|
328
|
+
|
|
329
|
+
const body = {
|
|
330
|
+
// SignInRequest
|
|
331
|
+
signInRequest: ...,
|
|
332
|
+
} satisfies PwSigninRequest;
|
|
333
|
+
|
|
334
|
+
try {
|
|
335
|
+
const data = await api.pwSignin(body);
|
|
336
|
+
console.log(data);
|
|
337
|
+
} catch (error) {
|
|
338
|
+
console.error(error);
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
|
|
342
|
+
// Run the test
|
|
343
|
+
example().catch(console.error);
|
|
344
|
+
```
|
|
345
|
+
|
|
346
|
+
### Parameters
|
|
347
|
+
|
|
348
|
+
|
|
349
|
+
| Name | Type | Description | Notes |
|
|
350
|
+
|------------- | ------------- | ------------- | -------------|
|
|
351
|
+
| **signInRequest** | [SignInRequest](SignInRequest.md) | | |
|
|
352
|
+
|
|
353
|
+
### Return type
|
|
354
|
+
|
|
355
|
+
[**UserResponse**](UserResponse.md)
|
|
356
|
+
|
|
357
|
+
### Authorization
|
|
358
|
+
|
|
359
|
+
No authorization required
|
|
360
|
+
|
|
361
|
+
### HTTP request headers
|
|
362
|
+
|
|
363
|
+
- **Content-Type**: `application/json`
|
|
364
|
+
- **Accept**: `application/json`
|
|
365
|
+
|
|
366
|
+
|
|
367
|
+
### HTTP response details
|
|
368
|
+
| Status code | Description | Response headers |
|
|
369
|
+
|-------------|-------------|------------------|
|
|
370
|
+
| **200** | Successful Response | - |
|
|
371
|
+
| **422** | Validation Error | - |
|
|
372
|
+
|
|
373
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
374
|
+
|
|
375
|
+
|
|
376
|
+
## refreshUat
|
|
377
|
+
|
|
378
|
+
> UserResponse refreshUat(tenantId, ksUat)
|
|
379
|
+
|
|
380
|
+
Refresh Uat Handler
|
|
381
|
+
|
|
382
|
+
Refresh or switch the user\'s active tenant token.
|
|
383
|
+
|
|
384
|
+
### Example
|
|
385
|
+
|
|
386
|
+
```ts
|
|
387
|
+
import {
|
|
388
|
+
Configuration,
|
|
389
|
+
AuthApi,
|
|
390
|
+
} from '@knowledge-stack/ksapi';
|
|
391
|
+
import type { RefreshUatRequest } from '@knowledge-stack/ksapi';
|
|
392
|
+
|
|
393
|
+
async function example() {
|
|
394
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
395
|
+
const api = new AuthApi();
|
|
396
|
+
|
|
397
|
+
const body = {
|
|
398
|
+
// string | Target tenant ID to switch to. None=refresh current tenant (optional)
|
|
399
|
+
tenantId: 38400000-8cf0-11bd-b23e-10b96e4ef00d,
|
|
400
|
+
// string (optional)
|
|
401
|
+
ksUat: ksUat_example,
|
|
402
|
+
} satisfies RefreshUatRequest;
|
|
403
|
+
|
|
404
|
+
try {
|
|
405
|
+
const data = await api.refreshUat(body);
|
|
406
|
+
console.log(data);
|
|
407
|
+
} catch (error) {
|
|
408
|
+
console.error(error);
|
|
409
|
+
}
|
|
410
|
+
}
|
|
411
|
+
|
|
412
|
+
// Run the test
|
|
413
|
+
example().catch(console.error);
|
|
414
|
+
```
|
|
415
|
+
|
|
416
|
+
### Parameters
|
|
417
|
+
|
|
418
|
+
|
|
419
|
+
| Name | Type | Description | Notes |
|
|
420
|
+
|------------- | ------------- | ------------- | -------------|
|
|
421
|
+
| **tenantId** | `string` | Target tenant ID to switch to. None=refresh current tenant | [Optional] [Defaults to `undefined`] |
|
|
422
|
+
| **ksUat** | `string` | | [Optional] [Defaults to `undefined`] |
|
|
423
|
+
|
|
424
|
+
### Return type
|
|
425
|
+
|
|
426
|
+
[**UserResponse**](UserResponse.md)
|
|
427
|
+
|
|
428
|
+
### Authorization
|
|
429
|
+
|
|
430
|
+
No authorization required
|
|
431
|
+
|
|
432
|
+
### HTTP request headers
|
|
433
|
+
|
|
434
|
+
- **Content-Type**: Not defined
|
|
435
|
+
- **Accept**: `application/json`
|
|
436
|
+
|
|
437
|
+
|
|
438
|
+
### HTTP response details
|
|
439
|
+
| Status code | Description | Response headers |
|
|
440
|
+
|-------------|-------------|------------------|
|
|
441
|
+
| **200** | Successful Response | - |
|
|
442
|
+
| **422** | Validation Error | - |
|
|
443
|
+
|
|
444
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
445
|
+
|
|
446
|
+
|
|
447
|
+
## resetPassword
|
|
448
|
+
|
|
449
|
+
> UserResponse resetPassword(passwordResetRequest, ksUat)
|
|
450
|
+
|
|
451
|
+
Reset Password Handler
|
|
452
|
+
|
|
453
|
+
Reset password for the authenticated user
|
|
454
|
+
|
|
455
|
+
### Example
|
|
456
|
+
|
|
457
|
+
```ts
|
|
458
|
+
import {
|
|
459
|
+
Configuration,
|
|
460
|
+
AuthApi,
|
|
461
|
+
} from '@knowledge-stack/ksapi';
|
|
462
|
+
import type { ResetPasswordRequest } from '@knowledge-stack/ksapi';
|
|
463
|
+
|
|
464
|
+
async function example() {
|
|
465
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
466
|
+
const api = new AuthApi();
|
|
467
|
+
|
|
468
|
+
const body = {
|
|
469
|
+
// PasswordResetRequest
|
|
470
|
+
passwordResetRequest: ...,
|
|
471
|
+
// string (optional)
|
|
472
|
+
ksUat: ksUat_example,
|
|
473
|
+
} satisfies ResetPasswordRequest;
|
|
474
|
+
|
|
475
|
+
try {
|
|
476
|
+
const data = await api.resetPassword(body);
|
|
477
|
+
console.log(data);
|
|
478
|
+
} catch (error) {
|
|
479
|
+
console.error(error);
|
|
480
|
+
}
|
|
481
|
+
}
|
|
482
|
+
|
|
483
|
+
// Run the test
|
|
484
|
+
example().catch(console.error);
|
|
485
|
+
```
|
|
486
|
+
|
|
487
|
+
### Parameters
|
|
488
|
+
|
|
489
|
+
|
|
490
|
+
| Name | Type | Description | Notes |
|
|
491
|
+
|------------- | ------------- | ------------- | -------------|
|
|
492
|
+
| **passwordResetRequest** | [PasswordResetRequest](PasswordResetRequest.md) | | |
|
|
493
|
+
| **ksUat** | `string` | | [Optional] [Defaults to `undefined`] |
|
|
494
|
+
|
|
495
|
+
### Return type
|
|
496
|
+
|
|
497
|
+
[**UserResponse**](UserResponse.md)
|
|
498
|
+
|
|
499
|
+
### Authorization
|
|
500
|
+
|
|
501
|
+
No authorization required
|
|
502
|
+
|
|
503
|
+
### HTTP request headers
|
|
504
|
+
|
|
505
|
+
- **Content-Type**: `application/json`
|
|
506
|
+
- **Accept**: `application/json`
|
|
507
|
+
|
|
508
|
+
|
|
509
|
+
### HTTP response details
|
|
510
|
+
| Status code | Description | Response headers |
|
|
511
|
+
|-------------|-------------|------------------|
|
|
512
|
+
| **200** | Successful Response | - |
|
|
513
|
+
| **422** | Validation Error | - |
|
|
514
|
+
|
|
515
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
516
|
+
|
|
517
|
+
|
|
518
|
+
## resetPasswordWithToken
|
|
519
|
+
|
|
520
|
+
> UserResponse resetPasswordWithToken(passwordResetWithTokenRequest)
|
|
521
|
+
|
|
522
|
+
Reset Password With Token Handler
|
|
523
|
+
|
|
524
|
+
Reset password with email verification token
|
|
525
|
+
|
|
526
|
+
### Example
|
|
527
|
+
|
|
528
|
+
```ts
|
|
529
|
+
import {
|
|
530
|
+
Configuration,
|
|
531
|
+
AuthApi,
|
|
532
|
+
} from '@knowledge-stack/ksapi';
|
|
533
|
+
import type { ResetPasswordWithTokenRequest } from '@knowledge-stack/ksapi';
|
|
534
|
+
|
|
535
|
+
async function example() {
|
|
536
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
537
|
+
const api = new AuthApi();
|
|
538
|
+
|
|
539
|
+
const body = {
|
|
540
|
+
// PasswordResetWithTokenRequest
|
|
541
|
+
passwordResetWithTokenRequest: ...,
|
|
542
|
+
} satisfies ResetPasswordWithTokenRequest;
|
|
543
|
+
|
|
544
|
+
try {
|
|
545
|
+
const data = await api.resetPasswordWithToken(body);
|
|
546
|
+
console.log(data);
|
|
547
|
+
} catch (error) {
|
|
548
|
+
console.error(error);
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
|
|
552
|
+
// Run the test
|
|
553
|
+
example().catch(console.error);
|
|
554
|
+
```
|
|
555
|
+
|
|
556
|
+
### Parameters
|
|
557
|
+
|
|
558
|
+
|
|
559
|
+
| Name | Type | Description | Notes |
|
|
560
|
+
|------------- | ------------- | ------------- | -------------|
|
|
561
|
+
| **passwordResetWithTokenRequest** | [PasswordResetWithTokenRequest](PasswordResetWithTokenRequest.md) | | |
|
|
562
|
+
|
|
563
|
+
### Return type
|
|
564
|
+
|
|
565
|
+
[**UserResponse**](UserResponse.md)
|
|
566
|
+
|
|
567
|
+
### Authorization
|
|
568
|
+
|
|
569
|
+
No authorization required
|
|
570
|
+
|
|
571
|
+
### HTTP request headers
|
|
572
|
+
|
|
573
|
+
- **Content-Type**: `application/json`
|
|
574
|
+
- **Accept**: `application/json`
|
|
575
|
+
|
|
576
|
+
|
|
577
|
+
### HTTP response details
|
|
578
|
+
| Status code | Description | Response headers |
|
|
579
|
+
|-------------|-------------|------------------|
|
|
580
|
+
| **200** | Successful Response | - |
|
|
581
|
+
| **422** | Validation Error | - |
|
|
582
|
+
|
|
583
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
584
|
+
|
|
585
|
+
|
|
586
|
+
## sendPwResetEmail
|
|
587
|
+
|
|
588
|
+
> EmailSentResponse sendPwResetEmail(emailVerificationRequest)
|
|
589
|
+
|
|
590
|
+
Send Pw Reset Email Handler
|
|
591
|
+
|
|
592
|
+
### Example
|
|
593
|
+
|
|
594
|
+
```ts
|
|
595
|
+
import {
|
|
596
|
+
Configuration,
|
|
597
|
+
AuthApi,
|
|
598
|
+
} from '@knowledge-stack/ksapi';
|
|
599
|
+
import type { SendPwResetEmailRequest } from '@knowledge-stack/ksapi';
|
|
600
|
+
|
|
601
|
+
async function example() {
|
|
602
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
603
|
+
const api = new AuthApi();
|
|
604
|
+
|
|
605
|
+
const body = {
|
|
606
|
+
// EmailVerificationRequest
|
|
607
|
+
emailVerificationRequest: ...,
|
|
608
|
+
} satisfies SendPwResetEmailRequest;
|
|
609
|
+
|
|
610
|
+
try {
|
|
611
|
+
const data = await api.sendPwResetEmail(body);
|
|
612
|
+
console.log(data);
|
|
613
|
+
} catch (error) {
|
|
614
|
+
console.error(error);
|
|
615
|
+
}
|
|
616
|
+
}
|
|
617
|
+
|
|
618
|
+
// Run the test
|
|
619
|
+
example().catch(console.error);
|
|
620
|
+
```
|
|
621
|
+
|
|
622
|
+
### Parameters
|
|
623
|
+
|
|
624
|
+
|
|
625
|
+
| Name | Type | Description | Notes |
|
|
626
|
+
|------------- | ------------- | ------------- | -------------|
|
|
627
|
+
| **emailVerificationRequest** | [EmailVerificationRequest](EmailVerificationRequest.md) | | |
|
|
628
|
+
|
|
629
|
+
### Return type
|
|
630
|
+
|
|
631
|
+
[**EmailSentResponse**](EmailSentResponse.md)
|
|
632
|
+
|
|
633
|
+
### Authorization
|
|
634
|
+
|
|
635
|
+
No authorization required
|
|
636
|
+
|
|
637
|
+
### HTTP request headers
|
|
638
|
+
|
|
639
|
+
- **Content-Type**: `application/json`
|
|
640
|
+
- **Accept**: `application/json`
|
|
641
|
+
|
|
642
|
+
|
|
643
|
+
### HTTP response details
|
|
644
|
+
| Status code | Description | Response headers |
|
|
645
|
+
|-------------|-------------|------------------|
|
|
646
|
+
| **200** | Successful Response | - |
|
|
647
|
+
| **422** | Validation Error | - |
|
|
648
|
+
|
|
649
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
650
|
+
|
|
651
|
+
|
|
652
|
+
## signout
|
|
653
|
+
|
|
654
|
+
> any signout()
|
|
655
|
+
|
|
656
|
+
Signout Handler
|
|
657
|
+
|
|
658
|
+
### Example
|
|
659
|
+
|
|
660
|
+
```ts
|
|
661
|
+
import {
|
|
662
|
+
Configuration,
|
|
663
|
+
AuthApi,
|
|
664
|
+
} from '@knowledge-stack/ksapi';
|
|
665
|
+
import type { SignoutRequest } from '@knowledge-stack/ksapi';
|
|
666
|
+
|
|
667
|
+
async function example() {
|
|
668
|
+
console.log("🚀 Testing @knowledge-stack/ksapi SDK...");
|
|
669
|
+
const api = new AuthApi();
|
|
670
|
+
|
|
671
|
+
try {
|
|
672
|
+
const data = await api.signout();
|
|
673
|
+
console.log(data);
|
|
674
|
+
} catch (error) {
|
|
675
|
+
console.error(error);
|
|
676
|
+
}
|
|
677
|
+
}
|
|
678
|
+
|
|
679
|
+
// Run the test
|
|
680
|
+
example().catch(console.error);
|
|
681
|
+
```
|
|
682
|
+
|
|
683
|
+
### Parameters
|
|
684
|
+
|
|
685
|
+
This endpoint does not need any parameter.
|
|
686
|
+
|
|
687
|
+
### Return type
|
|
688
|
+
|
|
689
|
+
**any**
|
|
690
|
+
|
|
691
|
+
### Authorization
|
|
692
|
+
|
|
693
|
+
No authorization required
|
|
694
|
+
|
|
695
|
+
### HTTP request headers
|
|
696
|
+
|
|
697
|
+
- **Content-Type**: Not defined
|
|
698
|
+
- **Accept**: `application/json`
|
|
699
|
+
|
|
700
|
+
|
|
701
|
+
### HTTP response details
|
|
702
|
+
| Status code | Description | Response headers |
|
|
703
|
+
|-------------|-------------|------------------|
|
|
704
|
+
| **200** | Successful Response | - |
|
|
705
|
+
|
|
706
|
+
[[Back to top]](#) [[Back to API list]](../README.md#api-endpoints) [[Back to Model list]](../README.md#models) [[Back to README]](../README.md)
|
|
707
|
+
|