@hed-hog/core 0.0.366 → 0.0.368

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 (87) hide show
  1. package/dist/file/file.service.d.ts +1 -0
  2. package/dist/file/file.service.d.ts.map +1 -1
  3. package/dist/file/file.service.js +1 -1
  4. package/dist/file/file.service.js.map +1 -1
  5. package/dist/integration/services/outbox-polling.coordinator.d.ts +2 -0
  6. package/dist/integration/services/outbox-polling.coordinator.d.ts.map +1 -1
  7. package/dist/integration/services/outbox-polling.coordinator.js +14 -4
  8. package/dist/integration/services/outbox-polling.coordinator.js.map +1 -1
  9. package/dist/integration/services/outbox.processor.d.ts.map +1 -1
  10. package/dist/integration/services/outbox.processor.js +4 -3
  11. package/dist/integration/services/outbox.processor.js.map +1 -1
  12. package/dist/locale/locale.controller.d.ts +1 -1
  13. package/dist/locale/locale.controller.d.ts.map +1 -1
  14. package/dist/locale/locale.controller.js +4 -3
  15. package/dist/locale/locale.controller.js.map +1 -1
  16. package/dist/locale/locale.service.d.ts +1 -1
  17. package/dist/locale/locale.service.d.ts.map +1 -1
  18. package/dist/locale/locale.service.js +6 -6
  19. package/dist/locale/locale.service.js.map +1 -1
  20. package/dist/notification/events/notification-stale-progress-check.event.d.ts +6 -0
  21. package/dist/notification/events/notification-stale-progress-check.event.d.ts.map +1 -0
  22. package/dist/notification/events/notification-stale-progress-check.event.js +11 -0
  23. package/dist/notification/events/notification-stale-progress-check.event.js.map +1 -0
  24. package/dist/notification/notification.service.d.ts +4 -1
  25. package/dist/notification/notification.service.d.ts.map +1 -1
  26. package/dist/notification/notification.service.js +9 -26
  27. package/dist/notification/notification.service.js.map +1 -1
  28. package/dist/task/task.service.d.ts +19 -0
  29. package/dist/task/task.service.d.ts.map +1 -1
  30. package/dist/task/task.service.js +46 -0
  31. package/dist/task/task.service.js.map +1 -1
  32. package/dist/user/user.controller.d.ts +23 -5
  33. package/dist/user/user.controller.d.ts.map +1 -1
  34. package/dist/user/user.controller.js +32 -15
  35. package/dist/user/user.controller.js.map +1 -1
  36. package/dist/user/user.service.d.ts +28 -8
  37. package/dist/user/user.service.d.ts.map +1 -1
  38. package/dist/user/user.service.js +120 -8
  39. package/dist/user/user.service.js.map +1 -1
  40. package/hedhog/data/integration_event_catalog.yaml +118 -118
  41. package/hedhog/data/integration_provider.yaml +25 -0
  42. package/hedhog/data/integration_type.yaml +6 -0
  43. package/hedhog/data/locale.yaml +5 -1
  44. package/hedhog/data/route.yaml +9 -0
  45. package/hedhog/data/setting_group.yaml +116 -106
  46. package/hedhog/data/setting_subgroup.yaml +32 -0
  47. package/hedhog/frontend/app/integration/profiles/page.tsx.ejs +56 -0
  48. package/hedhog/frontend/app/roles/page.tsx.ejs +4 -1
  49. package/hedhog/frontend/app/users/user-logs.tsx.ejs +190 -0
  50. package/hedhog/frontend/app/users/user-sheet.tsx.ejs +15 -1
  51. package/hedhog/frontend/messages/en.json +17 -0
  52. package/hedhog/frontend/messages/pt.json +17 -0
  53. package/hedhog/table/ai_instruction.yaml +1 -1
  54. package/hedhog/table/event_webhook.yaml +55 -55
  55. package/hedhog/table/event_webhook_delivery_log.yaml +66 -66
  56. package/hedhog/table/event_webhook_event.yaml +26 -26
  57. package/hedhog/table/integration_event_catalog.yaml +41 -41
  58. package/hedhog/table/mcp_conversation.yaml +12 -12
  59. package/hedhog/table/mcp_conversation_message.yaml +23 -23
  60. package/hedhog/table/mcp_tool_call_log.yaml +22 -22
  61. package/hedhog/table/route.yaml +33 -33
  62. package/hedhog/table/user_change_log.yaml +40 -0
  63. package/hedhog/table/webhook_call_log.yaml +46 -46
  64. package/hedhog/table/webhook_integration.yaml +43 -43
  65. package/package.json +4 -4
  66. package/src/file/file.service.ts +2 -1
  67. package/src/integration/services/outbox-polling.coordinator.ts +16 -4
  68. package/src/integration/services/outbox.processor.ts +14 -8
  69. package/src/integration/types/event.types.ts +4 -4
  70. package/src/locale/locale.controller.ts +2 -1
  71. package/src/locale/locale.service.ts +7 -6
  72. package/src/mcp/decorators/mcp-tool.decorator.ts +7 -7
  73. package/src/mcp/guards/mcp-permission.guard.ts +51 -51
  74. package/src/mcp/interfaces/mcp-tool-definition.interface.ts +6 -6
  75. package/src/mcp/mcp-server.service.ts +87 -87
  76. package/src/mcp/types/mcp-context.type.ts +6 -6
  77. package/src/mcp-chat/dto/create-conversation.dto.ts +7 -7
  78. package/src/mcp-chat/dto/send-message.dto.ts +7 -7
  79. package/src/notification/events/notification-stale-progress-check.event.ts +5 -0
  80. package/src/notification/notification.service.ts +12 -25
  81. package/src/route/dto/create.dto.ts +32 -32
  82. package/src/route/dto/update.dto.ts +31 -31
  83. package/src/task/task.service.ts +52 -0
  84. package/src/user/user.controller.ts +23 -9
  85. package/src/user/user.service.ts +183 -8
  86. package/src/webhook-integration/integration-event-catalog.controller.ts +50 -50
  87. package/src/webhook-integration/integration-event-catalog.service.ts +117 -117
@@ -244,6 +244,7 @@
244
244
  "tabIdentifiers": "Identificadores",
245
245
  "tabMfa": "MFA",
246
246
  "tabSessions": "Sessões",
247
+ "tabLogs": "Logs",
247
248
  "cardLastLoginDescription": "Último login",
248
249
  "cardLastLoginTitle": "Nunca",
249
250
  "securityTitle": "Visão Geral de Segurança",
@@ -944,6 +945,18 @@
944
945
  "revokeAllSuccess": "Sessões revogadas com sucesso!",
945
946
  "revokeAllFailure": "Falha ao revogar sessões"
946
947
  },
948
+ "UserChangeLog": {
949
+ "title": "Histórico de Alterações",
950
+ "byActor": "por",
951
+ "systemActor": "Sistema",
952
+ "update": "Perfil atualizado",
953
+ "reset_password": "Senha redefinida",
954
+ "role_assigned": "Papel atribuído",
955
+ "role_removed": "Papel removido",
956
+ "avatar_changed": "Avatar alterado",
957
+ "emptyTitle": "Nenhuma alteração registrada",
958
+ "emptyDescription": "As alterações administrativas feitas neste usuário aparecerão aqui."
959
+ },
947
960
  "UserActiveSessions": {
948
961
  "title": "Sessões Ativas",
949
962
  "revokeAll": "Revogar Todas",
@@ -2410,6 +2423,10 @@
2410
2423
  "fieldMode": "Modo",
2411
2424
  "fieldModeSandbox": "Sandbox",
2412
2425
  "fieldModeProduction": "Produção",
2426
+ "fieldSiteKey": "Chave do Site",
2427
+ "fieldHmacKey": "Chave HMAC",
2428
+ "fieldScoreThreshold": "Limiar de Pontuação",
2429
+ "fieldApiUrl": "URL da API",
2413
2430
  "callbackUrlsSectionTitle": "URLs de Callback",
2414
2431
  "callbackUrlsDescription": "Registre estas URLs nas configurações do seu aplicativo OAuth.",
2415
2432
  "addCallbackUrl": "Adicionar URL",
@@ -20,7 +20,7 @@ columns:
20
20
  isNullable: true
21
21
  - name: locale
22
22
  length: 10
23
- default: "'en'"
23
+ default: en
24
24
  - name: module_slug
25
25
  isNullable: true
26
26
  - name: is_active
@@ -1,55 +1,55 @@
1
- columns:
2
- - type: pk
3
- - type: slug
4
- - name: name
5
- type: varchar
6
- length: 127
7
- - name: description
8
- type: text
9
- isNullable: true
10
- - name: status
11
- type: enum
12
- enum:
13
- - active
14
- - inactive
15
- default: active
16
- - name: priority
17
- type: int
18
- default: 0
19
- - name: url
20
- type: text
21
- - name: method
22
- type: enum
23
- enum:
24
- - GET
25
- - POST
26
- - PUT
27
- - PATCH
28
- - DELETE
29
- default: POST
30
- - name: headers
31
- type: json
32
- isNullable: true
33
- - name: query
34
- type: json
35
- isNullable: true
36
- - name: payload
37
- type: json
38
- isNullable: true
39
- - name: timeout_ms
40
- type: int
41
- default: 10000
42
- - name: retry_count
43
- type: int
44
- default: 0
45
- - type: created_at
46
- - type: updated_at
47
- indices:
48
- - columns:
49
- - slug
50
- isUnique: true
51
- - columns:
52
- - status
53
- - columns:
54
- - priority
55
-
1
+ columns:
2
+ - type: pk
3
+ - type: slug
4
+ - name: name
5
+ type: varchar
6
+ length: 127
7
+ - name: description
8
+ type: text
9
+ isNullable: true
10
+ - name: status
11
+ type: enum
12
+ enum:
13
+ - active
14
+ - inactive
15
+ default: active
16
+ - name: priority
17
+ type: int
18
+ default: 0
19
+ - name: url
20
+ type: text
21
+ - name: method
22
+ type: enum
23
+ enum:
24
+ - GET
25
+ - POST
26
+ - PUT
27
+ - PATCH
28
+ - DELETE
29
+ default: POST
30
+ - name: headers
31
+ type: json
32
+ isNullable: true
33
+ - name: query
34
+ type: json
35
+ isNullable: true
36
+ - name: payload
37
+ type: json
38
+ isNullable: true
39
+ - name: timeout_ms
40
+ type: int
41
+ default: 10000
42
+ - name: retry_count
43
+ type: int
44
+ default: 0
45
+ - type: created_at
46
+ - type: updated_at
47
+ indices:
48
+ - columns:
49
+ - slug
50
+ isUnique: true
51
+ - columns:
52
+ - status
53
+ - columns:
54
+ - priority
55
+
@@ -1,66 +1,66 @@
1
- columns:
2
- - type: pk
3
- - type: fk
4
- name: event_webhook_id
5
- isNullable: true
6
- references:
7
- table: event_webhook
8
- column: id
9
- onDelete: set null
10
- onUpdate: cascade
11
- - type: fk
12
- name: integration_event_catalog_id
13
- isNullable: true
14
- references:
15
- table: integration_event_catalog
16
- column: id
17
- onDelete: set null
18
- onUpdate: cascade
19
- - name: outbox_event_id
20
- type: int
21
- isNullable: true
22
- - name: event_name
23
- type: varchar
24
- length: 255
25
- - name: method
26
- type: varchar
27
- length: 15
28
- - name: url
29
- type: text
30
- - name: status
31
- type: enum
32
- enum:
33
- - success
34
- - failed
35
- - name: http_status
36
- type: int
37
- isNullable: true
38
- - name: duration_ms
39
- type: int
40
- default: 0
41
- - name: attempt_count
42
- type: int
43
- default: 1
44
- - name: error_message
45
- type: text
46
- isNullable: true
47
- - name: request_summary
48
- type: json
49
- isNullable: true
50
- - name: response_summary
51
- type: json
52
- isNullable: true
53
- - type: created_at
54
- - type: updated_at
55
- indices:
56
- - columns:
57
- - event_webhook_id
58
- - columns:
59
- - integration_event_catalog_id
60
- - columns:
61
- - event_name
62
- - columns:
63
- - status
64
- - columns:
65
- - created_at
66
-
1
+ columns:
2
+ - type: pk
3
+ - type: fk
4
+ name: event_webhook_id
5
+ isNullable: true
6
+ references:
7
+ table: event_webhook
8
+ column: id
9
+ onDelete: set null
10
+ onUpdate: cascade
11
+ - type: fk
12
+ name: integration_event_catalog_id
13
+ isNullable: true
14
+ references:
15
+ table: integration_event_catalog
16
+ column: id
17
+ onDelete: set null
18
+ onUpdate: cascade
19
+ - name: outbox_event_id
20
+ type: int
21
+ isNullable: true
22
+ - name: event_name
23
+ type: varchar
24
+ length: 255
25
+ - name: method
26
+ type: varchar
27
+ length: 15
28
+ - name: url
29
+ type: text
30
+ - name: status
31
+ type: enum
32
+ enum:
33
+ - success
34
+ - failed
35
+ - name: http_status
36
+ type: int
37
+ isNullable: true
38
+ - name: duration_ms
39
+ type: int
40
+ default: 0
41
+ - name: attempt_count
42
+ type: int
43
+ default: 1
44
+ - name: error_message
45
+ type: text
46
+ isNullable: true
47
+ - name: request_summary
48
+ type: json
49
+ isNullable: true
50
+ - name: response_summary
51
+ type: json
52
+ isNullable: true
53
+ - type: created_at
54
+ - type: updated_at
55
+ indices:
56
+ - columns:
57
+ - event_webhook_id
58
+ - columns:
59
+ - integration_event_catalog_id
60
+ - columns:
61
+ - event_name
62
+ - columns:
63
+ - status
64
+ - columns:
65
+ - created_at
66
+
@@ -1,26 +1,26 @@
1
- columns:
2
- - type: pk
3
- - type: fk
4
- name: event_webhook_id
5
- references:
6
- table: event_webhook
7
- column: id
8
- onDelete: cascade
9
- onUpdate: cascade
10
- - type: fk
11
- name: integration_event_catalog_id
12
- references:
13
- table: integration_event_catalog
14
- column: id
15
- onDelete: cascade
16
- onUpdate: cascade
17
- - type: created_at
18
- - type: updated_at
19
- indices:
20
- - columns:
21
- - event_webhook_id
22
- - integration_event_catalog_id
23
- isUnique: true
24
- - columns:
25
- - integration_event_catalog_id
26
-
1
+ columns:
2
+ - type: pk
3
+ - type: fk
4
+ name: event_webhook_id
5
+ references:
6
+ table: event_webhook
7
+ column: id
8
+ onDelete: cascade
9
+ onUpdate: cascade
10
+ - type: fk
11
+ name: integration_event_catalog_id
12
+ references:
13
+ table: integration_event_catalog
14
+ column: id
15
+ onDelete: cascade
16
+ onUpdate: cascade
17
+ - type: created_at
18
+ - type: updated_at
19
+ indices:
20
+ - columns:
21
+ - event_webhook_id
22
+ - integration_event_catalog_id
23
+ isUnique: true
24
+ - columns:
25
+ - integration_event_catalog_id
26
+
@@ -1,41 +1,41 @@
1
- columns:
2
- - type: pk
3
- - type: slug
4
- - name: name
5
- type: varchar
6
- length: 127
7
- - name: module
8
- type: varchar
9
- length: 127
10
- - name: aggregate_type
11
- type: varchar
12
- length: 127
13
- isNullable: true
14
- - name: description
15
- type: text
16
- isNullable: true
17
- - name: payload_schema
18
- type: json
19
- isNullable: true
20
- - name: metadata_schema
21
- type: json
22
- isNullable: true
23
- - name: status
24
- type: enum
25
- enum:
26
- - active
27
- - inactive
28
- default: active
29
- - type: created_at
30
- - type: updated_at
31
- indices:
32
- - columns:
33
- - slug
34
- isUnique: true
35
- - columns:
36
- - module
37
- - columns:
38
- - aggregate_type
39
- - columns:
40
- - status
41
-
1
+ columns:
2
+ - type: pk
3
+ - type: slug
4
+ - name: name
5
+ type: varchar
6
+ length: 127
7
+ - name: module
8
+ type: varchar
9
+ length: 127
10
+ - name: aggregate_type
11
+ type: varchar
12
+ length: 127
13
+ isNullable: true
14
+ - name: description
15
+ type: text
16
+ isNullable: true
17
+ - name: payload_schema
18
+ type: json
19
+ isNullable: true
20
+ - name: metadata_schema
21
+ type: json
22
+ isNullable: true
23
+ - name: status
24
+ type: enum
25
+ enum:
26
+ - active
27
+ - inactive
28
+ default: active
29
+ - type: created_at
30
+ - type: updated_at
31
+ indices:
32
+ - columns:
33
+ - slug
34
+ isUnique: true
35
+ - columns:
36
+ - module
37
+ - columns:
38
+ - aggregate_type
39
+ - columns:
40
+ - status
41
+
@@ -1,12 +1,12 @@
1
- columns:
2
- - type: pk
3
- - name: user_id
4
- type: fk
5
- references:
6
- table: user
7
- column: id
8
- onDelete: CASCADE
9
- - name: title
10
- isNullable: true
11
- - type: created_at
12
- - type: updated_at
1
+ columns:
2
+ - type: pk
3
+ - name: user_id
4
+ type: fk
5
+ references:
6
+ table: user
7
+ column: id
8
+ onDelete: CASCADE
9
+ - name: title
10
+ isNullable: true
11
+ - type: created_at
12
+ - type: updated_at
@@ -1,23 +1,23 @@
1
- columns:
2
- - type: pk
3
- - name: conversation_id
4
- type: fk
5
- references:
6
- table: mcp_conversation
7
- column: id
8
- onDelete: CASCADE
9
- - name: role
10
- type: enum
11
- enum:
12
- - user
13
- - assistant
14
- - tool_call
15
- - tool_result
16
- - name: content
17
- type: text
18
- - name: tool_name
19
- isNullable: true
20
- - name: tool_call_id
21
- isNullable: true
22
- - type: created_at
23
- - type: updated_at
1
+ columns:
2
+ - type: pk
3
+ - name: conversation_id
4
+ type: fk
5
+ references:
6
+ table: mcp_conversation
7
+ column: id
8
+ onDelete: CASCADE
9
+ - name: role
10
+ type: enum
11
+ enum:
12
+ - user
13
+ - assistant
14
+ - tool_call
15
+ - tool_result
16
+ - name: content
17
+ type: text
18
+ - name: tool_name
19
+ isNullable: true
20
+ - name: tool_call_id
21
+ isNullable: true
22
+ - type: created_at
23
+ - type: updated_at
@@ -1,22 +1,22 @@
1
- columns:
2
- - type: pk
3
- - name: user_id
4
- type: fk
5
- references:
6
- table: user
7
- column: id
8
- onDelete: SET NULL
9
- isNullable: true
10
- - name: tool_name
11
- - name: input
12
- type: text
13
- isNullable: true
14
- - name: success
15
- type: boolean
16
- default: false
17
- - name: error
18
- isNullable: true
19
- - name: duration_ms
20
- type: int
21
- - type: created_at
22
- - type: updated_at
1
+ columns:
2
+ - type: pk
3
+ - name: user_id
4
+ type: fk
5
+ references:
6
+ table: user
7
+ column: id
8
+ onDelete: SET NULL
9
+ isNullable: true
10
+ - name: tool_name
11
+ - name: input
12
+ type: text
13
+ isNullable: true
14
+ - name: success
15
+ type: boolean
16
+ default: false
17
+ - name: error
18
+ isNullable: true
19
+ - name: duration_ms
20
+ type: int
21
+ - type: created_at
22
+ - type: updated_at
@@ -1,33 +1,33 @@
1
- columns:
2
- - type: pk
3
- - name: type
4
- type: enum
5
- enum:
6
- - HTTP
7
- - MCP
8
- default: HTTP
9
- - name: name
10
- isNullable: true
11
- - name: url
12
- isNullable: true
13
- - name: method
14
- type: enum
15
- enum:
16
- - GET
17
- - POST
18
- - PATCH
19
- - DELETE
20
- - PUT
21
- - OPTIONS
22
- - HEAD
23
- isNullable: true
24
- - name: tool_name
25
- isNullable: true
26
- - name: description
27
- isNullable: true
28
- - type: created_at
29
- - type: updated_at
30
- indices:
31
- - columns:
32
- - tool_name
33
- isUnique: true
1
+ columns:
2
+ - type: pk
3
+ - name: type
4
+ type: enum
5
+ enum:
6
+ - HTTP
7
+ - MCP
8
+ default: HTTP
9
+ - name: name
10
+ isNullable: true
11
+ - name: url
12
+ isNullable: true
13
+ - name: method
14
+ type: enum
15
+ enum:
16
+ - GET
17
+ - POST
18
+ - PATCH
19
+ - DELETE
20
+ - PUT
21
+ - OPTIONS
22
+ - HEAD
23
+ isNullable: true
24
+ - name: tool_name
25
+ isNullable: true
26
+ - name: description
27
+ isNullable: true
28
+ - type: created_at
29
+ - type: updated_at
30
+ indices:
31
+ - columns:
32
+ - tool_name
33
+ isUnique: true
@@ -0,0 +1,40 @@
1
+ columns:
2
+ - type: pk
3
+ - name: target_user_id
4
+ type: fk
5
+ references:
6
+ table: user
7
+ column: id
8
+ onDelete: CASCADE
9
+ onUpdate: CASCADE
10
+ - name: actor_user_id
11
+ type: fk
12
+ isNullable: true
13
+ references:
14
+ table: user
15
+ column: id
16
+ onDelete: SET NULL
17
+ onUpdate: CASCADE
18
+ - name: action
19
+ type: varchar
20
+ length: 80
21
+ - name: summary
22
+ type: text
23
+ isNullable: true
24
+ - name: before_data
25
+ type: text
26
+ isNullable: true
27
+ - name: after_data
28
+ type: text
29
+ isNullable: true
30
+ - name: ip_address
31
+ type: varchar
32
+ length: 64
33
+ isNullable: true
34
+ - type: created_at
35
+ - type: updated_at
36
+
37
+ indices:
38
+ - columns: [target_user_id]
39
+ - columns: [actor_user_id]
40
+ - columns: [action]