mftsccs-node 0.2.7 → 0.2.8
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/README.md +1148 -11
- package/dist/bundle.js +1 -1
- package/dist/types/Api/Create/CreateTheCharacter.d.ts +42 -0
- package/dist/types/Api/Create/CreateTheConceptApi.d.ts +50 -0
- package/dist/types/Api/Create/CreateTheConnectionApi.d.ts +51 -0
- package/dist/types/Api/Create/CreateTheTextData.d.ts +56 -0
- package/dist/types/Api/Delete/DeleteConceptInBackend.d.ts +43 -0
- package/dist/types/Api/DeleteConnectionApiBulk.d.ts +55 -0
- package/dist/types/Api/DeleteTheConcept.d.ts +64 -0
- package/dist/types/Api/DeleteTheConnection.d.ts +76 -0
- package/dist/types/Api/GetAiData.d.ts +36 -0
- package/dist/types/Api/GetAllConcepts.d.ts +42 -0
- package/dist/types/Api/GetAllConceptsByType.d.ts +45 -0
- package/dist/types/Api/GetAllConnections.d.ts +48 -0
- package/dist/types/Api/GetAllConnectionsOfComposition.d.ts +79 -0
- package/dist/types/Api/GetAllConnectionsOfCompositionBulk.d.ts +90 -0
- package/dist/types/Api/GetAllLinkerConnectionsFromTheConcept.d.ts +52 -0
- package/dist/types/Api/GetAllLinkerConnectionsToTheConcept.d.ts +61 -0
- package/dist/types/Api/GetAllPrefetchConnections.d.ts +51 -0
- package/dist/types/Api/GetCharacterDataByCharacter.d.ts +31 -0
- package/dist/types/Api/GetCompositionConnectionsBetweenTwoConcepts.d.ts +39 -0
- package/dist/types/Api/GetConcept.d.ts +47 -0
- package/dist/types/Api/GetConceptBulk.d.ts +68 -0
- package/dist/types/Api/GetConceptByCharacterAndType.d.ts +75 -0
- package/dist/types/Api/GetConceptByCharacterValue.d.ts +47 -0
- package/dist/types/Api/GetConnection.d.ts +49 -0
- package/dist/types/Api/GetConnectionBulk.d.ts +46 -0
- package/dist/types/Api/GetConnectionOfTheConcept.d.ts +50 -0
- package/dist/types/Api/GetConnectionToTheConcept.d.ts +56 -0
- package/dist/types/Api/GetReservedConnectionIds.d.ts +36 -0
- package/dist/types/Api/GetReservedIds.d.ts +37 -0
- package/dist/types/Api/Login.d.ts +38 -0
- package/dist/types/Api/MakeTheNameInBackend.d.ts +39 -0
- package/dist/types/Api/MakeTheTypeConceptApi.d.ts +40 -0
- package/dist/types/Api/RecursiveSearch.d.ts +43 -0
- package/dist/types/Api/Search/FreeschemaQueryApi.d.ts +46 -0
- package/dist/types/Api/Search/Search.d.ts +67 -0
- package/dist/types/Api/Search/SearchInternalApi.d.ts +69 -0
- package/dist/types/Api/Search/SearchLinkMultipleApi.d.ts +90 -0
- package/dist/types/Api/Search/SearchWithLinker.d.ts +97 -0
- package/dist/types/Api/SearchConcept/GetConceptByCharacterAndCategoryApi.d.ts +39 -0
- package/dist/types/Api/SearchConcept/GetConceptByCharacterAndCategoryDirect.d.ts +47 -0
- package/dist/types/Api/Session/CreateSession.d.ts +45 -0
- package/dist/types/Api/Session/CreateSessionVisit.d.ts +43 -0
- package/dist/types/Api/Signin.d.ts +48 -0
- package/dist/types/Api/Signup.d.ts +44 -0
- package/dist/types/Api/View/ViewInternalDataApi.d.ts +50 -0
- package/dist/types/Constants/ApiConstants.d.ts +226 -0
- package/dist/types/Constants/FormatConstants.d.ts +81 -0
- package/dist/types/DataStructures/BaseUrl.d.ts +210 -0
- package/dist/types/DataStructures/BinaryCharacterTree.d.ts +211 -0
- package/dist/types/DataStructures/BinaryTree.d.ts +139 -0
- package/dist/types/DataStructures/BinaryTypeTree.d.ts +196 -0
- package/dist/types/DataStructures/CharacterRepository.d.ts +109 -0
- package/dist/types/DataStructures/Composition/Composition.d.ts +103 -0
- package/dist/types/DataStructures/Composition/CompositionBinaryTree.d.ts +104 -0
- package/dist/types/DataStructures/Composition/CompositionNode.d.ts +202 -0
- package/dist/types/DataStructures/Concept.d.ts +110 -0
- package/dist/types/DataStructures/ConceptData.d.ts +292 -0
- package/dist/types/DataStructures/ConceptsToDraw.d.ts +168 -0
- package/dist/types/DataStructures/Connection.d.ts +76 -0
- package/dist/types/DataStructures/ConnectionBinaryTree/ConnectionBinaryTree.d.ts +115 -0
- package/dist/types/DataStructures/ConnectionBinaryTree/ConnectionNode.d.ts +169 -0
- package/dist/types/DataStructures/ConnectionBinaryTree/ConnectionTypeTree.d.ts +82 -0
- package/dist/types/DataStructures/ConnectionData.d.ts +191 -0
- package/dist/types/DataStructures/Count/CountInfo.d.ts +73 -0
- package/dist/types/DataStructures/FilterSearch.d.ts +84 -0
- package/dist/types/DataStructures/IdentifierFlags.d.ts +34 -0
- package/dist/types/DataStructures/Local/LConcept.d.ts +105 -0
- package/dist/types/DataStructures/Local/LConnection.d.ts +83 -0
- package/dist/types/DataStructures/Local/LNode.d.ts +190 -0
- package/dist/types/DataStructures/Local/LocalBinaryCharacterTree.d.ts +133 -0
- package/dist/types/DataStructures/Local/LocalBinaryTree.d.ts +135 -0
- package/dist/types/DataStructures/Local/LocalBinaryTypeTree.d.ts +147 -0
- package/dist/types/DataStructures/Local/LocalConceptData.d.ts +100 -0
- package/dist/types/DataStructures/Local/LocalConnectionData.d.ts +109 -0
- package/dist/types/DataStructures/Local/LocalSyncData.d.ts +89 -0
- package/dist/types/DataStructures/PatcherStructure.d.ts +86 -0
- package/dist/types/DataStructures/ReferentInfo.d.ts +68 -0
- package/dist/types/DataStructures/ReservedIds.d.ts +101 -0
- package/dist/types/DataStructures/Responses/ErrorResponse.d.ts +184 -22
- package/dist/types/DataStructures/Responses/StandardResponses.d.ts +65 -0
- package/dist/types/DataStructures/Returner.d.ts +59 -0
- package/dist/types/DataStructures/Search/FreeschemaQuery.d.ts +165 -0
- package/dist/types/DataStructures/Search/SearchStructure.d.ts +69 -0
- package/dist/types/DataStructures/SearchQuery.d.ts +130 -0
- package/dist/types/DataStructures/Security/TokenStorage.d.ts +48 -0
- package/dist/types/DataStructures/Session/SessionData.d.ts +118 -0
- package/dist/types/DataStructures/SettingData.d.ts +32 -0
- package/dist/types/DataStructures/Settings.d.ts +27 -0
- package/dist/types/DataStructures/SigninModel.d.ts +50 -0
- package/dist/types/DataStructures/SignupModel.d.ts +50 -0
- package/dist/types/DataStructures/SyncData.d.ts +206 -0
- package/dist/types/DataStructures/TheCharacter.d.ts +87 -0
- package/dist/types/DataStructures/TheTexts.d.ts +92 -0
- package/dist/types/DataStructures/Transaction/Transaction.d.ts +294 -4
- package/dist/types/DataStructures/User/UserBinaryTree.d.ts +117 -0
- package/dist/types/DataStructures/User/UserNode.d.ts +130 -0
- package/dist/types/Database/GetConceptFromIndexDb.d.ts +9 -0
- package/dist/types/Database/NoIndexDb.d.ts +169 -0
- package/dist/types/Database/indexdblocal.d.ts +42 -0
- package/dist/types/Database/indexeddb.d.ts +43 -0
- package/dist/types/Drawing/ConceptDraw.d.ts +28 -0
- package/dist/types/Drawing/ConceptEvents.d.ts +46 -0
- package/dist/types/Helpers/CheckIfExists.d.ts +159 -0
- package/dist/types/Helpers/RemoveFromArray.d.ts +66 -0
- package/dist/types/Helpers/UniqueInsert.d.ts +28 -0
- package/dist/types/Services/CheckForConnectionDeletion.d.ts +190 -0
- package/dist/types/Services/Common/DecodeCountInfo.d.ts +54 -0
- package/dist/types/Services/Common/ErrorPosting.d.ts +49 -0
- package/dist/types/Services/Common/RegexFunction.d.ts +28 -0
- package/dist/types/Services/Composition/BuildComposition.d.ts +37 -0
- package/dist/types/Services/Composition/CompositionCache.d.ts +89 -0
- package/dist/types/Services/Composition/CreateCompositionCache.d.ts +43 -0
- package/dist/types/Services/Conversion/ConvertConcepts.d.ts +83 -0
- package/dist/types/Services/CreateBinaryTreeFromData.d.ts +38 -0
- package/dist/types/Services/CreateCharacterBinaryTreeFromData.d.ts +42 -0
- package/dist/types/Services/CreateConnectionBetweenTwoConcepts.d.ts +206 -0
- package/dist/types/Services/CreateDefaultConcept.d.ts +114 -0
- package/dist/types/Services/CreateTheComposition.d.ts +101 -0
- package/dist/types/Services/CreateTheConcept.d.ts +179 -0
- package/dist/types/Services/CreateTheConnection.d.ts +59 -0
- package/dist/types/Services/CreateTheConnectionGeneral.d.ts +127 -0
- package/dist/types/Services/CreateTypeTreeFromData.d.ts +43 -0
- package/dist/types/Services/Delete/DeleteConnectionByType.d.ts +52 -5
- package/dist/types/Services/Delete/GetAllConnectionByType.d.ts +57 -9
- package/dist/types/Services/DeleteConcept.d.ts +136 -0
- package/dist/types/Services/DeleteConnection.d.ts +194 -0
- package/dist/types/Services/FindConeceptsFromConnection.d.ts +179 -0
- package/dist/types/Services/FindConnectionsOfCompositionBulkInMemory.d.ts +157 -0
- package/dist/types/Services/GenerateHexNumber.d.ts +64 -0
- package/dist/types/Services/GetComposition.d.ts +331 -0
- package/dist/types/Services/GetCompositionBulk.d.ts +251 -3
- package/dist/types/Services/GetCompositionList.d.ts +130 -0
- package/dist/types/Services/GetConceptByCharacter.d.ts +84 -0
- package/dist/types/Services/GetConnections.d.ts +72 -0
- package/dist/types/Services/GetDataFromIndexDb.d.ts +79 -0
- package/dist/types/Services/GetLink.d.ts +104 -0
- package/dist/types/Services/GetLinkerConnectionFromConcept.d.ts +99 -0
- package/dist/types/Services/GetMaximumConnectionSyncTime.d.ts +57 -0
- package/dist/types/Services/GetRelation.d.ts +162 -0
- package/dist/types/Services/GetTheConcept.d.ts +71 -0
- package/dist/types/Services/GetTheReferent.d.ts +74 -0
- package/dist/types/Services/InitializeSystem.d.ts +119 -0
- package/dist/types/Services/Local/CreateDefaultLConcept.d.ts +48 -0
- package/dist/types/Services/Local/CreateLocalBinaryTreeFromData.d.ts +49 -0
- package/dist/types/Services/Local/CreateLocalBinaryTypeTreeFromData.d.ts +54 -0
- package/dist/types/Services/Local/CreateLocalCharacterBinaryTree.d.ts +60 -0
- package/dist/types/Services/Local/CreateTheCompositionLocal.d.ts +70 -0
- package/dist/types/Services/Local/CreateTheConceptLocal.d.ts +58 -0
- package/dist/types/Services/Local/CreateTheConnectionLocal.d.ts +56 -0
- package/dist/types/Services/Local/GetCompositionListLocal.d.ts +103 -0
- package/dist/types/Services/Local/GetCompositionLocal.d.ts +96 -0
- package/dist/types/Services/Local/GetConceptByCharacterLocal.d.ts +57 -0
- package/dist/types/Services/Local/MakeTheConceptLocal.d.ts +71 -0
- package/dist/types/Services/Local/MakeTheInstanceConceptLocal.d.ts +89 -0
- package/dist/types/Services/Local/MakeTheTypeLocal.d.ts +71 -0
- package/dist/types/Services/Local/UpdateCompositionLocal.d.ts +101 -0
- package/dist/types/Services/MakeTheCharacter.d.ts +74 -0
- package/dist/types/Services/MakeTheCharacterData.d.ts +65 -0
- package/dist/types/Services/MakeTheInstanceConcept.d.ts +75 -0
- package/dist/types/Services/MakeTheName.d.ts +81 -0
- package/dist/types/Services/MakeTheTimestamp.d.ts +68 -0
- package/dist/types/Services/MakeTheTypeConcept.d.ts +68 -0
- package/dist/types/Services/Mqtt/publishMessage.d.ts +27 -0
- package/dist/types/Services/Mqtt/subscribeMessage.d.ts +23 -0
- package/dist/types/Services/PatchComposition.d.ts +105 -0
- package/dist/types/Services/Search/DataIdFormat.d.ts +96 -24
- package/dist/types/Services/Search/FormatData.d.ts +92 -17
- package/dist/types/Services/Search/JustIdFormat.d.ts +91 -16
- package/dist/types/Services/Search/NewFormat.d.ts +4 -0
- package/dist/types/Services/Search/SearchLinkInternal.d.ts +28 -0
- package/dist/types/Services/Search/SearchLinkMultiple.d.ts +58 -0
- package/dist/types/Services/Search/SearchWithTypeAndLinker.d.ts +92 -24
- package/dist/types/Services/Search/orderingConnections.d.ts +34 -0
- package/dist/types/Services/SplitStrings.d.ts +50 -0
- package/dist/types/Services/UpdateComposition.d.ts +123 -0
- package/dist/types/Services/User/UserTranslation.d.ts +102 -0
- package/dist/types/Services/View/ViewInternalData.d.ts +32 -0
- package/dist/types/WrapperFunctions/SchemaQueryObservable.d.ts +140 -5
- package/dist/types/app.d.ts +72 -1
- package/package.json +1 -1
|
@@ -1,23 +1,249 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* API Constants Module for Concept Connection System (CCS-JS)
|
|
3
|
+
*
|
|
4
|
+
* This module defines all API endpoint URLs and configuration for interacting with the FreeSchema backend.
|
|
5
|
+
* It provides centralized URL management and allows dynamic base URL configuration for different environments.
|
|
6
|
+
*
|
|
7
|
+
* @module Constants/ApiConstants
|
|
8
|
+
* @see https://documentation.freeschema.com for API reference
|
|
9
|
+
*/
|
|
10
|
+
/**
|
|
11
|
+
* Default configuration object for the API base URL.
|
|
12
|
+
* Points to the development environment of FreeSchema.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```typescript
|
|
16
|
+
* console.log(config.BASE_URL); // "https://devboom.freeschema.com"
|
|
17
|
+
* ```
|
|
18
|
+
*/
|
|
1
19
|
export declare const config: {
|
|
2
20
|
BASE_URL: string;
|
|
3
21
|
};
|
|
22
|
+
/**
|
|
23
|
+
* The current base URL for all API requests.
|
|
24
|
+
* This value is dynamically retrieved and can be changed using `changeBaseUrl()`.
|
|
25
|
+
*
|
|
26
|
+
* @see {@link getBaseUrl}
|
|
27
|
+
* @see {@link changeBaseUrl}
|
|
28
|
+
*/
|
|
4
29
|
export declare const BASE_URL: string;
|
|
30
|
+
/**
|
|
31
|
+
* API endpoint URL for retrieving a single concept by ID.
|
|
32
|
+
*
|
|
33
|
+
* @example
|
|
34
|
+
* ```typescript
|
|
35
|
+
* const response = await fetch(`${GetConceptUrl}?id=123`);
|
|
36
|
+
* ```
|
|
37
|
+
*
|
|
38
|
+
* @see https://documentation.freeschema.com for API documentation
|
|
39
|
+
*/
|
|
5
40
|
export declare const GetConceptUrl: string;
|
|
41
|
+
/**
|
|
42
|
+
* API endpoint URL for retrieving multiple concepts in bulk.
|
|
43
|
+
*
|
|
44
|
+
* @example
|
|
45
|
+
* ```typescript
|
|
46
|
+
* const response = await fetch(GetConceptBulkUrl, {
|
|
47
|
+
* method: 'POST',
|
|
48
|
+
* body: JSON.stringify({ ids: [1, 2, 3] })
|
|
49
|
+
* });
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
6
52
|
export declare const GetConceptBulkUrl: string;
|
|
53
|
+
/**
|
|
54
|
+
* API endpoint URL for retrieving all concepts belonging to a specific user.
|
|
55
|
+
*
|
|
56
|
+
* @example
|
|
57
|
+
* ```typescript
|
|
58
|
+
* const response = await fetch(`${GetAllConceptsOfUserUrl}?userId=456`);
|
|
59
|
+
* ```
|
|
60
|
+
*/
|
|
7
61
|
export declare const GetAllConceptsOfUserUrl: string;
|
|
62
|
+
/**
|
|
63
|
+
* API endpoint URL for retrieving all connections belonging to a specific user.
|
|
64
|
+
*
|
|
65
|
+
* @example
|
|
66
|
+
* ```typescript
|
|
67
|
+
* const response = await fetch(`${GetAllConnectionsOfUserUrl}?userId=456`);
|
|
68
|
+
* ```
|
|
69
|
+
*/
|
|
8
70
|
export declare const GetAllConnectionsOfUserUrl: string;
|
|
71
|
+
/**
|
|
72
|
+
* API endpoint URL for retrieving all connections within a composition.
|
|
73
|
+
* A composition is a grouping of related concepts and their connections.
|
|
74
|
+
*
|
|
75
|
+
* @example
|
|
76
|
+
* ```typescript
|
|
77
|
+
* const response = await fetch(`${GetAllConnectionsOfCompositionUrl}?compositionId=789`);
|
|
78
|
+
* ```
|
|
79
|
+
*/
|
|
9
80
|
export declare const GetAllConnectionsOfCompositionUrl: string;
|
|
81
|
+
/**
|
|
82
|
+
* API endpoint URL for retrieving connections of multiple compositions in bulk.
|
|
83
|
+
*
|
|
84
|
+
* @example
|
|
85
|
+
* ```typescript
|
|
86
|
+
* const response = await fetch(GetAllConnectionsOfCompositionBulkUrl, {
|
|
87
|
+
* method: 'POST',
|
|
88
|
+
* body: JSON.stringify({ compositionIds: [1, 2, 3] })
|
|
89
|
+
* });
|
|
90
|
+
* ```
|
|
91
|
+
*/
|
|
10
92
|
export declare const GetAllConnectionsOfCompositionBulkUrl: string;
|
|
93
|
+
/**
|
|
94
|
+
* API endpoint URL for retrieving a concept by its character value.
|
|
95
|
+
* Character value is the string representation/label of a concept.
|
|
96
|
+
*
|
|
97
|
+
* @example
|
|
98
|
+
* ```typescript
|
|
99
|
+
* const response = await fetch(`${GetConceptByCharacterValueUrl}?value=hello`);
|
|
100
|
+
* ```
|
|
101
|
+
*/
|
|
11
102
|
export declare const GetConceptByCharacterValueUrl: string;
|
|
103
|
+
/**
|
|
104
|
+
* API endpoint URL for retrieving a concept by both its character value and type.
|
|
105
|
+
* This provides more specific filtering when multiple concepts share the same character value.
|
|
106
|
+
*
|
|
107
|
+
* @example
|
|
108
|
+
* ```typescript
|
|
109
|
+
* const response = await fetch(`${GetConceptByCharacterAndTypeUrl}?value=hello&typeId=5`);
|
|
110
|
+
* ```
|
|
111
|
+
*/
|
|
12
112
|
export declare const GetConceptByCharacterAndTypeUrl: string;
|
|
113
|
+
/**
|
|
114
|
+
* API endpoint URL for retrieving character data by character string.
|
|
115
|
+
*
|
|
116
|
+
* @example
|
|
117
|
+
* ```typescript
|
|
118
|
+
* const response = await fetch(`${GetCharacterByCharacterUrl}?character=A`);
|
|
119
|
+
* ```
|
|
120
|
+
*/
|
|
13
121
|
export declare const GetCharacterByCharacterUrl: string;
|
|
122
|
+
/**
|
|
123
|
+
* API endpoint URL for retrieving all concepts of a specific type.
|
|
124
|
+
*
|
|
125
|
+
* @example
|
|
126
|
+
* ```typescript
|
|
127
|
+
* const response = await fetch(`${GetAllConceptsByTypeUrl}?typeId=10`);
|
|
128
|
+
* ```
|
|
129
|
+
*/
|
|
14
130
|
export declare const GetAllConceptsByTypeUrl: string;
|
|
131
|
+
/**
|
|
132
|
+
* API endpoint URL for retrieving all connections associated with a specific concept.
|
|
133
|
+
* This includes both incoming and outgoing connections.
|
|
134
|
+
*
|
|
135
|
+
* @example
|
|
136
|
+
* ```typescript
|
|
137
|
+
* const response = await fetch(`${GetAllConnectionsOfConceptUrl}?conceptId=123`);
|
|
138
|
+
* ```
|
|
139
|
+
*/
|
|
15
140
|
export declare const GetAllConnectionsOfConceptUrl: string;
|
|
141
|
+
/**
|
|
142
|
+
* API endpoint URL for retrieving AI-ranked data.
|
|
143
|
+
* Can be overridden via the AI_URL environment variable.
|
|
144
|
+
*
|
|
145
|
+
* @remarks
|
|
146
|
+
* The default query parameter `inpage=500` limits the number of results returned.
|
|
147
|
+
*
|
|
148
|
+
* @example
|
|
149
|
+
* ```typescript
|
|
150
|
+
* const response = await fetch(GetAllAiData);
|
|
151
|
+
* ```
|
|
152
|
+
*/
|
|
16
153
|
export declare const GetAllAiData: string;
|
|
154
|
+
/**
|
|
155
|
+
* API endpoint URL for retrieving reserved IDs from the system.
|
|
156
|
+
* Reserved IDs are pre-allocated concept IDs used for system-level concepts.
|
|
157
|
+
*
|
|
158
|
+
* @example
|
|
159
|
+
* ```typescript
|
|
160
|
+
* const response = await fetch(GetReservedIdUrl);
|
|
161
|
+
* ```
|
|
162
|
+
*
|
|
163
|
+
* @see https://documentation.freeschema.com for information about reserved IDs
|
|
164
|
+
*/
|
|
17
165
|
export declare const GetReservedIdUrl: string;
|
|
166
|
+
/**
|
|
167
|
+
* API endpoint URL for creating text data in the system.
|
|
168
|
+
*
|
|
169
|
+
* @example
|
|
170
|
+
* ```typescript
|
|
171
|
+
* const response = await fetch(CreateTheTextDataUrl, {
|
|
172
|
+
* method: 'POST',
|
|
173
|
+
* body: JSON.stringify({ text: 'Hello World' })
|
|
174
|
+
* });
|
|
175
|
+
* ```
|
|
176
|
+
*/
|
|
18
177
|
export declare const CreateTheTextDataUrl: string;
|
|
178
|
+
/**
|
|
179
|
+
* API endpoint URL for creating character data in the system.
|
|
180
|
+
*
|
|
181
|
+
* @example
|
|
182
|
+
* ```typescript
|
|
183
|
+
* const response = await fetch(CreateTheCharacterDataUrl, {
|
|
184
|
+
* method: 'POST',
|
|
185
|
+
* body: JSON.stringify({ character: 'A' })
|
|
186
|
+
* });
|
|
187
|
+
* ```
|
|
188
|
+
*/
|
|
19
189
|
export declare const CreateTheCharacterDataUrl: string;
|
|
190
|
+
/**
|
|
191
|
+
* API endpoint URL for creating a new concept in the system.
|
|
192
|
+
*
|
|
193
|
+
* @example
|
|
194
|
+
* ```typescript
|
|
195
|
+
* const response = await fetch(CreateTheConceptUrl, {
|
|
196
|
+
* method: 'POST',
|
|
197
|
+
* body: JSON.stringify({
|
|
198
|
+
* characterValue: 'example',
|
|
199
|
+
* typeId: 5,
|
|
200
|
+
* userId: 123
|
|
201
|
+
* })
|
|
202
|
+
* });
|
|
203
|
+
* ```
|
|
204
|
+
*/
|
|
20
205
|
export declare const CreateTheConceptUrl: string;
|
|
206
|
+
/**
|
|
207
|
+
* API endpoint URL for creating a new connection between concepts.
|
|
208
|
+
*
|
|
209
|
+
* @example
|
|
210
|
+
* ```typescript
|
|
211
|
+
* const response = await fetch(CreateTheConnectionUrl, {
|
|
212
|
+
* method: 'POST',
|
|
213
|
+
* body: JSON.stringify({
|
|
214
|
+
* ofTheConceptId: 1,
|
|
215
|
+
* toTheConceptId: 2,
|
|
216
|
+
* typeId: 3
|
|
217
|
+
* })
|
|
218
|
+
* });
|
|
219
|
+
* ```
|
|
220
|
+
*/
|
|
21
221
|
export declare const CreateTheConnectionUrl: string;
|
|
222
|
+
/**
|
|
223
|
+
* Changes the base URL for all API endpoints.
|
|
224
|
+
* This is useful for switching between development, staging, and production environments.
|
|
225
|
+
*
|
|
226
|
+
* @param url - The new base URL to use for API requests
|
|
227
|
+
*
|
|
228
|
+
* @example
|
|
229
|
+
* ```typescript
|
|
230
|
+
* changeBaseUrl('https://production.freeschema.com');
|
|
231
|
+
* ```
|
|
232
|
+
*
|
|
233
|
+
* @remarks
|
|
234
|
+
* This function modifies the global BaseUrl object, affecting all subsequent API calls.
|
|
235
|
+
* Make sure to call this before making any API requests if you need a custom URL.
|
|
236
|
+
*/
|
|
22
237
|
export declare function changeBaseUrl(url: string): void;
|
|
238
|
+
/**
|
|
239
|
+
* Retrieves the current base URL being used for API requests.
|
|
240
|
+
*
|
|
241
|
+
* @returns The current base URL string
|
|
242
|
+
*
|
|
243
|
+
* @example
|
|
244
|
+
* ```typescript
|
|
245
|
+
* const currentUrl = getBaseUrl();
|
|
246
|
+
* console.log(currentUrl); // "https://devboom.freeschema.com"
|
|
247
|
+
* ```
|
|
248
|
+
*/
|
|
23
249
|
export declare function getBaseUrl(): string;
|
|
@@ -1,7 +1,88 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Format Constants Module for Concept Connection System (CCS-JS)
|
|
3
|
+
*
|
|
4
|
+
* This module defines constants for different data format types used throughout the system.
|
|
5
|
+
* These format types determine how data structures (concepts, connections, etc.) are serialized
|
|
6
|
+
* and presented when retrieved from the API or displayed in the application.
|
|
7
|
+
*
|
|
8
|
+
* @module Constants/FormatConstants
|
|
9
|
+
* @see https://documentation.freeschema.com for format specifications
|
|
10
|
+
*/
|
|
11
|
+
/**
|
|
12
|
+
* Standard normal format for data representation.
|
|
13
|
+
* This format includes essential data fields without additional metadata.
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```typescript
|
|
17
|
+
* import { NORMAL } from './FormatConstants';
|
|
18
|
+
* const format = NORMAL; // 1
|
|
19
|
+
* ```
|
|
20
|
+
*/
|
|
1
21
|
export declare const NORMAL = 1;
|
|
22
|
+
/**
|
|
23
|
+
* Data with ID format.
|
|
24
|
+
* This format includes the data along with its unique identifier.
|
|
25
|
+
*
|
|
26
|
+
* @example
|
|
27
|
+
* ```typescript
|
|
28
|
+
* import { DATAID } from './FormatConstants';
|
|
29
|
+
* const format = DATAID; // 2
|
|
30
|
+
* ```
|
|
31
|
+
*/
|
|
2
32
|
export declare const DATAID = 2;
|
|
33
|
+
/**
|
|
34
|
+
* Just data format without any metadata.
|
|
35
|
+
* This format returns only the core data fields, excluding IDs and timestamps.
|
|
36
|
+
*
|
|
37
|
+
* @example
|
|
38
|
+
* ```typescript
|
|
39
|
+
* import { JUSTDATA } from './FormatConstants';
|
|
40
|
+
* const format = JUSTDATA; // 3
|
|
41
|
+
* ```
|
|
42
|
+
*/
|
|
3
43
|
export declare const JUSTDATA = 3;
|
|
44
|
+
/**
|
|
45
|
+
* Data with ID and date format.
|
|
46
|
+
* This format includes the data, its ID, and associated timestamp information.
|
|
47
|
+
*
|
|
48
|
+
* @example
|
|
49
|
+
* ```typescript
|
|
50
|
+
* import { DATAIDDATE } from './FormatConstants';
|
|
51
|
+
* const format = DATAIDDATE; // 4
|
|
52
|
+
* ```
|
|
53
|
+
*/
|
|
4
54
|
export declare const DATAIDDATE = 4;
|
|
55
|
+
/**
|
|
56
|
+
* Raw data format.
|
|
57
|
+
* This format returns data in its raw form as stored in the database without any processing.
|
|
58
|
+
*
|
|
59
|
+
* @example
|
|
60
|
+
* ```typescript
|
|
61
|
+
* import { RAW } from './FormatConstants';
|
|
62
|
+
* const format = RAW; // 5
|
|
63
|
+
* ```
|
|
64
|
+
*/
|
|
5
65
|
export declare const RAW = 5;
|
|
66
|
+
/**
|
|
67
|
+
* All IDs format.
|
|
68
|
+
* This format includes all related IDs (concept IDs, type IDs, user IDs, etc.).
|
|
69
|
+
*
|
|
70
|
+
* @example
|
|
71
|
+
* ```typescript
|
|
72
|
+
* import { ALLID } from './FormatConstants';
|
|
73
|
+
* const format = ALLID; // 6
|
|
74
|
+
* ```
|
|
75
|
+
*/
|
|
6
76
|
export declare const ALLID = 6;
|
|
77
|
+
/**
|
|
78
|
+
* List normal format.
|
|
79
|
+
* This format is used for representing lists or arrays of data in standard format.
|
|
80
|
+
*
|
|
81
|
+
* @example
|
|
82
|
+
* ```typescript
|
|
83
|
+
* import { LISTNORMAL } from './FormatConstants';
|
|
84
|
+
* const format = LISTNORMAL; // 7
|
|
85
|
+
* ```
|
|
86
|
+
*/
|
|
7
87
|
export declare const LISTNORMAL = 7;
|
|
88
|
+
export declare const DATAV2 = 8;
|
|
@@ -1,52 +1,262 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @fileoverview BaseUrl module for managing API endpoints and service URLs in CCS-JS.
|
|
3
|
+
* This module provides centralized configuration for all backend API endpoints,
|
|
4
|
+
* MQTT connections, and external services.
|
|
5
|
+
* @module DataStructures/BaseUrl
|
|
6
|
+
*/
|
|
7
|
+
/**
|
|
8
|
+
* Centralized configuration for all backend API endpoints and service URLs.
|
|
9
|
+
* Provides methods to generate fully qualified URLs for various API operations.
|
|
10
|
+
*
|
|
11
|
+
* @class BaseUrl
|
|
12
|
+
* @example
|
|
13
|
+
* ```typescript
|
|
14
|
+
* // Get concept API URL
|
|
15
|
+
* const url = BaseUrl.GetConceptUrl();
|
|
16
|
+
* fetch(url, { ... });
|
|
17
|
+
*
|
|
18
|
+
* // Change base URL for different environment
|
|
19
|
+
* BaseUrl.BASE_URL = "https://api.production.com/";
|
|
20
|
+
* ```
|
|
21
|
+
*
|
|
22
|
+
* @remarks
|
|
23
|
+
* All URL methods return fully qualified URLs by combining BASE_URL with the endpoint path.
|
|
24
|
+
* Static properties can be modified to point to different environments or services.
|
|
25
|
+
*/
|
|
1
26
|
export declare class BaseUrl {
|
|
27
|
+
/** Base URL for the main CCS backend API server */
|
|
2
28
|
static BASE_URL: string;
|
|
29
|
+
/** URL for AI service endpoints */
|
|
3
30
|
static AI_URL: string;
|
|
31
|
+
/** MQTT broker URL for real-time messaging */
|
|
4
32
|
static MQTT_URL: string;
|
|
33
|
+
/** Node.js service URL for additional backend operations */
|
|
5
34
|
static NODE_URL: string;
|
|
35
|
+
/** Active MQTT connection instance */
|
|
6
36
|
static MQTT_CONNECTION: any;
|
|
37
|
+
/**
|
|
38
|
+
* Returns the URL for retrieving a single concept by ID.
|
|
39
|
+
* @returns {string} The concept retrieval API endpoint
|
|
40
|
+
*/
|
|
7
41
|
static GetConceptUrl(): string;
|
|
42
|
+
/**
|
|
43
|
+
* Returns the URL for retrieving a single connection by ID.
|
|
44
|
+
* @returns {string} The connection retrieval API endpoint
|
|
45
|
+
*/
|
|
8
46
|
static GetConnectionUrl(): string;
|
|
47
|
+
/**
|
|
48
|
+
* Returns the URL for retrieving multiple concepts in bulk.
|
|
49
|
+
* @returns {string} The bulk concept retrieval API endpoint
|
|
50
|
+
*/
|
|
9
51
|
static GetConceptBulkUrl(): string;
|
|
52
|
+
/**
|
|
53
|
+
* Returns the URL for retrieving multiple connections in bulk.
|
|
54
|
+
* @returns {string} The bulk connection retrieval API endpoint
|
|
55
|
+
*/
|
|
10
56
|
static GetConnectionBulkUrl(): string;
|
|
57
|
+
/**
|
|
58
|
+
* Returns the URL for retrieving all concepts belonging to a user.
|
|
59
|
+
* @returns {string} The user concepts retrieval API endpoint
|
|
60
|
+
*/
|
|
11
61
|
static GetAllConceptsOfUserUrl(): string;
|
|
62
|
+
/**
|
|
63
|
+
* Returns the URL for retrieving all connections belonging to a user.
|
|
64
|
+
* @returns {string} The user connections retrieval API endpoint
|
|
65
|
+
*/
|
|
12
66
|
static GetAllConnectionsOfUserUrl(): string;
|
|
67
|
+
/**
|
|
68
|
+
* Returns the URL for retrieving all connections of a composition.
|
|
69
|
+
* @returns {string} The composition connections retrieval API endpoint
|
|
70
|
+
*/
|
|
13
71
|
static GetAllConnectionsOfCompositionUrl(): string;
|
|
72
|
+
/**
|
|
73
|
+
* Returns the URL for retrieving composition connections in bulk.
|
|
74
|
+
* @returns {string} The bulk composition connections retrieval API endpoint
|
|
75
|
+
*/
|
|
14
76
|
static GetAllConnectionsOfCompositionBulkUrl(): string;
|
|
77
|
+
/**
|
|
78
|
+
* Returns the URL for retrieving a concept by its character value.
|
|
79
|
+
* @returns {string} The character value search API endpoint
|
|
80
|
+
*/
|
|
15
81
|
static GetConceptByCharacterValueUrl(): string;
|
|
82
|
+
/**
|
|
83
|
+
* Returns the URL for retrieving a concept by both character value and type.
|
|
84
|
+
* @returns {string} The character and type search API endpoint
|
|
85
|
+
*/
|
|
16
86
|
static GetConceptByCharacterAndTypeUrl(): string;
|
|
87
|
+
/**
|
|
88
|
+
* Returns the URL for retrieving a concept by character value and category.
|
|
89
|
+
* @returns {string} The character and category search API endpoint
|
|
90
|
+
*/
|
|
17
91
|
static GetConceptByCharacterAndCategoryUrl(): string;
|
|
92
|
+
/**
|
|
93
|
+
* Returns the URL for direct retrieval by character and category.
|
|
94
|
+
* @returns {string} The direct character and category search API endpoint
|
|
95
|
+
*/
|
|
18
96
|
static GetConceptByCharacterAndCategoryDirectUrl(): string;
|
|
97
|
+
/**
|
|
98
|
+
* Returns the URL for retrieving character information by character value.
|
|
99
|
+
* @returns {string} The character search API endpoint
|
|
100
|
+
*/
|
|
19
101
|
static GetCharacterByCharacterUrl(): string;
|
|
102
|
+
/**
|
|
103
|
+
* Returns the URL for retrieving all concepts of a specific type.
|
|
104
|
+
* @returns {string} The type-based concept search API endpoint
|
|
105
|
+
*/
|
|
20
106
|
static GetAllConceptsByTypeUrl(): string;
|
|
107
|
+
/**
|
|
108
|
+
* Returns the URL for retrieving all outgoing connections from a concept.
|
|
109
|
+
* @returns {string} The concept outgoing connections API endpoint
|
|
110
|
+
*/
|
|
21
111
|
static GetAllConnectionsOfConceptUrl(): string;
|
|
112
|
+
/**
|
|
113
|
+
* Returns the URL for retrieving all incoming connections to a concept.
|
|
114
|
+
* @returns {string} The concept incoming connections API endpoint
|
|
115
|
+
*/
|
|
22
116
|
static GetAllConnectionsToConceptUrl(): string;
|
|
117
|
+
/**
|
|
118
|
+
* Returns the URL for retrieving AI-preloaded concept data.
|
|
119
|
+
* @returns {string} The AI preloaded concepts API endpoint
|
|
120
|
+
*/
|
|
23
121
|
static GetAllAiData(): string;
|
|
122
|
+
/**
|
|
123
|
+
* Returns the URL for prefetching user connections with pagination.
|
|
124
|
+
* @returns {string} The prefetch connections API endpoint with inpage parameter
|
|
125
|
+
*/
|
|
24
126
|
static GetAllPrefetchConnectionsUrl(): string;
|
|
127
|
+
/**
|
|
128
|
+
* Returns the URL for retrieving all linker connections from a concept.
|
|
129
|
+
* @returns {string} The concept linkers API endpoint
|
|
130
|
+
*/
|
|
25
131
|
static GetAllLinkerConnectionOfConceptUrl(): string;
|
|
132
|
+
/**
|
|
133
|
+
* Returns the URL for retrieving all linker connections to a concept.
|
|
134
|
+
* @returns {string} The reverse concept linkers API endpoint
|
|
135
|
+
*/
|
|
26
136
|
static GetAllLinkerConnectionToConceptUrl(): string;
|
|
137
|
+
/**
|
|
138
|
+
* Returns the URL for deleting a concept.
|
|
139
|
+
* @returns {string} The concept deletion API endpoint
|
|
140
|
+
*/
|
|
27
141
|
static DeleteConceptUrl(): string;
|
|
142
|
+
/**
|
|
143
|
+
* Returns the URL for recursive search of concepts and connections.
|
|
144
|
+
* @returns {string} The recursive search API endpoint
|
|
145
|
+
*/
|
|
28
146
|
static RecursiveSearchUrl(): string;
|
|
147
|
+
/**
|
|
148
|
+
* Returns the URL for searching multiple links in CCS format.
|
|
149
|
+
* @returns {string} The multiple link search API endpoint
|
|
150
|
+
*/
|
|
29
151
|
static SearchLinkMultipleAllApiUrl(): string;
|
|
152
|
+
/**
|
|
153
|
+
* Returns the URL for creating names in the backend.
|
|
154
|
+
* @returns {string} The name creation API endpoint
|
|
155
|
+
*/
|
|
30
156
|
static MakeTheNameInBackendUrl(): string;
|
|
157
|
+
/**
|
|
158
|
+
* Returns the URL for user login authentication.
|
|
159
|
+
* @returns {string} The login API endpoint
|
|
160
|
+
*/
|
|
31
161
|
static LoginUrl(): string;
|
|
162
|
+
/**
|
|
163
|
+
* Returns the URL for user signup/registration.
|
|
164
|
+
* @returns {string} The signup API endpoint
|
|
165
|
+
*/
|
|
32
166
|
static SignupUrl(): string;
|
|
167
|
+
/**
|
|
168
|
+
* Returns the URL for getting composition connections between two concepts.
|
|
169
|
+
* @returns {string} The composition connection API endpoint
|
|
170
|
+
*/
|
|
33
171
|
static GetCompositionConnectionBetweenTwoConceptsUrl(): string;
|
|
172
|
+
/**
|
|
173
|
+
* Returns the URL for searching compositions.
|
|
174
|
+
* @returns {string} The composition search API endpoint
|
|
175
|
+
*/
|
|
34
176
|
static SearchCompositionsUrl(): string;
|
|
177
|
+
/**
|
|
178
|
+
* Returns the URL for searching multiple links.
|
|
179
|
+
* @returns {string} The multiple link search API endpoint
|
|
180
|
+
*/
|
|
35
181
|
static SearchLinkMultipleAll(): string;
|
|
182
|
+
/**
|
|
183
|
+
* Returns the URL for creating remote session IDs.
|
|
184
|
+
* @returns {string} The session ID creation API endpoint
|
|
185
|
+
*/
|
|
36
186
|
static CreateSessionId(): string;
|
|
187
|
+
/**
|
|
188
|
+
* Returns the URL for recording remote session visits.
|
|
189
|
+
* @returns {string} The session visit recording API endpoint
|
|
190
|
+
*/
|
|
37
191
|
static CreateSessionVisitUrl(): string;
|
|
192
|
+
/**
|
|
193
|
+
* Returns the URL for viewing internal CCS data in bulk.
|
|
194
|
+
* @returns {string} The internal data viewing API endpoint
|
|
195
|
+
*/
|
|
38
196
|
static ViewInternalDataUrl(): string;
|
|
197
|
+
/**
|
|
198
|
+
* Returns the URL for searching internal authenticated CCS compositions.
|
|
199
|
+
* @returns {string} The authenticated internal search API endpoint
|
|
200
|
+
*/
|
|
39
201
|
static SearchInternalWithAuthenticatedCcsUrl(): string;
|
|
202
|
+
/**
|
|
203
|
+
* Returns the URL for retrieving reserved concept IDs.
|
|
204
|
+
* @returns {string} The reserved IDs API endpoint
|
|
205
|
+
*/
|
|
40
206
|
static GetReservedIdUrl(): string;
|
|
207
|
+
/**
|
|
208
|
+
* Returns the URL for retrieving reserved connection IDs.
|
|
209
|
+
* @returns {string} The reserved connection IDs API endpoint
|
|
210
|
+
*/
|
|
41
211
|
static GetReservedConnectionIdUrl(): string;
|
|
212
|
+
/**
|
|
213
|
+
* Returns the URL for creating text data.
|
|
214
|
+
* @returns {string} The text data creation API endpoint
|
|
215
|
+
*/
|
|
42
216
|
static CreateTheTextDataUrl(): string;
|
|
217
|
+
/**
|
|
218
|
+
* Returns the URL for creating character data.
|
|
219
|
+
* @returns {string} The character data creation API endpoint
|
|
220
|
+
*/
|
|
43
221
|
static CreateTheCharacterDataUrl(): string;
|
|
222
|
+
/**
|
|
223
|
+
* Returns the URL for creating concepts.
|
|
224
|
+
* @returns {string} The concept creation API endpoint
|
|
225
|
+
*/
|
|
44
226
|
static CreateTheConceptUrl(): string;
|
|
227
|
+
/**
|
|
228
|
+
* Returns the URL for creating connections.
|
|
229
|
+
* @returns {string} The connection creation API endpoint
|
|
230
|
+
*/
|
|
45
231
|
static CreateTheConnectionUrl(): string;
|
|
232
|
+
/**
|
|
233
|
+
* Returns the URL for creating connections using the new endpoint.
|
|
234
|
+
* @returns {string} The new connection creation API endpoint
|
|
235
|
+
*/
|
|
46
236
|
static CreateTheConnectionNewUrl(): string;
|
|
237
|
+
/**
|
|
238
|
+
* Returns the URL for creating type concepts.
|
|
239
|
+
* @returns {string} The type concept creation API endpoint
|
|
240
|
+
*/
|
|
47
241
|
static MakeTheTypeConceptUrl(): string;
|
|
242
|
+
/**
|
|
243
|
+
* Returns the URL for deleting a single connection.
|
|
244
|
+
* @returns {string} The connection deletion API endpoint
|
|
245
|
+
*/
|
|
48
246
|
static DeleteTheConnectionUrl(): string;
|
|
247
|
+
/**
|
|
248
|
+
* Returns the URL for deleting multiple connections in bulk.
|
|
249
|
+
* @returns {string} The bulk connection deletion API endpoint
|
|
250
|
+
*/
|
|
49
251
|
static DeleteTheConnectionBulkUrl(): string;
|
|
252
|
+
/**
|
|
253
|
+
* Returns the URL for executing FreeSchema queries.
|
|
254
|
+
* @returns {string} The FreeSchema query API endpoint
|
|
255
|
+
*/
|
|
50
256
|
static FreeschemaQueryUrl(): string;
|
|
257
|
+
/**
|
|
258
|
+
* Returns the URL for retrieving type concepts by character in bulk.
|
|
259
|
+
* @returns {string} The bulk type concept retrieval API endpoint
|
|
260
|
+
*/
|
|
51
261
|
static GetConceptConnectionByType(): string;
|
|
52
262
|
}
|