@xrystal/core 3.28.3 → 3.37.3

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.
Files changed (233) hide show
  1. package/README.md +2331 -21
  2. package/package.json +66 -24
  3. package/tsconfig.base.json +15 -0
  4. package/x/bin/commands/create.mjs +136 -0
  5. package/x/bin/commands/doctor.mjs +149 -0
  6. package/x/bin/commands/hooks.mjs +55 -0
  7. package/x/bin/commands/project.mjs +126 -0
  8. package/x/bin/commands/release.mjs +66 -0
  9. package/x/bin/commands/sync-toolchain.mjs +43 -0
  10. package/x/bin/commands/tmp.mjs +57 -0
  11. package/x/bin/constants/index.mjs +6 -0
  12. package/x/bin/helpers/.generated/.generated-from +1 -0
  13. package/x/bin/helpers/.generated/tmp-schema.mjs +192 -0
  14. package/x/bin/helpers/banner.mjs +80 -0
  15. package/x/bin/helpers/build-config.mjs +342 -0
  16. package/x/bin/helpers/cli-help.mjs +164 -0
  17. package/x/bin/helpers/cli-identity.mjs +17 -0
  18. package/x/bin/helpers/create-target.mjs +35 -0
  19. package/{bin → x/bin}/helpers/index.mjs +44 -1
  20. package/x/bin/helpers/project-artifacts.mjs +140 -0
  21. package/x/bin/helpers/project-root.mjs +70 -0
  22. package/x/bin/helpers/runtime-info.mjs +172 -0
  23. package/x/bin/helpers/tmp-config.mjs +67 -0
  24. package/x/bin/helpers/tmp-layout.mjs +281 -0
  25. package/x/bin/helpers/tmp-schema.mjs +9 -0
  26. package/x/bin/helpers/toolchain-config.mjs +233 -0
  27. package/x/bin/main-cli.js +80 -0
  28. package/x/bin/paths.mjs +14 -0
  29. package/x/bin/scripts/clean-source-types.mjs +19 -0
  30. package/x/bin/scripts/fix-dist-imports.mjs +80 -0
  31. package/x/bin/scripts/install-git-hooks.mjs +86 -0
  32. package/x/bin/scripts/minify-dist.mjs +50 -0
  33. package/x/bin/scripts/prepare-npm-publish.mjs +49 -0
  34. package/x/bin/scripts/release-prepare.mjs +56 -0
  35. package/x/bin/scripts/tag.mjs +17 -0
  36. package/x/bin/scripts/unpublish-leaked-versions.mjs +62 -0
  37. package/x/bin/scripts/verify-npm-pack.mjs +45 -0
  38. package/x/bin/scripts/verify-version-bump.mjs +27 -0
  39. package/x/bin/scripts/version-check.mjs +370 -0
  40. package/x/dist/index.d.ts +3 -0
  41. package/x/dist/index.js +1 -0
  42. package/{source → x/dist}/loader/clients/index.d.ts +2 -1
  43. package/x/dist/loader/clients/index.js +1 -0
  44. package/{source → x/dist}/loader/configs/index.d.ts +3 -2
  45. package/x/dist/loader/configs/index.js +1 -0
  46. package/x/dist/loader/controller/index.d.ts +69 -0
  47. package/x/dist/loader/controller/index.js +1 -0
  48. package/x/dist/loader/dto/index.d.ts +39 -0
  49. package/x/dist/loader/dto/index.js +1 -0
  50. package/{source → x/dist}/loader/events/index.d.ts +1 -1
  51. package/x/dist/loader/events/index.js +1 -0
  52. package/{source → x/dist}/loader/index.d.ts +2 -1
  53. package/x/dist/loader/index.js +1 -0
  54. package/{source → x/dist}/loader/kafka/index.d.ts +6 -3
  55. package/x/dist/loader/kafka/index.js +1 -0
  56. package/{source → x/dist}/loader/localizations/index.d.ts +4 -3
  57. package/x/dist/loader/localizations/index.js +1 -0
  58. package/{source → x/dist}/loader/logger/index.d.ts +10 -7
  59. package/x/dist/loader/logger/index.js +2 -0
  60. package/x/dist/loader/service/index.js +1 -0
  61. package/{source → x/dist}/loader/system/index.d.ts +4 -3
  62. package/x/dist/loader/system/index.js +1 -0
  63. package/{source → x/dist}/project/index.d.ts +2 -2
  64. package/x/dist/project/index.js +1 -0
  65. package/x/dist/utils/constants/defaults.json +44 -0
  66. package/x/dist/utils/constants/index.d.ts +27 -0
  67. package/x/dist/utils/constants/index.js +1 -0
  68. package/x/dist/utils/helpers/configs/index.js +1 -0
  69. package/x/dist/utils/helpers/context/controller-store.d.ts +51 -0
  70. package/x/dist/utils/helpers/context/controller-store.js +1 -0
  71. package/x/dist/utils/helpers/context/index.d.ts +18 -0
  72. package/x/dist/utils/helpers/context/index.js +1 -0
  73. package/{source → x/dist}/utils/helpers/core/index.d.ts +8 -6
  74. package/x/dist/utils/helpers/core/index.js +1 -0
  75. package/x/dist/utils/helpers/core/paths.d.ts +2 -0
  76. package/x/dist/utils/helpers/core/paths.js +1 -0
  77. package/x/dist/utils/helpers/core/tmp-layout.d.ts +45 -0
  78. package/x/dist/utils/helpers/core/tmp-layout.js +1 -0
  79. package/{source → x/dist}/utils/helpers/date/index.d.ts +1 -1
  80. package/x/dist/utils/helpers/date/index.js +1 -0
  81. package/x/dist/utils/helpers/dispatch/index.d.ts +9 -0
  82. package/x/dist/utils/helpers/dispatch/index.js +1 -0
  83. package/x/dist/utils/helpers/dto/index.d.ts +10 -0
  84. package/x/dist/utils/helpers/dto/index.js +1 -0
  85. package/x/dist/utils/helpers/filters/index.js +1 -0
  86. package/x/dist/utils/helpers/framework/index.d.ts +3 -0
  87. package/x/dist/utils/helpers/framework/index.js +1 -0
  88. package/x/dist/utils/helpers/handlers/adapters.d.ts +10 -0
  89. package/x/dist/utils/helpers/handlers/adapters.js +1 -0
  90. package/x/dist/utils/helpers/handlers/execute.d.ts +5 -0
  91. package/x/dist/utils/helpers/handlers/execute.js +1 -0
  92. package/x/dist/utils/helpers/handlers/index.d.ts +18 -0
  93. package/x/dist/utils/helpers/handlers/index.js +1 -0
  94. package/x/dist/utils/helpers/hash/crypto.js +1 -0
  95. package/x/dist/utils/helpers/id/index.js +1 -0
  96. package/x/dist/utils/helpers/index.d.ts +26 -0
  97. package/x/dist/utils/helpers/index.js +1 -0
  98. package/x/dist/utils/helpers/ip/index.js +1 -0
  99. package/x/dist/utils/helpers/is/index.js +1 -0
  100. package/{source → x/dist}/utils/helpers/locales/index.d.ts +1 -0
  101. package/x/dist/utils/helpers/locales/index.js +1 -0
  102. package/x/dist/utils/helpers/math/index.js +1 -0
  103. package/x/dist/utils/helpers/middleware/index.d.ts +19 -0
  104. package/x/dist/utils/helpers/middleware/index.js +1 -0
  105. package/x/dist/utils/helpers/objects/index.js +1 -0
  106. package/x/dist/utils/helpers/path/index.js +1 -0
  107. package/x/dist/utils/helpers/protocol/index.d.ts +20 -0
  108. package/x/dist/utils/helpers/protocol/index.js +1 -0
  109. package/x/dist/utils/helpers/protocol/options.d.ts +6 -0
  110. package/x/dist/utils/helpers/protocol/options.js +1 -0
  111. package/x/dist/utils/helpers/regex/checkSpecialRegexControl.js +1 -0
  112. package/x/dist/utils/helpers/runtime/dto-access.d.ts +3 -0
  113. package/x/dist/utils/helpers/runtime/dto-access.js +1 -0
  114. package/x/dist/utils/helpers/runtime/dto-types.d.ts +19 -0
  115. package/x/dist/utils/helpers/runtime/dto-types.js +1 -0
  116. package/x/dist/utils/helpers/runtime/index.d.ts +3 -0
  117. package/x/dist/utils/helpers/runtime/index.js +1 -0
  118. package/x/dist/utils/helpers/runtime/shutdown.d.ts +3 -0
  119. package/x/dist/utils/helpers/runtime/shutdown.js +1 -0
  120. package/x/dist/utils/helpers/state/index.d.ts +59 -0
  121. package/x/dist/utils/helpers/state/index.js +1 -0
  122. package/x/dist/utils/helpers/state/props-from-tmp.d.ts +9 -0
  123. package/x/dist/utils/helpers/state/props-from-tmp.js +1 -0
  124. package/x/dist/utils/helpers/state/request-key-guard.d.ts +3 -0
  125. package/x/dist/utils/helpers/state/request-key-guard.js +1 -0
  126. package/x/dist/utils/helpers/state/scopes.d.ts +21 -0
  127. package/x/dist/utils/helpers/state/scopes.js +1 -0
  128. package/x/dist/utils/helpers/string/index.js +1 -0
  129. package/x/dist/utils/helpers/tests/tmp-schema.test.js +1 -0
  130. package/{source/utils/models/types/index.js → x/dist/utils/helpers/tests/tmp-watch.test.d.ts} +0 -1
  131. package/x/dist/utils/helpers/tests/tmp-watch.test.js +1 -0
  132. package/x/dist/utils/helpers/timer/index.js +1 -0
  133. package/x/dist/utils/helpers/tmp/index.d.ts +5 -0
  134. package/x/dist/utils/helpers/tmp/index.js +1 -0
  135. package/x/dist/utils/helpers/tmp/loader-tmp-sync.d.ts +4 -0
  136. package/x/dist/utils/helpers/tmp/loader-tmp-sync.js +1 -0
  137. package/x/dist/utils/helpers/tmp/runtime-tmp.d.ts +9 -0
  138. package/x/dist/utils/helpers/tmp/runtime-tmp.js +1 -0
  139. package/x/dist/utils/helpers/tmp/tmp-loader.d.ts +7 -0
  140. package/x/dist/utils/helpers/tmp/tmp-loader.js +1 -0
  141. package/x/dist/utils/helpers/tmp/tmp-schema.d.ts +47 -0
  142. package/x/dist/utils/helpers/tmp/tmp-schema.js +1 -0
  143. package/x/dist/utils/helpers/tmp/tmp-watch.d.ts +1 -0
  144. package/x/dist/utils/helpers/tmp/tmp-watch.js +1 -0
  145. package/x/dist/utils/helpers/validates/index.js +1 -0
  146. package/x/dist/utils/index.d.ts +3 -0
  147. package/x/dist/utils/index.js +1 -0
  148. package/x/dist/utils/models/classes/class.clients.js +1 -0
  149. package/x/dist/utils/models/classes/class.interfaces.js +1 -0
  150. package/x/dist/utils/models/classes/class.service-locator.js +1 -0
  151. package/{source → x/dist}/utils/models/classes/class.tmp-file-loader.d.ts +3 -2
  152. package/x/dist/utils/models/classes/class.tmp-file-loader.js +1 -0
  153. package/x/dist/utils/models/classes/class.x.js +1 -0
  154. package/{source → x/dist}/utils/models/enums/index.d.ts +14 -1
  155. package/x/dist/utils/models/enums/index.js +1 -0
  156. package/x/dist/utils/models/index.d.ts +9 -0
  157. package/x/dist/utils/models/index.js +1 -0
  158. package/x/dist/utils/models/types/index.d.ts +5 -0
  159. package/x/dist/utils/models/types/index.js +1 -0
  160. package/x/dist/utils/package-root.d.ts +2 -0
  161. package/x/dist/utils/package-root.js +1 -0
  162. package/x/tmp.yml +48 -17
  163. package/bin/constants/index.mjs +0 -17
  164. package/bin/main-cli.js +0 -131
  165. package/source/index.js +0 -6
  166. package/source/loader/clients/index.js +0 -18
  167. package/source/loader/configs/index.js +0 -81
  168. package/source/loader/controller/index.d.ts +0 -129
  169. package/source/loader/controller/index.js +0 -327
  170. package/source/loader/events/index.js +0 -44
  171. package/source/loader/index.js +0 -10
  172. package/source/loader/kafka/index.js +0 -122
  173. package/source/loader/localizations/index.js +0 -40
  174. package/source/loader/logger/index.js +0 -183
  175. package/source/loader/service/index.js +0 -7
  176. package/source/loader/system/index.js +0 -19
  177. package/source/project/index.js +0 -66
  178. package/source/utils/constants/index.d.ts +0 -10
  179. package/source/utils/constants/index.js +0 -11
  180. package/source/utils/helpers/configs/index.js +0 -1
  181. package/source/utils/helpers/core/index.js +0 -105
  182. package/source/utils/helpers/date/index.js +0 -48
  183. package/source/utils/helpers/filters/index.js +0 -44
  184. package/source/utils/helpers/hash/crypto.js +0 -22
  185. package/source/utils/helpers/id/index.js +0 -24
  186. package/source/utils/helpers/index.d.ts +0 -17
  187. package/source/utils/helpers/index.js +0 -17
  188. package/source/utils/helpers/ip/index.js +0 -21
  189. package/source/utils/helpers/is/index.js +0 -35
  190. package/source/utils/helpers/locales/index.js +0 -63
  191. package/source/utils/helpers/math/index.js +0 -14
  192. package/source/utils/helpers/middlewares/index.d.ts +0 -1
  193. package/source/utils/helpers/middlewares/index.js +0 -26
  194. package/source/utils/helpers/objects/index.js +0 -55
  195. package/source/utils/helpers/path/index.js +0 -4
  196. package/source/utils/helpers/regex/checkSpecialRegexControl.js +0 -3
  197. package/source/utils/helpers/string/index.js +0 -9
  198. package/source/utils/helpers/timer/index.js +0 -5
  199. package/source/utils/helpers/validates/index.js +0 -20
  200. package/source/utils/index.d.ts +0 -3
  201. package/source/utils/index.js +0 -3
  202. package/source/utils/models/classes/class.clients.js +0 -142
  203. package/source/utils/models/classes/class.dtos.d.ts +0 -47
  204. package/source/utils/models/classes/class.dtos.js +0 -36
  205. package/source/utils/models/classes/class.interfaces.js +0 -10
  206. package/source/utils/models/classes/class.response.d.ts +0 -17
  207. package/source/utils/models/classes/class.response.js +0 -35
  208. package/source/utils/models/classes/class.service-locator.js +0 -16
  209. package/source/utils/models/classes/class.tmp-file-loader.js +0 -38
  210. package/source/utils/models/classes/class.x.js +0 -179
  211. package/source/utils/models/enums/index.js +0 -133
  212. package/source/utils/models/index.d.ts +0 -11
  213. package/source/utils/models/index.js +0 -11
  214. package/source/utils/models/types/index.d.ts +0 -3
  215. /package/{source → x/dist}/loader/service/index.d.ts +0 -0
  216. /package/{source → x/dist}/utils/helpers/configs/index.d.ts +0 -0
  217. /package/{source → x/dist}/utils/helpers/filters/index.d.ts +0 -0
  218. /package/{source → x/dist}/utils/helpers/hash/crypto.d.ts +0 -0
  219. /package/{source → x/dist}/utils/helpers/id/index.d.ts +0 -0
  220. /package/{source → x/dist}/utils/helpers/ip/index.d.ts +0 -0
  221. /package/{source → x/dist}/utils/helpers/is/index.d.ts +0 -0
  222. /package/{source → x/dist}/utils/helpers/math/index.d.ts +0 -0
  223. /package/{source → x/dist}/utils/helpers/objects/index.d.ts +0 -0
  224. /package/{source → x/dist}/utils/helpers/path/index.d.ts +0 -0
  225. /package/{source → x/dist}/utils/helpers/regex/checkSpecialRegexControl.d.ts +0 -0
  226. /package/{source → x/dist}/utils/helpers/string/index.d.ts +0 -0
  227. /package/{source/index.d.ts → x/dist/utils/helpers/tests/tmp-schema.test.d.ts} +0 -0
  228. /package/{source → x/dist}/utils/helpers/timer/index.d.ts +0 -0
  229. /package/{source → x/dist}/utils/helpers/validates/index.d.ts +0 -0
  230. /package/{source → x/dist}/utils/models/classes/class.clients.d.ts +0 -0
  231. /package/{source → x/dist}/utils/models/classes/class.interfaces.d.ts +0 -0
  232. /package/{source → x/dist}/utils/models/classes/class.service-locator.d.ts +0 -0
  233. /package/{source → x/dist}/utils/models/classes/class.x.d.ts +0 -0
@@ -1,179 +0,0 @@
1
- import { createContainer, asClass, asValue, InjectionMode, listModules, Lifetime } from 'awilix';
2
- import path from 'node:path';
3
- import { pathToFileURL } from 'node:url';
4
- export const xSymbol = Symbol.for('@xrystal/core/di-container');
5
- class X {
6
- checkRegistration(container, name) {
7
- return !!container.registrations[name];
8
- }
9
- }
10
- class DIM extends X {
11
- container;
12
- initializedNames = new Set();
13
- loadedPaths = new Set();
14
- registeredClasses = new Set();
15
- isInitializing = false;
16
- constructor() {
17
- super();
18
- this.container = createContainer({
19
- injectionMode: InjectionMode.PROXY,
20
- strict: true
21
- });
22
- }
23
- getName(target) {
24
- if (typeof target === 'string')
25
- return target.charAt(0).toLowerCase() + target.slice(1);
26
- if (typeof target === 'function' && target.name)
27
- return target.name.charAt(0).toLowerCase() + target.name.slice(1);
28
- return '';
29
- }
30
- async load(patterns, options = {}) {
31
- const { verbose = false, exclude = [], lifetime = Lifetime.SINGLETON } = options;
32
- const cwd = process.cwd();
33
- const resolvedPatterns = (Array.isArray(patterns) ? patterns : [patterns]).map(p => {
34
- const resolved = path.isAbsolute(p) ? p : path.resolve(cwd, p);
35
- return resolved.replace(/\\/g, '/').toLowerCase();
36
- });
37
- let modules = [];
38
- try {
39
- modules = listModules(resolvedPatterns);
40
- }
41
- catch (err) {
42
- return this;
43
- }
44
- for (const m of modules) {
45
- const normalizedMPath = m.path.replace(/\\/g, '/').toLowerCase();
46
- if (this.loadedPaths.has(normalizedMPath))
47
- continue;
48
- if (normalizedMPath === __filename.replace(/\\/g, '/').toLowerCase() || normalizedMPath.endsWith('.d.ts'))
49
- continue;
50
- try {
51
- const fileUrl = pathToFileURL(m.path).href;
52
- const loaded = await import(fileUrl);
53
- let dependency = loaded.default;
54
- if (!dependency) {
55
- dependency = Object.values(loaded).find(val => typeof val === 'function' && !!val.prototype && !!val.name);
56
- }
57
- if (typeof dependency === 'function' && !!dependency.prototype && !!dependency.name) {
58
- if (this.registeredClasses.has(dependency))
59
- continue;
60
- const name = this.getName(dependency);
61
- if (name && !this.checkRegistration(this.container, name)) {
62
- this.container.register({
63
- [name]: asClass(dependency).setLifetime(lifetime)
64
- });
65
- this.loadedPaths.add(normalizedMPath);
66
- this.registeredClasses.add(dependency);
67
- }
68
- }
69
- }
70
- catch (err) {
71
- if (verbose)
72
- console.error(`[DI] Load Error:`, err.message);
73
- }
74
- }
75
- return this;
76
- }
77
- register(Dependency, lifetime = Lifetime.SINGLETON) {
78
- const name = this.getName(Dependency);
79
- if (!name || this.registeredClasses.has(Dependency))
80
- return this;
81
- if (this.checkRegistration(this.container, name))
82
- return this;
83
- this.container.register({ [name]: asClass(Dependency).setLifetime(lifetime) });
84
- this.registeredClasses.add(Dependency);
85
- return this;
86
- }
87
- registerInstance(name, instance) {
88
- if (!name)
89
- return this;
90
- const formattedName = this.getName(name);
91
- this.container.register({ [formattedName]: asValue(instance) });
92
- return this;
93
- }
94
- async initialize(input, verbose = false) {
95
- if (this.isInitializing)
96
- return this;
97
- this.isInitializing = true;
98
- try {
99
- const inputList = input ? (Array.isArray(input) ? input : [input]) : [];
100
- for (const item of inputList) {
101
- const name = this.getName(item.service);
102
- if (!name || this.initializedNames.has(name))
103
- continue;
104
- const reg = this.container.registrations[name];
105
- if (!reg || reg.lifetime !== Lifetime.SINGLETON)
106
- continue;
107
- try {
108
- const instance = this.container.cradle[name];
109
- if (instance && typeof instance.onInit === 'function') {
110
- await instance.onInit(item.props || {});
111
- }
112
- this.initializedNames.add(name);
113
- }
114
- catch (err) {
115
- if (verbose)
116
- console.error(`[DI] Priority onInit Failed (${name}):`, err.message);
117
- }
118
- }
119
- const allKeys = Object.keys(this.container.registrations);
120
- for (const key of allKeys) {
121
- if (this.initializedNames.has(key))
122
- continue;
123
- const reg = this.container.registrations[key];
124
- if (reg.lifetime !== Lifetime.SINGLETON)
125
- continue;
126
- try {
127
- const instance = this.container.cradle[key];
128
- if (instance && typeof instance.onInit === 'function') {
129
- await instance.onInit({});
130
- }
131
- this.initializedNames.add(key);
132
- }
133
- catch (err) {
134
- if (verbose)
135
- console.error(`[DI] Auto onInit Failed (${key}):`, err.message);
136
- }
137
- }
138
- for (const name of this.initializedNames) {
139
- try {
140
- const instance = this.container.cradle[name];
141
- if (instance && typeof instance.onAfterInit === 'function') {
142
- await instance.onAfterInit();
143
- }
144
- }
145
- catch (err) {
146
- if (verbose)
147
- console.error(`[DI] onAfterInit Failed (${name}):`, err.message);
148
- }
149
- }
150
- }
151
- finally {
152
- this.isInitializing = false;
153
- }
154
- return this;
155
- }
156
- get(target) {
157
- const resolveName = this.getName(target);
158
- return this.container.resolve(resolveName);
159
- }
160
- async shutdown() {
161
- for (const name of this.initializedNames) {
162
- try {
163
- const instance = this.container.cradle[name];
164
- if (instance && typeof instance.onDispose === 'function') {
165
- await instance.onDispose();
166
- }
167
- }
168
- catch (err) {
169
- console.error(`[DI] onDispose Failed (${name})`);
170
- }
171
- }
172
- await this.container.dispose();
173
- }
174
- get cradle() { return this.container.cradle; }
175
- }
176
- if (!global[xSymbol]) {
177
- global[xSymbol] = new DIM();
178
- }
179
- export default global[xSymbol];
@@ -1,133 +0,0 @@
1
- export var NodeEnvEnum;
2
- (function (NodeEnvEnum) {
3
- NodeEnvEnum["DEV"] = "dev";
4
- NodeEnvEnum["TEST"] = "test";
5
- NodeEnvEnum["PROD"] = "prod";
6
- })(NodeEnvEnum || (NodeEnvEnum = {}));
7
- export var ProtocolEnum;
8
- (function (ProtocolEnum) {
9
- ProtocolEnum["HTTP"] = "http";
10
- ProtocolEnum["HTTPS"] = "https";
11
- ProtocolEnum["WEBSOCKET"] = "ws";
12
- ProtocolEnum["SOCKETIO"] = "ws";
13
- ProtocolEnum["NONE"] = "none";
14
- })(ProtocolEnum || (ProtocolEnum = {}));
15
- export var PolarityTypeEnum;
16
- (function (PolarityTypeEnum) {
17
- PolarityTypeEnum[PolarityTypeEnum["NOTR"] = 0] = "NOTR";
18
- PolarityTypeEnum[PolarityTypeEnum["POSITIVE"] = 1] = "POSITIVE";
19
- PolarityTypeEnum[PolarityTypeEnum["NEGATIVE"] = -1] = "NEGATIVE";
20
- })(PolarityTypeEnum || (PolarityTypeEnum = {}));
21
- export var LoggerLayerEnum;
22
- (function (LoggerLayerEnum) {
23
- LoggerLayerEnum[LoggerLayerEnum["CRITICAL"] = 0] = "CRITICAL";
24
- LoggerLayerEnum[LoggerLayerEnum["ERROR"] = 1] = "ERROR";
25
- LoggerLayerEnum[LoggerLayerEnum["WARN"] = 2] = "WARN";
26
- LoggerLayerEnum[LoggerLayerEnum["INFO"] = 3] = "INFO";
27
- LoggerLayerEnum[LoggerLayerEnum["HTTP"] = 4] = "HTTP";
28
- LoggerLayerEnum[LoggerLayerEnum["DEBUG"] = 5] = "DEBUG";
29
- })(LoggerLayerEnum || (LoggerLayerEnum = {}));
30
- export var CountryCodeEnum;
31
- (function (CountryCodeEnum) {
32
- CountryCodeEnum["EN"] = "en";
33
- CountryCodeEnum["TR"] = "tr";
34
- })(CountryCodeEnum || (CountryCodeEnum = {}));
35
- export var CurrencyCodeEnum;
36
- (function (CurrencyCodeEnum) {
37
- CurrencyCodeEnum["USD"] = "usd";
38
- CurrencyCodeEnum["EUR"] = "eur";
39
- CurrencyCodeEnum["TRY"] = "try";
40
- })(CurrencyCodeEnum || (CurrencyCodeEnum = {}));
41
- export var HttpMethodEnum;
42
- (function (HttpMethodEnum) {
43
- HttpMethodEnum["POST"] = "post";
44
- HttpMethodEnum["GET"] = "get";
45
- HttpMethodEnum["PUT"] = "put";
46
- HttpMethodEnum["DELETE"] = "delete";
47
- })(HttpMethodEnum || (HttpMethodEnum = {}));
48
- export var ContentTypeEnum;
49
- (function (ContentTypeEnum) {
50
- ContentTypeEnum["applicationJson"] = "application/json";
51
- ContentTypeEnum["applicationXWwwFormUrlencoded"] = "application/x-www-form-urlencoded";
52
- })(ContentTypeEnum || (ContentTypeEnum = {}));
53
- export var DeviceStatusEnum;
54
- (function (DeviceStatusEnum) {
55
- DeviceStatusEnum[DeviceStatusEnum["PENDING"] = 0] = "PENDING";
56
- DeviceStatusEnum[DeviceStatusEnum["OFFLINE"] = 1] = "OFFLINE";
57
- DeviceStatusEnum[DeviceStatusEnum["ONLINE"] = 2] = "ONLINE";
58
- DeviceStatusEnum[DeviceStatusEnum["CONNECTING"] = 3] = "CONNECTING";
59
- DeviceStatusEnum[DeviceStatusEnum["CONNECTED"] = 4] = "CONNECTED";
60
- })(DeviceStatusEnum || (DeviceStatusEnum = {}));
61
- export var DevicePlatformEnum;
62
- (function (DevicePlatformEnum) {
63
- DevicePlatformEnum["WEB"] = "web";
64
- DevicePlatformEnum["NATIVE"] = "native";
65
- DevicePlatformEnum["OTHER"] = "other";
66
- })(DevicePlatformEnum || (DevicePlatformEnum = {}));
67
- export var DeviceOSEnum;
68
- (function (DeviceOSEnum) {
69
- DeviceOSEnum["ANDROID"] = "android";
70
- DeviceOSEnum["IOS"] = "ios";
71
- DeviceOSEnum["WINDOWS"] = "windows";
72
- DeviceOSEnum["MACOS"] = "macos";
73
- DeviceOSEnum["MACOSX"] = "macosx";
74
- DeviceOSEnum["OTHER"] = "other";
75
- })(DeviceOSEnum || (DeviceOSEnum = {}));
76
- export var PriorityEnum;
77
- (function (PriorityEnum) {
78
- PriorityEnum[PriorityEnum["HIGH"] = 0] = "HIGH";
79
- PriorityEnum[PriorityEnum["MEDIUM"] = 1] = "MEDIUM";
80
- PriorityEnum[PriorityEnum["LOW"] = 2] = "LOW";
81
- })(PriorityEnum || (PriorityEnum = {}));
82
- export var PrivacyEnum;
83
- (function (PrivacyEnum) {
84
- PrivacyEnum[PrivacyEnum["PRIVATE"] = 0] = "PRIVATE";
85
- PrivacyEnum[PrivacyEnum["PUBLIC"] = 1] = "PUBLIC";
86
- PrivacyEnum[PrivacyEnum["ONLY_FRIENDS"] = 2] = "ONLY_FRIENDS";
87
- })(PrivacyEnum || (PrivacyEnum = {}));
88
- export var TimezoneEnum;
89
- (function (TimezoneEnum) {
90
- TimezoneEnum["UTC"] = "UTC";
91
- TimezoneEnum["EtcUTC"] = "Etc/UTC";
92
- TimezoneEnum["EtcGMT"] = "Etc/GMT";
93
- })(TimezoneEnum || (TimezoneEnum = {}));
94
- export var ModeEnum;
95
- (function (ModeEnum) {
96
- ModeEnum["MONOLITIC"] = "monolitic";
97
- ModeEnum["MICRO_SERVICE"] = "micro_service";
98
- })(ModeEnum || (ModeEnum = {}));
99
- export var TokensEnum;
100
- (function (TokensEnum) {
101
- TokensEnum["INTERNAL_API_TOKEN"] = "internal_api_key";
102
- TokensEnum["CSRF_TOKEN"] = "csrf_token";
103
- TokensEnum["ACCESS_TOKEN"] = "access_token";
104
- TokensEnum["REFRESH_TOKEN"] = "refresh_token";
105
- TokensEnum["REFERENCE_TOKEN"] = "reference_token";
106
- TokensEnum["PERSONAL_ACCESS_TOKEN"] = "personal_access_token";
107
- })(TokensEnum || (TokensEnum = {}));
108
- export var CoreClientsEnum;
109
- (function (CoreClientsEnum) {
110
- CoreClientsEnum["BASE_API_CLIENT"] = "base_client_name";
111
- CoreClientsEnum["SOAP_API_CLIENT"] = "soap_api_client";
112
- })(CoreClientsEnum || (CoreClientsEnum = {}));
113
- export var EndpointResourceEnum;
114
- (function (EndpointResourceEnum) {
115
- EndpointResourceEnum["EXAMPLE"] = "example";
116
- EndpointResourceEnum["FULL"] = "full";
117
- EndpointResourceEnum["SYSTEM"] = "system";
118
- EndpointResourceEnum["CLIENTS"] = "clients";
119
- EndpointResourceEnum["AUTH"] = "auth";
120
- EndpointResourceEnum["ACCOUNTS"] = "accounts";
121
- EndpointResourceEnum["USERS"] = "users";
122
- EndpointResourceEnum["TRANSACTIONS"] = "transactions";
123
- EndpointResourceEnum["NOTIFICATIONS"] = "notifications";
124
- EndpointResourceEnum["ADDRESSES"] = "addresses";
125
- EndpointResourceEnum["PAYMENTS"] = "payments";
126
- EndpointResourceEnum["COMMISSIONS_AND_TAXES"] = "commissions-and-taxes";
127
- EndpointResourceEnum["SUPPORTS"] = "supports";
128
- EndpointResourceEnum["INVOICES"] = "invoices";
129
- EndpointResourceEnum["FILES"] = "files";
130
- EndpointResourceEnum["TOKENS"] = "tokens";
131
- EndpointResourceEnum["WEBHOOKS"] = "webhooks";
132
- EndpointResourceEnum["OTHERS"] = "others";
133
- })(EndpointResourceEnum || (EndpointResourceEnum = {}));
@@ -1,11 +0,0 @@
1
- import _ from 'lodash';
2
- import x from './classes/class.x';
3
- import locator from './classes/class.service-locator';
4
- export * from './classes/class.tmp-file-loader';
5
- export * from './classes/class.interfaces';
6
- export * from './classes/class.dtos';
7
- export * from './classes/class.response';
8
- export * from './classes/class.clients';
9
- export * from './types';
10
- export * from './enums';
11
- export { x, locator, _ };
@@ -1,11 +0,0 @@
1
- import _ from 'lodash';
2
- import x from './classes/class.x';
3
- import locator from './classes/class.service-locator';
4
- export * from './classes/class.tmp-file-loader';
5
- export * from './classes/class.interfaces';
6
- export * from './classes/class.dtos';
7
- export * from './classes/class.response';
8
- export * from './classes/class.clients';
9
- export * from './types';
10
- export * from './enums';
11
- export { x, locator, _ };
@@ -1,3 +0,0 @@
1
- export interface ICustomError extends Error {
2
- status?: number;
3
- }
File without changes
File without changes
File without changes
File without changes