@aneuhold/core-ts-api-lib 3.0.6 → 3.0.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/CHANGELOG.md +19 -1
- package/lib/browser.d.ts +2 -1
- package/lib/browser.d.ts.map +1 -1
- package/lib/browser.js.map +1 -1
- package/lib/browser.ts +9 -1
- package/lib/services/APIService/APIService.d.ts +8 -0
- package/lib/services/APIService/APIService.d.ts.map +1 -1
- package/lib/services/APIService/APIService.js +12 -0
- package/lib/services/APIService/APIService.js.map +1 -1
- package/lib/services/APIService/APIService.ts +15 -1
- package/lib/services/GCloudAPIService/GCloudAPIService.d.ts +7 -0
- package/lib/services/GCloudAPIService/GCloudAPIService.d.ts.map +1 -1
- package/lib/services/GCloudAPIService/GCloudAPIService.js +10 -1
- package/lib/services/GCloudAPIService/GCloudAPIService.js.map +1 -1
- package/lib/services/GCloudAPIService/GCloudAPIService.ts +12 -1
- package/lib/types/ProjectDashboard.d.ts +1 -0
- package/lib/types/ProjectDashboard.d.ts.map +1 -1
- package/lib/types/ProjectDashboard.ts +1 -0
- package/lib/types/WebSocket.d.ts +29 -0
- package/lib/types/WebSocket.d.ts.map +1 -0
- package/lib/types/WebSocket.js +2 -0
- package/lib/types/WebSocket.js.map +1 -0
- package/lib/types/WebSocket.ts +31 -0
- package/package.json +7 -7
package/CHANGELOG.md
CHANGED
|
@@ -5,6 +5,23 @@ All notable changes to this project will be documented in this file.
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
|
6
6
|
and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
|
|
7
7
|
|
|
8
|
+
## 🔖 [3.0.8] (2025-12-14)
|
|
9
|
+
|
|
10
|
+
### ✅ Added
|
|
11
|
+
- Added `APIService.getCurrentAPIUrl()` to retrieve the current API base URL.
|
|
12
|
+
|
|
13
|
+
### 🏗️ Changed
|
|
14
|
+
- Updated dependencies: now requires `@aneuhold/core-ts-db-lib@^4.0.4`, `@aneuhold/core-ts-lib@^2.3.16`, and `@aneuhold/local-npm-registry@^0.2.23`.
|
|
15
|
+
|
|
16
|
+
## 🔖 [3.0.7] (2025-12-14)
|
|
17
|
+
|
|
18
|
+
### ✅ Added
|
|
19
|
+
- Added websocket types for dashboard communication
|
|
20
|
+
|
|
21
|
+
### 🏗️ Changed
|
|
22
|
+
- Updated dependencies for compatibility
|
|
23
|
+
|
|
24
|
+
|
|
8
25
|
## 🔖 [3.0.6] (2025-12-13)
|
|
9
26
|
|
|
10
27
|
### 🏗️ Changed
|
|
@@ -165,7 +182,8 @@ No direct code changes; version bump for compatibility.
|
|
|
165
182
|
- Updated workflow permissions to allow repository write access
|
|
166
183
|
|
|
167
184
|
<!-- Link References -->
|
|
168
|
-
|
|
185
|
+
[3.0.8]: https://github.com/aneuhold/ts-libs/compare/core-ts-api-lib-v3.0.7...core-ts-api-lib-v3.0.8
|
|
186
|
+
[3.0.7]: https://github.com/aneuhold/ts-libs/compare/core-ts-api-lib-v3.0.6...core-ts-api-lib-v3.0.7
|
|
169
187
|
[3.0.6]: https://github.com/aneuhold/ts-libs/compare/core-ts-api-lib-v3.0.5...core-ts-api-lib-v3.0.6
|
|
170
188
|
[3.0.5]: https://github.com/aneuhold/ts-libs/compare/core-ts-api-lib-v3.0.4...core-ts-api-lib-v3.0.5
|
|
171
189
|
[3.0.4]: https://github.com/aneuhold/ts-libs/compare/core-ts-api-lib-v3.0.3...core-ts-api-lib-v3.0.4
|
package/lib/browser.d.ts
CHANGED
|
@@ -5,6 +5,7 @@ import type { AuthValidateUserInput, AuthValidateUserOutput } from './types/Auth
|
|
|
5
5
|
import type { DashboardConfig } from './types/DashboardConfig.js';
|
|
6
6
|
import type { ProjectDashboardInput, ProjectDashboardOptions, ProjectDashboardOutput } from './types/ProjectDashboard.js';
|
|
7
7
|
import type { Translation, Translations } from './types/Translations.js';
|
|
8
|
+
import type { DashboardWebSocketClientToServerEvents, DashboardWebSocketServerToClientEvents, WebSocketHandshakeAuth } from './types/WebSocket.js';
|
|
8
9
|
export { APIService };
|
|
9
|
-
export type { APIResponse, AuthCheckPasswordInput, AuthCheckPasswordOutput, AuthValidateUserInput, AuthValidateUserOutput, DashboardConfig, ProjectDashboardInput, ProjectDashboardOptions, ProjectDashboardOutput, Translation, Translations };
|
|
10
|
+
export type { APIResponse, AuthCheckPasswordInput, AuthCheckPasswordOutput, AuthValidateUserInput, AuthValidateUserOutput, DashboardConfig, DashboardWebSocketClientToServerEvents, DashboardWebSocketServerToClientEvents, ProjectDashboardInput, ProjectDashboardOptions, ProjectDashboardOutput, Translation, Translations, WebSocketHandshakeAuth };
|
|
10
11
|
//# sourceMappingURL=browser.d.ts.map
|
package/lib/browser.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"browser.d.ts","sourceRoot":"","sources":["../src/browser.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;AAC7D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,KAAK,EAAE,sBAAsB,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACpG,OAAO,KAAK,EAAE,qBAAqB,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACjG,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EACV,qBAAqB,EACrB,uBAAuB,EACvB,sBAAsB,EACvB,MAAM,6BAA6B,CAAC;AACrC,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;
|
|
1
|
+
{"version":3,"file":"browser.d.ts","sourceRoot":"","sources":["../src/browser.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;AAC7D,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,wBAAwB,CAAC;AAC1D,OAAO,KAAK,EAAE,sBAAsB,EAAE,uBAAuB,EAAE,MAAM,8BAA8B,CAAC;AACpG,OAAO,KAAK,EAAE,qBAAqB,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AACjG,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,4BAA4B,CAAC;AAClE,OAAO,KAAK,EACV,qBAAqB,EACrB,uBAAuB,EACvB,sBAAsB,EACvB,MAAM,6BAA6B,CAAC;AACrC,OAAO,KAAK,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACzE,OAAO,KAAK,EACV,sCAAsC,EACtC,sCAAsC,EACtC,sBAAsB,EACvB,MAAM,sBAAsB,CAAC;AAG9B,OAAO,EAAE,UAAU,EAAE,CAAC;AAGtB,YAAY,EACV,WAAW,EACX,sBAAsB,EACtB,uBAAuB,EACvB,qBAAqB,EACrB,sBAAsB,EACtB,eAAe,EACf,sCAAsC,EACtC,sCAAsC,EACtC,qBAAqB,EACrB,uBAAuB,EACvB,sBAAsB,EACtB,WAAW,EACX,YAAY,EACZ,sBAAsB,EACvB,CAAC"}
|
package/lib/browser.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"browser.js","sourceRoot":"","sources":["../src/browser.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;
|
|
1
|
+
{"version":3,"file":"browser.js","sourceRoot":"","sources":["../src/browser.ts"],"names":[],"mappings":"AAAA,OAAO,UAAU,MAAM,qCAAqC,CAAC;AAiB7D,kEAAkE;AAClE,OAAO,EAAE,UAAU,EAAE,CAAC"}
|
package/lib/browser.ts
CHANGED
|
@@ -9,6 +9,11 @@ import type {
|
|
|
9
9
|
ProjectDashboardOutput
|
|
10
10
|
} from './types/ProjectDashboard.js';
|
|
11
11
|
import type { Translation, Translations } from './types/Translations.js';
|
|
12
|
+
import type {
|
|
13
|
+
DashboardWebSocketClientToServerEvents,
|
|
14
|
+
DashboardWebSocketServerToClientEvents,
|
|
15
|
+
WebSocketHandshakeAuth
|
|
16
|
+
} from './types/WebSocket.js';
|
|
12
17
|
|
|
13
18
|
// Export all browser-safe functions and classes from this library
|
|
14
19
|
export { APIService };
|
|
@@ -21,9 +26,12 @@ export type {
|
|
|
21
26
|
AuthValidateUserInput,
|
|
22
27
|
AuthValidateUserOutput,
|
|
23
28
|
DashboardConfig,
|
|
29
|
+
DashboardWebSocketClientToServerEvents,
|
|
30
|
+
DashboardWebSocketServerToClientEvents,
|
|
24
31
|
ProjectDashboardInput,
|
|
25
32
|
ProjectDashboardOptions,
|
|
26
33
|
ProjectDashboardOutput,
|
|
27
34
|
Translation,
|
|
28
|
-
Translations
|
|
35
|
+
Translations,
|
|
36
|
+
WebSocketHandshakeAuth
|
|
29
37
|
};
|
|
@@ -22,11 +22,19 @@ export default class APIService {
|
|
|
22
22
|
* @returns A promise that resolves to the result of the dashboard API call.
|
|
23
23
|
*/
|
|
24
24
|
static callDashboardAPI(input: ProjectDashboardInput): Promise<APIResponse<ProjectDashboardOutput>>;
|
|
25
|
+
/**
|
|
26
|
+
* Gets the current base URL for the API.
|
|
27
|
+
*/
|
|
28
|
+
static getCurrentAPIUrl(): string;
|
|
25
29
|
/**
|
|
26
30
|
* Sets the base URL for the API.
|
|
27
31
|
*
|
|
28
32
|
* @param url - The URL to be set for the API. This should include a trailing slash.
|
|
29
33
|
*/
|
|
30
34
|
static setAPIUrl(url: string): void;
|
|
35
|
+
/**
|
|
36
|
+
* Gets the default base URL for the API.
|
|
37
|
+
*/
|
|
38
|
+
static getDefaultAPIUrl(): string;
|
|
31
39
|
}
|
|
32
40
|
//# sourceMappingURL=APIService.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"APIService.d.ts","sourceRoot":"","sources":["../../../src/services/APIService/APIService.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AAGzC;;;GAGG;AACH,MAAM,CAAC,OAAO,OAAO,UAAU;IAC7B;;;;;;OAMG;WACU,YAAY,CACvB,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;;;;;OAMG;WACU,gBAAgB,CAC3B,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,MAAM;
|
|
1
|
+
{"version":3,"file":"APIService.d.ts","sourceRoot":"","sources":["../../../src/services/APIService/APIService.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AAGzC;;;GAGG;AACH,MAAM,CAAC,OAAO,OAAO,UAAU;IAC7B;;;;;;OAMG;WACU,YAAY,CACvB,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;;;;;OAMG;WACU,gBAAgB,CAC3B,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;OAEG;IACH,MAAM,CAAC,gBAAgB,IAAI,MAAM;IAIjC;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAInC;;OAEG;IACH,MAAM,CAAC,gBAAgB,IAAI,MAAM;CAGlC"}
|
|
@@ -24,6 +24,12 @@ export default class APIService {
|
|
|
24
24
|
static async callDashboardAPI(input) {
|
|
25
25
|
return GCloudAPIService.projectDashboard(input);
|
|
26
26
|
}
|
|
27
|
+
/**
|
|
28
|
+
* Gets the current base URL for the API.
|
|
29
|
+
*/
|
|
30
|
+
static getCurrentAPIUrl() {
|
|
31
|
+
return GCloudAPIService.getUrl();
|
|
32
|
+
}
|
|
27
33
|
/**
|
|
28
34
|
* Sets the base URL for the API.
|
|
29
35
|
*
|
|
@@ -32,5 +38,11 @@ export default class APIService {
|
|
|
32
38
|
static setAPIUrl(url) {
|
|
33
39
|
GCloudAPIService.setUrl(url);
|
|
34
40
|
}
|
|
41
|
+
/**
|
|
42
|
+
* Gets the default base URL for the API.
|
|
43
|
+
*/
|
|
44
|
+
static getDefaultAPIUrl() {
|
|
45
|
+
return GCloudAPIService.defaultUrl;
|
|
46
|
+
}
|
|
35
47
|
}
|
|
36
48
|
//# sourceMappingURL=APIService.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"APIService.js","sourceRoot":"","sources":["../../../src/services/APIService/APIService.ts"],"names":[],"mappings":"AASA,OAAO,gBAAgB,MAAM,yCAAyC,CAAC;AAEvE;;;GAGG;AACH,MAAM,CAAC,OAAO,OAAO,UAAU;IAC7B;;;;;;OAMG;IACH,MAAM,CAAC,KAAK,CAAC,YAAY,CACvB,KAA4B;QAE5B,OAAO,MAAM,gBAAgB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IACxD,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CAAC,KAAK,CAAC,gBAAgB,CAC3B,KAA4B;QAE5B,OAAO,gBAAgB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IAClD,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,GAAW;QAC1B,gBAAgB,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAC/B,CAAC;CACF"}
|
|
1
|
+
{"version":3,"file":"APIService.js","sourceRoot":"","sources":["../../../src/services/APIService/APIService.ts"],"names":[],"mappings":"AASA,OAAO,gBAAgB,MAAM,yCAAyC,CAAC;AAEvE;;;GAGG;AACH,MAAM,CAAC,OAAO,OAAO,UAAU;IAC7B;;;;;;OAMG;IACH,MAAM,CAAC,KAAK,CAAC,YAAY,CACvB,KAA4B;QAE5B,OAAO,MAAM,gBAAgB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IACxD,CAAC;IAED;;;;;;OAMG;IACH,MAAM,CAAC,KAAK,CAAC,gBAAgB,CAC3B,KAA4B;QAE5B,OAAO,gBAAgB,CAAC,gBAAgB,CAAC,KAAK,CAAC,CAAC;IAClD,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,gBAAgB;QACrB,OAAO,gBAAgB,CAAC,MAAM,EAAE,CAAC;IACnC,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,SAAS,CAAC,GAAW;QAC1B,gBAAgB,CAAC,MAAM,CAAC,GAAG,CAAC,CAAC;IAC/B,CAAC;IAED;;OAEG;IACH,MAAM,CAAC,gBAAgB;QACrB,OAAO,gBAAgB,CAAC,UAAU,CAAC;IACrC,CAAC;CACF"}
|
|
@@ -40,12 +40,26 @@ export default class APIService {
|
|
|
40
40
|
return GCloudAPIService.projectDashboard(input);
|
|
41
41
|
}
|
|
42
42
|
|
|
43
|
+
/**
|
|
44
|
+
* Gets the current base URL for the API.
|
|
45
|
+
*/
|
|
46
|
+
static getCurrentAPIUrl(): string {
|
|
47
|
+
return GCloudAPIService.getUrl();
|
|
48
|
+
}
|
|
49
|
+
|
|
43
50
|
/**
|
|
44
51
|
* Sets the base URL for the API.
|
|
45
52
|
*
|
|
46
53
|
* @param url - The URL to be set for the API. This should include a trailing slash.
|
|
47
54
|
*/
|
|
48
|
-
static setAPIUrl(url: string) {
|
|
55
|
+
static setAPIUrl(url: string): void {
|
|
49
56
|
GCloudAPIService.setUrl(url);
|
|
50
57
|
}
|
|
58
|
+
|
|
59
|
+
/**
|
|
60
|
+
* Gets the default base URL for the API.
|
|
61
|
+
*/
|
|
62
|
+
static getDefaultAPIUrl(): string {
|
|
63
|
+
return GCloudAPIService.defaultUrl;
|
|
64
|
+
}
|
|
51
65
|
}
|
|
@@ -6,6 +6,13 @@ import type { ProjectDashboardInput, ProjectDashboardOutput } from '../../types/
|
|
|
6
6
|
*/
|
|
7
7
|
export default class GCloudAPIService {
|
|
8
8
|
#private;
|
|
9
|
+
static readonly defaultUrl: string;
|
|
10
|
+
/**
|
|
11
|
+
* Gets the current URL of the Google Cloud API.
|
|
12
|
+
*
|
|
13
|
+
* @returns the current URL of the Google Cloud API.
|
|
14
|
+
*/
|
|
15
|
+
static getUrl(): string;
|
|
9
16
|
/**
|
|
10
17
|
* Sets the URL of the Google Cloud API.
|
|
11
18
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GCloudAPIService.d.ts","sourceRoot":"","sources":["../../../src/services/GCloudAPIService/GCloudAPIService.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AAEzC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAgB;;
|
|
1
|
+
{"version":3,"file":"GCloudAPIService.d.ts","sourceRoot":"","sources":["../../../src/services/GCloudAPIService/GCloudAPIService.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,4BAA4B,CAAC;AAC9D,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AACzC,OAAO,KAAK,EACV,qBAAqB,EACrB,sBAAsB,EACvB,MAAM,iCAAiC,CAAC;AAEzC;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAgB;;IACnC,MAAM,CAAC,QAAQ,CAAC,UAAU,EAAE,MAAM,CAA2D;IAQ7F;;;;OAIG;IACH,MAAM,CAAC,MAAM,IAAI,MAAM;IAIvB;;;;OAIG;IACH,MAAM,CAAC,MAAM,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI;IAIhC;;;;OAIG;WACU,gBAAgB,CAC3B,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;;;OAIG;WACU,gBAAgB,CAC3B,KAAK,EAAE,qBAAqB,GAC3B,OAAO,CAAC,WAAW,CAAC,sBAAsB,CAAC,CAAC;IAI/C;;;;;;OAMG;mBACkB,IAAI;IAiBzB;;;;;OAKG;mBACkB,cAAc;CAYpC"}
|
|
@@ -3,11 +3,20 @@ import { DateService, ErrorUtils } from '@aneuhold/core-ts-lib';
|
|
|
3
3
|
* A service for interacting with the Google Cloud API service for personal projects.
|
|
4
4
|
*/
|
|
5
5
|
export default class GCloudAPIService {
|
|
6
|
+
static defaultUrl = 'https://gcloud-backend-926119935605.us-west1.run.app/';
|
|
6
7
|
/**
|
|
7
8
|
* The base URL of the Google Cloud API. For example, `something.com/api/`. It will include
|
|
8
9
|
* the trailing slash.
|
|
9
10
|
*/
|
|
10
|
-
static #baseUrl =
|
|
11
|
+
static #baseUrl = this.defaultUrl;
|
|
12
|
+
/**
|
|
13
|
+
* Gets the current URL of the Google Cloud API.
|
|
14
|
+
*
|
|
15
|
+
* @returns the current URL of the Google Cloud API.
|
|
16
|
+
*/
|
|
17
|
+
static getUrl() {
|
|
18
|
+
return this.#baseUrl;
|
|
19
|
+
}
|
|
11
20
|
/**
|
|
12
21
|
* Sets the URL of the Google Cloud API.
|
|
13
22
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"GCloudAPIService.js","sourceRoot":"","sources":["../../../src/services/GCloudAPIService/GCloudAPIService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAWhE;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAgB;IACnC;;;OAGG;IACH,MAAM,CAAC,QAAQ,GAAW,
|
|
1
|
+
{"version":3,"file":"GCloudAPIService.js","sourceRoot":"","sources":["../../../src/services/GCloudAPIService/GCloudAPIService.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,uBAAuB,CAAC;AAWhE;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAgB;IACnC,MAAM,CAAU,UAAU,GAAW,uDAAuD,CAAC;IAE7F;;;OAGG;IACH,MAAM,CAAC,QAAQ,GAAW,IAAI,CAAC,UAAU,CAAC;IAE1C;;;;OAIG;IACH,MAAM,CAAC,MAAM;QACX,OAAO,IAAI,CAAC,QAAQ,CAAC;IACvB,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,MAAM,CAAC,GAAW;QACvB,IAAI,CAAC,QAAQ,GAAG,GAAG,CAAC;IACtB,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,KAAK,CAAC,gBAAgB,CAC3B,KAA4B;QAE5B,OAAO,IAAI,CAAC,IAAI,CAAgD,mBAAmB,EAAE,KAAK,CAAC,CAAC;IAC9F,CAAC;IAED;;;;OAIG;IACH,MAAM,CAAC,KAAK,CAAC,gBAAgB,CAC3B,KAA4B;QAE5B,OAAO,IAAI,CAAC,IAAI,CAAgD,mBAAmB,EAAE,KAAK,CAAC,CAAC;IAC9F,CAAC;IAED;;;;;;OAMG;IACK,MAAM,CAAC,KAAK,CAAC,IAAI,CACvB,OAAe,EACf,KAAa;QAEb,MAAM,QAAQ,GAAG,MAAM,KAAK,CAAC,IAAI,CAAC,QAAQ,GAAG,OAAO,EAAE;YACpD,MAAM,EAAE,MAAM;YACd,OAAO,EAAE;gBACP,UAAU,EAAE,YAAY;gBACxB,cAAc,EAAE,kBAAkB;gBAClC,MAAM,EAAE,kBAAkB;aAC3B;YACD,IAAI,EAAE,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC;SAC5B,CAAC,CAAC;QACH,MAAM,eAAe,GAAG,MAAM,IAAI,CAAC,cAAc,CAAU,QAAQ,CAAC,CAAC;QACrE,OAAO,eAAe,CAAC;IACzB,CAAC;IAED;;;;;OAKG;IACK,MAAM,CAAC,KAAK,CAAC,cAAc,CAAU,QAAkB;QAC7D,IAAI,CAAC;YACH,MAAM,IAAI,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;YACnC,OAAO,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,WAAW,CAAC,WAAW,CAAyB,CAAC;QAC3E,CAAC;QAAC,OAAO,KAAK,EAAE,CAAC;YACf,OAAO;gBACL,OAAO,EAAE,KAAK;gBACd,MAAM,EAAE,CAAC,0BAA0B,EAAE,UAAU,CAAC,cAAc,CAAC,KAAK,CAAC,CAAC;gBACtE,IAAI,EAAE,EAAa;aACpB,CAAC;QACJ,CAAC;IACH,CAAC"}
|
|
@@ -13,11 +13,22 @@ import type {
|
|
|
13
13
|
* A service for interacting with the Google Cloud API service for personal projects.
|
|
14
14
|
*/
|
|
15
15
|
export default class GCloudAPIService {
|
|
16
|
+
static readonly defaultUrl: string = 'https://gcloud-backend-926119935605.us-west1.run.app/';
|
|
17
|
+
|
|
16
18
|
/**
|
|
17
19
|
* The base URL of the Google Cloud API. For example, `something.com/api/`. It will include
|
|
18
20
|
* the trailing slash.
|
|
19
21
|
*/
|
|
20
|
-
static #baseUrl: string =
|
|
22
|
+
static #baseUrl: string = this.defaultUrl;
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* Gets the current URL of the Google Cloud API.
|
|
26
|
+
*
|
|
27
|
+
* @returns the current URL of the Google Cloud API.
|
|
28
|
+
*/
|
|
29
|
+
static getUrl(): string {
|
|
30
|
+
return this.#baseUrl;
|
|
31
|
+
}
|
|
21
32
|
|
|
22
33
|
/**
|
|
23
34
|
* Sets the URL of the Google Cloud API.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ProjectDashboard.d.ts","sourceRoot":"","sources":["../../src/types/ProjectDashboard.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,mBAAmB,EACnB,kBAAkB,EAClB,qBAAqB,EACrB,OAAO,EACR,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEtD;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC,GAAG,CAAC,EAAE;QACJ;;WAEG;QACH,YAAY,CAAC,EAAE,OAAO,CAAC;QACvB;;;WAGG;QACH,UAAU,CAAC,EAAE,OAAO,CAAC;QACrB;;WAEG;QACH,KAAK,CAAC,EAAE,OAAO,CAAC;QAChB;;WAEG;QACH,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB;;WAEG;QACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;QAC9B;;WAEG;QACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;KAClC,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;QACxB;;WAEG;QACH,mBAAmB,CAAC,EAAE,kBAAkB,EAAE,CAAC;QAC3C;;WAEG;QACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;KAClD,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,UAAU,CAAC,EAAE,mBAAmB,CAAC;QACjC;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;QACxB;;WAEG;QACH,mBAAmB,CAAC,EAAE,kBAAkB,EAAE,CAAC;QAC3C;;WAEG;QACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;KAClD,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;KACzB,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE,IAAI,CAAC;IACb,OAAO,EAAE,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"ProjectDashboard.d.ts","sourceRoot":"","sources":["../../src/types/ProjectDashboard.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EACV,aAAa,EACb,mBAAmB,EACnB,kBAAkB,EAClB,qBAAqB,EACrB,OAAO,EACR,MAAM,0BAA0B,CAAC;AAClC,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,mBAAmB,CAAC;AAEtD;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC,GAAG,CAAC,EAAE;QACJ;;WAEG;QACH,YAAY,CAAC,EAAE,OAAO,CAAC;QACvB;;;WAGG;QACH,UAAU,CAAC,EAAE,OAAO,CAAC;QACrB;;WAEG;QACH,KAAK,CAAC,EAAE,OAAO,CAAC;QAChB;;WAEG;QACH,eAAe,CAAC,EAAE,MAAM,CAAC;QACzB;;WAEG;QACH,mBAAmB,CAAC,EAAE,OAAO,CAAC;QAC9B;;WAEG;QACH,sBAAsB,CAAC,EAAE,OAAO,CAAC;KAClC,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;QACxB;;WAEG;QACH,mBAAmB,CAAC,EAAE,kBAAkB,EAAE,CAAC;QAC3C;;WAEG;QACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;KAClD,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,UAAU,CAAC,EAAE,mBAAmB,CAAC;QACjC;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;QACxB;;WAEG;QACH,mBAAmB,CAAC,EAAE,kBAAkB,EAAE,CAAC;QAC3C;;WAEG;QACH,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;KAClD,CAAC;IACF,MAAM,CAAC,EAAE;QACP;;WAEG;QACH,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;KACzB,CAAC;CACH;AAED;;GAEG;AACH,MAAM,WAAW,qBAAqB;IACpC,MAAM,EAAE,IAAI,CAAC;IACb,OAAO,EAAE,uBAAuB,CAAC;IACjC,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,sBAAsB;IACrC,YAAY,CAAC,EAAE,YAAY,CAAC;IAC5B,UAAU,CAAC,EAAE,mBAAmB,CAAC;IACjC,KAAK,CAAC,EAAE,aAAa,EAAE,CAAC;IACxB,aAAa,CAAC,EAAE,OAAO,EAAE,CAAC;IAC1B,gBAAgB,CAAC,EAAE,OAAO,GAAG,IAAI,CAAC;IAClC,mBAAmB,CAAC,EAAE,kBAAkB,EAAE,CAAC;IAC3C,sBAAsB,CAAC,EAAE,qBAAqB,EAAE,CAAC;CAClD"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { UUID } from 'crypto';
|
|
2
|
+
import type { ProjectDashboardOutput } from './ProjectDashboard.js';
|
|
3
|
+
/**
|
|
4
|
+
* The data each client is expected to send over with a request. For example on the client side:
|
|
5
|
+
*
|
|
6
|
+
* ```
|
|
7
|
+
const socket = io('http://localhost:8080', {
|
|
8
|
+
auth: {
|
|
9
|
+
apiKey: 'your-api-key' // Replace with your actual API key
|
|
10
|
+
}
|
|
11
|
+
});
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
14
|
+
export type WebSocketHandshakeAuth = {
|
|
15
|
+
apiKey?: UUID;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* Nothing for now, except a test event if wanted.
|
|
19
|
+
*/
|
|
20
|
+
export type DashboardWebSocketClientToServerEvents = {
|
|
21
|
+
test: (data: string) => void;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* The events that the server can send to clients.
|
|
25
|
+
*/
|
|
26
|
+
export type DashboardWebSocketServerToClientEvents = {
|
|
27
|
+
rootPostResult: (data: ProjectDashboardOutput) => void;
|
|
28
|
+
};
|
|
29
|
+
//# sourceMappingURL=WebSocket.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WebSocket.d.ts","sourceRoot":"","sources":["../../src/types/WebSocket.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,QAAQ,CAAC;AACnC,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,uBAAuB,CAAC;AAEpE;;;;;;;;;;GAUG;AACH,MAAM,MAAM,sBAAsB,GAAG;IACnC,MAAM,CAAC,EAAE,IAAI,CAAC;CACf,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,sCAAsC,GAAG;IACnD,IAAI,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,IAAI,CAAC;CAC9B,CAAC;AAEF;;GAEG;AACH,MAAM,MAAM,sCAAsC,GAAG;IACnD,cAAc,EAAE,CAAC,IAAI,EAAE,sBAAsB,KAAK,IAAI,CAAC;CACxD,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"WebSocket.js","sourceRoot":"","sources":["../../src/types/WebSocket.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import type { UUID } from 'crypto';
|
|
2
|
+
import type { ProjectDashboardOutput } from './ProjectDashboard.js';
|
|
3
|
+
|
|
4
|
+
/**
|
|
5
|
+
* The data each client is expected to send over with a request. For example on the client side:
|
|
6
|
+
*
|
|
7
|
+
* ```
|
|
8
|
+
const socket = io('http://localhost:8080', {
|
|
9
|
+
auth: {
|
|
10
|
+
apiKey: 'your-api-key' // Replace with your actual API key
|
|
11
|
+
}
|
|
12
|
+
});
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
export type WebSocketHandshakeAuth = {
|
|
16
|
+
apiKey?: UUID;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* Nothing for now, except a test event if wanted.
|
|
21
|
+
*/
|
|
22
|
+
export type DashboardWebSocketClientToServerEvents = {
|
|
23
|
+
test: (data: string) => void;
|
|
24
|
+
};
|
|
25
|
+
|
|
26
|
+
/**
|
|
27
|
+
* The events that the server can send to clients.
|
|
28
|
+
*/
|
|
29
|
+
export type DashboardWebSocketServerToClientEvents = {
|
|
30
|
+
rootPostResult: (data: ProjectDashboardOutput) => void;
|
|
31
|
+
};
|
package/package.json
CHANGED
|
@@ -2,9 +2,9 @@
|
|
|
2
2
|
"name": "@aneuhold/core-ts-api-lib",
|
|
3
3
|
"author": "Anton G. Neuhold Jr.",
|
|
4
4
|
"license": "MIT",
|
|
5
|
-
"version": "3.0.
|
|
5
|
+
"version": "3.0.8",
|
|
6
6
|
"description": "A library for interacting with the backend and defining the backend API for personal projects.",
|
|
7
|
-
"packageManager": "pnpm@10.
|
|
7
|
+
"packageManager": "pnpm@10.25.0",
|
|
8
8
|
"type": "module",
|
|
9
9
|
"scripts": {
|
|
10
10
|
"build": "rimraf lib && pnpm build:withoutClean",
|
|
@@ -71,15 +71,15 @@
|
|
|
71
71
|
"TypeScript"
|
|
72
72
|
],
|
|
73
73
|
"dependencies": {
|
|
74
|
-
"@aneuhold/core-ts-db-lib": "^4.0.
|
|
75
|
-
"@aneuhold/core-ts-lib": "^2.3.
|
|
74
|
+
"@aneuhold/core-ts-db-lib": "^4.0.4",
|
|
75
|
+
"@aneuhold/core-ts-lib": "^2.3.16",
|
|
76
76
|
"bson": "^7.0.0"
|
|
77
77
|
},
|
|
78
78
|
"devDependencies": {
|
|
79
|
-
"@aneuhold/local-npm-registry": "^0.2.
|
|
79
|
+
"@aneuhold/local-npm-registry": "^0.2.23",
|
|
80
80
|
"@aneuhold/main-scripts": "^2.8.0",
|
|
81
|
-
"@types/node": "^
|
|
82
|
-
"eslint": "^9.39.
|
|
81
|
+
"@types/node": "^25.0.2",
|
|
82
|
+
"eslint": "^9.39.2",
|
|
83
83
|
"jsr": "^0.13.5",
|
|
84
84
|
"prettier": "^3.7.4",
|
|
85
85
|
"rimraf": "^6.1.2",
|