@octaviaflow/telemetry-attributes 1.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md ADDED
@@ -0,0 +1,165 @@
1
+ # OctaviaFlow Telemetry Attributes
2
+
3
+ > Attribute definitions and constants for OctaviaFlow Telemetry
4
+
5
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
6
+ [![NPM version](https://img.shields.io/npm/v/%40octaviaflow/telemetry-attributes.svg)](https://npmjs.org/package/@octaviaflow/telemetry-attributes)
7
+
8
+ ## Overview
9
+
10
+ This package provides standardized attribute definitions and constants used by the OctaviaFlow Telemetry system. It defines the structure and naming conventions for telemetry data across different collection scopes.
11
+
12
+ ## Installation
13
+
14
+ ```bash
15
+ npm install @octaviaflow/telemetry-attributes
16
+ ```
17
+
18
+ ## Usage
19
+
20
+ ```typescript
21
+ import {
22
+ JsScopeAttributes,
23
+ JsxScopeAttributes,
24
+ NpmScopeAttributes,
25
+ WcScopeAttributes,
26
+ CustomResourceAttributes,
27
+ LogsAttributes,
28
+ ALL_SCOPE_NAMES
29
+ } from '@octaviaflow/telemetry-attributes';
30
+
31
+ // Use scope names
32
+ console.log(JsScopeAttributes.SCOPE_NAME); // 'js'
33
+ console.log(JsxScopeAttributes.SCOPE_NAME); // 'jsx'
34
+
35
+ // Use metric names
36
+ console.log(JsScopeAttributes.JS_FUNCTION_METRIC); // 'js.function'
37
+ console.log(JsxScopeAttributes.JSX_ELEMENT_METRIC); // 'jsx.element'
38
+
39
+ // Use attribute names
40
+ console.log(JsScopeAttributes.FUNCTION_NAME); // 'js.function.name'
41
+ console.log(JsxScopeAttributes.ELEMENT_NAME); // 'jsx.element.name'
42
+ ```
43
+
44
+ ## Available Scopes
45
+
46
+ ### JavaScript Scope (`JsScopeAttributes`)
47
+
48
+ Attributes for JavaScript token and function analysis:
49
+
50
+ ```typescript
51
+ JsScopeAttributes.SCOPE_NAME // 'js'
52
+ JsScopeAttributes.JS_TOKEN_METRIC // 'js.token'
53
+ JsScopeAttributes.JS_FUNCTION_METRIC // 'js.function'
54
+ JsScopeAttributes.TOKEN_NAME // 'js.token.name'
55
+ JsScopeAttributes.TOKEN_ACCESS_PATH // 'js.token.accessPath'
56
+ JsScopeAttributes.TOKEN_MODULE_SPECIFIER // 'js.token.module.specifier'
57
+ JsScopeAttributes.FUNCTION_NAME // 'js.function.name'
58
+ JsScopeAttributes.FUNCTION_ACCESS_PATH // 'js.function.accessPath'
59
+ JsScopeAttributes.FUNCTION_ARGUMENT_VALUES // 'js.function.arguments.values'
60
+ JsScopeAttributes.FUNCTION_MODULE_SPECIFIER // 'js.function.module.specifier'
61
+ ```
62
+
63
+ ### JSX Scope (`JsxScopeAttributes`)
64
+
65
+ Attributes for React component analysis:
66
+
67
+ ```typescript
68
+ JsxScopeAttributes.SCOPE_NAME // 'jsx'
69
+ JsxScopeAttributes.JSX_ELEMENT_METRIC // 'jsx.element'
70
+ JsxScopeAttributes.ELEMENT_NAME // 'jsx.element.name'
71
+ JsxScopeAttributes.ELEMENT_ATTRIBUTE_NAMES // 'jsx.element.attributeNames'
72
+ JsxScopeAttributes.ELEMENT_ATTRIBUTE_VALUES // 'jsx.element.attributeValues'
73
+ JsxScopeAttributes.ELEMENT_MODULE_SPECIFIER // 'jsx.element.module.specifier'
74
+ ```
75
+
76
+ ### NPM Scope (`NpmScopeAttributes`)
77
+
78
+ Attributes for NPM dependency analysis:
79
+
80
+ ```typescript
81
+ NpmScopeAttributes.SCOPE_NAME // 'npm'
82
+ NpmScopeAttributes.NPM_DEPENDENCY_METRIC // 'npm.dependency'
83
+ NpmScopeAttributes.DEPENDENCY_NAME // 'npm.dependency.name'
84
+ NpmScopeAttributes.DEPENDENCY_VERSION // 'npm.dependency.version'
85
+ NpmScopeAttributes.DEPENDENCY_TYPE // 'npm.dependency.type'
86
+ NpmScopeAttributes.PROJECT_NAME // 'npm.project.name'
87
+ NpmScopeAttributes.PROJECT_VERSION // 'npm.project.version'
88
+ ```
89
+
90
+ ### Web Components Scope (`WcScopeAttributes`)
91
+
92
+ Attributes for Web Component analysis:
93
+
94
+ ```typescript
95
+ WcScopeAttributes.SCOPE_NAME // 'wc'
96
+ WcScopeAttributes.WC_ELEMENT_METRIC // 'wc.element'
97
+ WcScopeAttributes.ELEMENT_NAME // 'wc.element.name'
98
+ WcScopeAttributes.ELEMENT_ATTRIBUTE_NAMES // 'wc.element.attributeNames'
99
+ WcScopeAttributes.ELEMENT_ATTRIBUTE_VALUES // 'wc.element.attributeValues'
100
+ WcScopeAttributes.ELEMENT_MODULE_SPECIFIER // 'wc.element.module.specifier'
101
+ ```
102
+
103
+ ### Custom Resource Attributes (`CustomResourceAttributes`)
104
+
105
+ octaviaflow-specific resource attributes:
106
+
107
+ ```typescript
108
+ CustomResourceAttributes.octaviaflow_PROJECT_ID // 'octaviaflow.project.id'
109
+ CustomResourceAttributes.octaviaflow_PROJECT_NAME // 'octaviaflow.project.name'
110
+ CustomResourceAttributes.octaviaflow_PROJECT_VERSION // 'octaviaflow.project.version'
111
+ CustomResourceAttributes.octaviaflow_COLLECTION_TIMESTAMP // 'octaviaflow.collection.timestamp'
112
+ CustomResourceAttributes.octaviaflow_STORAGE_TYPE // 'octaviaflow.storage.type'
113
+ CustomResourceAttributes.octaviaflow_STORAGE_LOCATION // 'octaviaflow.storage.location'
114
+ ```
115
+
116
+ ### Logs Attributes (`LogsAttributes`)
117
+
118
+ Attributes for logging and error tracking:
119
+
120
+ ```typescript
121
+ LogsAttributes.LOG_LEVEL // 'log.level'
122
+ LogsAttributes.LOG_MESSAGE // 'log.message'
123
+ LogsAttributes.LOG_TIMESTAMP // 'log.timestamp'
124
+ LogsAttributes.LOG_SOURCE // 'log.source'
125
+ LogsAttributes.LOG_FILE_PATH // 'log.file.path'
126
+ LogsAttributes.LOG_LINE_NUMBER // 'log.line.number'
127
+ LogsAttributes.LOG_FUNCTION_NAME // 'log.function.name'
128
+ LogsAttributes.LOG_ERROR_TYPE // 'log.error.type'
129
+ LogsAttributes.LOG_ERROR_MESSAGE // 'log.error.message'
130
+ LogsAttributes.LOG_ERROR_STACK // 'log.error.stack'
131
+ ```
132
+
133
+ ## Utility Constants
134
+
135
+ ```typescript
136
+ import { ALL_SCOPE_NAMES } from '@octaviaflow/telemetry-attributes';
137
+
138
+ console.log(ALL_SCOPE_NAMES); // ['js', 'jsx', 'npm', 'wc']
139
+ ```
140
+
141
+ ## Integration Example
142
+
143
+ ```typescript
144
+ import { JsScopeAttributes } from '@octaviaflow/telemetry-attributes';
145
+
146
+ // Create telemetry data with standardized attributes
147
+ const telemetryData = {
148
+ scope: JsScopeAttributes.SCOPE_NAME,
149
+ metric: JsScopeAttributes.JS_FUNCTION_METRIC,
150
+ attributes: {
151
+ [JsScopeAttributes.FUNCTION_NAME]: 'useAnalytics',
152
+ [JsScopeAttributes.FUNCTION_MODULE_SPECIFIER]: '@octaviaflow/analytics',
153
+ [JsScopeAttributes.FUNCTION_ARGUMENT_VALUES]: ['track', 'user_action']
154
+ }
155
+ };
156
+ ```
157
+
158
+ ## Related Packages
159
+
160
+ - [`@octaviaflow/telemetry-collector`](../octaviaflow-telemetry-collector) - Main telemetry collection tool
161
+ - [`@octaviaflow/telemetry-config-schema`](../octaviaflow-telemetry-config-schema) - Configuration schema and validation
162
+
163
+ ## License
164
+
165
+ MIT © octaviaflow
@@ -0,0 +1,9 @@
1
+ export declare const CustomResourceAttributes: Readonly<{
2
+ octaviaflow_PROJECT_ID: "octaviaflow.project.id";
3
+ octaviaflow_PROJECT_NAME: "octaviaflow.project.name";
4
+ octaviaflow_PROJECT_VERSION: "octaviaflow.project.version";
5
+ octaviaflow_COLLECTION_TIMESTAMP: "octaviaflow.collection.timestamp";
6
+ octaviaflow_STORAGE_TYPE: "octaviaflow.storage.type";
7
+ octaviaflow_STORAGE_LOCATION: "octaviaflow.storage.location";
8
+ }>;
9
+ //# sourceMappingURL=custom-resource-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"custom-resource-attributes.d.ts","sourceRoot":"","sources":["../../src/main/custom-resource-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,wBAAwB;;;;;;;EAUnC,CAAC"}
@@ -0,0 +1,18 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const CustomResourceAttributes = Object.freeze({
8
+ //
9
+ // Custom resource attributes for octaviaflow telemetry
10
+ //
11
+ octaviaflow_PROJECT_ID: 'octaviaflow.project.id',
12
+ octaviaflow_PROJECT_NAME: 'octaviaflow.project.name',
13
+ octaviaflow_PROJECT_VERSION: 'octaviaflow.project.version',
14
+ octaviaflow_COLLECTION_TIMESTAMP: 'octaviaflow.collection.timestamp',
15
+ octaviaflow_STORAGE_TYPE: 'octaviaflow.storage.type',
16
+ octaviaflow_STORAGE_LOCATION: 'octaviaflow.storage.location'
17
+ });
18
+ //# sourceMappingURL=custom-resource-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"custom-resource-attributes.js","sourceRoot":"","sources":["../../src/main/custom-resource-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,wBAAwB,GAAG,MAAM,CAAC,MAAM,CAAC;IACpD,EAAE;IACF,uDAAuD;IACvD,EAAE;IACF,sBAAsB,EAAE,wBAAwB;IAChD,wBAAwB,EAAE,0BAA0B;IACpD,2BAA2B,EAAE,6BAA6B;IAC1D,gCAAgC,EAAE,kCAAkC;IACpE,wBAAwB,EAAE,0BAA0B;IACpD,4BAA4B,EAAE,8BAA8B;CAC7D,CAAC,CAAC"}
@@ -0,0 +1,14 @@
1
+ import { CustomResourceAttributes } from './custom-resource-attributes.js';
2
+ import { JsScopeAttributes } from './js-scope-attributes.js';
3
+ import { JsxScopeAttributes } from './jsx-scope-attributes.js';
4
+ import { LogsAttributes } from './logs-attributes.js';
5
+ import { NpmScopeAttributes } from './npm-scope-attributes.js';
6
+ import { WcScopeAttributes } from './wc-scope-attributes.js';
7
+ export { CustomResourceAttributes };
8
+ export { JsScopeAttributes };
9
+ export { JsxScopeAttributes };
10
+ export { NpmScopeAttributes };
11
+ export { WcScopeAttributes };
12
+ export { LogsAttributes };
13
+ export declare const ALL_SCOPE_NAMES: ("js" | "jsx" | "npm" | "wc")[];
14
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/main/index.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAC3E,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAE7D,OAAO,EAAE,wBAAwB,EAAE,CAAC;AACpC,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AAC9B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AAC9B,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAC;AAE1B,eAAO,MAAM,eAAe,iCAK3B,CAAC"}
@@ -0,0 +1,25 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ import { CustomResourceAttributes } from './custom-resource-attributes.js';
8
+ import { JsScopeAttributes } from './js-scope-attributes.js';
9
+ import { JsxScopeAttributes } from './jsx-scope-attributes.js';
10
+ import { LogsAttributes } from './logs-attributes.js';
11
+ import { NpmScopeAttributes } from './npm-scope-attributes.js';
12
+ import { WcScopeAttributes } from './wc-scope-attributes.js';
13
+ export { CustomResourceAttributes };
14
+ export { JsScopeAttributes };
15
+ export { JsxScopeAttributes };
16
+ export { NpmScopeAttributes };
17
+ export { WcScopeAttributes };
18
+ export { LogsAttributes };
19
+ export const ALL_SCOPE_NAMES = [
20
+ JsScopeAttributes.SCOPE_NAME,
21
+ JsxScopeAttributes.SCOPE_NAME,
22
+ NpmScopeAttributes.SCOPE_NAME,
23
+ WcScopeAttributes.SCOPE_NAME
24
+ ];
25
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/main/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,wBAAwB,EAAE,MAAM,iCAAiC,CAAC;AAC3E,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAC7D,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AACtD,OAAO,EAAE,kBAAkB,EAAE,MAAM,2BAA2B,CAAC;AAC/D,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAE7D,OAAO,EAAE,wBAAwB,EAAE,CAAC;AACpC,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AAC9B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AAC9B,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,OAAO,EAAE,cAAc,EAAE,CAAC;AAE1B,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,iBAAiB,CAAC,UAAU;IAC5B,kBAAkB,CAAC,UAAU;IAC7B,kBAAkB,CAAC,UAAU;IAC7B,iBAAiB,CAAC,UAAU;CAC7B,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const JsScopeAttributes: Readonly<{
2
+ SCOPE_NAME: "js";
3
+ JS_TOKEN_METRIC: "js.token";
4
+ JS_FUNCTION_METRIC: "js.function";
5
+ TOKEN_NAME: "js.token.name";
6
+ TOKEN_ACCESS_PATH: "js.token.accessPath";
7
+ TOKEN_MODULE_SPECIFIER: "js.token.module.specifier";
8
+ FUNCTION_NAME: "js.function.name";
9
+ FUNCTION_ACCESS_PATH: "js.function.accessPath";
10
+ FUNCTION_ARGUMENT_VALUES: "js.function.arguments.values";
11
+ FUNCTION_MODULE_SPECIFIER: "js.function.module.specifier";
12
+ }>;
13
+ //# sourceMappingURL=js-scope-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"js-scope-attributes.d.ts","sourceRoot":"","sources":["../../src/main/js-scope-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,iBAAiB;;;;;;;;;;;EA0B5B,CAAC"}
@@ -0,0 +1,31 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const JsScopeAttributes = Object.freeze({
8
+ //
9
+ // General scope attributes
10
+ //
11
+ SCOPE_NAME: 'js',
12
+ //
13
+ // JS scope metrics
14
+ //
15
+ JS_TOKEN_METRIC: 'js.token',
16
+ JS_FUNCTION_METRIC: 'js.function',
17
+ //
18
+ // Attributes relating to a js token
19
+ //
20
+ TOKEN_NAME: 'js.token.name',
21
+ TOKEN_ACCESS_PATH: 'js.token.accessPath',
22
+ TOKEN_MODULE_SPECIFIER: 'js.token.module.specifier',
23
+ //
24
+ // Attributes relating to a js function
25
+ //
26
+ FUNCTION_NAME: 'js.function.name',
27
+ FUNCTION_ACCESS_PATH: 'js.function.accessPath',
28
+ FUNCTION_ARGUMENT_VALUES: 'js.function.arguments.values',
29
+ FUNCTION_MODULE_SPECIFIER: 'js.function.module.specifier'
30
+ });
31
+ //# sourceMappingURL=js-scope-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"js-scope-attributes.js","sourceRoot":"","sources":["../../src/main/js-scope-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC7C,EAAE;IACF,2BAA2B;IAC3B,EAAE;IACF,UAAU,EAAE,IAAI;IAEhB,EAAE;IACF,mBAAmB;IACnB,EAAE;IACF,eAAe,EAAE,UAAU;IAC3B,kBAAkB,EAAE,aAAa;IAEjC,EAAE;IACF,oCAAoC;IACpC,EAAE;IACF,UAAU,EAAE,eAAe;IAC3B,iBAAiB,EAAE,qBAAqB;IACxC,sBAAsB,EAAE,2BAA2B;IAEnD,EAAE;IACF,uCAAuC;IACvC,EAAE;IACF,aAAa,EAAE,kBAAkB;IACjC,oBAAoB,EAAE,wBAAwB;IAC9C,wBAAwB,EAAE,8BAA8B;IACxD,yBAAyB,EAAE,8BAA8B;CAC1D,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ export declare const JsxScopeAttributes: Readonly<{
2
+ SCOPE_NAME: "jsx";
3
+ JSX_ELEMENT_METRIC: "jsx.element";
4
+ ELEMENT_NAME: "jsx.element.name";
5
+ ELEMENT_ATTRIBUTE_NAMES: "jsx.element.attributeNames";
6
+ ELEMENT_ATTRIBUTE_VALUES: "jsx.element.attributeValues";
7
+ ELEMENT_MODULE_SPECIFIER: "jsx.element.module.specifier";
8
+ }>;
9
+ //# sourceMappingURL=jsx-scope-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jsx-scope-attributes.d.ts","sourceRoot":"","sources":["../../src/main/jsx-scope-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,kBAAkB;;;;;;;EAkB7B,CAAC"}
@@ -0,0 +1,24 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const JsxScopeAttributes = Object.freeze({
8
+ //
9
+ // General scope attributes
10
+ //
11
+ SCOPE_NAME: 'jsx',
12
+ //
13
+ // JSX scope metrics
14
+ //
15
+ JSX_ELEMENT_METRIC: 'jsx.element',
16
+ //
17
+ // Attributes relating to a jsx element
18
+ //
19
+ ELEMENT_NAME: 'jsx.element.name',
20
+ ELEMENT_ATTRIBUTE_NAMES: 'jsx.element.attributeNames',
21
+ ELEMENT_ATTRIBUTE_VALUES: 'jsx.element.attributeValues',
22
+ ELEMENT_MODULE_SPECIFIER: 'jsx.element.module.specifier'
23
+ });
24
+ //# sourceMappingURL=jsx-scope-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"jsx-scope-attributes.js","sourceRoot":"","sources":["../../src/main/jsx-scope-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC9C,EAAE;IACF,2BAA2B;IAC3B,EAAE;IACF,UAAU,EAAE,KAAK;IAEjB,EAAE;IACF,oBAAoB;IACpB,EAAE;IACF,kBAAkB,EAAE,aAAa;IAEjC,EAAE;IACF,uCAAuC;IACvC,EAAE;IACF,YAAY,EAAE,kBAAkB;IAChC,uBAAuB,EAAE,4BAA4B;IACrD,wBAAwB,EAAE,6BAA6B;IACvD,wBAAwB,EAAE,8BAA8B;CACzD,CAAC,CAAC"}
@@ -0,0 +1,13 @@
1
+ export declare const LogsAttributes: Readonly<{
2
+ LOG_LEVEL: "log.level";
3
+ LOG_MESSAGE: "log.message";
4
+ LOG_TIMESTAMP: "log.timestamp";
5
+ LOG_SOURCE: "log.source";
6
+ LOG_FILE_PATH: "log.file.path";
7
+ LOG_LINE_NUMBER: "log.line.number";
8
+ LOG_FUNCTION_NAME: "log.function.name";
9
+ LOG_ERROR_TYPE: "log.error.type";
10
+ LOG_ERROR_MESSAGE: "log.error.message";
11
+ LOG_ERROR_STACK: "log.error.stack";
12
+ }>;
13
+ //# sourceMappingURL=logs-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logs-attributes.d.ts","sourceRoot":"","sources":["../../src/main/logs-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,cAAc;;;;;;;;;;;EAczB,CAAC"}
@@ -0,0 +1,22 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const LogsAttributes = Object.freeze({
8
+ //
9
+ // Log-related attributes for telemetry data
10
+ //
11
+ LOG_LEVEL: 'log.level',
12
+ LOG_MESSAGE: 'log.message',
13
+ LOG_TIMESTAMP: 'log.timestamp',
14
+ LOG_SOURCE: 'log.source',
15
+ LOG_FILE_PATH: 'log.file.path',
16
+ LOG_LINE_NUMBER: 'log.line.number',
17
+ LOG_FUNCTION_NAME: 'log.function.name',
18
+ LOG_ERROR_TYPE: 'log.error.type',
19
+ LOG_ERROR_MESSAGE: 'log.error.message',
20
+ LOG_ERROR_STACK: 'log.error.stack'
21
+ });
22
+ //# sourceMappingURL=logs-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"logs-attributes.js","sourceRoot":"","sources":["../../src/main/logs-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,cAAc,GAAG,MAAM,CAAC,MAAM,CAAC;IAC1C,EAAE;IACF,4CAA4C;IAC5C,EAAE;IACF,SAAS,EAAE,WAAW;IACtB,WAAW,EAAE,aAAa;IAC1B,aAAa,EAAE,eAAe;IAC9B,UAAU,EAAE,YAAY;IACxB,aAAa,EAAE,eAAe;IAC9B,eAAe,EAAE,iBAAiB;IAClC,iBAAiB,EAAE,mBAAmB;IACtC,cAAc,EAAE,gBAAgB;IAChC,iBAAiB,EAAE,mBAAmB;IACtC,eAAe,EAAE,iBAAiB;CACnC,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ export declare const NpmScopeAttributes: Readonly<{
2
+ SCOPE_NAME: "npm";
3
+ NPM_DEPENDENCY_METRIC: "npm.dependency";
4
+ DEPENDENCY_NAME: "npm.dependency.name";
5
+ DEPENDENCY_VERSION: "npm.dependency.version";
6
+ DEPENDENCY_TYPE: "npm.dependency.type";
7
+ PROJECT_NAME: "npm.project.name";
8
+ PROJECT_VERSION: "npm.project.version";
9
+ }>;
10
+ //# sourceMappingURL=npm-scope-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"npm-scope-attributes.d.ts","sourceRoot":"","sources":["../../src/main/npm-scope-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,kBAAkB;;;;;;;;EAmB7B,CAAC"}
@@ -0,0 +1,25 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const NpmScopeAttributes = Object.freeze({
8
+ //
9
+ // General scope attributes
10
+ //
11
+ SCOPE_NAME: 'npm',
12
+ //
13
+ // NPM scope metrics
14
+ //
15
+ NPM_DEPENDENCY_METRIC: 'npm.dependency',
16
+ //
17
+ // Attributes relating to npm dependencies
18
+ //
19
+ DEPENDENCY_NAME: 'npm.dependency.name',
20
+ DEPENDENCY_VERSION: 'npm.dependency.version',
21
+ DEPENDENCY_TYPE: 'npm.dependency.type',
22
+ PROJECT_NAME: 'npm.project.name',
23
+ PROJECT_VERSION: 'npm.project.version'
24
+ });
25
+ //# sourceMappingURL=npm-scope-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"npm-scope-attributes.js","sourceRoot":"","sources":["../../src/main/npm-scope-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,kBAAkB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC9C,EAAE;IACF,2BAA2B;IAC3B,EAAE;IACF,UAAU,EAAE,KAAK;IAEjB,EAAE;IACF,oBAAoB;IACpB,EAAE;IACF,qBAAqB,EAAE,gBAAgB;IAEvC,EAAE;IACF,0CAA0C;IAC1C,EAAE;IACF,eAAe,EAAE,qBAAqB;IACtC,kBAAkB,EAAE,wBAAwB;IAC5C,eAAe,EAAE,qBAAqB;IACtC,YAAY,EAAE,kBAAkB;IAChC,eAAe,EAAE,qBAAqB;CACvC,CAAC,CAAC"}
@@ -0,0 +1,9 @@
1
+ export declare const WcScopeAttributes: Readonly<{
2
+ SCOPE_NAME: "wc";
3
+ WC_ELEMENT_METRIC: "wc.element";
4
+ ELEMENT_NAME: "wc.element.name";
5
+ ELEMENT_ATTRIBUTE_NAMES: "wc.element.attributeNames";
6
+ ELEMENT_ATTRIBUTE_VALUES: "wc.element.attributeValues";
7
+ ELEMENT_MODULE_SPECIFIER: "wc.element.module.specifier";
8
+ }>;
9
+ //# sourceMappingURL=wc-scope-attributes.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wc-scope-attributes.d.ts","sourceRoot":"","sources":["../../src/main/wc-scope-attributes.ts"],"names":[],"mappings":"AAOA,eAAO,MAAM,iBAAiB;;;;;;;EAkB5B,CAAC"}
@@ -0,0 +1,24 @@
1
+ /*
2
+ * Copyright octaviaflow 2025
3
+ *
4
+ * This source code is licensed under the MIT license found in the
5
+ * LICENSE file in the root directory of this source tree.
6
+ */
7
+ export const WcScopeAttributes = Object.freeze({
8
+ //
9
+ // General scope attributes
10
+ //
11
+ SCOPE_NAME: 'wc',
12
+ //
13
+ // Web Component scope metrics
14
+ //
15
+ WC_ELEMENT_METRIC: 'wc.element',
16
+ //
17
+ // Attributes relating to a web component element
18
+ //
19
+ ELEMENT_NAME: 'wc.element.name',
20
+ ELEMENT_ATTRIBUTE_NAMES: 'wc.element.attributeNames',
21
+ ELEMENT_ATTRIBUTE_VALUES: 'wc.element.attributeValues',
22
+ ELEMENT_MODULE_SPECIFIER: 'wc.element.module.specifier'
23
+ });
24
+ //# sourceMappingURL=wc-scope-attributes.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"wc-scope-attributes.js","sourceRoot":"","sources":["../../src/main/wc-scope-attributes.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,MAAM,CAAC,MAAM,iBAAiB,GAAG,MAAM,CAAC,MAAM,CAAC;IAC7C,EAAE;IACF,2BAA2B;IAC3B,EAAE;IACF,UAAU,EAAE,IAAI;IAEhB,EAAE;IACF,8BAA8B;IAC9B,EAAE;IACF,iBAAiB,EAAE,YAAY;IAE/B,EAAE;IACF,iDAAiD;IACjD,EAAE;IACF,YAAY,EAAE,iBAAiB;IAC/B,uBAAuB,EAAE,2BAA2B;IACpD,wBAAwB,EAAE,4BAA4B;IACtD,wBAAwB,EAAE,6BAA6B;CACxD,CAAC,CAAC"}
package/package.json ADDED
@@ -0,0 +1,63 @@
1
+ {
2
+ "name": "@octaviaflow/telemetry-attributes",
3
+ "description": "OctaviaFlow Telemetry attribute definitions for JS code",
4
+ "version": "1.0.0",
5
+ "license": "MIT",
6
+ "author": "OctaviaFlow",
7
+ "keywords": [
8
+ "octaviaflow",
9
+ "telemetry",
10
+ "attributes",
11
+ "analytics",
12
+ "metrics"
13
+ ],
14
+ "publishConfig": {
15
+ "access": "public"
16
+ },
17
+ "homepage": "https://github.com/octaviaflow/OctaviaFlow-Design-System/#readme",
18
+ "repository": {
19
+ "type": "git",
20
+ "url": "git+https://github.com/octaviaflow/OctaviaFlow-Design-System.git"
21
+ },
22
+ "bugs": {
23
+ "url": "https://github.com/octaviaflow/OctaviaFlow-Design-System/issues"
24
+ },
25
+ "type": "module",
26
+ "exports": {
27
+ ".": {
28
+ "types": "./dist/main/index.d.ts",
29
+ "default": "./dist/main/index.js"
30
+ }
31
+ },
32
+ "files": [
33
+ "dist/"
34
+ ],
35
+ "scripts": {
36
+ "build": "tsc",
37
+ "build:watch": "tsc --watch",
38
+ "clean": "rimraf dist",
39
+ "lint": "scripts/lint",
40
+ "lint:fix": "scripts/lint_and_fix",
41
+ "prepare": "husky install"
42
+ },
43
+ "devDependencies": {
44
+ "@commitlint/cli": "^19.8.1",
45
+ "@commitlint/config-conventional": "^19.8.1",
46
+ "@types/node": "^20.19.9",
47
+ "@typescript-eslint/eslint-plugin": "^7.18.0",
48
+ "@typescript-eslint/parser": "^7.18.0",
49
+ "eslint": "^8.57.1",
50
+ "eslint-plugin-eslint-comments": "^3.2.0",
51
+ "eslint-plugin-import": "^2.32.0",
52
+ "eslint-plugin-jsdoc": "^48.11.0",
53
+ "eslint-plugin-n": "^16.6.2",
54
+ "eslint-plugin-notice": "^0.9.10",
55
+ "eslint-plugin-promise": "^6.6.0",
56
+ "eslint-plugin-simple-import-sort": "^12.1.1",
57
+ "husky": "^9.1.7",
58
+ "lint-staged": "^15.5.2",
59
+ "prettier": "^3.6.2",
60
+ "rimraf": "^5.0.10",
61
+ "typescript": "^5.8.3"
62
+ }
63
+ }