@webda/core 2.4.2 → 3.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.
Files changed (227) hide show
  1. package/lib/application.d.ts +171 -34
  2. package/lib/application.js +243 -47
  3. package/lib/application.js.map +1 -1
  4. package/lib/application.spec.js +44 -8
  5. package/lib/application.spec.js.map +1 -1
  6. package/lib/core.d.ts +113 -54
  7. package/lib/core.js +222 -135
  8. package/lib/core.js.map +1 -1
  9. package/lib/core.spec.js +87 -43
  10. package/lib/core.spec.js.map +1 -1
  11. package/lib/errors.d.ts +65 -0
  12. package/lib/errors.js +113 -0
  13. package/lib/errors.js.map +1 -0
  14. package/lib/errors.spec.d.ts +1 -0
  15. package/lib/errors.spec.js +33 -0
  16. package/lib/errors.spec.js.map +1 -0
  17. package/lib/index.d.ts +3 -0
  18. package/lib/index.js +3 -0
  19. package/lib/index.js.map +1 -1
  20. package/lib/models/aclmodel.d.ts +4 -4
  21. package/lib/models/aclmodel.js +10 -6
  22. package/lib/models/aclmodel.js.map +1 -1
  23. package/lib/models/aclmodel.spec.js +33 -24
  24. package/lib/models/aclmodel.spec.js.map +1 -1
  25. package/lib/models/coremodel.d.ts +284 -92
  26. package/lib/models/coremodel.js +403 -103
  27. package/lib/models/coremodel.js.map +1 -1
  28. package/lib/models/coremodel.spec.js +162 -24
  29. package/lib/models/coremodel.spec.js.map +1 -1
  30. package/lib/models/ident.d.ts +20 -6
  31. package/lib/models/ident.js.map +1 -1
  32. package/lib/models/ownermodel.d.ts +13 -23
  33. package/lib/models/ownermodel.js +24 -51
  34. package/lib/models/ownermodel.js.map +1 -1
  35. package/lib/models/ownermodel.spec.js +23 -11
  36. package/lib/models/ownermodel.spec.js.map +1 -1
  37. package/lib/models/relations.d.ts +167 -0
  38. package/lib/models/relations.js +113 -0
  39. package/lib/models/relations.js.map +1 -0
  40. package/lib/models/rolemodel.d.ts +3 -3
  41. package/lib/models/rolemodel.js +6 -6
  42. package/lib/models/rolemodel.js.map +1 -1
  43. package/lib/models/rolemodel.spec.js +12 -12
  44. package/lib/models/rolemodel.spec.js.map +1 -1
  45. package/lib/models/user.d.ts +40 -24
  46. package/lib/models/user.js +74 -48
  47. package/lib/models/user.js.map +1 -1
  48. package/lib/models/user.spec.js +24 -4
  49. package/lib/models/user.spec.js.map +1 -1
  50. package/lib/queues/memoryqueue.spec.js +9 -5
  51. package/lib/queues/memoryqueue.spec.js.map +1 -1
  52. package/lib/queues/queueservice.js.map +1 -1
  53. package/lib/router.d.ts +17 -8
  54. package/lib/router.js +81 -9
  55. package/lib/router.js.map +1 -1
  56. package/lib/router.spec.js +89 -5
  57. package/lib/router.spec.js.map +1 -1
  58. package/lib/services/asyncevents.spec.js +4 -4
  59. package/lib/services/authentication.d.ts +21 -22
  60. package/lib/services/authentication.js +90 -109
  61. package/lib/services/authentication.js.map +1 -1
  62. package/lib/services/authentication.spec.js +51 -65
  63. package/lib/services/authentication.spec.js.map +1 -1
  64. package/lib/services/binary.d.ts +132 -31
  65. package/lib/services/binary.js +257 -72
  66. package/lib/services/binary.js.map +1 -1
  67. package/lib/services/binary.spec.d.ts +16 -6
  68. package/lib/services/binary.spec.js +44 -117
  69. package/lib/services/binary.spec.js.map +1 -1
  70. package/lib/services/cloudbinary.d.ts +9 -10
  71. package/lib/services/cloudbinary.js +14 -15
  72. package/lib/services/cloudbinary.js.map +1 -1
  73. package/lib/services/cloudbinary.spec.d.ts +2 -2
  74. package/lib/services/cloudbinary.spec.js +13 -12
  75. package/lib/services/cloudbinary.spec.js.map +1 -1
  76. package/lib/services/configuration.js +9 -9
  77. package/lib/services/configuration.js.map +1 -1
  78. package/lib/services/configuration.spec.js +5 -7
  79. package/lib/services/configuration.spec.js.map +1 -1
  80. package/lib/services/cron.spec.js +3 -4
  81. package/lib/services/cron.spec.js.map +1 -1
  82. package/lib/services/cryptoservice.d.ts +2 -2
  83. package/lib/services/cryptoservice.js +5 -2
  84. package/lib/services/cryptoservice.js.map +1 -1
  85. package/lib/services/domainservice.d.ts +113 -0
  86. package/lib/services/domainservice.js +357 -0
  87. package/lib/services/domainservice.js.map +1 -0
  88. package/lib/services/domainservice.spec.d.ts +1 -0
  89. package/lib/services/domainservice.spec.js +334 -0
  90. package/lib/services/domainservice.spec.js.map +1 -0
  91. package/lib/services/echo.d.ts +2 -2
  92. package/lib/services/echo.js.map +1 -1
  93. package/lib/services/echo.spec.js +9 -2
  94. package/lib/services/echo.spec.js.map +1 -1
  95. package/lib/services/filebinary.d.ts +13 -14
  96. package/lib/services/filebinary.js +79 -73
  97. package/lib/services/filebinary.js.map +1 -1
  98. package/lib/services/filebinary.spec.d.ts +5 -0
  99. package/lib/services/filebinary.spec.js +222 -11
  100. package/lib/services/filebinary.spec.js.map +1 -1
  101. package/lib/services/fileconfiguration.js +4 -4
  102. package/lib/services/fileconfiguration.js.map +1 -1
  103. package/lib/services/fileconfiguration.spec.js +23 -24
  104. package/lib/services/fileconfiguration.spec.js.map +1 -1
  105. package/lib/services/invitationservice.d.ts +11 -9
  106. package/lib/services/invitationservice.js +17 -23
  107. package/lib/services/invitationservice.js.map +1 -1
  108. package/lib/services/invitationservice.spec.js +43 -40
  109. package/lib/services/invitationservice.spec.js.map +1 -1
  110. package/lib/services/kubernetesconfiguration.js +12 -22
  111. package/lib/services/kubernetesconfiguration.js.map +1 -1
  112. package/lib/services/kubernetesconfiguration.spec.js +1 -6
  113. package/lib/services/kubernetesconfiguration.spec.js.map +1 -1
  114. package/lib/services/mailer.js +1 -1
  115. package/lib/services/mailer.js.map +1 -1
  116. package/lib/services/mailer.spec.js +4 -1
  117. package/lib/services/mailer.spec.js.map +1 -1
  118. package/lib/services/oauth.d.ts +17 -9
  119. package/lib/services/oauth.js +30 -4
  120. package/lib/services/oauth.js.map +1 -1
  121. package/lib/services/oauth.spec.js +32 -15
  122. package/lib/services/oauth.spec.js.map +1 -1
  123. package/lib/services/prometheus.spec.js.map +1 -1
  124. package/lib/services/proxy.d.ts +9 -8
  125. package/lib/services/proxy.js +65 -36
  126. package/lib/services/proxy.js.map +1 -1
  127. package/lib/services/proxy.spec.js +28 -2
  128. package/lib/services/proxy.spec.js.map +1 -1
  129. package/lib/services/resource.d.ts +3 -3
  130. package/lib/services/resource.js +4 -3
  131. package/lib/services/resource.js.map +1 -1
  132. package/lib/services/resource.spec.js +3 -3
  133. package/lib/services/resource.spec.js.map +1 -1
  134. package/lib/services/service.d.ts +10 -13
  135. package/lib/services/service.js +29 -13
  136. package/lib/services/service.js.map +1 -1
  137. package/lib/services/service.spec.js +49 -11
  138. package/lib/services/service.spec.js.map +1 -1
  139. package/lib/services/version.d.ts +2 -2
  140. package/lib/services/version.js.map +1 -1
  141. package/lib/stores/aggregator.js +1 -0
  142. package/lib/stores/aggregator.js.map +1 -1
  143. package/lib/stores/aliasstore.d.ts +2 -2
  144. package/lib/stores/aliasstore.js +15 -4
  145. package/lib/stores/aliasstore.js.map +1 -1
  146. package/lib/stores/aliasstore.spec.js +4 -2
  147. package/lib/stores/aliasstore.spec.js.map +1 -1
  148. package/lib/stores/file.d.ts +5 -2
  149. package/lib/stores/file.js +11 -8
  150. package/lib/stores/file.js.map +1 -1
  151. package/lib/stores/file.spec.js +21 -34
  152. package/lib/stores/file.spec.js.map +1 -1
  153. package/lib/stores/mapper.d.ts +4 -2
  154. package/lib/stores/mapper.js +18 -11
  155. package/lib/stores/mapper.js.map +1 -1
  156. package/lib/stores/mapper.spec.js +6 -3
  157. package/lib/stores/mapper.spec.js.map +1 -1
  158. package/lib/stores/memory.d.ts +5 -2
  159. package/lib/stores/memory.js +11 -9
  160. package/lib/stores/memory.js.map +1 -1
  161. package/lib/stores/memory.spec.d.ts +3 -0
  162. package/lib/stores/memory.spec.js +100 -11
  163. package/lib/stores/memory.spec.js.map +1 -1
  164. package/lib/stores/store.d.ts +177 -87
  165. package/lib/stores/store.js +312 -141
  166. package/lib/stores/store.js.map +1 -1
  167. package/lib/stores/store.spec.d.ts +2 -2
  168. package/lib/stores/store.spec.js +54 -38
  169. package/lib/stores/store.spec.js.map +1 -1
  170. package/lib/stores/webdaql/WebdaQLLexer.d.ts +14 -13
  171. package/lib/stores/webdaql/WebdaQLLexer.js +121 -112
  172. package/lib/stores/webdaql/WebdaQLLexer.js.map +1 -1
  173. package/lib/stores/webdaql/WebdaQLParserLexer.d.ts +14 -13
  174. package/lib/stores/webdaql/WebdaQLParserLexer.js +121 -112
  175. package/lib/stores/webdaql/WebdaQLParserLexer.js.map +1 -1
  176. package/lib/stores/webdaql/WebdaQLParserListener.d.ts +15 -3
  177. package/lib/stores/webdaql/WebdaQLParserParser.d.ts +23 -13
  178. package/lib/stores/webdaql/WebdaQLParserParser.js +149 -94
  179. package/lib/stores/webdaql/WebdaQLParserParser.js.map +1 -1
  180. package/lib/stores/webdaql/WebdaQLParserVisitor.d.ts +9 -2
  181. package/lib/stores/webdaql/query.d.ts +6 -2
  182. package/lib/stores/webdaql/query.js +14 -1
  183. package/lib/stores/webdaql/query.js.map +1 -1
  184. package/lib/stores/webdaql/query.spec.js +10 -1
  185. package/lib/stores/webdaql/query.spec.js.map +1 -1
  186. package/lib/test.d.ts +48 -19
  187. package/lib/test.js +171 -63
  188. package/lib/test.js.map +1 -1
  189. package/lib/unpackedapplication.d.ts +5 -0
  190. package/lib/unpackedapplication.js +58 -10
  191. package/lib/unpackedapplication.js.map +1 -1
  192. package/lib/utils/context.d.ts +76 -29
  193. package/lib/utils/context.js +91 -55
  194. package/lib/utils/context.js.map +1 -1
  195. package/lib/utils/context.spec.d.ts +9 -1
  196. package/lib/utils/context.spec.js +73 -8
  197. package/lib/utils/context.spec.js.map +1 -1
  198. package/lib/utils/cookie.d.ts +4 -5
  199. package/lib/utils/cookie.js +1 -2
  200. package/lib/utils/cookie.js.map +1 -1
  201. package/lib/utils/cookie.spec.js +5 -3
  202. package/lib/utils/cookie.spec.js.map +1 -1
  203. package/lib/utils/httpcontext.spec.js +9 -3
  204. package/lib/utils/httpcontext.spec.js.map +1 -1
  205. package/lib/utils/serializers.d.ts +46 -17
  206. package/lib/utils/serializers.js +116 -2
  207. package/lib/utils/serializers.js.map +1 -1
  208. package/lib/utils/serializers.spec.js +84 -20
  209. package/lib/utils/serializers.spec.js.map +1 -1
  210. package/lib/utils/session.d.ts +14 -8
  211. package/lib/utils/session.js +14 -3
  212. package/lib/utils/session.js.map +1 -1
  213. package/lib/utils/session.spec.js +6 -1
  214. package/lib/utils/session.spec.js.map +1 -1
  215. package/package.json +16 -10
  216. package/test/cachedapp/webda.config.json +6 -1
  217. package/test/config-cached.json +5 -0
  218. package/test/config-file-missing-file.json +5 -7
  219. package/test/config-file-no-reload.json +5 -7
  220. package/test/config-file-reload.json +5 -7
  221. package/test/config-kube-reload.json +5 -11
  222. package/test/config-reload.json +2 -4
  223. package/test/config.json +12 -2
  224. package/test/moddas/voidstore.js +1 -1
  225. package/test/models/ident.js +6 -4
  226. package/test/models/task.js +4 -4
  227. package/webda.module.json +1587 -1266
package/webda.module.json CHANGED
@@ -1,48 +1,227 @@
1
1
  {
2
+ "beans": {},
3
+ "deployers": {},
2
4
  "moddas": {
3
- "webda/aggregator": "lib/stores/aggregator:default",
4
- "webda/aliasstore": "lib/stores/aliasstore:AliasStore",
5
- "webda/asyncevents": "lib/services/asyncevents:EventService",
6
- "webda/authentication": "lib/services/authentication:Authentication",
7
- "webda/configurationservice": "lib/services/configuration:default",
8
- "webda/consolelogger": "lib/utils/logger:ConsoleLoggerService",
9
- "webda/cookiesessionmanager": "lib/utils/session:CookieSessionManager",
10
- "webda/cronservice": "lib/services/cron:CronService",
11
- "webda/cryptoservice": "lib/services/cryptoservice:default",
12
- "webda/debugmailer": "lib/services/debugmailer:default",
13
- "webda/echoservice": "lib/services/echo:EchoService",
14
- "webda/filebinary": "lib/services/filebinary:FileBinary",
15
- "webda/fileconfiguration": "lib/services/fileconfiguration:FileConfigurationService",
16
- "webda/filelogger": "lib/utils/logger:FileLoggerService",
17
- "webda/filequeue": "lib/queues/filequeue:FileQueue",
18
- "webda/filestore": "lib/stores/file:FileStore",
19
- "webda/invitationservice": "lib/services/invitationservice:default",
20
- "webda/kubernetesconfigurationservice": "lib/services/kubernetesconfiguration:KubernetesConfigurationService",
21
- "webda/mailer": "lib/services/mailer:Mailer",
22
- "webda/mapper": "lib/stores/mapper:default",
23
- "webda/memorylogger": "lib/utils/logger:MemoryLoggerService",
24
- "webda/memoryqueue": "lib/queues/memoryqueue:MemoryQueue",
25
- "webda/memorystore": "lib/stores/memory:MemoryStore",
26
- "webda/multinotificationservice": "lib/services/notificationservice:default",
27
- "webda/prometheusservice": "lib/services/prometheus:PrometheusService",
28
- "webda/proxyservice": "lib/services/proxy:ProxyService",
29
- "webda/resourceservice": "lib/services/resource:default",
30
- "webda/versionservice": "lib/services/version:VersionService"
5
+ "Webda/Aggregator": "lib/stores/aggregator:default",
6
+ "Webda/AliasStore": "lib/stores/aliasstore:AliasStore",
7
+ "Webda/AsyncEvents": "lib/services/asyncevents:EventService",
8
+ "Webda/Authentication": "lib/services/authentication:Authentication",
9
+ "Webda/Binary": "lib/services/binary:BinaryService",
10
+ "Webda/ConfigurationService": "lib/services/configuration:default",
11
+ "Webda/ConsoleLogger": "lib/utils/logger:ConsoleLoggerService",
12
+ "Webda/CookieSessionManager": "lib/utils/session:CookieSessionManager",
13
+ "Webda/CronService": "lib/services/cron:CronService",
14
+ "Webda/CryptoService": "lib/services/cryptoservice:default",
15
+ "Webda/DebugMailer": "lib/services/debugmailer:default",
16
+ "Webda/EchoService": "lib/services/echo:EchoService",
17
+ "Webda/FileBinary": "lib/services/filebinary:FileBinary",
18
+ "Webda/FileConfiguration": "lib/services/fileconfiguration:FileConfigurationService",
19
+ "Webda/FileLogger": "lib/utils/logger:FileLoggerService",
20
+ "Webda/FileQueue": "lib/queues/filequeue:FileQueue",
21
+ "Webda/FileStore": "lib/stores/file:FileStore",
22
+ "Webda/InvitationService": "lib/services/invitationservice:default",
23
+ "Webda/KubernetesConfigurationService": "lib/services/kubernetesconfiguration:KubernetesConfigurationService",
24
+ "Webda/Mailer": "lib/services/mailer:Mailer",
25
+ "Webda/Mapper": "lib/stores/mapper:default",
26
+ "Webda/MemoryLogger": "lib/utils/logger:MemoryLoggerService",
27
+ "Webda/MemoryQueue": "lib/queues/memoryqueue:MemoryQueue",
28
+ "Webda/MemoryStore": "lib/stores/memory:MemoryStore",
29
+ "Webda/ModelsOperationsService": "lib/services/domainservice:ModelsOperationsService",
30
+ "Webda/MultiNotificationService": "lib/services/notificationservice:default",
31
+ "Webda/PrometheusService": "lib/services/prometheus:PrometheusService",
32
+ "Webda/ProxyService": "lib/services/proxy:ProxyService",
33
+ "Webda/RESTDomainService": "lib/services/domainservice:RESTDomainService",
34
+ "Webda/ResourceService": "lib/services/resource:default",
35
+ "Webda/VersionService": "lib/services/version:VersionService"
31
36
  },
32
- "beans": {},
33
37
  "models": {
34
- "webda/aclmodel": "lib/models/aclmodel:default",
35
- "webda/context": "lib/utils/context:Context",
36
- "webda/coremodel": "lib/models/coremodel:CoreModel",
37
- "webda/ident": "lib/models/ident:Ident",
38
- "webda/ownermodel": "lib/models/ownermodel:OwnerModel",
39
- "webda/securecookie": "lib/utils/cookie:SecureCookie",
40
- "webda/session": "lib/utils/session:Session",
41
- "webda/user": "lib/models/user:User"
38
+ "graph": {
39
+ "Webda/AclModel": {},
40
+ "Webda/CoreModel": {},
41
+ "Webda/Ident": {
42
+ "links": [
43
+ {
44
+ "attribute": "_user",
45
+ "model": "Webda/User",
46
+ "type": "LINK"
47
+ }
48
+ ]
49
+ },
50
+ "Webda/OwnerModel": {
51
+ "links": [
52
+ {
53
+ "attribute": "_user",
54
+ "model": "Webda/User",
55
+ "type": "LINK"
56
+ }
57
+ ]
58
+ },
59
+ "Webda/RoleModel": {},
60
+ "Webda/SimpleUser": {
61
+ "maps": [
62
+ {
63
+ "attribute": "_idents",
64
+ "model": "Webda/Ident",
65
+ "targetAttribute": "_type | uuid | email"
66
+ }
67
+ ]
68
+ },
69
+ "Webda/User": {},
70
+ "Webda/UuidModel": {}
71
+ },
72
+ "tree": {
73
+ "Webda/AclModel": {},
74
+ "Webda/RoleModel": {},
75
+ "Webda/User": {
76
+ "Webda/SimpleUser": {}
77
+ },
78
+ "Webda/UuidModel": {
79
+ "Webda/OwnerModel": {
80
+ "Webda/Ident": {}
81
+ }
82
+ }
83
+ },
84
+ "plurals": {},
85
+ "list": {
86
+ "Webda/AclModel": "lib/models/aclmodel:default",
87
+ "Webda/CoreModel": "lib/models/coremodel:CoreModel",
88
+ "Webda/Ident": "lib/models/ident:Ident",
89
+ "Webda/OwnerModel": "lib/models/ownermodel:OwnerModel",
90
+ "Webda/RoleModel": "lib/models/rolemodel:RoleModel",
91
+ "Webda/SimpleUser": "lib/models/user:SimpleUser",
92
+ "Webda/User": "lib/models/user:User",
93
+ "Webda/UuidModel": "lib/models/coremodel:UuidModel"
94
+ },
95
+ "reflections": {
96
+ "Webda/AclModel": {
97
+ "_creator": "string",
98
+ "___acl": "Acl",
99
+ "_permissions": "string[]",
100
+ "___class": "CoreModelDefinition",
101
+ "___type": "string",
102
+ "___types": "string[]",
103
+ "___ctx": "OperationContext",
104
+ "___store": "Store<this>",
105
+ "___dirty": "Set<string | symbol>",
106
+ "_creationDate": "Date",
107
+ "_lastUpdate": "Date",
108
+ "___deleted": "boolean"
109
+ },
110
+ "Webda/CoreModel": {
111
+ "___class": "CoreModelDefinition",
112
+ "___type": "string",
113
+ "___types": "string[]",
114
+ "___ctx": "OperationContext",
115
+ "___store": "Store<this>",
116
+ "___dirty": "Set<string | symbol>",
117
+ "_creationDate": "Date",
118
+ "_lastUpdate": "Date",
119
+ "___deleted": "boolean"
120
+ },
121
+ "Webda/Ident": {
122
+ "_type": "string",
123
+ "uid": "string",
124
+ "___profile": "any",
125
+ "___tokens": "IdentTokens",
126
+ "_lastUsed": "Date",
127
+ "_user": "ModelLink<User>",
128
+ "___new": "boolean",
129
+ "_failedLogin": "number",
130
+ "_lastValidationEmail": "number",
131
+ "_validation": "Date",
132
+ "email": "string",
133
+ "provider": "string",
134
+ "profile": "any",
135
+ "public": "boolean",
136
+ "uuid": "string",
137
+ "___class": "CoreModelDefinition",
138
+ "___type": "string",
139
+ "___types": "string[]",
140
+ "___ctx": "OperationContext",
141
+ "___store": "Store<this>",
142
+ "___dirty": "Set<string | symbol>",
143
+ "_creationDate": "Date",
144
+ "_lastUpdate": "Date",
145
+ "___deleted": "boolean"
146
+ },
147
+ "Webda/OwnerModel": {
148
+ "_user": "ModelLink<User>",
149
+ "public": "boolean",
150
+ "uuid": "string",
151
+ "___class": "CoreModelDefinition",
152
+ "___type": "string",
153
+ "___types": "string[]",
154
+ "___ctx": "OperationContext",
155
+ "___store": "Store<this>",
156
+ "___dirty": "Set<string | symbol>",
157
+ "_creationDate": "Date",
158
+ "_lastUpdate": "Date",
159
+ "___deleted": "boolean"
160
+ },
161
+ "Webda/RoleModel": {
162
+ "___class": "CoreModelDefinition",
163
+ "___type": "string",
164
+ "___types": "string[]",
165
+ "___ctx": "OperationContext",
166
+ "___store": "Store<this>",
167
+ "___dirty": "Set<string | symbol>",
168
+ "_creationDate": "Date",
169
+ "_lastUpdate": "Date",
170
+ "___deleted": "boolean"
171
+ },
172
+ "Webda/SimpleUser": {
173
+ "_groups": "string[]",
174
+ "_roles": "string[]",
175
+ "_idents": "ModelsMapped<Ident, \"_type\" | \"uuid\" | \"email\">",
176
+ "___password": "string",
177
+ "displayName": "string",
178
+ "_lastPasswordRecovery": "number",
179
+ "_avatar": "string",
180
+ "locale": "string",
181
+ "email": "string",
182
+ "___class": "CoreModelDefinition",
183
+ "___type": "string",
184
+ "___types": "string[]",
185
+ "___ctx": "OperationContext",
186
+ "___store": "Store<this>",
187
+ "___dirty": "Set<string | symbol>",
188
+ "_creationDate": "Date",
189
+ "_lastUpdate": "Date",
190
+ "___deleted": "boolean"
191
+ },
192
+ "Webda/User": {
193
+ "___password": "string",
194
+ "displayName": "string",
195
+ "_lastPasswordRecovery": "number",
196
+ "_avatar": "string",
197
+ "locale": "string",
198
+ "email": "string",
199
+ "___class": "CoreModelDefinition",
200
+ "___type": "string",
201
+ "___types": "string[]",
202
+ "___ctx": "OperationContext",
203
+ "___store": "Store<this>",
204
+ "___dirty": "Set<string | symbol>",
205
+ "_creationDate": "Date",
206
+ "_lastUpdate": "Date",
207
+ "___deleted": "boolean"
208
+ },
209
+ "Webda/UuidModel": {
210
+ "uuid": "string",
211
+ "___class": "CoreModelDefinition",
212
+ "___type": "string",
213
+ "___types": "string[]",
214
+ "___ctx": "OperationContext",
215
+ "___store": "Store<this>",
216
+ "___dirty": "Set<string | symbol>",
217
+ "_creationDate": "Date",
218
+ "_lastUpdate": "Date",
219
+ "___deleted": "boolean"
220
+ }
221
+ }
42
222
  },
43
- "deployers": {},
44
223
  "schemas": {
45
- "webda/ownermodel": {
224
+ "Webda/AclModel": {
46
225
  "type": "object",
47
226
  "properties": {
48
227
  "_creationDate": {
@@ -57,173 +236,207 @@
57
236
  "description": "Last update date",
58
237
  "readOnly": true
59
238
  },
60
- "_user": {
239
+ "_creator": {
61
240
  "type": "string",
62
- "description": "Default owner of the object",
241
+ "description": "Object creator",
63
242
  "readOnly": true
64
- },
65
- "public": {
66
- "type": "boolean",
67
- "description": "Define if the object is publicly readable",
68
- "default": false
69
- },
70
- "uuid": {
71
- "type": "string",
72
- "description": "UUID of the object"
73
243
  }
74
244
  },
75
- "required": [
76
- "uuid"
77
- ],
245
+ "description": "Object that contains ACL to define its own permissions",
78
246
  "$schema": "http://json-schema.org/draft-07/schema#",
79
- "title": "OwnerModel"
247
+ "title": "AclModel"
80
248
  },
81
- "webda/ident": {
249
+ "Webda/Aggregator": {
82
250
  "type": "object",
83
251
  "properties": {
84
- "_creationDate": {
85
- "type": "string",
86
- "format": "date-time",
87
- "description": "Creation date",
88
- "readOnly": true
89
- },
90
- "_lastUpdate": {
252
+ "type": {
91
253
  "type": "string",
92
- "format": "date-time",
93
- "description": "Last update date",
94
- "readOnly": true
254
+ "description": "Type of the service"
95
255
  },
96
- "_user": {
256
+ "url": {
97
257
  "type": "string",
98
- "description": "Default owner of the object",
99
- "readOnly": true
258
+ "description": "URL on which to serve the content"
100
259
  },
101
- "public": {
102
- "type": "boolean",
103
- "description": "Define if the object is publicly readable",
104
- "default": false
260
+ "fields": {
261
+ "type": "array",
262
+ "items": {
263
+ "type": "string"
264
+ },
265
+ "description": "Field to duplicate"
105
266
  },
106
- "uuid": {
267
+ "source": {
107
268
  "type": "string",
108
- "description": "UUID of the object"
269
+ "description": "Source service"
109
270
  },
110
- "_type": {
271
+ "target": {
111
272
  "type": "string",
112
- "readOnly": true
273
+ "description": "Target store"
113
274
  },
114
- "uid": {
115
- "type": "string"
275
+ "async": {
276
+ "type": "boolean",
277
+ "description": "Async",
278
+ "default": false
116
279
  },
117
- "_lastUsed": {
280
+ "attribute": {
118
281
  "type": "string",
119
- "format": "date-time",
120
- "readOnly": true
282
+ "description": "Attribute to use for link\n\nDepending on the type - string[]: will consider each string as id - string: will be consider as id - Object: each keys will be consider as id"
121
283
  },
122
- "_failedLogin": {
123
- "type": "number",
124
- "readOnly": true
284
+ "targetAttribute": {
285
+ "type": "string",
286
+ "description": "The object will contain a Mapper"
125
287
  },
126
- "_lastValidationEmail": {
127
- "type": "number",
128
- "description": "If EmailIdent",
129
- "readOnly": true
288
+ "cascade": {
289
+ "type": "boolean",
290
+ "description": "Delete source if target object is deleted"
130
291
  },
131
- "_validation": {
292
+ "key": {
132
293
  "type": "string",
133
- "format": "date-time",
134
- "description": "When the ident was validated",
135
- "readOnly": true
294
+ "default": "index"
136
295
  },
137
- "email": {
138
- "type": "string",
139
- "description": "Email for this ident if it exist"
296
+ "openapi": {
297
+ "type": "object",
298
+ "additionalProperties": true
140
299
  }
141
300
  },
142
301
  "required": [
143
- "uid",
144
- "uuid"
302
+ "async",
303
+ "attribute",
304
+ "cascade",
305
+ "fields",
306
+ "key",
307
+ "source",
308
+ "target",
309
+ "targetAttribute",
310
+ "type"
145
311
  ],
146
- "description": "First basic model for Ident",
147
312
  "$schema": "http://json-schema.org/draft-07/schema#",
148
- "title": "Ident"
313
+ "title": "AggregatorService"
149
314
  },
150
- "webda/user": {
315
+ "Webda/AliasStore": {
151
316
  "type": "object",
152
317
  "properties": {
153
- "_creationDate": {
318
+ "type": {
154
319
  "type": "string",
155
- "format": "date-time",
156
- "description": "Creation date",
157
- "readOnly": true
320
+ "description": "Type of the service"
158
321
  },
159
- "_lastUpdate": {
322
+ "url": {
160
323
  "type": "string",
161
- "format": "date-time",
162
- "description": "Last update date",
163
- "readOnly": true
324
+ "description": "URL on which to serve the content"
164
325
  },
165
- "_user": {
326
+ "model": {
166
327
  "type": "string",
167
- "description": "Default owner of the object",
168
- "readOnly": true
328
+ "description": "Webda model to use within the Store",
329
+ "default": "Webda/CoreModel"
169
330
  },
170
- "public": {
331
+ "asyncDelete": {
171
332
  "type": "boolean",
172
- "description": "Define if the object is publicly readable",
333
+ "description": "async delete"
334
+ },
335
+ "expose": {
336
+ "$ref": "#/definitions/StoreExposeParameters",
337
+ "description": "Expose the service to an urls",
338
+ "deprecated": "will probably be removed in 4.0 in favor of Expose annotation"
339
+ },
340
+ "strict": {
341
+ "type": "boolean",
342
+ "description": "Allow to load object that does not have the type data\n\nIf set to true, then the Store will only managed the defined _model and no model extending this one",
173
343
  "default": false
174
344
  },
175
- "uuid": {
176
- "type": "string",
177
- "description": "UUID of the object"
345
+ "defaultModel": {
346
+ "type": "boolean",
347
+ "description": "When __type model not found, use the model If strict is setup this parameter is not used",
348
+ "default": true
178
349
  },
179
- "displayName": {
180
- "type": "string",
181
- "description": "Display name for this user"
350
+ "forceModel": {
351
+ "type": "boolean",
352
+ "description": "If set, Store will ignore the __type",
353
+ "default": false
182
354
  },
183
- "_lastPasswordRecovery": {
355
+ "slowQueryThreshold": {
184
356
  "type": "number",
185
- "description": "Last time the password was recovered",
186
- "readOnly": true
187
- },
188
- "_roles": {
189
- "type": "array",
190
- "items": {
191
- "type": "string"
192
- },
193
- "description": "Roles of the user",
194
- "readOnly": true
357
+ "description": "Slow query threshold",
358
+ "default": 30000
195
359
  },
196
- "_groups": {
197
- "type": "array",
198
- "items": {
360
+ "modelAliases": {
361
+ "type": "object",
362
+ "additionalProperties": {
199
363
  "type": "string"
200
364
  },
201
- "description": "Groups for a user",
202
- "readOnly": true
365
+ "description": "Model Aliases to allow easier rename of Model"
203
366
  },
204
- "_avatar": {
367
+ "targetStore": {
205
368
  "type": "string",
206
- "description": "Define the user avatar if exists",
207
- "readOnly": true
369
+ "description": "Store to alias"
208
370
  },
209
- "locale": {
371
+ "idTemplate": {
210
372
  "type": "string",
211
- "description": "Contains the locale of the user if known"
373
+ "description": "Store to alias"
212
374
  },
213
- "email": {
214
- "type": "string",
215
- "description": "Contain main user email if exists"
375
+ "openapi": {
376
+ "type": "object",
377
+ "additionalProperties": true
216
378
  }
217
379
  },
218
380
  "required": [
219
- "displayName",
220
- "uuid"
381
+ "asyncDelete",
382
+ "idTemplate",
383
+ "slowQueryThreshold",
384
+ "targetStore",
385
+ "type"
221
386
  ],
222
- "description": "First basic model for User",
223
387
  "$schema": "http://json-schema.org/draft-07/schema#",
224
- "title": "User"
388
+ "definitions": {
389
+ "StoreExposeParameters": {
390
+ "type": "object",
391
+ "properties": {
392
+ "url": {
393
+ "type": "string",
394
+ "description": "URL endpoint to use to expose REST Resources API",
395
+ "default": "service.getName().toLowerCase()"
396
+ },
397
+ "restrict": {
398
+ "type": "object",
399
+ "properties": {
400
+ "create": {
401
+ "type": "boolean",
402
+ "description": "Do not expose the POST"
403
+ },
404
+ "update": {
405
+ "type": "boolean",
406
+ "description": "Do not expose the PUT and PATCH"
407
+ },
408
+ "get": {
409
+ "type": "boolean",
410
+ "description": "Do not expose the GET"
411
+ },
412
+ "delete": {
413
+ "type": "boolean",
414
+ "description": "Do not expose the DELETE"
415
+ },
416
+ "query": {
417
+ "type": "boolean",
418
+ "description": "Do not expose the query endpoint"
419
+ }
420
+ },
421
+ "description": "You can restrict any part of the CRUD",
422
+ "default": {}
423
+ },
424
+ "queryMethod": {
425
+ "type": "string",
426
+ "enum": [
427
+ "PUT",
428
+ "GET"
429
+ ],
430
+ "description": "For confidentiality sometimes you might prefer to expose query through PUT To avoid GET logging",
431
+ "default": "GET"
432
+ }
433
+ },
434
+ "deprecated": "Store should not be exposed directly anymore\nYou should use the DomainService instead"
435
+ }
436
+ },
437
+ "title": "AliasStore"
225
438
  },
226
- "webda/cryptoservice": {
439
+ "Webda/AsyncEvents": {
227
440
  "type": "object",
228
441
  "properties": {
229
442
  "type": {
@@ -232,197 +445,265 @@
232
445
  },
233
446
  "url": {
234
447
  "type": "string",
235
- "description": "To expose JWKS"
448
+ "description": "URL on which to serve the content"
236
449
  },
237
- "keyActiveLifespan": {
238
- "type": "number",
239
- "description": "Number of hours a key should be used for encryption\n\nif auto-rotate is not set this"
450
+ "queues": {
451
+ "type": "object",
452
+ "additionalProperties": {
453
+ "type": "string"
454
+ },
455
+ "description": "Queues to post async events to"
240
456
  },
241
- "keyLifespan": {
242
- "type": "number",
243
- "description": "Number of hours allowed to decrypt data encrypted with this key"
457
+ "sync": {
458
+ "type": "boolean",
459
+ "description": "Make the event sending asynchronous"
244
460
  },
245
- "autoRotate": {
246
- "type": "number",
247
- "description": "Try to rotate keys when they expire in days"
461
+ "openapi": {
462
+ "type": "object",
463
+ "additionalProperties": true
464
+ }
465
+ },
466
+ "required": [
467
+ "type"
468
+ ],
469
+ "$schema": "http://json-schema.org/draft-07/schema#",
470
+ "title": "EventService"
471
+ },
472
+ "Webda/Authentication": {
473
+ "type": "object",
474
+ "properties": {
475
+ "type": {
476
+ "type": "string",
477
+ "description": "Type of the service"
248
478
  },
249
- "autoCreate": {
250
- "type": "boolean",
251
- "description": "Create first set of key if does not exist"
479
+ "url": {
480
+ "type": "string",
481
+ "description": "URL on which to serve the content",
482
+ "default": "/auth"
252
483
  },
253
- "asymetricType": {
484
+ "identModel": {
254
485
  "type": "string",
255
- "enum": [
256
- "rsa",
257
- "dsa",
258
- "ec",
259
- "ed25519",
260
- "ed448",
261
- "x25519",
262
- "x448",
263
- "dh"
264
- ],
265
- "description": "Type of asymetric key\n\nhttps://nodejs.org/api/crypto.html#cryptogeneratekeypairsynctype-options https://nodejs.org/docs/latest-v14.x/api/crypto.html#crypto_crypto_generatekeypairsync_type_options"
486
+ "description": "Idents store for authentication identifiers",
487
+ "default": "Webda/Ident"
266
488
  },
267
- "asymetricOptions": {
489
+ "userModel": {
490
+ "type": "string",
491
+ "description": "User store for authentication users",
492
+ "default": "Webda/User"
493
+ },
494
+ "email": {
268
495
  "type": "object",
269
496
  "properties": {
270
- "modulusLength": {
497
+ "mailer": {
498
+ "type": "string",
499
+ "description": "Mailer service name"
500
+ },
501
+ "postValidation": {
502
+ "type": "boolean",
503
+ "description": "Allow user to create their account without validating their email first"
504
+ },
505
+ "skipEmailValidation": {
506
+ "type": "boolean",
507
+ "description": "Do not even validate the email at all"
508
+ },
509
+ "delay": {
271
510
  "type": "number",
272
- "default": 2048
511
+ "description": "Minimal delay between two password recovery or validation email",
512
+ "default": "3600000 * 4"
273
513
  },
274
- "namedCurve": {
514
+ "failedLoginBeforeDelay": {
515
+ "type": "number",
516
+ "description": "When a delay is added between two attempt to authenticate",
517
+ "default": 3
518
+ }
519
+ },
520
+ "required": [
521
+ "postValidation",
522
+ "skipEmailValidation",
523
+ "delay",
524
+ "failedLoginBeforeDelay"
525
+ ],
526
+ "description": "Enable the email authentication"
527
+ },
528
+ "password": {
529
+ "type": "object",
530
+ "properties": {
531
+ "verifier": {
275
532
  "type": "string",
276
- "description": "Only if asymetricType \"ec\""
533
+ "description": "Password verifier Service name"
277
534
  },
278
- "publicKeyEncoding": {
279
- "type": "object",
280
- "properties": {
281
- "type": {
282
- "type": "string",
283
- "enum": [
284
- "spki",
285
- "pkcs1"
286
- ],
287
- "default": "spki"
288
- },
289
- "format": {
290
- "type": "string",
291
- "const": "pem"
292
- }
293
- }
535
+ "regexp": {
536
+ "type": "string",
537
+ "description": "Regexp that password must check",
538
+ "default": "{8,}"
539
+ }
540
+ }
541
+ },
542
+ "salt": {
543
+ "type": "string",
544
+ "description": "Number of salt iteration for bcrypt.hashSync"
545
+ },
546
+ "failureRedirect": {
547
+ "type": "string",
548
+ "description": "Redirect to this page when email validation failed"
549
+ },
550
+ "successRedirect": {
551
+ "type": "string",
552
+ "description": "Redirect to this page when email validation succeed"
553
+ },
554
+ "registerRedirect": {
555
+ "type": "string",
556
+ "description": "Redirect to this page once email is validate to finish the registration process"
557
+ },
558
+ "openapi": {
559
+ "type": "object",
560
+ "additionalProperties": true
561
+ }
562
+ },
563
+ "required": [
564
+ "failureRedirect",
565
+ "password",
566
+ "registerRedirect",
567
+ "salt",
568
+ "successRedirect",
569
+ "type"
570
+ ],
571
+ "$schema": "http://json-schema.org/draft-07/schema#",
572
+ "title": "Authentication"
573
+ },
574
+ "Webda/Binary": {
575
+ "type": "object",
576
+ "properties": {
577
+ "type": {
578
+ "type": "string",
579
+ "description": "Type of the service"
580
+ },
581
+ "url": {
582
+ "type": "string",
583
+ "description": "URL on which to serve the content"
584
+ },
585
+ "map": {
586
+ "type": "object",
587
+ "additionalProperties": {
588
+ "type": "array",
589
+ "items": {
590
+ "type": "string"
591
+ }
592
+ },
593
+ "description": "Define the map to Object collection\n\nkey is a Store name the string[] represent all valids attributes to store files in",
594
+ "deprecated": true
595
+ },
596
+ "models": {
597
+ "type": "object",
598
+ "additionalProperties": {
599
+ "type": "array",
600
+ "items": {
601
+ "type": "string"
602
+ }
603
+ },
604
+ "description": "Define the map of models\n* indicates all models\n\nkey is a Store name the string[] represent all valids attributes to store files in * indicates all attributes"
605
+ },
606
+ "expose": {
607
+ "type": "object",
608
+ "properties": {
609
+ "url": {
610
+ "type": "string",
611
+ "description": "URL to expose the service to"
294
612
  },
295
- "privateKeyEncoding": {
613
+ "restrict": {
296
614
  "type": "object",
297
615
  "properties": {
298
- "type": {
299
- "type": "string",
300
- "enum": [
301
- "pkcs1",
302
- "pkcs8",
303
- "sec1"
304
- ],
305
- "description": "https://nodejs.org/docs/latest-v14.x/api/crypto.html#crypto_keyobject_export_options",
306
- "default": "pkcs8"
616
+ "get": {
617
+ "type": "boolean",
618
+ "description": "Restrict GET"
307
619
  },
308
- "format": {
309
- "type": "string",
310
- "const": "pem"
620
+ "create": {
621
+ "type": "boolean",
622
+ "description": "Restrict POST"
311
623
  },
312
- "cipher": {
313
- "type": "string"
624
+ "delete": {
625
+ "type": "boolean",
626
+ "description": "Restrict DELETE"
314
627
  },
315
- "passphrase": {
316
- "type": "string"
628
+ "metadata": {
629
+ "type": "boolean",
630
+ "description": "Restrict update of metadata"
317
631
  }
318
- }
632
+ },
633
+ "description": "Restrict some APIs"
319
634
  }
320
635
  },
321
- "description": "Options for asymetric generation"
636
+ "required": [
637
+ "url"
638
+ ],
639
+ "description": "Expose the service to http",
640
+ "deprecated": "will be removed in 4.0"
322
641
  },
323
- "symetricKeyLength": {
642
+ "openapi": {
643
+ "type": "object",
644
+ "additionalProperties": true
645
+ }
646
+ },
647
+ "required": [
648
+ "map",
649
+ "models",
650
+ "type"
651
+ ],
652
+ "$schema": "http://json-schema.org/draft-07/schema#",
653
+ "title": "BinaryService"
654
+ },
655
+ "Webda/ConfigurationService": {
656
+ "type": "object",
657
+ "properties": {
658
+ "type": {
659
+ "type": "string",
660
+ "description": "Type of the service"
661
+ },
662
+ "url": {
663
+ "type": "string",
664
+ "description": "URL on which to serve the content"
665
+ },
666
+ "checkInterval": {
324
667
  "type": "number",
325
- "default": 256
668
+ "description": "Check configuration every {checkInterval} seconds"
326
669
  },
327
- "symetricCipher": {
670
+ "source": {
328
671
  "type": "string",
329
- "default": "aes-256-ctr"
672
+ "description": "Format sourceServiceName:sourceId"
330
673
  },
331
- "jwt": {
674
+ "default": {
675
+ "description": "Default configuration to use"
676
+ },
677
+ "openapi": {
332
678
  "type": "object",
333
- "properties": {
334
- "secretOrPublicKey": {
335
- "anyOf": [
336
- {
337
- "type": "string"
338
- },
339
- {
340
- "type": "object",
341
- "properties": {
342
- "BYTES_PER_ELEMENT": {
343
- "type": "number"
344
- },
345
- "buffer": {
346
- "$ref": "#/definitions/ArrayBufferLike"
347
- },
348
- "byteLength": {
349
- "type": "number"
350
- },
351
- "byteOffset": {
352
- "type": "number"
353
- },
354
- "length": {
355
- "type": "number"
356
- }
357
- },
358
- "required": [
359
- "BYTES_PER_ELEMENT",
360
- "buffer",
361
- "byteLength",
362
- "byteOffset",
363
- "length"
364
- ],
365
- "description": "Raw data is stored in instances of the Buffer class. A Buffer is similar to an array of integers but corresponds to a raw memory allocation outside the V8 heap. A Buffer cannot be resized. Valid string encodings: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex'"
366
- },
367
- {
368
- "type": "object",
369
- "properties": {
370
- "key": {
371
- "type": "string"
372
- },
373
- "passphrase": {
374
- "type": "string"
375
- }
376
- },
377
- "required": [
378
- "key",
379
- "passphrase"
380
- ]
381
- }
382
- ],
383
- "description": "Secret to use with JWT"
384
- },
385
- "algorithm": {
386
- "type": "string",
387
- "enum": [
388
- "HS256",
389
- "HS384",
390
- "HS512",
391
- "RS256",
392
- "RS384",
393
- "RS512",
394
- "PS256",
395
- "PS384",
396
- "PS512",
397
- "ES256",
398
- "ES384",
399
- "ES512"
400
- ],
401
- "description": "Algorithm for JWT token",
402
- "default": "HS256"
403
- },
404
- "expiresIn": {
405
- "type": [
406
- "number",
407
- "string"
408
- ],
409
- "description": "expressed in seconds or a string describing a time span zeit/ms.\n\nEg: 60, \"2 days\", \"10h\", \"7d\". A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default (\"120\" is equal to \"120ms\")."
410
- },
411
- "audience": {
412
- "type": "string",
413
- "description": "Audience for the jwt"
414
- },
415
- "issuer": {
416
- "type": "string",
417
- "description": "Issuer of the token"
418
- },
419
- "subject": {
420
- "type": "string",
421
- "description": "Subject for JWT"
422
- },
423
- "keyid": {}
424
- },
425
- "description": "Default JWT options"
679
+ "additionalProperties": true
680
+ }
681
+ },
682
+ "required": [
683
+ "default",
684
+ "source",
685
+ "type"
686
+ ],
687
+ "$schema": "http://json-schema.org/draft-07/schema#",
688
+ "title": "ConfigurationService"
689
+ },
690
+ "Webda/ConsoleLogger": {
691
+ "type": "object",
692
+ "properties": {
693
+ "type": {
694
+ "type": "string",
695
+ "description": "Type of the service"
696
+ },
697
+ "url": {
698
+ "type": "string",
699
+ "description": "URL on which to serve the content"
700
+ },
701
+ "logLevel": {
702
+ "$ref": "#/definitions/WorkerLogLevel",
703
+ "description": "Specify the log level of this service"
704
+ },
705
+ "format": {
706
+ "type": "string"
426
707
  },
427
708
  "openapi": {
428
709
  "type": "object",
@@ -430,33 +711,26 @@
430
711
  }
431
712
  },
432
713
  "required": [
433
- "asymetricType",
434
- "keyActiveLifespan",
435
- "keyLifespan",
714
+ "logLevel",
436
715
  "type"
437
716
  ],
438
717
  "$schema": "http://json-schema.org/draft-07/schema#",
439
718
  "definitions": {
440
- "ArrayBufferLike": {
441
- "anyOf": [
442
- {
443
- "type": "object",
444
- "properties": {
445
- "byteLength": {
446
- "type": "number"
447
- }
448
- },
449
- "required": [
450
- "byteLength"
451
- ]
452
- },
453
- {}
454
- ]
719
+ "WorkerLogLevel": {
720
+ "type": "string",
721
+ "enum": [
722
+ "ERROR",
723
+ "WARN",
724
+ "INFO",
725
+ "DEBUG",
726
+ "TRACE"
727
+ ],
728
+ "description": "LogLevel as intersection to compare with integer values"
455
729
  }
456
730
  },
457
- "title": "CryptoService"
731
+ "title": "ConsoleLoggerService"
458
732
  },
459
- "webda/cookiesessionmanager": {
733
+ "Webda/CookieSessionManager": {
460
734
  "type": "object",
461
735
  "properties": {
462
736
  "type": {
@@ -638,242 +912,31 @@
638
912
  },
639
913
  {}
640
914
  ]
641
- }
642
- },
643
- "title": "CookieSessionManager"
644
- },
645
- "webda/asyncevents": {
646
- "type": "object",
647
- "properties": {
648
- "type": {
649
- "type": "string",
650
- "description": "Type of the service"
651
- },
652
- "url": {
653
- "type": "string",
654
- "description": "URL on which to serve the content"
655
- },
656
- "queues": {
657
- "type": "object",
658
- "additionalProperties": {
659
- "type": "string"
660
- },
661
- "description": "Queues to post async events to"
662
- },
663
- "sync": {
664
- "type": "boolean",
665
- "description": "Make the event sending asynchronous"
666
- },
667
- "openapi": {
668
- "type": "object",
669
- "additionalProperties": true
670
- }
671
- },
672
- "required": [
673
- "type"
674
- ],
675
- "$schema": "http://json-schema.org/draft-07/schema#",
676
- "title": "AsyncEvents"
677
- },
678
- "webda/coremodel": {
679
- "type": "object",
680
- "properties": {
681
- "_creationDate": {
682
- "type": "string",
683
- "format": "date-time",
684
- "description": "Creation date",
685
- "readOnly": true
686
- },
687
- "_lastUpdate": {
688
- "type": "string",
689
- "format": "date-time",
690
- "description": "Last update date",
691
- "readOnly": true
692
- }
693
- },
694
- "description": "Basic Object in Webda\n\nIt is used to define a data stored Any variable starting with _ can only be set by the server Any variable starting with __ won't be exported outside of the server",
695
- "$schema": "http://json-schema.org/draft-07/schema#",
696
- "title": "CoreModel"
697
- },
698
- "webda/aclmodel": {
699
- "type": "object",
700
- "properties": {
701
- "_creationDate": {
702
- "type": "string",
703
- "format": "date-time",
704
- "description": "Creation date",
705
- "readOnly": true
706
- },
707
- "_lastUpdate": {
708
- "type": "string",
709
- "format": "date-time",
710
- "description": "Last update date",
711
- "readOnly": true
712
- },
713
- "_creator": {
714
- "type": "string",
715
- "description": "Object creator",
716
- "readOnly": true
717
- }
718
- },
719
- "description": "Object that contains ACL to define its own permissions",
720
- "$schema": "http://json-schema.org/draft-07/schema#",
721
- "title": "AclModel"
722
- },
723
- "webda/filequeue": {
724
- "type": "object",
725
- "properties": {
726
- "type": {
727
- "type": "string",
728
- "description": "Type of the service"
729
- },
730
- "url": {
731
- "type": "string",
732
- "description": "URL on which to serve the content"
733
- },
734
- "workerDelayer": {
735
- "type": "object",
736
- "properties": {
737
- "interval": {
738
- "type": "number",
739
- "description": "Interval"
740
- },
741
- "type": {
742
- "type": "string",
743
- "description": "Type of delayer registered in WaitDelayerFactoryRegistry"
744
- }
745
- },
746
- "required": [
747
- "interval",
748
- "type"
749
- ],
750
- "description": "Delayer between two failed attempts to process messages"
751
- },
752
- "workerParallelism": {
753
- "type": "boolean",
754
- "description": "Define if worker should process multi message received in //",
755
- "default": true
756
- },
757
- "maxConsumers": {
758
- "type": "number",
759
- "description": "Max number of queue consumers Queue will auto increase to this max number if queue is loaded and it will decrease to just one consumer if no messages are available",
760
- "default": 10
761
- },
762
- "expire": {
763
- "type": "number",
764
- "description": "Number of seconds before droping message",
765
- "default": 30
766
- },
767
- "folder": {
768
- "type": "string",
769
- "description": "Where to store the queue"
770
- },
771
- "openapi": {
772
- "type": "object",
773
- "additionalProperties": true
774
- }
775
- },
776
- "required": [
777
- "folder",
778
- "maxConsumers",
779
- "type"
780
- ],
781
- "$schema": "http://json-schema.org/draft-07/schema#",
782
- "title": "FileQueue"
783
- },
784
- "webda/memoryqueue": {
785
- "type": "object",
786
- "properties": {
787
- "type": {
788
- "type": "string",
789
- "description": "Type of the service"
790
- },
791
- "url": {
792
- "type": "string",
793
- "description": "URL on which to serve the content"
794
- },
795
- "workerDelayer": {
796
- "type": "object",
797
- "properties": {
798
- "interval": {
799
- "type": "number",
800
- "description": "Interval"
801
- },
802
- "type": {
803
- "type": "string",
804
- "description": "Type of delayer registered in WaitDelayerFactoryRegistry"
805
- }
806
- },
807
- "required": [
808
- "interval",
809
- "type"
810
- ],
811
- "description": "Delayer between two failed attempts to process messages"
812
- },
813
- "workerParallelism": {
814
- "type": "boolean",
815
- "description": "Define if worker should process multi message received in //",
816
- "default": true
817
- },
818
- "maxConsumers": {
819
- "type": "number",
820
- "description": "Max number of queue consumers Queue will auto increase to this max number if queue is loaded and it will decrease to just one consumer if no messages are available",
821
- "default": 10
822
- },
823
- "expire": {
824
- "type": "number",
825
- "description": "Number of seconds before droping message",
826
- "default": 30
827
- },
828
- "openapi": {
829
- "type": "object",
830
- "additionalProperties": true
831
- }
832
- },
833
- "required": [
834
- "maxConsumers",
835
- "type"
836
- ],
837
- "$schema": "http://json-schema.org/draft-07/schema#",
838
- "title": "MemoryQueue"
839
- },
840
- "webda/multinotificationservice": {
841
- "type": "object",
842
- "properties": {
843
- "type": {
844
- "type": "string",
845
- "description": "Type of the service"
846
- },
847
- "url": {
848
- "type": "string",
849
- "description": "URL on which to serve the content"
850
- },
851
- "senders": {
852
- "type": "array",
853
- "items": {
854
- "type": "string"
855
- },
856
- "description": "Notification service that will send The order of the array is important if multiple is false When multiple is `false` the first available NotificationService will be used, otherwise every available NotificationService will be used"
857
- },
858
- "multiple": {
859
- "type": "boolean",
860
- "description": "Define if it sends one or several notification per user",
861
- "default": false
915
+ }
916
+ },
917
+ "title": "CookieSessionManager"
918
+ },
919
+ "Webda/CoreModel": {
920
+ "type": "object",
921
+ "properties": {
922
+ "_creationDate": {
923
+ "type": "string",
924
+ "format": "date-time",
925
+ "description": "Creation date",
926
+ "readOnly": true
862
927
  },
863
- "openapi": {
864
- "type": "object",
865
- "additionalProperties": true
928
+ "_lastUpdate": {
929
+ "type": "string",
930
+ "format": "date-time",
931
+ "description": "Last update date",
932
+ "readOnly": true
866
933
  }
867
934
  },
868
- "required": [
869
- "senders",
870
- "type"
871
- ],
872
- "description": "Parameters for multi notification service",
935
+ "description": "Basic Object in Webda\n\nIt is used to define a data stored Any variable starting with _ can only be set by the server Any variable starting with __ won't be exported outside of the server",
873
936
  "$schema": "http://json-schema.org/draft-07/schema#",
874
- "title": "MultiNotificationService"
937
+ "title": "CoreModel"
875
938
  },
876
- "webda/mailer": {
939
+ "Webda/CronService": {
877
940
  "type": "object",
878
941
  "properties": {
879
942
  "type": {
@@ -884,42 +947,19 @@
884
947
  "type": "string",
885
948
  "description": "URL on which to serve the content"
886
949
  },
887
- "templates": {
888
- "type": "string",
889
- "description": "Specify which foldeer contains templates",
890
- "default": "templates"
891
- },
892
- "templatesEngine": {
893
- "type": "string",
894
- "description": "Template engine to usee",
895
- "default": "mustache"
896
- },
897
- "sender": {
898
- "type": "string",
899
- "description": "Define the default sender"
900
- },
901
- "emailTemplateOptions": {},
902
- "transport": {
903
- "type": "string",
904
- "description": "Define the type of transport to use"
905
- },
906
- "SES": {
907
- "description": "SES AWS Bean if transport === \"ses\""
908
- },
909
950
  "openapi": {
910
951
  "type": "object",
911
952
  "additionalProperties": true
912
953
  }
913
954
  },
914
955
  "required": [
915
- "SES",
916
- "sender",
917
956
  "type"
918
957
  ],
958
+ "description": "Interface to specify the Service parameters",
919
959
  "$schema": "http://json-schema.org/draft-07/schema#",
920
- "title": "Mailer"
960
+ "title": "ModelsOperationsService"
921
961
  },
922
- "webda/authentication": {
962
+ "Webda/CryptoService": {
923
963
  "type": "object",
924
964
  "properties": {
925
965
  "type": {
@@ -928,120 +968,197 @@
928
968
  },
929
969
  "url": {
930
970
  "type": "string",
931
- "description": "URL on which to serve the content",
932
- "default": "/auth"
971
+ "description": "To expose JWKS"
933
972
  },
934
- "identStore": {
935
- "type": "string",
936
- "description": "Idents store for authentication identifiers",
937
- "default": "idents"
973
+ "keyActiveLifespan": {
974
+ "type": "number",
975
+ "description": "Number of hours a key should be used for encryption\n\nif auto-rotate is not set this"
976
+ },
977
+ "keyLifespan": {
978
+ "type": "number",
979
+ "description": "Number of hours allowed to decrypt data encrypted with this key"
980
+ },
981
+ "autoRotate": {
982
+ "type": "number",
983
+ "description": "Try to rotate keys when they expire in days"
984
+ },
985
+ "autoCreate": {
986
+ "type": "boolean",
987
+ "description": "Create first set of key if does not exist"
938
988
  },
939
- "userStore": {
989
+ "asymetricType": {
940
990
  "type": "string",
941
- "description": "User store for authentication users",
942
- "default": "users"
991
+ "enum": [
992
+ "rsa",
993
+ "dsa",
994
+ "ec",
995
+ "ed25519",
996
+ "ed448",
997
+ "x25519",
998
+ "x448",
999
+ "dh"
1000
+ ],
1001
+ "description": "Type of asymetric key\n\nhttps://nodejs.org/api/crypto.html#cryptogeneratekeypairsynctype-options https://nodejs.org/docs/latest-v14.x/api/crypto.html#crypto_crypto_generatekeypairsync_type_options"
943
1002
  },
944
- "email": {
1003
+ "asymetricOptions": {
945
1004
  "type": "object",
946
1005
  "properties": {
947
- "mailer": {
948
- "type": "string",
949
- "description": "Mailer service name"
950
- },
951
- "postValidation": {
952
- "type": "boolean",
953
- "description": "Allow user to create their account without validating their email first"
1006
+ "modulusLength": {
1007
+ "type": "number",
1008
+ "default": 2048
954
1009
  },
955
- "skipEmailValidation": {
956
- "type": "boolean",
957
- "description": "Do not even validate the email at all"
1010
+ "namedCurve": {
1011
+ "type": "string",
1012
+ "description": "Only if asymetricType \"ec\""
958
1013
  },
959
- "delay": {
960
- "type": "number",
961
- "description": "Minimal delay between two password recovery or validation email",
962
- "default": "3600000 * 4"
1014
+ "publicKeyEncoding": {
1015
+ "type": "object",
1016
+ "properties": {
1017
+ "type": {
1018
+ "type": "string",
1019
+ "enum": [
1020
+ "spki",
1021
+ "pkcs1"
1022
+ ],
1023
+ "default": "spki"
1024
+ },
1025
+ "format": {
1026
+ "type": "string",
1027
+ "const": "pem"
1028
+ }
1029
+ }
963
1030
  },
964
- "failedLoginBeforeDelay": {
965
- "type": "number",
966
- "description": "When a delay is added between two attempt to authenticate",
967
- "default": 3
1031
+ "privateKeyEncoding": {
1032
+ "type": "object",
1033
+ "properties": {
1034
+ "type": {
1035
+ "type": "string",
1036
+ "enum": [
1037
+ "pkcs1",
1038
+ "pkcs8",
1039
+ "sec1"
1040
+ ],
1041
+ "description": "https://nodejs.org/docs/latest-v14.x/api/crypto.html#crypto_keyobject_export_options",
1042
+ "default": "pkcs8"
1043
+ },
1044
+ "format": {
1045
+ "type": "string",
1046
+ "const": "pem"
1047
+ },
1048
+ "cipher": {
1049
+ "type": "string"
1050
+ },
1051
+ "passphrase": {
1052
+ "type": "string"
1053
+ }
1054
+ }
968
1055
  }
969
1056
  },
970
- "required": [
971
- "postValidation",
972
- "skipEmailValidation",
973
- "delay",
974
- "failedLoginBeforeDelay"
975
- ],
976
- "description": "Enable the email authentication"
1057
+ "description": "Options for asymetric generation"
977
1058
  },
978
- "password": {
1059
+ "symetricKeyLength": {
1060
+ "type": "number",
1061
+ "default": 256
1062
+ },
1063
+ "symetricCipher": {
1064
+ "type": "string",
1065
+ "default": "aes-256-ctr"
1066
+ },
1067
+ "jwt": {
979
1068
  "type": "object",
980
1069
  "properties": {
981
- "verifier": {
1070
+ "secretOrPublicKey": {
1071
+ "anyOf": [
1072
+ {
1073
+ "type": "string"
1074
+ },
1075
+ {
1076
+ "type": "object",
1077
+ "properties": {
1078
+ "BYTES_PER_ELEMENT": {
1079
+ "type": "number"
1080
+ },
1081
+ "buffer": {
1082
+ "$ref": "#/definitions/ArrayBufferLike"
1083
+ },
1084
+ "byteLength": {
1085
+ "type": "number"
1086
+ },
1087
+ "byteOffset": {
1088
+ "type": "number"
1089
+ },
1090
+ "length": {
1091
+ "type": "number"
1092
+ }
1093
+ },
1094
+ "required": [
1095
+ "BYTES_PER_ELEMENT",
1096
+ "buffer",
1097
+ "byteLength",
1098
+ "byteOffset",
1099
+ "length"
1100
+ ],
1101
+ "description": "Raw data is stored in instances of the Buffer class. A Buffer is similar to an array of integers but corresponds to a raw memory allocation outside the V8 heap. A Buffer cannot be resized. Valid string encodings: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex'"
1102
+ },
1103
+ {
1104
+ "type": "object",
1105
+ "properties": {
1106
+ "key": {
1107
+ "type": "string"
1108
+ },
1109
+ "passphrase": {
1110
+ "type": "string"
1111
+ }
1112
+ },
1113
+ "required": [
1114
+ "key",
1115
+ "passphrase"
1116
+ ]
1117
+ }
1118
+ ],
1119
+ "description": "Secret to use with JWT"
1120
+ },
1121
+ "algorithm": {
982
1122
  "type": "string",
983
- "description": "Password verifier Service name"
1123
+ "enum": [
1124
+ "HS256",
1125
+ "HS384",
1126
+ "HS512",
1127
+ "RS256",
1128
+ "RS384",
1129
+ "RS512",
1130
+ "PS256",
1131
+ "PS384",
1132
+ "PS512",
1133
+ "ES256",
1134
+ "ES384",
1135
+ "ES512"
1136
+ ],
1137
+ "description": "Algorithm for JWT token",
1138
+ "default": "HS256"
984
1139
  },
985
- "regexp": {
1140
+ "expiresIn": {
1141
+ "type": [
1142
+ "number",
1143
+ "string"
1144
+ ],
1145
+ "description": "expressed in seconds or a string describing a time span zeit/ms.\n\nEg: 60, \"2 days\", \"10h\", \"7d\". A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default (\"120\" is equal to \"120ms\")."
1146
+ },
1147
+ "audience": {
1148
+ "type": "string",
1149
+ "description": "Audience for the jwt"
1150
+ },
1151
+ "issuer": {
1152
+ "type": "string",
1153
+ "description": "Issuer of the token"
1154
+ },
1155
+ "subject": {
986
1156
  "type": "string",
987
- "description": "Regexp that password must check",
988
- "default": "{8,}"
989
- }
990
- }
991
- },
992
- "salt": {
993
- "type": "string",
994
- "description": "Number of salt iteration for bcrypt.hashSync"
995
- },
996
- "failureRedirect": {
997
- "type": "string",
998
- "description": "Redirect to this page when email validation failed"
999
- },
1000
- "successRedirect": {
1001
- "type": "string",
1002
- "description": "Redirect to this page when email validation succeed"
1003
- },
1004
- "registerRedirect": {
1005
- "type": "string",
1006
- "description": "Redirect to this page once email is validate to finish the registration process"
1007
- },
1008
- "openapi": {
1009
- "type": "object",
1010
- "additionalProperties": true
1011
- }
1012
- },
1013
- "required": [
1014
- "failureRedirect",
1015
- "password",
1016
- "registerRedirect",
1017
- "salt",
1018
- "successRedirect",
1019
- "type"
1020
- ],
1021
- "$schema": "http://json-schema.org/draft-07/schema#",
1022
- "title": "Authentication"
1023
- },
1024
- "webda/configurationservice": {
1025
- "type": "object",
1026
- "properties": {
1027
- "type": {
1028
- "type": "string",
1029
- "description": "Type of the service"
1030
- },
1031
- "url": {
1032
- "type": "string",
1033
- "description": "URL on which to serve the content"
1034
- },
1035
- "checkInterval": {
1036
- "type": "number",
1037
- "description": "Check configuration every {checkInterval} seconds"
1038
- },
1039
- "source": {
1040
- "type": "string",
1041
- "description": "Format sourceServiceName:sourceId"
1042
- },
1043
- "default": {
1044
- "description": "Default configuration to use"
1157
+ "description": "Subject for JWT"
1158
+ },
1159
+ "keyid": {}
1160
+ },
1161
+ "description": "Default JWT options"
1045
1162
  },
1046
1163
  "openapi": {
1047
1164
  "type": "object",
@@ -1049,37 +1166,33 @@
1049
1166
  }
1050
1167
  },
1051
1168
  "required": [
1052
- "default",
1053
- "source",
1169
+ "asymetricType",
1170
+ "keyActiveLifespan",
1171
+ "keyLifespan",
1054
1172
  "type"
1055
1173
  ],
1056
1174
  "$schema": "http://json-schema.org/draft-07/schema#",
1057
- "title": "ConfigurationService"
1058
- },
1059
- "webda/cronservice": {
1060
- "type": "object",
1061
- "properties": {
1062
- "type": {
1063
- "type": "string",
1064
- "description": "Type of the service"
1065
- },
1066
- "url": {
1067
- "type": "string",
1068
- "description": "URL on which to serve the content"
1069
- },
1070
- "openapi": {
1071
- "type": "object",
1072
- "additionalProperties": true
1175
+ "definitions": {
1176
+ "ArrayBufferLike": {
1177
+ "anyOf": [
1178
+ {
1179
+ "type": "object",
1180
+ "properties": {
1181
+ "byteLength": {
1182
+ "type": "number"
1183
+ }
1184
+ },
1185
+ "required": [
1186
+ "byteLength"
1187
+ ]
1188
+ },
1189
+ {}
1190
+ ]
1073
1191
  }
1074
1192
  },
1075
- "required": [
1076
- "type"
1077
- ],
1078
- "description": "Interface to specify the Service parameters",
1079
- "$schema": "http://json-schema.org/draft-07/schema#",
1080
- "title": "CronService"
1193
+ "title": "CryptoService"
1081
1194
  },
1082
- "webda/debugmailer": {
1195
+ "Webda/DebugMailer": {
1083
1196
  "type": "object",
1084
1197
  "properties": {
1085
1198
  "type": {
@@ -1102,7 +1215,7 @@
1102
1215
  "$schema": "http://json-schema.org/draft-07/schema#",
1103
1216
  "title": "DebugMailer"
1104
1217
  },
1105
- "webda/echoservice": {
1218
+ "Webda/EchoService": {
1106
1219
  "type": "object",
1107
1220
  "properties": {
1108
1221
  "type": {
@@ -1139,7 +1252,7 @@
1139
1252
  "$schema": "http://json-schema.org/draft-07/schema#",
1140
1253
  "title": "EchoService"
1141
1254
  },
1142
- "webda/filebinary": {
1255
+ "Webda/FileBinary": {
1143
1256
  "type": "object",
1144
1257
  "properties": {
1145
1258
  "type": {
@@ -1158,7 +1271,18 @@
1158
1271
  "type": "string"
1159
1272
  }
1160
1273
  },
1161
- "description": "Define the map to Object collection\n\nkey is a Store name the string[] represent all valids attributes to store files in"
1274
+ "description": "Define the map to Object collection\n\nkey is a Store name the string[] represent all valids attributes to store files in",
1275
+ "deprecated": true
1276
+ },
1277
+ "models": {
1278
+ "type": "object",
1279
+ "additionalProperties": {
1280
+ "type": "array",
1281
+ "items": {
1282
+ "type": "string"
1283
+ }
1284
+ },
1285
+ "description": "Define the map of models\n* indicates all models\n\nkey is a Store name the string[] represent all valids attributes to store files in * indicates all attributes"
1162
1286
  },
1163
1287
  "expose": {
1164
1288
  "type": "object",
@@ -1193,19 +1317,167 @@
1193
1317
  "required": [
1194
1318
  "url"
1195
1319
  ],
1196
- "description": "Expose the service to http"
1320
+ "description": "Expose the service to http",
1321
+ "deprecated": "will be removed in 4.0"
1197
1322
  },
1198
1323
  "prefix": {
1199
1324
  "type": "string"
1200
1325
  },
1201
1326
  "folder": {
1202
1327
  "type": "string",
1203
- "description": "Define the folder to store objects in"
1204
- },
1205
- "maxSize": {
1206
- "type": "number",
1207
- "description": "Maximum size to handle",
1208
- "default": "10Mb"
1328
+ "description": "Define the folder to store objects in"
1329
+ },
1330
+ "maxSize": {
1331
+ "type": "number",
1332
+ "description": "Maximum size to handle",
1333
+ "default": "10Mb"
1334
+ },
1335
+ "openapi": {
1336
+ "type": "object",
1337
+ "additionalProperties": true
1338
+ }
1339
+ },
1340
+ "required": [
1341
+ "folder",
1342
+ "map",
1343
+ "models",
1344
+ "type"
1345
+ ],
1346
+ "$schema": "http://json-schema.org/draft-07/schema#",
1347
+ "title": "FileBinary"
1348
+ },
1349
+ "Webda/FileConfiguration": {
1350
+ "type": "object",
1351
+ "properties": {
1352
+ "type": {
1353
+ "type": "string",
1354
+ "description": "Type of the service"
1355
+ },
1356
+ "url": {
1357
+ "type": "string",
1358
+ "description": "URL on which to serve the content"
1359
+ },
1360
+ "checkInterval": {
1361
+ "type": "number",
1362
+ "description": "Check configuration every {checkInterval} seconds"
1363
+ },
1364
+ "source": {
1365
+ "type": "string",
1366
+ "description": "Format sourceServiceName:sourceId"
1367
+ },
1368
+ "default": {
1369
+ "description": "Default configuration to use"
1370
+ },
1371
+ "openapi": {
1372
+ "type": "object",
1373
+ "additionalProperties": true
1374
+ }
1375
+ },
1376
+ "required": [
1377
+ "default",
1378
+ "source",
1379
+ "type"
1380
+ ],
1381
+ "$schema": "http://json-schema.org/draft-07/schema#",
1382
+ "title": "FileConfigurationService"
1383
+ },
1384
+ "Webda/FileLogger": {
1385
+ "type": "object",
1386
+ "properties": {
1387
+ "type": {
1388
+ "type": "string",
1389
+ "description": "Type of the service"
1390
+ },
1391
+ "url": {
1392
+ "type": "string",
1393
+ "description": "URL on which to serve the content"
1394
+ },
1395
+ "logLevel": {
1396
+ "$ref": "#/definitions/WorkerLogLevel",
1397
+ "description": "Specify the log level of this service"
1398
+ },
1399
+ "format": {
1400
+ "type": "string"
1401
+ },
1402
+ "file": {
1403
+ "type": "string"
1404
+ },
1405
+ "sizeLimit": {
1406
+ "type": "number"
1407
+ },
1408
+ "openapi": {
1409
+ "type": "object",
1410
+ "additionalProperties": true
1411
+ }
1412
+ },
1413
+ "required": [
1414
+ "file",
1415
+ "logLevel",
1416
+ "type"
1417
+ ],
1418
+ "$schema": "http://json-schema.org/draft-07/schema#",
1419
+ "definitions": {
1420
+ "WorkerLogLevel": {
1421
+ "type": "string",
1422
+ "enum": [
1423
+ "ERROR",
1424
+ "WARN",
1425
+ "INFO",
1426
+ "DEBUG",
1427
+ "TRACE"
1428
+ ],
1429
+ "description": "LogLevel as intersection to compare with integer values"
1430
+ }
1431
+ },
1432
+ "title": "FileLoggerService"
1433
+ },
1434
+ "Webda/FileQueue": {
1435
+ "type": "object",
1436
+ "properties": {
1437
+ "type": {
1438
+ "type": "string",
1439
+ "description": "Type of the service"
1440
+ },
1441
+ "url": {
1442
+ "type": "string",
1443
+ "description": "URL on which to serve the content"
1444
+ },
1445
+ "workerDelayer": {
1446
+ "type": "object",
1447
+ "properties": {
1448
+ "interval": {
1449
+ "type": "number",
1450
+ "description": "Interval"
1451
+ },
1452
+ "type": {
1453
+ "type": "string",
1454
+ "description": "Type of delayer registered in WaitDelayerFactoryRegistry"
1455
+ }
1456
+ },
1457
+ "required": [
1458
+ "interval",
1459
+ "type"
1460
+ ],
1461
+ "description": "Delayer between two failed attempts to process messages"
1462
+ },
1463
+ "workerParallelism": {
1464
+ "type": "boolean",
1465
+ "description": "Define if worker should process multi message received in //",
1466
+ "default": true
1467
+ },
1468
+ "maxConsumers": {
1469
+ "type": "number",
1470
+ "description": "Max number of queue consumers Queue will auto increase to this max number if queue is loaded and it will decrease to just one consumer if no messages are available",
1471
+ "default": 10
1472
+ },
1473
+ "expire": {
1474
+ "type": "number",
1475
+ "description": "Number of seconds before droping message",
1476
+ "default": 30
1477
+ },
1478
+ "folder": {
1479
+ "type": "string",
1480
+ "description": "Where to store the queue"
1209
1481
  },
1210
1482
  "openapi": {
1211
1483
  "type": "object",
@@ -1214,13 +1486,13 @@
1214
1486
  },
1215
1487
  "required": [
1216
1488
  "folder",
1217
- "map",
1489
+ "maxConsumers",
1218
1490
  "type"
1219
1491
  ],
1220
1492
  "$schema": "http://json-schema.org/draft-07/schema#",
1221
- "title": "FileBinary"
1493
+ "title": "FileQueue"
1222
1494
  },
1223
- "webda/fileconfiguration": {
1495
+ "Webda/FileStore": {
1224
1496
  "type": "object",
1225
1497
  "properties": {
1226
1498
  "type": {
@@ -1231,89 +1503,62 @@
1231
1503
  "type": "string",
1232
1504
  "description": "URL on which to serve the content"
1233
1505
  },
1234
- "checkInterval": {
1235
- "type": "number",
1236
- "description": "Check configuration every {checkInterval} seconds"
1237
- },
1238
- "source": {
1506
+ "model": {
1239
1507
  "type": "string",
1240
- "description": "Format sourceServiceName:sourceId"
1241
- },
1242
- "default": {
1243
- "description": "Default configuration to use"
1508
+ "description": "Webda model to use within the Store",
1509
+ "default": "Webda/CoreModel"
1244
1510
  },
1245
- "openapi": {
1246
- "type": "object",
1247
- "additionalProperties": true
1248
- }
1249
- },
1250
- "required": [
1251
- "default",
1252
- "source",
1253
- "type"
1254
- ],
1255
- "$schema": "http://json-schema.org/draft-07/schema#",
1256
- "title": "FileConfiguration"
1257
- },
1258
- "webda/invitationservice": {
1259
- "type": "object",
1260
- "properties": {
1261
- "type": {
1262
- "type": "string",
1263
- "description": "Type of the service"
1511
+ "asyncDelete": {
1512
+ "type": "boolean",
1513
+ "description": "async delete"
1264
1514
  },
1265
- "url": {
1266
- "type": "string",
1267
- "description": "URL on which to serve the content"
1515
+ "expose": {
1516
+ "$ref": "#/definitions/StoreExposeParameters",
1517
+ "description": "Expose the service to an urls",
1518
+ "deprecated": "will probably be removed in 4.0 in favor of Expose annotation"
1268
1519
  },
1269
- "authenticationService": {
1270
- "type": "string",
1271
- "description": "Name of the bean to use for Authentication",
1272
- "default": "Authentication"
1520
+ "strict": {
1521
+ "type": "boolean",
1522
+ "description": "Allow to load object that does not have the type data\n\nIf set to true, then the Store will only managed the defined _model and no model extending this one",
1523
+ "default": false
1273
1524
  },
1274
- "notificationService": {
1275
- "type": "string",
1276
- "description": "Notification service",
1277
- "default": "Mailer"
1525
+ "defaultModel": {
1526
+ "type": "boolean",
1527
+ "description": "When __type model not found, use the model If strict is setup this parameter is not used",
1528
+ "default": true
1278
1529
  },
1279
- "modelStore": {
1280
- "type": "string",
1281
- "description": "Store to use"
1530
+ "forceModel": {
1531
+ "type": "boolean",
1532
+ "description": "If set, Store will ignore the __type",
1533
+ "default": false
1282
1534
  },
1283
- "invitationStore": {
1284
- "type": "string",
1285
- "description": "Used to store pending invitation"
1535
+ "slowQueryThreshold": {
1536
+ "type": "number",
1537
+ "description": "Slow query threshold",
1538
+ "default": 30000
1286
1539
  },
1287
- "mapFields": {
1288
- "type": "array",
1289
- "items": {
1540
+ "modelAliases": {
1541
+ "type": "object",
1542
+ "additionalProperties": {
1290
1543
  "type": "string"
1291
1544
  },
1292
- "description": "Fields to duplicate"
1293
- },
1294
- "mapAttribute": {
1295
- "type": "string",
1296
- "description": "Attribute to use for the mapping"
1297
- },
1298
- "attribute": {
1299
- "type": "string",
1300
- "description": "Attribute where to store once the invitation is accepted\n\nIf attribute is __acls, the multiple will be ignored and the storage will be compatible with AclModel\n\nWhere to store within the model User"
1545
+ "description": "Model Aliases to allow easier rename of Model"
1301
1546
  },
1302
- "pendingAttribute": {
1547
+ "folder": {
1303
1548
  "type": "string",
1304
- "description": "Attribute where to store once the invitation is created and pending\n\nWhere to store within the model Ident and User"
1549
+ "description": "Local path where to store all `json` files"
1305
1550
  },
1306
- "multiple": {
1307
- "type": "boolean",
1308
- "description": "Define if several invitation can be accepted or just one"
1551
+ "beautify": {
1552
+ "type": [
1553
+ "string",
1554
+ "number"
1555
+ ],
1556
+ "description": "Parameter sent to JSON.stringify when storing the json"
1309
1557
  },
1310
- "autoAccept": {
1558
+ "noCache": {
1311
1559
  "type": "boolean",
1312
- "description": "Do not require a validation by the invitee"
1313
- },
1314
- "notification": {
1315
- "type": "string",
1316
- "description": "Email template to send to the user"
1560
+ "description": "Disable memory cache\n\nUseful if several process update storage files",
1561
+ "default": false
1317
1562
  },
1318
1563
  "openapi": {
1319
1564
  "type": "object",
@@ -1321,89 +1566,141 @@
1321
1566
  }
1322
1567
  },
1323
1568
  "required": [
1324
- "attribute",
1325
- "authenticationService",
1326
- "autoAccept",
1327
- "invitationStore",
1328
- "mapAttribute",
1329
- "mapFields",
1330
- "modelStore",
1331
- "multiple",
1332
- "pendingAttribute",
1569
+ "asyncDelete",
1570
+ "folder",
1571
+ "slowQueryThreshold",
1333
1572
  "type"
1334
1573
  ],
1335
1574
  "$schema": "http://json-schema.org/draft-07/schema#",
1336
- "title": "InvitationService"
1575
+ "definitions": {
1576
+ "StoreExposeParameters": {
1577
+ "type": "object",
1578
+ "properties": {
1579
+ "url": {
1580
+ "type": "string",
1581
+ "description": "URL endpoint to use to expose REST Resources API",
1582
+ "default": "service.getName().toLowerCase()"
1583
+ },
1584
+ "restrict": {
1585
+ "type": "object",
1586
+ "properties": {
1587
+ "create": {
1588
+ "type": "boolean",
1589
+ "description": "Do not expose the POST"
1590
+ },
1591
+ "update": {
1592
+ "type": "boolean",
1593
+ "description": "Do not expose the PUT and PATCH"
1594
+ },
1595
+ "get": {
1596
+ "type": "boolean",
1597
+ "description": "Do not expose the GET"
1598
+ },
1599
+ "delete": {
1600
+ "type": "boolean",
1601
+ "description": "Do not expose the DELETE"
1602
+ },
1603
+ "query": {
1604
+ "type": "boolean",
1605
+ "description": "Do not expose the query endpoint"
1606
+ }
1607
+ },
1608
+ "description": "You can restrict any part of the CRUD",
1609
+ "default": {}
1610
+ },
1611
+ "queryMethod": {
1612
+ "type": "string",
1613
+ "enum": [
1614
+ "PUT",
1615
+ "GET"
1616
+ ],
1617
+ "description": "For confidentiality sometimes you might prefer to expose query through PUT To avoid GET logging",
1618
+ "default": "GET"
1619
+ }
1620
+ },
1621
+ "deprecated": "Store should not be exposed directly anymore\nYou should use the DomainService instead"
1622
+ }
1623
+ },
1624
+ "title": "FileStore"
1337
1625
  },
1338
- "webda/kubernetesconfigurationservice": {
1626
+ "Webda/Ident": {
1339
1627
  "type": "object",
1340
1628
  "properties": {
1341
- "type": {
1629
+ "_creationDate": {
1342
1630
  "type": "string",
1343
- "description": "Type of the service"
1631
+ "format": "date-time",
1632
+ "description": "Creation date",
1633
+ "readOnly": true
1344
1634
  },
1345
- "url": {
1635
+ "_lastUpdate": {
1346
1636
  "type": "string",
1347
- "description": "URL on which to serve the content"
1348
- },
1349
- "checkInterval": {
1350
- "type": "number",
1351
- "description": "Check configuration every {checkInterval} seconds"
1637
+ "format": "date-time",
1638
+ "description": "Last update date",
1639
+ "readOnly": true
1352
1640
  },
1353
- "source": {
1641
+ "uuid": {
1354
1642
  "type": "string",
1355
- "description": "Format sourceServiceName:sourceId"
1643
+ "description": "UUID of the object"
1356
1644
  },
1357
- "default": {
1358
- "description": "Default configuration to use"
1645
+ "_user": {
1646
+ "type": "string"
1359
1647
  },
1360
- "openapi": {
1361
- "type": "object",
1362
- "additionalProperties": true
1363
- }
1364
- },
1365
- "required": [
1366
- "default",
1367
- "source",
1368
- "type"
1369
- ],
1370
- "$schema": "http://json-schema.org/draft-07/schema#",
1371
- "title": "KubernetesConfigurationService"
1372
- },
1373
- "webda/proxyservice": {
1374
- "type": "object",
1375
- "properties": {
1376
- "type": {
1648
+ "public": {
1649
+ "type": "boolean",
1650
+ "description": "Define if the object is publicly readable",
1651
+ "default": false
1652
+ },
1653
+ "_type": {
1377
1654
  "type": "string",
1378
- "description": "Type of the service"
1655
+ "description": "Type of the ident",
1656
+ "readOnly": true
1379
1657
  },
1380
- "url": {
1658
+ "uid": {
1381
1659
  "type": "string",
1382
- "description": "URL to expose"
1660
+ "description": "Uid on the provider"
1383
1661
  },
1384
- "backend": {
1662
+ "_lastUsed": {
1385
1663
  "type": "string",
1386
- "description": "URL to proxy to"
1664
+ "format": "date-time",
1665
+ "readOnly": true
1387
1666
  },
1388
- "requireAuthentication": {
1389
- "type": "boolean",
1390
- "description": "Helper to refuse any request if user is not auth"
1667
+ "_failedLogin": {
1668
+ "type": "number",
1669
+ "readOnly": true
1391
1670
  },
1392
- "openapi": {
1393
- "type": "object",
1394
- "additionalProperties": true
1671
+ "_lastValidationEmail": {
1672
+ "type": "number",
1673
+ "description": "If EmailIdent",
1674
+ "readOnly": true
1675
+ },
1676
+ "_validation": {
1677
+ "type": "string",
1678
+ "format": "date-time",
1679
+ "description": "When the ident was validated",
1680
+ "readOnly": true
1681
+ },
1682
+ "email": {
1683
+ "type": "string",
1684
+ "description": "Email for this ident if it exist"
1685
+ },
1686
+ "provider": {
1687
+ "type": "string",
1688
+ "description": "Provider id"
1689
+ },
1690
+ "profile": {
1691
+ "description": "Provider profile"
1395
1692
  }
1396
1693
  },
1397
1694
  "required": [
1398
- "backend",
1399
- "requireAuthentication",
1400
- "type"
1695
+ "_user",
1696
+ "uid",
1697
+ "uuid"
1401
1698
  ],
1402
- "description": "Proxy to a backend service",
1699
+ "description": "First basic model for Ident",
1403
1700
  "$schema": "http://json-schema.org/draft-07/schema#",
1404
- "title": "ProxyService"
1701
+ "title": "Ident"
1405
1702
  },
1406
- "webda/resourceservice": {
1703
+ "Webda/InvitationService": {
1407
1704
  "type": "object",
1408
1705
  "properties": {
1409
1706
  "type": {
@@ -1412,28 +1709,56 @@
1412
1709
  },
1413
1710
  "url": {
1414
1711
  "type": "string",
1415
- "description": "URL on which to serve the content",
1416
- "default": "resources"
1712
+ "description": "URL on which to serve the content"
1417
1713
  },
1418
- "folder": {
1714
+ "authenticationService": {
1419
1715
  "type": "string",
1420
- "description": "Folder to server",
1421
- "default": "\".\" + url"
1716
+ "description": "Name of the bean to use for Authentication",
1717
+ "default": "Authentication"
1422
1718
  },
1423
- "rootRedirect": {
1424
- "type": "boolean",
1425
- "description": "Add the / root to redirect to /{url}",
1426
- "default": false
1719
+ "notificationService": {
1720
+ "type": "string",
1721
+ "description": "Notification service",
1722
+ "default": "Mailer"
1427
1723
  },
1428
- "index": {
1724
+ "model": {
1429
1725
  "type": "string",
1430
- "description": "Index file",
1431
- "default": "index.html"
1726
+ "description": "Model to use"
1432
1727
  },
1433
- "indexFallback": {
1728
+ "invitationStore": {
1729
+ "type": "string",
1730
+ "description": "Used to store pending invitation"
1731
+ },
1732
+ "mapFields": {
1733
+ "type": "array",
1734
+ "items": {
1735
+ "type": "string"
1736
+ },
1737
+ "description": "Fields to duplicate"
1738
+ },
1739
+ "mapAttribute": {
1740
+ "type": "string",
1741
+ "description": "Attribute to use for the mapping"
1742
+ },
1743
+ "attribute": {
1744
+ "type": "string",
1745
+ "description": "Attribute where to store once the invitation is accepted\n\nIf attribute is __acls, the multiple will be ignored and the storage will be compatible with AclModel\n\nWhere to store within the model User"
1746
+ },
1747
+ "pendingAttribute": {
1748
+ "type": "string",
1749
+ "description": "Attribute where to store once the invitation is created and pending\n\nWhere to store within the model Ident and User"
1750
+ },
1751
+ "multiple": {
1434
1752
  "type": "boolean",
1435
- "description": "Return the index file for any unfound resource Useful for single page application",
1436
- "default": true
1753
+ "description": "Define if several invitation can be accepted or just one"
1754
+ },
1755
+ "autoAccept": {
1756
+ "type": "boolean",
1757
+ "description": "Do not require a validation by the invitee"
1758
+ },
1759
+ "notification": {
1760
+ "type": "string",
1761
+ "description": "Email template to send to the user"
1437
1762
  },
1438
1763
  "openapi": {
1439
1764
  "type": "object",
@@ -1441,13 +1766,21 @@
1441
1766
  }
1442
1767
  },
1443
1768
  "required": [
1769
+ "attribute",
1770
+ "authenticationService",
1771
+ "autoAccept",
1772
+ "invitationStore",
1773
+ "mapAttribute",
1774
+ "mapFields",
1775
+ "model",
1776
+ "multiple",
1777
+ "pendingAttribute",
1444
1778
  "type"
1445
1779
  ],
1446
- "description": "ResourceService parameters",
1447
1780
  "$schema": "http://json-schema.org/draft-07/schema#",
1448
- "title": "ResourceService"
1781
+ "title": "InvitationService"
1449
1782
  },
1450
- "webda/versionservice": {
1783
+ "Webda/KubernetesConfigurationService": {
1451
1784
  "type": "object",
1452
1785
  "properties": {
1453
1786
  "type": {
@@ -1456,12 +1789,18 @@
1456
1789
  },
1457
1790
  "url": {
1458
1791
  "type": "string",
1459
- "description": "URL on which to serve the content",
1460
- "default": "/version"
1792
+ "description": "URL on which to serve the content"
1461
1793
  },
1462
- "version": {
1794
+ "checkInterval": {
1795
+ "type": "number",
1796
+ "description": "Check configuration every {checkInterval} seconds"
1797
+ },
1798
+ "source": {
1463
1799
  "type": "string",
1464
- "description": "To force version otherwise would read from package.json"
1800
+ "description": "Format sourceServiceName:sourceId"
1801
+ },
1802
+ "default": {
1803
+ "description": "Default configuration to use"
1465
1804
  },
1466
1805
  "openapi": {
1467
1806
  "type": "object",
@@ -1469,13 +1808,14 @@
1469
1808
  }
1470
1809
  },
1471
1810
  "required": [
1811
+ "default",
1812
+ "source",
1472
1813
  "type"
1473
1814
  ],
1474
- "description": "Version parameters",
1475
1815
  "$schema": "http://json-schema.org/draft-07/schema#",
1476
- "title": "VersionService"
1816
+ "title": "KubernetesConfigurationService"
1477
1817
  },
1478
- "webda/aliasstore": {
1818
+ "Webda/Mailer": {
1479
1819
  "type": "object",
1480
1820
  "properties": {
1481
1821
  "type": {
@@ -1486,73 +1826,27 @@
1486
1826
  "type": "string",
1487
1827
  "description": "URL on which to serve the content"
1488
1828
  },
1489
- "model": {
1829
+ "templates": {
1490
1830
  "type": "string",
1491
- "description": "Webda model to use within the Store",
1492
- "default": "Webda/CoreModel"
1493
- },
1494
- "models": {
1495
- "type": "array",
1496
- "items": {
1497
- "type": "string"
1498
- },
1499
- "description": "Different models managed by this store"
1500
- },
1501
- "asyncDelete": {
1502
- "type": "boolean",
1503
- "description": "async delete"
1504
- },
1505
- "expose": {
1506
- "$ref": "#/definitions/ExposeParameters",
1507
- "description": "Expose the service to an urls"
1508
- },
1509
- "strict": {
1510
- "type": "boolean",
1511
- "description": "Allow to load object that does not have the type data\n\nIf set to true, then the Store will only managed the defined _model and no model extending this one",
1512
- "default": false
1513
- },
1514
- "defaultModel": {
1515
- "type": "boolean",
1516
- "description": "When __type model not found, use the model If strict is setup this parameter is not used",
1517
- "default": true
1518
- },
1519
- "forceModel": {
1520
- "type": "boolean",
1521
- "description": "If set, Store will ignore the __type",
1522
- "default": false
1523
- },
1524
- "slowQueryThreshold": {
1525
- "type": "number",
1526
- "description": "Slow query threshold",
1527
- "default": 30000
1528
- },
1529
- "parent": {
1530
- "type": "object",
1531
- "properties": {
1532
- "name": {
1533
- "type": "string"
1534
- },
1535
- "condition": {
1536
- "type": "string"
1537
- }
1538
- },
1539
- "required": [
1540
- "name",
1541
- "condition"
1542
- ],
1543
- "description": "Parent of the store\n\nIf parent is specified the url route is relative to it"
1831
+ "description": "Specify which foldeer contains templates",
1832
+ "default": "templates"
1544
1833
  },
1545
- "graphql": {
1546
- "type": "boolean",
1547
- "description": "For future use in our GraphQL api\n\nExpose this store in the graphql"
1834
+ "templatesEngine": {
1835
+ "type": "string",
1836
+ "description": "Template engine to usee",
1837
+ "default": "mustache"
1548
1838
  },
1549
- "targetStore": {
1839
+ "sender": {
1550
1840
  "type": "string",
1551
- "description": "Store to alias"
1841
+ "description": "Define the default sender"
1552
1842
  },
1553
- "idTemplate": {
1843
+ "emailTemplateOptions": {},
1844
+ "transport": {
1554
1845
  "type": "string",
1555
- "description": "Store to alias"
1846
+ "description": "Define the type of transport to use"
1847
+ },
1848
+ "SES": {
1849
+ "description": "SES AWS Bean if transport === \"ses\""
1556
1850
  },
1557
1851
  "openapi": {
1558
1852
  "type": "object",
@@ -1560,64 +1854,14 @@
1560
1854
  }
1561
1855
  },
1562
1856
  "required": [
1563
- "asyncDelete",
1564
- "idTemplate",
1565
- "slowQueryThreshold",
1566
- "targetStore",
1857
+ "SES",
1858
+ "sender",
1567
1859
  "type"
1568
1860
  ],
1569
1861
  "$schema": "http://json-schema.org/draft-07/schema#",
1570
- "definitions": {
1571
- "ExposeParameters": {
1572
- "type": "object",
1573
- "properties": {
1574
- "url": {
1575
- "type": "string",
1576
- "description": "URL endpoint to use to expose REST Resources API",
1577
- "default": "service.getName().toLowerCase()"
1578
- },
1579
- "restrict": {
1580
- "type": "object",
1581
- "properties": {
1582
- "create": {
1583
- "type": "boolean",
1584
- "description": "Do not expose the POST"
1585
- },
1586
- "update": {
1587
- "type": "boolean",
1588
- "description": "Do not expose the PUT and PATCH"
1589
- },
1590
- "get": {
1591
- "type": "boolean",
1592
- "description": "Do not expose the GET"
1593
- },
1594
- "delete": {
1595
- "type": "boolean",
1596
- "description": "Do not expose the DELETE"
1597
- },
1598
- "query": {
1599
- "type": "boolean",
1600
- "description": "Do not expose the query endpoint"
1601
- }
1602
- },
1603
- "description": "You can restrict any part of the CRUD",
1604
- "default": {}
1605
- },
1606
- "queryMethod": {
1607
- "type": "string",
1608
- "enum": [
1609
- "PUT",
1610
- "GET"
1611
- ],
1612
- "description": "For confidentiality sometimes you might prefer to expose query through PUT To avoid GET logging",
1613
- "default": "GET"
1614
- }
1615
- }
1616
- }
1617
- },
1618
- "title": "AliasStore"
1862
+ "title": "Mailer"
1619
1863
  },
1620
- "webda/mapper": {
1864
+ "Webda/Mapper": {
1621
1865
  "type": "object",
1622
1866
  "properties": {
1623
1867
  "type": {
@@ -1677,9 +1921,9 @@
1677
1921
  ],
1678
1922
  "description": "Mapper configuration",
1679
1923
  "$schema": "http://json-schema.org/draft-07/schema#",
1680
- "title": "Mapper"
1924
+ "title": "MapperService"
1681
1925
  },
1682
- "webda/aggregator": {
1926
+ "Webda/MemoryLogger": {
1683
1927
  "type": "object",
1684
1928
  "properties": {
1685
1929
  "type": {
@@ -1690,41 +1934,81 @@
1690
1934
  "type": "string",
1691
1935
  "description": "URL on which to serve the content"
1692
1936
  },
1693
- "fields": {
1694
- "type": "array",
1695
- "items": {
1696
- "type": "string"
1697
- },
1698
- "description": "Field to duplicate"
1937
+ "logLevel": {
1938
+ "$ref": "#/definitions/WorkerLogLevel",
1939
+ "description": "Specify the log level of this service"
1699
1940
  },
1700
- "source": {
1701
- "type": "string",
1702
- "description": "Source service"
1941
+ "limit": {
1942
+ "type": "number"
1703
1943
  },
1704
- "target": {
1944
+ "openapi": {
1945
+ "type": "object",
1946
+ "additionalProperties": true
1947
+ }
1948
+ },
1949
+ "required": [
1950
+ "logLevel",
1951
+ "type"
1952
+ ],
1953
+ "$schema": "http://json-schema.org/draft-07/schema#",
1954
+ "definitions": {
1955
+ "WorkerLogLevel": {
1956
+ "type": "string",
1957
+ "enum": [
1958
+ "ERROR",
1959
+ "WARN",
1960
+ "INFO",
1961
+ "DEBUG",
1962
+ "TRACE"
1963
+ ],
1964
+ "description": "LogLevel as intersection to compare with integer values"
1965
+ }
1966
+ },
1967
+ "title": "MemoryLoggerService"
1968
+ },
1969
+ "Webda/MemoryQueue": {
1970
+ "type": "object",
1971
+ "properties": {
1972
+ "type": {
1705
1973
  "type": "string",
1706
- "description": "Target store"
1707
- },
1708
- "async": {
1709
- "type": "boolean",
1710
- "description": "Async",
1711
- "default": false
1974
+ "description": "Type of the service"
1712
1975
  },
1713
- "attribute": {
1976
+ "url": {
1714
1977
  "type": "string",
1715
- "description": "Attribute to use for link\n\nDepending on the type - string[]: will consider each string as id - string: will be consider as id - Object: each keys will be consider as id"
1978
+ "description": "URL on which to serve the content"
1716
1979
  },
1717
- "targetAttribute": {
1718
- "type": "string",
1719
- "description": "The object will contain a Mapper"
1980
+ "workerDelayer": {
1981
+ "type": "object",
1982
+ "properties": {
1983
+ "interval": {
1984
+ "type": "number",
1985
+ "description": "Interval"
1986
+ },
1987
+ "type": {
1988
+ "type": "string",
1989
+ "description": "Type of delayer registered in WaitDelayerFactoryRegistry"
1990
+ }
1991
+ },
1992
+ "required": [
1993
+ "interval",
1994
+ "type"
1995
+ ],
1996
+ "description": "Delayer between two failed attempts to process messages"
1720
1997
  },
1721
- "cascade": {
1998
+ "workerParallelism": {
1722
1999
  "type": "boolean",
1723
- "description": "Delete source if target object is deleted"
2000
+ "description": "Define if worker should process multi message received in //",
2001
+ "default": true
1724
2002
  },
1725
- "key": {
1726
- "type": "string",
1727
- "default": "index"
2003
+ "maxConsumers": {
2004
+ "type": "number",
2005
+ "description": "Max number of queue consumers Queue will auto increase to this max number if queue is loaded and it will decrease to just one consumer if no messages are available",
2006
+ "default": 10
2007
+ },
2008
+ "expire": {
2009
+ "type": "number",
2010
+ "description": "Number of seconds before droping message",
2011
+ "default": 30
1728
2012
  },
1729
2013
  "openapi": {
1730
2014
  "type": "object",
@@ -1732,20 +2016,13 @@
1732
2016
  }
1733
2017
  },
1734
2018
  "required": [
1735
- "async",
1736
- "attribute",
1737
- "cascade",
1738
- "fields",
1739
- "key",
1740
- "source",
1741
- "target",
1742
- "targetAttribute",
2019
+ "maxConsumers",
1743
2020
  "type"
1744
2021
  ],
1745
2022
  "$schema": "http://json-schema.org/draft-07/schema#",
1746
- "title": "Aggregator"
2023
+ "title": "MemoryQueue"
1747
2024
  },
1748
- "webda/memorystore": {
2025
+ "Webda/MemoryStore": {
1749
2026
  "type": "object",
1750
2027
  "properties": {
1751
2028
  "type": {
@@ -1761,20 +2038,14 @@
1761
2038
  "description": "Webda model to use within the Store",
1762
2039
  "default": "Webda/CoreModel"
1763
2040
  },
1764
- "models": {
1765
- "type": "array",
1766
- "items": {
1767
- "type": "string"
1768
- },
1769
- "description": "Different models managed by this store"
1770
- },
1771
2041
  "asyncDelete": {
1772
2042
  "type": "boolean",
1773
2043
  "description": "async delete"
1774
2044
  },
1775
2045
  "expose": {
1776
- "$ref": "#/definitions/ExposeParameters",
1777
- "description": "Expose the service to an urls"
2046
+ "$ref": "#/definitions/StoreExposeParameters",
2047
+ "description": "Expose the service to an urls",
2048
+ "deprecated": "will probably be removed in 4.0 in favor of Expose annotation"
1778
2049
  },
1779
2050
  "strict": {
1780
2051
  "type": "boolean",
@@ -1796,25 +2067,12 @@
1796
2067
  "description": "Slow query threshold",
1797
2068
  "default": 30000
1798
2069
  },
1799
- "parent": {
2070
+ "modelAliases": {
1800
2071
  "type": "object",
1801
- "properties": {
1802
- "name": {
1803
- "type": "string"
1804
- },
1805
- "condition": {
1806
- "type": "string"
1807
- }
2072
+ "additionalProperties": {
2073
+ "type": "string"
1808
2074
  },
1809
- "required": [
1810
- "name",
1811
- "condition"
1812
- ],
1813
- "description": "Parent of the store\n\nIf parent is specified the url route is relative to it"
1814
- },
1815
- "graphql": {
1816
- "type": "boolean",
1817
- "description": "For future use in our GraphQL api\n\nExpose this store in the graphql"
2075
+ "description": "Model Aliases to allow easier rename of Model"
1818
2076
  },
1819
2077
  "persistence": {
1820
2078
  "type": "object",
@@ -1855,7 +2113,7 @@
1855
2113
  "description": "Memory store",
1856
2114
  "$schema": "http://json-schema.org/draft-07/schema#",
1857
2115
  "definitions": {
1858
- "ExposeParameters": {
2116
+ "StoreExposeParameters": {
1859
2117
  "type": "object",
1860
2118
  "properties": {
1861
2119
  "url": {
@@ -1899,12 +2157,13 @@
1899
2157
  "description": "For confidentiality sometimes you might prefer to expose query through PUT To avoid GET logging",
1900
2158
  "default": "GET"
1901
2159
  }
1902
- }
2160
+ },
2161
+ "deprecated": "Store should not be exposed directly anymore\nYou should use the DomainService instead"
1903
2162
  }
1904
2163
  },
1905
2164
  "title": "MemoryStore"
1906
2165
  },
1907
- "webda/filestore": {
2166
+ "Webda/ModelsOperationsService": {
1908
2167
  "type": "object",
1909
2168
  "properties": {
1910
2169
  "type": {
@@ -1915,145 +2174,148 @@
1915
2174
  "type": "string",
1916
2175
  "description": "URL on which to serve the content"
1917
2176
  },
1918
- "model": {
2177
+ "openapi": {
2178
+ "type": "object",
2179
+ "additionalProperties": true
2180
+ }
2181
+ },
2182
+ "required": [
2183
+ "type"
2184
+ ],
2185
+ "description": "Interface to specify the Service parameters",
2186
+ "$schema": "http://json-schema.org/draft-07/schema#",
2187
+ "title": "ModelsOperationsService"
2188
+ },
2189
+ "Webda/MultiNotificationService": {
2190
+ "type": "object",
2191
+ "properties": {
2192
+ "type": {
1919
2193
  "type": "string",
1920
- "description": "Webda model to use within the Store",
1921
- "default": "Webda/CoreModel"
2194
+ "description": "Type of the service"
1922
2195
  },
1923
- "models": {
2196
+ "url": {
2197
+ "type": "string",
2198
+ "description": "URL on which to serve the content"
2199
+ },
2200
+ "senders": {
1924
2201
  "type": "array",
1925
2202
  "items": {
1926
2203
  "type": "string"
1927
2204
  },
1928
- "description": "Different models managed by this store"
1929
- },
1930
- "asyncDelete": {
1931
- "type": "boolean",
1932
- "description": "async delete"
1933
- },
1934
- "expose": {
1935
- "$ref": "#/definitions/ExposeParameters",
1936
- "description": "Expose the service to an urls"
1937
- },
1938
- "strict": {
1939
- "type": "boolean",
1940
- "description": "Allow to load object that does not have the type data\n\nIf set to true, then the Store will only managed the defined _model and no model extending this one",
1941
- "default": false
1942
- },
1943
- "defaultModel": {
1944
- "type": "boolean",
1945
- "description": "When __type model not found, use the model If strict is setup this parameter is not used",
1946
- "default": true
2205
+ "description": "Notification service that will send The order of the array is important if multiple is false When multiple is `false` the first available NotificationService will be used, otherwise every available NotificationService will be used"
1947
2206
  },
1948
- "forceModel": {
2207
+ "multiple": {
1949
2208
  "type": "boolean",
1950
- "description": "If set, Store will ignore the __type",
2209
+ "description": "Define if it sends one or several notification per user",
1951
2210
  "default": false
1952
2211
  },
1953
- "slowQueryThreshold": {
1954
- "type": "number",
1955
- "description": "Slow query threshold",
1956
- "default": 30000
1957
- },
1958
- "parent": {
2212
+ "openapi": {
1959
2213
  "type": "object",
1960
- "properties": {
1961
- "name": {
1962
- "type": "string"
1963
- },
1964
- "condition": {
1965
- "type": "string"
1966
- }
1967
- },
1968
- "required": [
1969
- "name",
1970
- "condition"
1971
- ],
1972
- "description": "Parent of the store\n\nIf parent is specified the url route is relative to it"
2214
+ "additionalProperties": true
2215
+ }
2216
+ },
2217
+ "required": [
2218
+ "senders",
2219
+ "type"
2220
+ ],
2221
+ "description": "Parameters for multi notification service",
2222
+ "$schema": "http://json-schema.org/draft-07/schema#",
2223
+ "title": "MultiNotificationService"
2224
+ },
2225
+ "Webda/OwnerModel": {
2226
+ "type": "object",
2227
+ "properties": {
2228
+ "_creationDate": {
2229
+ "type": "string",
2230
+ "format": "date-time",
2231
+ "description": "Creation date",
2232
+ "readOnly": true
1973
2233
  },
1974
- "graphql": {
1975
- "type": "boolean",
1976
- "description": "For future use in our GraphQL api\n\nExpose this store in the graphql"
2234
+ "_lastUpdate": {
2235
+ "type": "string",
2236
+ "format": "date-time",
2237
+ "description": "Last update date",
2238
+ "readOnly": true
1977
2239
  },
1978
- "folder": {
2240
+ "uuid": {
1979
2241
  "type": "string",
1980
- "description": "Local path where to store all `json` files"
2242
+ "description": "UUID of the object"
1981
2243
  },
1982
- "beautify": {
1983
- "type": [
1984
- "string",
1985
- "number"
1986
- ],
1987
- "description": "Parameter sent to JSON.stringify when storing the json"
2244
+ "_user": {
2245
+ "type": "string"
1988
2246
  },
1989
- "noCache": {
2247
+ "public": {
1990
2248
  "type": "boolean",
1991
- "description": "Disable memory cache\n\nUseful if several process update storage files",
2249
+ "description": "Define if the object is publicly readable",
1992
2250
  "default": false
1993
- },
1994
- "openapi": {
1995
- "type": "object",
1996
- "additionalProperties": true
1997
2251
  }
1998
2252
  },
1999
2253
  "required": [
2000
- "asyncDelete",
2001
- "folder",
2002
- "slowQueryThreshold",
2003
- "type"
2254
+ "_user",
2255
+ "uuid"
2004
2256
  ],
2005
2257
  "$schema": "http://json-schema.org/draft-07/schema#",
2006
- "definitions": {
2007
- "ExposeParameters": {
2008
- "type": "object",
2009
- "properties": {
2010
- "url": {
2011
- "type": "string",
2012
- "description": "URL endpoint to use to expose REST Resources API",
2013
- "default": "service.getName().toLowerCase()"
2014
- },
2015
- "restrict": {
2016
- "type": "object",
2017
- "properties": {
2018
- "create": {
2019
- "type": "boolean",
2020
- "description": "Do not expose the POST"
2021
- },
2022
- "update": {
2023
- "type": "boolean",
2024
- "description": "Do not expose the PUT and PATCH"
2025
- },
2026
- "get": {
2027
- "type": "boolean",
2028
- "description": "Do not expose the GET"
2029
- },
2030
- "delete": {
2031
- "type": "boolean",
2032
- "description": "Do not expose the DELETE"
2033
- },
2034
- "query": {
2035
- "type": "boolean",
2036
- "description": "Do not expose the query endpoint"
2037
- }
2038
- },
2039
- "description": "You can restrict any part of the CRUD",
2040
- "default": {}
2041
- },
2042
- "queryMethod": {
2043
- "type": "string",
2044
- "enum": [
2045
- "PUT",
2046
- "GET"
2047
- ],
2048
- "description": "For confidentiality sometimes you might prefer to expose query through PUT To avoid GET logging",
2049
- "default": "GET"
2050
- }
2051
- }
2258
+ "title": "OwnerModel"
2259
+ },
2260
+ "Webda/PrometheusService": {
2261
+ "type": "object",
2262
+ "properties": {
2263
+ "type": {
2264
+ "type": "string",
2265
+ "description": "Type of the service"
2266
+ },
2267
+ "url": {
2268
+ "type": "string",
2269
+ "description": "URL on which to serve the content",
2270
+ "default": "/metrics"
2271
+ },
2272
+ "portNumber": {
2273
+ "type": "number",
2274
+ "description": "If defined will launch another http server to serve the scaper"
2275
+ },
2276
+ "bind": {
2277
+ "type": "string",
2278
+ "description": "If defined along with portNumber used to bind specific address for dedicated http server"
2279
+ },
2280
+ "includeNodeMetrics": {
2281
+ "type": "boolean",
2282
+ "description": "Include NodeJS engine metrics",
2283
+ "default": true
2284
+ },
2285
+ "includeRequestMetrics": {
2286
+ "type": "boolean",
2287
+ "description": "Include request served by Webda\n\nIt should generate common http_* metrics",
2288
+ "default": true
2289
+ },
2290
+ "partitionHistogram": {
2291
+ "type": "boolean",
2292
+ "description": "Do not partition histogram with requests labels"
2293
+ },
2294
+ "labels": {
2295
+ "type": "object",
2296
+ "additionalProperties": {
2297
+ "type": "string"
2298
+ },
2299
+ "description": "Labels to add"
2300
+ },
2301
+ "prefix": {
2302
+ "type": "string",
2303
+ "description": "Prefix to add to metrics"
2304
+ },
2305
+ "openapi": {
2306
+ "type": "object",
2307
+ "additionalProperties": true
2052
2308
  }
2053
2309
  },
2054
- "title": "FileStore"
2310
+ "required": [
2311
+ "includeNodeMetrics",
2312
+ "includeRequestMetrics",
2313
+ "type"
2314
+ ],
2315
+ "$schema": "http://json-schema.org/draft-07/schema#",
2316
+ "title": "PrometheusService"
2055
2317
  },
2056
- "webda/memorylogger": {
2318
+ "Webda/ProxyService": {
2057
2319
  "type": "object",
2058
2320
  "properties": {
2059
2321
  "type": {
@@ -2062,14 +2324,15 @@
2062
2324
  },
2063
2325
  "url": {
2064
2326
  "type": "string",
2065
- "description": "URL on which to serve the content"
2327
+ "description": "URL to expose"
2066
2328
  },
2067
- "logLevel": {
2068
- "$ref": "#/definitions/WorkerLogLevel",
2069
- "description": "Specify the log level of this service"
2329
+ "backend": {
2330
+ "type": "string",
2331
+ "description": "URL to proxy to"
2070
2332
  },
2071
- "limit": {
2072
- "type": "number"
2333
+ "requireAuthentication": {
2334
+ "type": "boolean",
2335
+ "description": "Helper to refuse any request if user is not auth"
2073
2336
  },
2074
2337
  "openapi": {
2075
2338
  "type": "object",
@@ -2077,26 +2340,15 @@
2077
2340
  }
2078
2341
  },
2079
2342
  "required": [
2080
- "logLevel",
2343
+ "backend",
2344
+ "requireAuthentication",
2081
2345
  "type"
2082
2346
  ],
2347
+ "description": "Proxy to a backend service",
2083
2348
  "$schema": "http://json-schema.org/draft-07/schema#",
2084
- "definitions": {
2085
- "WorkerLogLevel": {
2086
- "type": "string",
2087
- "enum": [
2088
- "ERROR",
2089
- "WARN",
2090
- "INFO",
2091
- "DEBUG",
2092
- "TRACE"
2093
- ],
2094
- "description": "LogLevel as intersection to compare with integer values"
2095
- }
2096
- },
2097
- "title": "MemoryLogger"
2349
+ "title": "ProxyService"
2098
2350
  },
2099
- "webda/consolelogger": {
2351
+ "Webda/ResourceService": {
2100
2352
  "type": "object",
2101
2353
  "properties": {
2102
2354
  "type": {
@@ -2105,14 +2357,28 @@
2105
2357
  },
2106
2358
  "url": {
2107
2359
  "type": "string",
2108
- "description": "URL on which to serve the content"
2360
+ "description": "URL on which to serve the content",
2361
+ "default": "resources"
2109
2362
  },
2110
- "logLevel": {
2111
- "$ref": "#/definitions/WorkerLogLevel",
2112
- "description": "Specify the log level of this service"
2363
+ "folder": {
2364
+ "type": "string",
2365
+ "description": "Folder to server",
2366
+ "default": "\".\" + url"
2113
2367
  },
2114
- "format": {
2115
- "type": "string"
2368
+ "rootRedirect": {
2369
+ "type": "boolean",
2370
+ "description": "Add the / root to redirect to /{url}",
2371
+ "default": false
2372
+ },
2373
+ "index": {
2374
+ "type": "string",
2375
+ "description": "Index file",
2376
+ "default": "index.html"
2377
+ },
2378
+ "indexFallback": {
2379
+ "type": "boolean",
2380
+ "description": "Return the index file for any unfound resource Useful for single page application",
2381
+ "default": true
2116
2382
  },
2117
2383
  "openapi": {
2118
2384
  "type": "object",
@@ -2120,26 +2386,13 @@
2120
2386
  }
2121
2387
  },
2122
2388
  "required": [
2123
- "logLevel",
2124
2389
  "type"
2125
2390
  ],
2391
+ "description": "ResourceService parameters",
2126
2392
  "$schema": "http://json-schema.org/draft-07/schema#",
2127
- "definitions": {
2128
- "WorkerLogLevel": {
2129
- "type": "string",
2130
- "enum": [
2131
- "ERROR",
2132
- "WARN",
2133
- "INFO",
2134
- "DEBUG",
2135
- "TRACE"
2136
- ],
2137
- "description": "LogLevel as intersection to compare with integer values"
2138
- }
2139
- },
2140
- "title": "ConsoleLogger"
2393
+ "title": "ResourceService"
2141
2394
  },
2142
- "webda/filelogger": {
2395
+ "Webda/RESTDomainService": {
2143
2396
  "type": "object",
2144
2397
  "properties": {
2145
2398
  "type": {
@@ -2150,18 +2403,37 @@
2150
2403
  "type": "string",
2151
2404
  "description": "URL on which to serve the content"
2152
2405
  },
2153
- "logLevel": {
2154
- "$ref": "#/definitions/WorkerLogLevel",
2155
- "description": "Specify the log level of this service"
2406
+ "operations": {
2407
+ "type": "boolean",
2408
+ "description": "Expose objects as operations too"
2156
2409
  },
2157
- "format": {
2158
- "type": "string"
2410
+ "nameTransfomer": {
2411
+ "type": "string",
2412
+ "enum": [
2413
+ "camelCase",
2414
+ "lowercase",
2415
+ "none"
2416
+ ],
2417
+ "description": "Transform the name of the model to be used in the URL"
2159
2418
  },
2160
- "file": {
2161
- "type": "string"
2419
+ "queryMethod": {
2420
+ "type": "string",
2421
+ "enum": [
2422
+ "PUT",
2423
+ "GET"
2424
+ ],
2425
+ "description": "Method used for query objects",
2426
+ "default": "PUT"
2162
2427
  },
2163
- "sizeLimit": {
2164
- "type": "number"
2428
+ "models": {
2429
+ "type": "array",
2430
+ "items": {
2431
+ "type": "string"
2432
+ },
2433
+ "description": "List of models to include\n\nIf model is prefixed with a ! it will be excluded",
2434
+ "default": [
2435
+ "*"
2436
+ ]
2165
2437
  },
2166
2438
  "openapi": {
2167
2439
  "type": "object",
@@ -2169,70 +2441,120 @@
2169
2441
  }
2170
2442
  },
2171
2443
  "required": [
2172
- "file",
2173
- "logLevel",
2444
+ "models",
2445
+ "nameTransfomer",
2446
+ "operations",
2447
+ "queryMethod",
2174
2448
  "type"
2175
2449
  ],
2176
2450
  "$schema": "http://json-schema.org/draft-07/schema#",
2177
- "definitions": {
2178
- "WorkerLogLevel": {
2451
+ "title": "RESTDomainService"
2452
+ },
2453
+ "Webda/RoleModel": {
2454
+ "type": "object",
2455
+ "properties": {
2456
+ "_creationDate": {
2179
2457
  "type": "string",
2180
- "enum": [
2181
- "ERROR",
2182
- "WARN",
2183
- "INFO",
2184
- "DEBUG",
2185
- "TRACE"
2186
- ],
2187
- "description": "LogLevel as intersection to compare with integer values"
2458
+ "format": "date-time",
2459
+ "description": "Creation date",
2460
+ "readOnly": true
2461
+ },
2462
+ "_lastUpdate": {
2463
+ "type": "string",
2464
+ "format": "date-time",
2465
+ "description": "Last update date",
2466
+ "readOnly": true
2188
2467
  }
2189
2468
  },
2190
- "title": "FileLogger"
2469
+ "$schema": "http://json-schema.org/draft-07/schema#",
2470
+ "title": "RoleModel"
2191
2471
  },
2192
- "webda/prometheusservice": {
2472
+ "Webda/User": {
2193
2473
  "type": "object",
2194
2474
  "properties": {
2195
- "type": {
2475
+ "_creationDate": {
2196
2476
  "type": "string",
2197
- "description": "Type of the service"
2477
+ "format": "date-time",
2478
+ "description": "Creation date",
2479
+ "readOnly": true
2198
2480
  },
2199
- "url": {
2481
+ "_lastUpdate": {
2200
2482
  "type": "string",
2201
- "description": "URL on which to serve the content",
2202
- "default": "/metrics"
2483
+ "format": "date-time",
2484
+ "description": "Last update date",
2485
+ "readOnly": true
2203
2486
  },
2204
- "portNumber": {
2487
+ "displayName": {
2488
+ "type": "string",
2489
+ "description": "Display name for this user"
2490
+ },
2491
+ "_lastPasswordRecovery": {
2205
2492
  "type": "number",
2206
- "description": "If defined will launch another http server to serve the scaper"
2493
+ "description": "Last time the password was recovered",
2494
+ "readOnly": true
2207
2495
  },
2208
- "bind": {
2496
+ "_avatar": {
2209
2497
  "type": "string",
2210
- "description": "If defined along with portNumber used to bind specific address for dedicated http server"
2498
+ "description": "Define the user avatar if exists",
2499
+ "readOnly": true
2211
2500
  },
2212
- "includeNodeMetrics": {
2213
- "type": "boolean",
2214
- "description": "Include NodeJS engine metrics",
2215
- "default": true
2501
+ "locale": {
2502
+ "type": "string",
2503
+ "description": "Contains the locale of the user if known"
2216
2504
  },
2217
- "includeRequestMetrics": {
2218
- "type": "boolean",
2219
- "description": "Include request served by Webda\n\nIt should generate common http_* metrics",
2220
- "default": true
2505
+ "email": {
2506
+ "type": "string",
2507
+ "description": "Contain main user email if exists"
2508
+ }
2509
+ },
2510
+ "required": [
2511
+ "displayName"
2512
+ ],
2513
+ "description": "First basic model for User",
2514
+ "$schema": "http://json-schema.org/draft-07/schema#",
2515
+ "title": "User"
2516
+ },
2517
+ "Webda/UuidModel": {
2518
+ "type": "object",
2519
+ "properties": {
2520
+ "_creationDate": {
2521
+ "type": "string",
2522
+ "format": "date-time",
2523
+ "description": "Creation date",
2524
+ "readOnly": true
2221
2525
  },
2222
- "partitionHistogram": {
2223
- "type": "boolean",
2224
- "description": "Do not partition histogram with requests labels"
2526
+ "_lastUpdate": {
2527
+ "type": "string",
2528
+ "format": "date-time",
2529
+ "description": "Last update date",
2530
+ "readOnly": true
2225
2531
  },
2226
- "labels": {
2227
- "type": "object",
2228
- "additionalProperties": {
2229
- "type": "string"
2230
- },
2231
- "description": "Labels to add"
2532
+ "uuid": {
2533
+ "type": "string"
2534
+ }
2535
+ },
2536
+ "required": [
2537
+ "uuid"
2538
+ ],
2539
+ "description": "CoreModel with a uuid",
2540
+ "$schema": "http://json-schema.org/draft-07/schema#",
2541
+ "title": "UuidModel"
2542
+ },
2543
+ "Webda/VersionService": {
2544
+ "type": "object",
2545
+ "properties": {
2546
+ "type": {
2547
+ "type": "string",
2548
+ "description": "Type of the service"
2232
2549
  },
2233
- "prefix": {
2550
+ "url": {
2234
2551
  "type": "string",
2235
- "description": "Prefix to add to metrics"
2552
+ "description": "URL on which to serve the content",
2553
+ "default": "/version"
2554
+ },
2555
+ "version": {
2556
+ "type": "string",
2557
+ "description": "To force version otherwise would read from package.json"
2236
2558
  },
2237
2559
  "openapi": {
2238
2560
  "type": "object",
@@ -2240,12 +2562,11 @@
2240
2562
  }
2241
2563
  },
2242
2564
  "required": [
2243
- "includeNodeMetrics",
2244
- "includeRequestMetrics",
2245
2565
  "type"
2246
2566
  ],
2567
+ "description": "Version parameters",
2247
2568
  "$schema": "http://json-schema.org/draft-07/schema#",
2248
- "title": "PrometheusService"
2569
+ "title": "VersionService"
2249
2570
  }
2250
2571
  }
2251
2572
  }