core-services-sdk 1.3.36 → 1.3.38

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 (52) hide show
  1. package/package.json +2 -2
  2. package/src/fastify/error-codes.js +2 -4
  3. package/src/fastify/error-handlers/with-error-handling.js +5 -6
  4. package/src/http/HttpError.js +10 -29
  5. package/src/http/http.js +2 -3
  6. package/tests/fastify/error-handler.unit.test.js +3 -11
  7. package/tests/fastify/error-handlers/with-error-handling.test.js +3 -6
  8. package/tests/http/HttpError.unit.test.js +13 -17
  9. package/tsconfig.json +3 -1
  10. package/types/core/combine-unique-arrays.d.ts +1 -1
  11. package/types/core/index.d.ts +9 -9
  12. package/types/core/normalize-array-operators.d.ts +1 -1
  13. package/types/core/normalize-min-max.d.ts +16 -10
  14. package/types/core/normalize-phone-number.d.ts +30 -24
  15. package/types/core/normalize-premitives-types-or-default.d.ts +17 -4
  16. package/types/core/normalize-to-array.d.ts +1 -1
  17. package/types/core/otp-generators.d.ts +22 -18
  18. package/types/core/regex-utils.d.ts +1 -1
  19. package/types/core/sanitize-objects.d.ts +13 -4
  20. package/types/crypto/crypto.d.ts +31 -18
  21. package/types/crypto/encryption.d.ts +14 -6
  22. package/types/crypto/index.d.ts +2 -2
  23. package/types/fastify/error-codes.d.ts +11 -16
  24. package/types/fastify/error-handlers/with-error-handling.d.ts +26 -15
  25. package/types/fastify/index.d.ts +2 -2
  26. package/types/http/HttpError.d.ts +67 -76
  27. package/types/http/http-method.d.ts +6 -6
  28. package/types/http/http.d.ts +58 -34
  29. package/types/http/index.d.ts +4 -4
  30. package/types/http/responseType.d.ts +6 -6
  31. package/types/ids/generators.d.ts +28 -28
  32. package/types/ids/index.d.ts +2 -2
  33. package/types/ids/prefixes.d.ts +54 -54
  34. package/types/index.d.ts +11 -11
  35. package/types/logger/get-logger.d.ts +23 -21
  36. package/types/logger/index.d.ts +1 -1
  37. package/types/mailer/index.d.ts +2 -2
  38. package/types/mailer/mailer.service.d.ts +29 -19
  39. package/types/mailer/transport.factory.d.ts +43 -43
  40. package/types/mongodb/connect.d.ts +12 -7
  41. package/types/mongodb/dsl-to-mongo.d.ts +2 -1
  42. package/types/mongodb/index.d.ts +5 -5
  43. package/types/mongodb/initialize-mongodb.d.ts +18 -13
  44. package/types/mongodb/paginate.d.ts +23 -13
  45. package/types/mongodb/validate-mongo-uri.d.ts +1 -1
  46. package/types/rabbit-mq/index.d.ts +1 -1
  47. package/types/rabbit-mq/rabbit-mq.d.ts +62 -37
  48. package/types/templates/index.d.ts +1 -1
  49. package/types/templates/template-loader.d.ts +7 -3
  50. package/types/util/context.d.ts +53 -53
  51. package/types/util/index.d.ts +6 -6
  52. package/types/util/mask-sensitive.d.ts +14 -2
@@ -1,18 +1,31 @@
1
- export function getSalt(length: number): Buffer;
2
- export function getSaltHex(length: number): string;
3
- export function getEncryptedBuffer({ salt, expression, length, }: {
4
- expression: string;
5
- salt: string;
6
- length?: number;
7
- }): Promise<Buffer>;
8
- export function encrypt({ salt, expression, passwordPrivateKey }: {
9
- expression: string;
10
- salt: string;
11
- passwordPrivateKey?: string;
12
- }): Promise<string>;
13
- export function isPasswordMatch({ salt, password, encryptedPassword, passwordPrivateKey, }: {
14
- salt: string;
15
- password: string;
16
- encryptedPassword: string;
17
- passwordPrivateKey?: string;
18
- }): Promise<boolean>;
1
+ export function getSalt(length: number): Buffer
2
+ export function getSaltHex(length: number): string
3
+ export function getEncryptedBuffer({
4
+ salt,
5
+ expression,
6
+ length,
7
+ }: {
8
+ expression: string
9
+ salt: string
10
+ length?: number
11
+ }): Promise<Buffer>
12
+ export function encrypt({
13
+ salt,
14
+ expression,
15
+ passwordPrivateKey,
16
+ }: {
17
+ expression: string
18
+ salt: string
19
+ passwordPrivateKey?: string
20
+ }): Promise<string>
21
+ export function isPasswordMatch({
22
+ salt,
23
+ password,
24
+ encryptedPassword,
25
+ passwordPrivateKey,
26
+ }: {
27
+ salt: string
28
+ password: string
29
+ encryptedPassword: string
30
+ passwordPrivateKey?: string
31
+ }): Promise<boolean>
@@ -1,6 +1,14 @@
1
- export function encryptPassword({ password }: {
2
- password: string;
3
- }, { saltLength, passwordPrivateKey }: {
4
- saltLength: number;
5
- passwordPrivateKey?: string;
6
- }): Promise<any>;
1
+ export function encryptPassword(
2
+ {
3
+ password,
4
+ }: {
5
+ password: string
6
+ },
7
+ {
8
+ saltLength,
9
+ passwordPrivateKey,
10
+ }: {
11
+ saltLength: number
12
+ passwordPrivateKey?: string
13
+ },
14
+ ): Promise<any>
@@ -1,2 +1,2 @@
1
- export * from "./crypto.js";
2
- export * from "./encryption.js";
1
+ export * from './crypto.js'
2
+ export * from './encryption.js'
@@ -3,27 +3,22 @@
3
3
  * Useful as a fallback error descriptor for unhandled or unexpected failures.
4
4
  *
5
5
  * @typedef {Object} GeneralError
6
- * @property {number} httpStatusCode - The HTTP status code (500).
7
- * @property {string} httpStatusText - The human-readable status text ("Internal Server Error").
6
+ * @property {number} status - The HTTP status code (500).
8
7
  * @property {string} code - An application-specific error code in the format "GENERAL.<StatusText>".
9
8
  */
10
9
  /** @type {GeneralError} */
11
- export const GENERAL_ERROR: GeneralError;
10
+ export const GENERAL_ERROR: GeneralError
12
11
  /**
13
12
  * A reusable generic error object representing a server-side failure (HTTP 500).
14
13
  * Useful as a fallback error descriptor for unhandled or unexpected failures.
15
14
  */
16
15
  export type GeneralError = {
17
- /**
18
- * - The HTTP status code (500).
19
- */
20
- httpStatusCode: number;
21
- /**
22
- * - The human-readable status text ("Internal Server Error").
23
- */
24
- httpStatusText: string;
25
- /**
26
- * - An application-specific error code in the format "GENERAL.<StatusText>".
27
- */
28
- code: string;
29
- };
16
+ /**
17
+ * - The HTTP status code (500).
18
+ */
19
+ status: number
20
+ /**
21
+ * - An application-specific error code in the format "GENERAL.<StatusText>".
22
+ */
23
+ code: string
24
+ }
@@ -1,15 +1,26 @@
1
- export function withErrorHandling(log: object, defaultError: HttpError): (funcToInvoke: () => Promise<any>) => Promise<any>;
2
- export function withErrorHandlingReply({ reply, log, defaultError }: {
3
- reply: Reply;
4
- log: Logger;
5
- defaultError?: HttpError;
6
- }): (funcToInvoke: any) => Promise<any>;
7
- export function replyOnErrorOnly({ reply, log, defaultError }: {
8
- reply: Reply;
9
- log: Logger;
10
- defaultError?: HttpError;
11
- }): (funcToInvoke: any) => Promise<any>;
12
- export type Reply = import("fastify").FastifyReply;
13
- export type Request = import("fastify").FastifyRequest;
14
- export type Logger = import("pino").Logger;
15
- import { HttpError } from '../../http/HttpError.js';
1
+ export function withErrorHandling(
2
+ log: object,
3
+ defaultError: HttpError,
4
+ ): (funcToInvoke: () => Promise<any>) => Promise<any>
5
+ export function withErrorHandlingReply({
6
+ reply,
7
+ log,
8
+ defaultError,
9
+ }: {
10
+ reply: Reply
11
+ log: Logger
12
+ defaultError?: HttpError
13
+ }): (funcToInvoke: any) => Promise<any>
14
+ export function replyOnErrorOnly({
15
+ reply,
16
+ log,
17
+ defaultError,
18
+ }: {
19
+ reply: Reply
20
+ log: Logger
21
+ defaultError?: HttpError
22
+ }): (funcToInvoke: any) => Promise<any>
23
+ export type Reply = import('fastify').FastifyReply
24
+ export type Request = import('fastify').FastifyRequest
25
+ export type Logger = import('pino').Logger
26
+ import { HttpError } from '../../http/HttpError.js'
@@ -1,2 +1,2 @@
1
- export { GENERAL_ERROR } from "./error-codes.js";
2
- export * from "./error-handlers/with-error-handling.js";
1
+ export { GENERAL_ERROR } from './error-codes.js'
2
+ export * from './error-handlers/with-error-handling.js'
@@ -3,80 +3,71 @@
3
3
  * Useful for consistent error handling across services.
4
4
  */
5
5
  export class HttpError extends Error {
6
- /**
7
- * Checks if a given object is an instance of `HttpError`.
8
- *
9
- * @param {*} instance - The object to check.
10
- * @returns {boolean} True if `instance` is an instance of `HttpError`.
11
- */
12
- static isInstanceOf(instance: any): boolean;
13
- /**
14
- * Checks if the error is an instance of `HttpError` or has similar shape.
15
- *
16
- * @param {object} error
17
- * @returns {error is HttpError}
18
- */
19
- static isHttpError(error: object): error is HttpError;
20
- /**
21
- * Creates an HttpError from a generic Error instance or returns it if already an HttpError.
22
- *
23
- * @param {Error | HttpError} error
24
- * @returns {HttpError}
25
- */
26
- static FromError(error: Error | HttpError): HttpError;
27
- /**
28
- * Creates an instance of HttpError.
29
- *
30
- * @param {Object} [error] - Optional error object.
31
- * @param {string | number} [error.code] - Application-specific error code.
32
- * @param {string} [error.message] - Custom error message.
33
- * @param {number} [error.httpStatusCode] - HTTP status code (e.g., 404, 500).
34
- * @param {string} [error.httpStatusText] - Optional human-readable HTTP status text.
35
- * @param {object} [error.extendInfo] - Optional extended metadata for diagnostics.
36
- */
37
- constructor(error?: {
38
- code?: string | number;
39
- message?: string;
40
- httpStatusCode?: number;
41
- httpStatusText?: string;
42
- extendInfo?: object;
43
- });
44
- /**
45
- * @type {string | number | undefined}
46
- * A short application-specific error code (e.g., "INVALID_INPUT" or a numeric code).
47
- */
48
- code: string | number | undefined;
49
- /**
50
- * @type {number | undefined}
51
- * HTTP status code associated with the error (e.g., 400, 500).
52
- */
53
- httpStatusCode: number | undefined;
54
- /**
55
- * @type {string | undefined}
56
- * Human-readable HTTP status text (e.g., "Bad Request").
57
- */
58
- httpStatusText: string | undefined;
59
- /**
60
- * @type {object | undefined}
61
- * Optional metadata for debugging/logging (e.g., request ID, user ID, retryAfter).
62
- */
63
- extendInfo: object | undefined;
64
- /**
65
- * Converts the error to a plain object (useful for logging or sending as JSON).
66
- *
67
- * @returns {{
68
- * code: string | number | undefined,
69
- * message: string,
70
- * httpStatusCode: number | undefined,
71
- * httpStatusText: string | undefined,
72
- * extendInfo?: object
73
- * }}
74
- */
75
- toJSON(): {
76
- code: string | number | undefined;
77
- message: string;
78
- httpStatusCode: number | undefined;
79
- httpStatusText: string | undefined;
80
- extendInfo?: object;
81
- };
6
+ /**
7
+ * Checks if a given object is an instance of `HttpError`.
8
+ *
9
+ * @param {*} instance - The object to check.
10
+ * @returns {boolean} True if `instance` is an instance of `HttpError`.
11
+ */
12
+ static isInstanceOf(instance: any): boolean
13
+ /**
14
+ * Checks if the error is an instance of `HttpError` or has similar shape.
15
+ *
16
+ * @param {object} error
17
+ * @returns {error is HttpError}
18
+ */
19
+ static isHttpError(error: object): error is HttpError
20
+ /**
21
+ * Creates an HttpError from a generic Error instance or returns it if already an HttpError.
22
+ *
23
+ * @param {Error | HttpError} error
24
+ * @returns {HttpError}
25
+ */
26
+ static FromError(error: Error | HttpError): HttpError
27
+ /**
28
+ * Creates an instance of HttpError.
29
+ *
30
+ * @param {Object} [error] - Optional error object.
31
+ * @param {string | number} [error.code] - Application-specific error code.
32
+ * @param {string} [error.message] - Custom error message.
33
+ * @param {number} [error.status] - HTTP status code (e.g., 404, 500).
34
+ * @param {object} [error.extendInfo] - Optional extended metadata for diagnostics.
35
+ */
36
+ constructor(error?: {
37
+ code?: string | number
38
+ message?: string
39
+ status?: number
40
+ extendInfo?: object
41
+ })
42
+ /**
43
+ * @type {string | number | undefined}
44
+ * A short application-specific error code (e.g., "INVALID_INPUT" or a numeric code).
45
+ */
46
+ code: string | number | undefined
47
+ /**
48
+ * @type {number | undefined}
49
+ * HTTP status code associated with the error (e.g., 400, 500).
50
+ */
51
+ status: number | undefined
52
+ /**
53
+ * @type {object | undefined}
54
+ * Optional metadata for debugging/logging (e.g., request ID, user ID, retryAfter).
55
+ */
56
+ extendInfo: object | undefined
57
+ /**
58
+ * Converts the error to a plain object (useful for logging or sending as JSON).
59
+ *
60
+ * @returns {{
61
+ * code: string | number | undefined,
62
+ * message: string,
63
+ * status: number | undefined,
64
+ * extendInfo?: object
65
+ * }}
66
+ */
67
+ toJSON(): {
68
+ code: string | number | undefined
69
+ message: string
70
+ status: number | undefined
71
+ extendInfo?: object
72
+ }
82
73
  }
@@ -1,7 +1,7 @@
1
1
  export const HTTP_METHODS: Readonly<{
2
- GET: "GET";
3
- POST: "POST";
4
- PUT: "PUT";
5
- PATCH: "PATCH";
6
- DELETE: "DELETE";
7
- }>;
2
+ GET: 'GET'
3
+ POST: 'POST'
4
+ PUT: 'PUT'
5
+ PATCH: 'PATCH'
6
+ DELETE: 'DELETE'
7
+ }>
@@ -1,36 +1,60 @@
1
- export function get({ url, headers, expectedType, }: {
2
- url: any;
3
- headers?: {};
4
- expectedType?: "json";
5
- }): Promise<any>;
6
- export function post({ url, body, headers, expectedType, }: {
7
- url: any;
8
- body: any;
9
- headers?: {};
10
- expectedType?: "json";
11
- }): Promise<any>;
12
- export function put({ url, body, headers, expectedType, }: {
13
- url: any;
14
- body: any;
15
- headers?: {};
16
- expectedType?: "json";
17
- }): Promise<any>;
18
- export function patch({ url, body, headers, expectedType, }: {
19
- url: any;
20
- body: any;
21
- headers?: {};
22
- expectedType?: "json";
23
- }): Promise<any>;
24
- export function deleteApi({ url, body, headers, expectedType, }: {
25
- url: any;
26
- body: any;
27
- headers?: {};
28
- expectedType?: "json";
29
- }): Promise<any>;
1
+ export function get({
2
+ url,
3
+ headers,
4
+ expectedType,
5
+ }: {
6
+ url: any
7
+ headers?: {}
8
+ expectedType?: 'json'
9
+ }): Promise<any>
10
+ export function post({
11
+ url,
12
+ body,
13
+ headers,
14
+ expectedType,
15
+ }: {
16
+ url: any
17
+ body: any
18
+ headers?: {}
19
+ expectedType?: 'json'
20
+ }): Promise<any>
21
+ export function put({
22
+ url,
23
+ body,
24
+ headers,
25
+ expectedType,
26
+ }: {
27
+ url: any
28
+ body: any
29
+ headers?: {}
30
+ expectedType?: 'json'
31
+ }): Promise<any>
32
+ export function patch({
33
+ url,
34
+ body,
35
+ headers,
36
+ expectedType,
37
+ }: {
38
+ url: any
39
+ body: any
40
+ headers?: {}
41
+ expectedType?: 'json'
42
+ }): Promise<any>
43
+ export function deleteApi({
44
+ url,
45
+ body,
46
+ headers,
47
+ expectedType,
48
+ }: {
49
+ url: any
50
+ body: any
51
+ headers?: {}
52
+ expectedType?: 'json'
53
+ }): Promise<any>
30
54
  export namespace http {
31
- export { get };
32
- export { put };
33
- export { post };
34
- export { patch };
35
- export { deleteApi };
55
+ export { get }
56
+ export { put }
57
+ export { post }
58
+ export { patch }
59
+ export { deleteApi }
36
60
  }
@@ -1,4 +1,4 @@
1
- export * from "./http.js";
2
- export * from "./HttpError.js";
3
- export * from "./http-method.js";
4
- export * from "./responseType.js";
1
+ export * from './http.js'
2
+ export * from './HttpError.js'
3
+ export * from './http-method.js'
4
+ export * from './responseType.js'
@@ -1,7 +1,7 @@
1
1
  /**
2
2
  * *
3
3
  */
4
- export type ResponseType = string;
4
+ export type ResponseType = string
5
5
  /**
6
6
  * Enum representing supported response types for HTTP client parsing.
7
7
  *
@@ -13,8 +13,8 @@ export type ResponseType = string;
13
13
  * @property {string} file - Binary file or blob (not automatically parsed).
14
14
  */
15
15
  export const ResponseType: Readonly<{
16
- xml: "xml";
17
- json: "json";
18
- text: "text";
19
- file: "file";
20
- }>;
16
+ xml: 'xml'
17
+ json: 'json'
18
+ text: 'text'
19
+ file: 'file'
20
+ }>
@@ -1,28 +1,28 @@
1
- export function generateId(): string;
2
- export function generatePrefixedId(prefix: string): string;
3
- export function generateUserId(): string;
4
- export function generateTenantId(): string;
5
- export function generatePermissionId(): string;
6
- export function generateCorrelationId(): string;
7
- export function generateVerificationId(): string;
8
- export function generateRolePermissionsId(): string;
9
- export function generateOnboardingId(): string;
10
- export function generateSessionId(): string;
11
- export function generateFileId(): string;
12
- export function generateEventId(): string;
13
- export function generateJobId(): string;
14
- export function generateTaskId(): string;
15
- export function generateQueueId(): string;
16
- export function generateMessageId(): string;
17
- export function generateNotificationId(): string;
18
- export function generateLogId(): string;
19
- export function generateAuditId(): string;
20
- export function generateConfigId(): string;
21
- export function generateKeyId(): string;
22
- export function generateMetricId(): string;
23
- export function generateTagId(): string;
24
- export function generatePolicyId(): string;
25
- export function generateProfileId(): string;
26
- export function generateDeviceId(): string;
27
- export function generateAlertId(): string;
28
- export function generateResourceId(): string;
1
+ export function generateId(): string
2
+ export function generatePrefixedId(prefix: string): string
3
+ export function generateUserId(): string
4
+ export function generateTenantId(): string
5
+ export function generatePermissionId(): string
6
+ export function generateCorrelationId(): string
7
+ export function generateVerificationId(): string
8
+ export function generateRolePermissionsId(): string
9
+ export function generateOnboardingId(): string
10
+ export function generateSessionId(): string
11
+ export function generateFileId(): string
12
+ export function generateEventId(): string
13
+ export function generateJobId(): string
14
+ export function generateTaskId(): string
15
+ export function generateQueueId(): string
16
+ export function generateMessageId(): string
17
+ export function generateNotificationId(): string
18
+ export function generateLogId(): string
19
+ export function generateAuditId(): string
20
+ export function generateConfigId(): string
21
+ export function generateKeyId(): string
22
+ export function generateMetricId(): string
23
+ export function generateTagId(): string
24
+ export function generatePolicyId(): string
25
+ export function generateProfileId(): string
26
+ export function generateDeviceId(): string
27
+ export function generateAlertId(): string
28
+ export function generateResourceId(): string
@@ -1,2 +1,2 @@
1
- export * from "./prefixes.js";
2
- export * from "./generators.js";
1
+ export * from './prefixes.js'
2
+ export * from './generators.js'
@@ -4,7 +4,7 @@
4
4
  * These prefixes are prepended to ULIDs to create consistent and identifiable IDs across the system.
5
5
  * For example: 'usr_01HZY3M7K4FJ9A8Q4Y1ZB5NX3T'
6
6
  */
7
- export type ID_PREFIXES = string;
7
+ export type ID_PREFIXES = string
8
8
  /**
9
9
  * Mapping of entity types to their unique ID prefixes.
10
10
  *
@@ -15,56 +15,56 @@ export type ID_PREFIXES = string;
15
15
  * @enum {string}
16
16
  */
17
17
  export const ID_PREFIXES: Readonly<{
18
- /** User entity ID prefix */
19
- USER: "usr";
20
- /** Tenant entity ID prefix */
21
- TENANT: "tnt";
22
- /** Permission entity ID prefix */
23
- PERMISSION: "prm";
24
- /** Correlation ID prefix (e.g., for tracing requests) */
25
- CORRELATION: "crln";
26
- /** Verification entity ID prefix (e.g., email/phone code) */
27
- VERIFICATION: "vrf";
28
- /** Role-permissions mapping ID prefix */
29
- ROLE_PERMISSIONS: "role";
30
- /** Onboarding mapping ID prefix */
31
- ONBOARDING: "onb";
32
- /** Session mapping ID prefix */
33
- SESSION: "sess";
34
- /** File mapping ID prefix */
35
- FILE: "fil";
36
- /** Event entity ID prefix */
37
- EVENT: "evt";
38
- /** Job entity ID prefix */
39
- JOB: "job";
40
- /** Task entity ID prefix */
41
- TASK: "task";
42
- /** Queue entity ID prefix */
43
- QUEUE: "que";
44
- /** Message entity ID prefix */
45
- MESSAGE: "msg";
46
- /** Notification entity ID prefix */
47
- NOTIFICATION: "ntf";
48
- /** Log entity ID prefix */
49
- LOG: "log";
50
- /** Audit entity ID prefix */
51
- AUDIT: "adt";
52
- /** Config entity ID prefix */
53
- CONFIG: "cfg";
54
- /** Key entity ID prefix */
55
- KEY: "key";
56
- /** Metric entity ID prefix */
57
- METRIC: "met";
58
- /** Tag entity ID prefix */
59
- TAG: "tag";
60
- /** Policy entity ID prefix */
61
- POLICY: "plc";
62
- /** Profile entity ID prefix */
63
- PROFILE: "prf";
64
- /** Device entity ID prefix */
65
- DEVICE: "dev";
66
- /** Alert entity ID prefix */
67
- ALERT: "alr";
68
- /** Resource entity ID prefix */
69
- RESOURCE: "res";
70
- }>;
18
+ /** User entity ID prefix */
19
+ USER: 'usr'
20
+ /** Tenant entity ID prefix */
21
+ TENANT: 'tnt'
22
+ /** Permission entity ID prefix */
23
+ PERMISSION: 'prm'
24
+ /** Correlation ID prefix (e.g., for tracing requests) */
25
+ CORRELATION: 'crln'
26
+ /** Verification entity ID prefix (e.g., email/phone code) */
27
+ VERIFICATION: 'vrf'
28
+ /** Role-permissions mapping ID prefix */
29
+ ROLE_PERMISSIONS: 'role'
30
+ /** Onboarding mapping ID prefix */
31
+ ONBOARDING: 'onb'
32
+ /** Session mapping ID prefix */
33
+ SESSION: 'sess'
34
+ /** File mapping ID prefix */
35
+ FILE: 'fil'
36
+ /** Event entity ID prefix */
37
+ EVENT: 'evt'
38
+ /** Job entity ID prefix */
39
+ JOB: 'job'
40
+ /** Task entity ID prefix */
41
+ TASK: 'task'
42
+ /** Queue entity ID prefix */
43
+ QUEUE: 'que'
44
+ /** Message entity ID prefix */
45
+ MESSAGE: 'msg'
46
+ /** Notification entity ID prefix */
47
+ NOTIFICATION: 'ntf'
48
+ /** Log entity ID prefix */
49
+ LOG: 'log'
50
+ /** Audit entity ID prefix */
51
+ AUDIT: 'adt'
52
+ /** Config entity ID prefix */
53
+ CONFIG: 'cfg'
54
+ /** Key entity ID prefix */
55
+ KEY: 'key'
56
+ /** Metric entity ID prefix */
57
+ METRIC: 'met'
58
+ /** Tag entity ID prefix */
59
+ TAG: 'tag'
60
+ /** Policy entity ID prefix */
61
+ POLICY: 'plc'
62
+ /** Profile entity ID prefix */
63
+ PROFILE: 'prf'
64
+ /** Device entity ID prefix */
65
+ DEVICE: 'dev'
66
+ /** Alert entity ID prefix */
67
+ ALERT: 'alr'
68
+ /** Resource entity ID prefix */
69
+ RESOURCE: 'res'
70
+ }>