@twin.org/telemetry-service 0.0.1-next.8 → 0.0.1

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.
@@ -29,7 +29,7 @@ function generateRestRoutesTelemetry(baseRouteName, componentName) {
29
29
  summary: "Create a telemetry metric",
30
30
  tag: tagsTelemetry[0].name,
31
31
  method: "POST",
32
- path: `${baseRouteName}/metric/`,
32
+ path: `${baseRouteName}/metric`,
33
33
  handler: async (httpRequestContext, request) => telemetryCreateMetric(httpRequestContext, componentName, request),
34
34
  requestType: {
35
35
  type: "ITelemetryCreateMetricRequest",
@@ -223,7 +223,7 @@ function generateRestRoutesTelemetry(baseRouteName, componentName) {
223
223
  summary: "Get a list of the telemetry metrics",
224
224
  tag: tagsTelemetry[0].name,
225
225
  method: "GET",
226
- path: `${baseRouteName}/metric/`,
226
+ path: `${baseRouteName}/metric`,
227
227
  handler: async (httpRequestContext, request) => telemetryMetricList(httpRequestContext, componentName, request),
228
228
  requestType: {
229
229
  type: "ITelemetryListRequest",
@@ -437,7 +437,7 @@ async function telemetryMetricList(httpRequestContext, componentName, request) {
437
437
  core.Guards.object(ROUTES_SOURCE, "request", request);
438
438
  core.Guards.object(ROUTES_SOURCE, "request.query", request.query);
439
439
  const component = core.ComponentFactory.get(componentName);
440
- const itemsAndCursor = await component.query(request?.query.type, request?.query?.cursor, core.Coerce.number(request?.query?.pageSize));
440
+ const itemsAndCursor = await component.query(core.Coerce.number(request?.query?.type), request?.query?.cursor, core.Coerce.number(request?.query?.pageSize));
441
441
  return {
442
442
  body: itemsAndCursor
443
443
  };
@@ -27,7 +27,7 @@ function generateRestRoutesTelemetry(baseRouteName, componentName) {
27
27
  summary: "Create a telemetry metric",
28
28
  tag: tagsTelemetry[0].name,
29
29
  method: "POST",
30
- path: `${baseRouteName}/metric/`,
30
+ path: `${baseRouteName}/metric`,
31
31
  handler: async (httpRequestContext, request) => telemetryCreateMetric(httpRequestContext, componentName, request),
32
32
  requestType: {
33
33
  type: "ITelemetryCreateMetricRequest",
@@ -221,7 +221,7 @@ function generateRestRoutesTelemetry(baseRouteName, componentName) {
221
221
  summary: "Get a list of the telemetry metrics",
222
222
  tag: tagsTelemetry[0].name,
223
223
  method: "GET",
224
- path: `${baseRouteName}/metric/`,
224
+ path: `${baseRouteName}/metric`,
225
225
  handler: async (httpRequestContext, request) => telemetryMetricList(httpRequestContext, componentName, request),
226
226
  requestType: {
227
227
  type: "ITelemetryListRequest",
@@ -435,7 +435,7 @@ async function telemetryMetricList(httpRequestContext, componentName, request) {
435
435
  Guards.object(ROUTES_SOURCE, "request", request);
436
436
  Guards.object(ROUTES_SOURCE, "request.query", request.query);
437
437
  const component = ComponentFactory.get(componentName);
438
- const itemsAndCursor = await component.query(request?.query.type, request?.query?.cursor, Coerce.number(request?.query?.pageSize));
438
+ const itemsAndCursor = await component.query(Coerce.number(request?.query?.type), request?.query?.cursor, Coerce.number(request?.query?.pageSize));
439
439
  return {
440
440
  body: itemsAndCursor
441
441
  };
package/docs/changelog.md CHANGED
@@ -1,5 +1,75 @@
1
1
  # @twin.org/telemetry-service - Changelog
2
2
 
3
- ## v0.0.1-next.8
3
+ ## 0.0.1 (2025-07-04)
4
+
5
+
6
+ ### Features
7
+
8
+ * release to production ([df2151d](https://github.com/twinfoundation/telemetry/commit/df2151d24844fd2c3e6092ce3a6f888ac16219a0))
9
+
10
+
11
+ ### Dependencies
12
+
13
+ * The following workspace dependencies were updated
14
+ * dependencies
15
+ * @twin.org/telemetry-models bumped from ^0.0.0 to ^0.0.1
16
+
17
+ ## [0.0.1-next.18](https://github.com/twinfoundation/telemetry/compare/telemetry-service-v0.0.1-next.17...telemetry-service-v0.0.1-next.18) (2025-06-20)
18
+
19
+
20
+ ### Bug Fixes
21
+
22
+ * query params force coercion ([ec7999e](https://github.com/twinfoundation/telemetry/commit/ec7999eadb66c65585efa19f3ce4cabb50eed761))
23
+
24
+
25
+ ### Dependencies
26
+
27
+ * The following workspace dependencies were updated
28
+ * dependencies
29
+ * @twin.org/telemetry-models bumped from 0.0.1-next.17 to 0.0.1-next.18
30
+
31
+ ## [0.0.1-next.17](https://github.com/twinfoundation/telemetry/compare/telemetry-service-v0.0.1-next.16...telemetry-service-v0.0.1-next.17) (2025-06-12)
32
+
33
+
34
+ ### Features
35
+
36
+ * update dependencies ([0e55c48](https://github.com/twinfoundation/telemetry/commit/0e55c48de4139c6fe66b823101ca17973e60847c))
37
+
38
+
39
+ ### Dependencies
40
+
41
+ * The following workspace dependencies were updated
42
+ * dependencies
43
+ * @twin.org/telemetry-models bumped from 0.0.1-next.16 to 0.0.1-next.17
44
+
45
+ ## [0.0.1-next.16](https://github.com/twinfoundation/telemetry/compare/telemetry-service-v0.0.1-next.15...telemetry-service-v0.0.1-next.16) (2025-04-17)
46
+
47
+
48
+ ### Features
49
+
50
+ * use shared store mechanism ([#7](https://github.com/twinfoundation/telemetry/issues/7)) ([806fe2c](https://github.com/twinfoundation/telemetry/commit/806fe2c2b7653d6b949c27ebf57bd13c3e040242))
51
+
52
+
53
+ ### Dependencies
54
+
55
+ * The following workspace dependencies were updated
56
+ * dependencies
57
+ * @twin.org/telemetry-models bumped from 0.0.1-next.15 to 0.0.1-next.16
58
+
59
+ ## [0.0.1-next.15](https://github.com/twinfoundation/telemetry/compare/telemetry-service-v0.0.1-next.14...telemetry-service-v0.0.1-next.15) (2025-03-28)
60
+
61
+
62
+ ### Bug Fixes
63
+
64
+ * Update metric endpoint paths by removing trailing slashes and query type as string ([#3](https://github.com/twinfoundation/telemetry/issues/3)) ([b386ca5](https://github.com/twinfoundation/telemetry/commit/b386ca55404aa933ad8917f82a7f0e588593fcc8))
65
+
66
+
67
+ ### Dependencies
68
+
69
+ * The following workspace dependencies were updated
70
+ * dependencies
71
+ * @twin.org/telemetry-models bumped from 0.0.1-next.14 to 0.0.1-next.15
72
+
73
+ ## v0.0.1-next.14
4
74
 
5
75
  - Initial Release