@tsed/schema 7.49.0 → 7.50.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (308) hide show
  1. package/jest.config.js +2 -2
  2. package/lib/browser/schema.umd.min.js +1 -1
  3. package/lib/browser/schema.umd.min.js.map +1 -1
  4. package/lib/cjs/components/async-api/channelsMapper.js +62 -0
  5. package/lib/cjs/components/async-api/channelsMapper.js.map +1 -0
  6. package/lib/cjs/components/async-api/generate.js +20 -0
  7. package/lib/cjs/components/async-api/generate.js.map +1 -0
  8. package/lib/cjs/components/async-api/messageMapper.js +44 -0
  9. package/lib/cjs/components/async-api/messageMapper.js.map +1 -0
  10. package/lib/cjs/components/async-api/payloadMapper.js +52 -0
  11. package/lib/cjs/components/async-api/payloadMapper.js.map +1 -0
  12. package/lib/cjs/components/async-api/responseMapper.js +58 -0
  13. package/lib/cjs/components/async-api/responseMapper.js.map +1 -0
  14. package/lib/cjs/components/{anyMapper.js → default/anyMapper.js} +9 -9
  15. package/lib/cjs/components/default/anyMapper.js.map +1 -0
  16. package/lib/cjs/components/{classMapper.js → default/classMapper.js} +11 -9
  17. package/lib/cjs/components/default/classMapper.js.map +1 -0
  18. package/lib/cjs/components/{genericsMapper.js → default/genericsMapper.js} +6 -6
  19. package/lib/cjs/components/default/genericsMapper.js.map +1 -0
  20. package/lib/cjs/components/{inheritedClassMapper.js → default/inheritedClassMapper.js} +3 -3
  21. package/lib/cjs/components/default/inheritedClassMapper.js.map +1 -0
  22. package/lib/cjs/components/{itemMapper.js → default/itemMapper.js} +2 -2
  23. package/lib/cjs/components/default/itemMapper.js.map +1 -0
  24. package/lib/cjs/components/{lazyRefMapper.js → default/lazyRefMapper.js} +4 -4
  25. package/lib/cjs/components/default/lazyRefMapper.js.map +1 -0
  26. package/lib/cjs/components/{mapMapper.js → default/mapMapper.js} +3 -3
  27. package/lib/cjs/components/default/mapMapper.js.map +1 -0
  28. package/lib/cjs/components/{objectMapper.js → default/objectMapper.js} +5 -5
  29. package/lib/cjs/components/default/objectMapper.js.map +1 -0
  30. package/lib/cjs/components/{ofMapper.js → default/ofMapper.js} +2 -2
  31. package/lib/cjs/components/default/ofMapper.js.map +1 -0
  32. package/lib/cjs/components/{propertiesMapper.js → default/propertiesMapper.js} +3 -3
  33. package/lib/cjs/components/default/propertiesMapper.js.map +1 -0
  34. package/lib/cjs/components/{schemaMapper.js → default/schemaMapper.js} +16 -16
  35. package/lib/cjs/components/default/schemaMapper.js.map +1 -0
  36. package/lib/cjs/components/index.js +26 -20
  37. package/lib/cjs/components/index.js.map +1 -1
  38. package/lib/cjs/components/open-spec/generate.js +24 -0
  39. package/lib/cjs/components/open-spec/generate.js.map +1 -0
  40. package/lib/cjs/components/{operationInFilesMapper.js → open-spec/operationInFilesMapper.js} +1 -1
  41. package/lib/cjs/components/open-spec/operationInFilesMapper.js.map +1 -0
  42. package/lib/cjs/components/{operationInParameterMapper.js → open-spec/operationInParameterMapper.js} +7 -7
  43. package/lib/cjs/components/open-spec/operationInParameterMapper.js.map +1 -0
  44. package/lib/cjs/components/{operationInParametersMapper.js → open-spec/operationInParametersMapper.js} +2 -2
  45. package/lib/cjs/components/open-spec/operationInParametersMapper.js.map +1 -0
  46. package/lib/cjs/components/{operationInQueryMapper.js → open-spec/operationInQueryMapper.js} +4 -4
  47. package/lib/cjs/components/open-spec/operationInQueryMapper.js.map +1 -0
  48. package/lib/cjs/components/{operationMapper.js → open-spec/operationMapper.js} +6 -6
  49. package/lib/cjs/components/open-spec/operationMapper.js.map +1 -0
  50. package/lib/cjs/components/{operationMediaMapper.js → open-spec/operationMediaMapper.js} +2 -2
  51. package/lib/cjs/components/open-spec/operationMediaMapper.js.map +1 -0
  52. package/lib/cjs/components/{operationRequestBodyMapper.js → open-spec/operationRequestBodyMapper.js} +5 -5
  53. package/lib/cjs/components/open-spec/operationRequestBodyMapper.js.map +1 -0
  54. package/lib/cjs/components/{operationResponseMapper.js → open-spec/operationResponseMapper.js} +2 -2
  55. package/lib/cjs/components/open-spec/operationResponseMapper.js.map +1 -0
  56. package/lib/cjs/components/{pathsMapper.js → open-spec/pathsMapper.js} +38 -33
  57. package/lib/cjs/components/open-spec/pathsMapper.js.map +1 -0
  58. package/lib/cjs/constants/OperationVerbs.js +36 -0
  59. package/lib/cjs/constants/OperationVerbs.js.map +1 -0
  60. package/lib/cjs/decorators/operations/operation.js +45 -0
  61. package/lib/cjs/decorators/operations/operation.js.map +1 -0
  62. package/lib/cjs/decorators/operations/operationPath.js.map +1 -1
  63. package/lib/cjs/decorators/operations/publish.js +10 -0
  64. package/lib/cjs/decorators/operations/publish.js.map +1 -0
  65. package/lib/cjs/decorators/operations/route.js +14 -49
  66. package/lib/cjs/decorators/operations/route.js.map +1 -1
  67. package/lib/cjs/decorators/operations/subscribe.js +10 -0
  68. package/lib/cjs/decorators/operations/subscribe.js.map +1 -0
  69. package/lib/cjs/domain/JsonEntityStore.js +0 -4
  70. package/lib/cjs/domain/JsonEntityStore.js.map +1 -1
  71. package/lib/cjs/domain/JsonMap.js +1 -1
  72. package/lib/cjs/domain/JsonMap.js.map +1 -1
  73. package/lib/cjs/domain/JsonOperation.js +6 -0
  74. package/lib/cjs/domain/JsonOperation.js.map +1 -1
  75. package/lib/cjs/domain/JsonOperationPathsMap.js +4 -5
  76. package/lib/cjs/domain/JsonOperationPathsMap.js.map +1 -1
  77. package/lib/cjs/domain/JsonParameter.js +1 -1
  78. package/lib/cjs/domain/JsonParameter.js.map +1 -1
  79. package/lib/cjs/domain/JsonSchema.js +1 -1
  80. package/lib/cjs/domain/JsonSchema.js.map +1 -1
  81. package/lib/cjs/domain/SpecTypes.js +1 -0
  82. package/lib/cjs/domain/SpecTypes.js.map +1 -1
  83. package/lib/cjs/index.js +33 -22
  84. package/lib/cjs/index.js.map +1 -1
  85. package/lib/cjs/registries/JsonSchemaMapperContainer.js +13 -11
  86. package/lib/cjs/registries/JsonSchemaMapperContainer.js.map +1 -1
  87. package/lib/cjs/utils/getJsonSchema.js +7 -4
  88. package/lib/cjs/utils/getJsonSchema.js.map +1 -1
  89. package/lib/cjs/utils/getOperationsRoutes.js +3 -3
  90. package/lib/cjs/utils/getOperationsRoutes.js.map +1 -1
  91. package/lib/cjs/utils/getSpec.js +4 -14
  92. package/lib/cjs/utils/getSpec.js.map +1 -1
  93. package/lib/cjs/utils/mapOperationOptions.js +31 -0
  94. package/lib/cjs/utils/mapOperationOptions.js.map +1 -0
  95. package/lib/cjs/utils/operationIdFormatter.js +5 -1
  96. package/lib/cjs/utils/operationIdFormatter.js.map +1 -1
  97. package/lib/cjs/utils/ref.js +2 -2
  98. package/lib/cjs/utils/ref.js.map +1 -1
  99. package/lib/cjs/utils/removeHiddenOperation.js +8 -0
  100. package/lib/cjs/utils/removeHiddenOperation.js.map +1 -0
  101. package/lib/cjs/utils/somethingOf.js +16 -0
  102. package/lib/cjs/utils/somethingOf.js.map +1 -0
  103. package/lib/esm/components/async-api/channelsMapper.js +58 -0
  104. package/lib/esm/components/async-api/channelsMapper.js.map +1 -0
  105. package/lib/esm/components/async-api/generate.js +18 -0
  106. package/lib/esm/components/async-api/generate.js.map +1 -0
  107. package/lib/esm/components/async-api/messageMapper.js +40 -0
  108. package/lib/esm/components/async-api/messageMapper.js.map +1 -0
  109. package/lib/esm/components/async-api/payloadMapper.js +48 -0
  110. package/lib/esm/components/async-api/payloadMapper.js.map +1 -0
  111. package/lib/esm/components/async-api/responseMapper.js +54 -0
  112. package/lib/esm/components/async-api/responseMapper.js.map +1 -0
  113. package/lib/esm/components/{anyMapper.js → default/anyMapper.js} +9 -9
  114. package/lib/esm/components/default/anyMapper.js.map +1 -0
  115. package/lib/esm/components/{classMapper.js → default/classMapper.js} +11 -9
  116. package/lib/esm/components/default/classMapper.js.map +1 -0
  117. package/lib/esm/components/{genericsMapper.js → default/genericsMapper.js} +6 -6
  118. package/lib/esm/components/default/genericsMapper.js.map +1 -0
  119. package/lib/esm/components/{inheritedClassMapper.js → default/inheritedClassMapper.js} +3 -3
  120. package/lib/esm/components/default/inheritedClassMapper.js.map +1 -0
  121. package/lib/esm/components/default/itemMapper.js +6 -0
  122. package/lib/esm/components/default/itemMapper.js.map +1 -0
  123. package/lib/esm/components/{lazyRefMapper.js → default/lazyRefMapper.js} +4 -4
  124. package/lib/esm/components/default/lazyRefMapper.js.map +1 -0
  125. package/lib/esm/components/{mapMapper.js → default/mapMapper.js} +3 -3
  126. package/lib/esm/components/default/mapMapper.js.map +1 -0
  127. package/lib/esm/components/{objectMapper.js → default/objectMapper.js} +5 -5
  128. package/lib/esm/components/default/objectMapper.js.map +1 -0
  129. package/lib/esm/components/{ofMapper.js → default/ofMapper.js} +2 -2
  130. package/lib/esm/components/default/ofMapper.js.map +1 -0
  131. package/lib/esm/components/{propertiesMapper.js → default/propertiesMapper.js} +3 -3
  132. package/lib/esm/components/default/propertiesMapper.js.map +1 -0
  133. package/lib/esm/components/{schemaMapper.js → default/schemaMapper.js} +17 -17
  134. package/lib/esm/components/default/schemaMapper.js.map +1 -0
  135. package/lib/esm/components/index.js +26 -20
  136. package/lib/esm/components/index.js.map +1 -1
  137. package/lib/esm/components/open-spec/generate.js +22 -0
  138. package/lib/esm/components/open-spec/generate.js.map +1 -0
  139. package/lib/esm/components/{operationInFilesMapper.js → open-spec/operationInFilesMapper.js} +1 -1
  140. package/lib/esm/components/open-spec/operationInFilesMapper.js.map +1 -0
  141. package/lib/esm/components/{operationInParameterMapper.js → open-spec/operationInParameterMapper.js} +7 -7
  142. package/lib/esm/components/open-spec/operationInParameterMapper.js.map +1 -0
  143. package/lib/esm/components/{operationInParametersMapper.js → open-spec/operationInParametersMapper.js} +2 -2
  144. package/lib/esm/components/open-spec/operationInParametersMapper.js.map +1 -0
  145. package/lib/esm/components/{operationInQueryMapper.js → open-spec/operationInQueryMapper.js} +4 -4
  146. package/lib/esm/components/open-spec/operationInQueryMapper.js.map +1 -0
  147. package/lib/esm/components/{operationMapper.js → open-spec/operationMapper.js} +6 -6
  148. package/lib/esm/components/open-spec/operationMapper.js.map +1 -0
  149. package/lib/esm/components/open-spec/operationMediaMapper.js +7 -0
  150. package/lib/esm/components/open-spec/operationMediaMapper.js.map +1 -0
  151. package/lib/esm/components/{operationRequestBodyMapper.js → open-spec/operationRequestBodyMapper.js} +5 -5
  152. package/lib/esm/components/open-spec/operationRequestBodyMapper.js.map +1 -0
  153. package/lib/esm/components/{operationResponseMapper.js → open-spec/operationResponseMapper.js} +2 -2
  154. package/lib/esm/components/open-spec/operationResponseMapper.js.map +1 -0
  155. package/lib/esm/components/open-spec/pathsMapper.js +91 -0
  156. package/lib/esm/components/open-spec/pathsMapper.js.map +1 -0
  157. package/lib/esm/constants/OperationVerbs.js +33 -0
  158. package/lib/esm/constants/OperationVerbs.js.map +1 -0
  159. package/lib/esm/decorators/operations/operation.js +41 -0
  160. package/lib/esm/decorators/operations/operation.js.map +1 -0
  161. package/lib/esm/decorators/operations/operationPath.js.map +1 -1
  162. package/lib/esm/decorators/operations/publish.js +6 -0
  163. package/lib/esm/decorators/operations/publish.js.map +1 -0
  164. package/lib/esm/decorators/operations/route.js +14 -48
  165. package/lib/esm/decorators/operations/route.js.map +1 -1
  166. package/lib/esm/decorators/operations/subscribe.js +6 -0
  167. package/lib/esm/decorators/operations/subscribe.js.map +1 -0
  168. package/lib/esm/domain/JsonEntityStore.js +0 -4
  169. package/lib/esm/domain/JsonEntityStore.js.map +1 -1
  170. package/lib/esm/domain/JsonMap.js +1 -1
  171. package/lib/esm/domain/JsonMap.js.map +1 -1
  172. package/lib/esm/domain/JsonOperation.js +6 -0
  173. package/lib/esm/domain/JsonOperation.js.map +1 -1
  174. package/lib/esm/domain/JsonOperationPathsMap.js +4 -5
  175. package/lib/esm/domain/JsonOperationPathsMap.js.map +1 -1
  176. package/lib/esm/domain/JsonParameter.js +1 -1
  177. package/lib/esm/domain/JsonParameter.js.map +1 -1
  178. package/lib/esm/domain/JsonSchema.js +1 -1
  179. package/lib/esm/domain/JsonSchema.js.map +1 -1
  180. package/lib/esm/domain/SpecTypes.js +1 -0
  181. package/lib/esm/domain/SpecTypes.js.map +1 -1
  182. package/lib/esm/index.js +33 -22
  183. package/lib/esm/index.js.map +1 -1
  184. package/lib/esm/registries/JsonSchemaMapperContainer.js +13 -11
  185. package/lib/esm/registries/JsonSchemaMapperContainer.js.map +1 -1
  186. package/lib/esm/utils/getJsonSchema.js +7 -4
  187. package/lib/esm/utils/getJsonSchema.js.map +1 -1
  188. package/lib/esm/utils/getOperationsRoutes.js +3 -3
  189. package/lib/esm/utils/getOperationsRoutes.js.map +1 -1
  190. package/lib/esm/utils/getSpec.js +5 -15
  191. package/lib/esm/utils/getSpec.js.map +1 -1
  192. package/lib/{cjs/utils/mapRouteOptions.js → esm/utils/mapOperationOptions.js} +9 -8
  193. package/lib/esm/utils/mapOperationOptions.js.map +1 -0
  194. package/lib/esm/utils/operationIdFormatter.js +3 -0
  195. package/lib/esm/utils/operationIdFormatter.js.map +1 -1
  196. package/lib/esm/utils/ref.js +3 -3
  197. package/lib/esm/utils/ref.js.map +1 -1
  198. package/lib/esm/utils/removeHiddenOperation.js +4 -0
  199. package/lib/esm/utils/removeHiddenOperation.js.map +1 -0
  200. package/lib/esm/utils/somethingOf.js +12 -0
  201. package/lib/esm/utils/somethingOf.js.map +1 -0
  202. package/lib/tsconfig.esm.tsbuildinfo +1 -1
  203. package/lib/tsconfig.tsbuildinfo +1 -1
  204. package/lib/types/components/async-api/channelsMapper.d.ts +2 -0
  205. package/lib/types/components/async-api/generate.d.ts +1 -0
  206. package/lib/types/components/async-api/messageMapper.d.ts +6 -0
  207. package/lib/types/components/async-api/payloadMapper.d.ts +4 -0
  208. package/lib/types/components/async-api/responseMapper.d.ts +6 -0
  209. package/lib/types/components/{anyMapper.d.ts → default/anyMapper.d.ts} +1 -1
  210. package/lib/types/components/default/classMapper.d.ts +3 -0
  211. package/lib/types/components/{genericsMapper.d.ts → default/genericsMapper.d.ts} +1 -1
  212. package/lib/types/components/{inheritedClassMapper.d.ts → default/inheritedClassMapper.d.ts} +1 -1
  213. package/lib/types/components/{itemMapper.d.ts → default/itemMapper.d.ts} +1 -1
  214. package/lib/types/components/default/lazyRefMapper.d.ts +3 -0
  215. package/lib/types/components/{mapMapper.d.ts → default/mapMapper.d.ts} +1 -1
  216. package/lib/types/components/{objectMapper.d.ts → default/objectMapper.d.ts} +1 -1
  217. package/lib/types/components/default/ofMapper.d.ts +3 -0
  218. package/lib/types/components/default/propertiesMapper.d.ts +3 -0
  219. package/lib/types/components/default/schemaMapper.d.ts +3 -0
  220. package/lib/types/components/index.d.ts +26 -20
  221. package/lib/types/components/open-spec/generate.d.ts +1 -0
  222. package/lib/types/components/{operationInParameterMapper.d.ts → open-spec/operationInParameterMapper.d.ts} +2 -2
  223. package/lib/types/components/open-spec/operationInParametersMapper.d.ts +3 -0
  224. package/lib/types/components/open-spec/operationMapper.d.ts +3 -0
  225. package/lib/types/components/open-spec/operationMediaMapper.d.ts +3 -0
  226. package/lib/types/components/{operationRequestBodyMapper.d.ts → open-spec/operationRequestBodyMapper.d.ts} +2 -2
  227. package/lib/types/components/open-spec/operationResponseMapper.d.ts +3 -0
  228. package/lib/types/components/{pathsMapper.d.ts → open-spec/pathsMapper.d.ts} +1 -1
  229. package/lib/types/constants/OperationVerbs.d.ts +20 -0
  230. package/lib/types/decorators/operations/operation.d.ts +60 -0
  231. package/lib/types/decorators/operations/operationPath.d.ts +2 -2
  232. package/lib/types/decorators/operations/publish.d.ts +1 -0
  233. package/lib/types/decorators/operations/route.d.ts +11 -66
  234. package/lib/types/decorators/operations/subscribe.d.ts +1 -0
  235. package/lib/types/domain/JsonOperation.d.ts +1 -0
  236. package/lib/types/domain/SpecTypes.d.ts +2 -1
  237. package/lib/types/index.d.ts +33 -22
  238. package/lib/types/interfaces/JsonSchemaOptions.d.ts +3 -4
  239. package/lib/types/registries/JsonSchemaMapperContainer.d.ts +6 -5
  240. package/lib/types/utils/getOperationsRoutes.d.ts +2 -0
  241. package/lib/types/utils/getSpec.d.ts +5 -1
  242. package/lib/types/utils/{mapRouteOptions.d.ts → mapOperationOptions.d.ts} +1 -1
  243. package/lib/types/utils/operationIdFormatter.d.ts +2 -0
  244. package/lib/types/utils/removeHiddenOperation.d.ts +2 -0
  245. package/lib/types/utils/somethingOf.d.ts +1 -0
  246. package/package.json +6 -6
  247. package/lib/cjs/components/anyMapper.js.map +0 -1
  248. package/lib/cjs/components/classMapper.js.map +0 -1
  249. package/lib/cjs/components/genericsMapper.js.map +0 -1
  250. package/lib/cjs/components/inheritedClassMapper.js.map +0 -1
  251. package/lib/cjs/components/itemMapper.js.map +0 -1
  252. package/lib/cjs/components/lazyRefMapper.js.map +0 -1
  253. package/lib/cjs/components/mapMapper.js.map +0 -1
  254. package/lib/cjs/components/objectMapper.js.map +0 -1
  255. package/lib/cjs/components/ofMapper.js.map +0 -1
  256. package/lib/cjs/components/operationInFilesMapper.js.map +0 -1
  257. package/lib/cjs/components/operationInParameterMapper.js.map +0 -1
  258. package/lib/cjs/components/operationInParametersMapper.js.map +0 -1
  259. package/lib/cjs/components/operationInQueryMapper.js.map +0 -1
  260. package/lib/cjs/components/operationMapper.js.map +0 -1
  261. package/lib/cjs/components/operationMediaMapper.js.map +0 -1
  262. package/lib/cjs/components/operationRequestBodyMapper.js.map +0 -1
  263. package/lib/cjs/components/operationResponseMapper.js.map +0 -1
  264. package/lib/cjs/components/pathsMapper.js.map +0 -1
  265. package/lib/cjs/components/propertiesMapper.js.map +0 -1
  266. package/lib/cjs/components/schemaMapper.js.map +0 -1
  267. package/lib/cjs/constants/httpMethods.js +0 -46
  268. package/lib/cjs/constants/httpMethods.js.map +0 -1
  269. package/lib/cjs/utils/mapRouteOptions.js.map +0 -1
  270. package/lib/esm/components/anyMapper.js.map +0 -1
  271. package/lib/esm/components/classMapper.js.map +0 -1
  272. package/lib/esm/components/genericsMapper.js.map +0 -1
  273. package/lib/esm/components/inheritedClassMapper.js.map +0 -1
  274. package/lib/esm/components/itemMapper.js +0 -6
  275. package/lib/esm/components/itemMapper.js.map +0 -1
  276. package/lib/esm/components/lazyRefMapper.js.map +0 -1
  277. package/lib/esm/components/mapMapper.js.map +0 -1
  278. package/lib/esm/components/objectMapper.js.map +0 -1
  279. package/lib/esm/components/ofMapper.js.map +0 -1
  280. package/lib/esm/components/operationInFilesMapper.js.map +0 -1
  281. package/lib/esm/components/operationInParameterMapper.js.map +0 -1
  282. package/lib/esm/components/operationInParametersMapper.js.map +0 -1
  283. package/lib/esm/components/operationInQueryMapper.js.map +0 -1
  284. package/lib/esm/components/operationMapper.js.map +0 -1
  285. package/lib/esm/components/operationMediaMapper.js +0 -7
  286. package/lib/esm/components/operationMediaMapper.js.map +0 -1
  287. package/lib/esm/components/operationRequestBodyMapper.js.map +0 -1
  288. package/lib/esm/components/operationResponseMapper.js.map +0 -1
  289. package/lib/esm/components/pathsMapper.js +0 -86
  290. package/lib/esm/components/pathsMapper.js.map +0 -1
  291. package/lib/esm/components/propertiesMapper.js.map +0 -1
  292. package/lib/esm/components/schemaMapper.js.map +0 -1
  293. package/lib/esm/constants/httpMethods.js +0 -43
  294. package/lib/esm/constants/httpMethods.js.map +0 -1
  295. package/lib/esm/utils/mapRouteOptions.js +0 -22
  296. package/lib/esm/utils/mapRouteOptions.js.map +0 -1
  297. package/lib/types/components/classMapper.d.ts +0 -3
  298. package/lib/types/components/lazyRefMapper.d.ts +0 -3
  299. package/lib/types/components/ofMapper.d.ts +0 -3
  300. package/lib/types/components/operationInParametersMapper.d.ts +0 -3
  301. package/lib/types/components/operationMapper.d.ts +0 -3
  302. package/lib/types/components/operationMediaMapper.d.ts +0 -3
  303. package/lib/types/components/operationResponseMapper.d.ts +0 -3
  304. package/lib/types/components/propertiesMapper.d.ts +0 -3
  305. package/lib/types/components/schemaMapper.d.ts +0 -3
  306. package/lib/types/constants/httpMethods.d.ts +0 -12
  307. /package/lib/types/components/{operationInFilesMapper.d.ts → open-spec/operationInFilesMapper.d.ts} +0 -0
  308. /package/lib/types/components/{operationInQueryMapper.d.ts → open-spec/operationInQueryMapper.d.ts} +0 -0
@@ -0,0 +1,2 @@
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
+ export declare function channelsMapper(model: any, { channels, rootPath, ...options }: JsonSchemaOptions): any;
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,6 @@
1
+ import { JsonMethodStore } from "../../domain/JsonMethodStore";
2
+ import { JsonMethodPath } from "../../domain/JsonOperation";
3
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
4
+ export declare function messageMapper(jsonOperationStore: JsonMethodStore, operationPath: JsonMethodPath, { tags, defaultTags, ...options }?: JsonSchemaOptions): {
5
+ $ref: string;
6
+ };
@@ -0,0 +1,4 @@
1
+ import { JsonMethodStore } from "../../domain/JsonMethodStore";
2
+ import { JsonMethodPath } from "../../domain/JsonOperation";
3
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
4
+ export declare function payloadMapper(jsonOperationStore: JsonMethodStore, operationPath: JsonMethodPath, options: JsonSchemaOptions): unknown;
@@ -0,0 +1,6 @@
1
+ import { JsonMethodStore } from "../../domain/JsonMethodStore";
2
+ import { JsonMethodPath } from "../../domain/JsonOperation";
3
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
4
+ export declare function responsePayloadMapper(jsonOperationStore: JsonMethodStore, operationPath: JsonMethodPath, options: JsonSchemaOptions): {
5
+ $ref: string;
6
+ };
@@ -1,2 +1,2 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  export declare function anyMapper(input: any, options?: JsonSchemaOptions): any;
@@ -0,0 +1,3 @@
1
+ import { JsonSchema } from "../../domain/JsonSchema";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function classMapper(value: JsonSchema, options: JsonSchemaOptions): any;
@@ -1,4 +1,4 @@
1
- import { GenericsContext } from "../utils/generics";
1
+ import { GenericsContext } from "../../utils/generics";
2
2
  /**
3
3
  * @ignore
4
4
  */
@@ -1,4 +1,4 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  /**
3
3
  * @ignore
4
4
  */
@@ -1,2 +1,2 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  export declare function itemMapper(value: any, options: JsonSchemaOptions): any;
@@ -0,0 +1,3 @@
1
+ import { JsonLazyRef } from "../../domain/JsonLazyRef";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function lazyRefMapper(jsonLazyRef: JsonLazyRef, options: JsonSchemaOptions): any;
@@ -1,4 +1,4 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  /**
3
3
  * Serialize class which inherit from Map like JsonMap, JsonOperation, JsonParameter.
4
4
  * @param input
@@ -1,4 +1,4 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  /**
3
3
  * Serialize Any object to a json schema
4
4
  * @param input
@@ -0,0 +1,3 @@
1
+ import type { JsonSchema } from "../../domain/JsonSchema";
2
+ import type { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function ofMapper(input: (any | JsonSchema)[], options: JsonSchemaOptions, parent: JsonSchema): any[];
@@ -0,0 +1,3 @@
1
+ import type { JsonSchema } from "../../domain/JsonSchema";
2
+ import type { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function propertiesMapper(input: any | JsonSchema, options: JsonSchemaOptions, parent: JsonSchema): any;
@@ -0,0 +1,3 @@
1
+ import { JsonSchema } from "../../domain/JsonSchema";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function schemaMapper(schema: JsonSchema, opts: JsonSchemaOptions): any;
@@ -1,23 +1,29 @@
1
1
  /**
2
2
  * @file Automatically generated by barrelsby.
3
3
  */
4
- export * from "./anyMapper";
5
- export * from "./classMapper";
6
- export * from "./genericsMapper";
7
- export * from "./inheritedClassMapper";
8
- export * from "./itemMapper";
9
- export * from "./lazyRefMapper";
10
- export * from "./mapMapper";
11
- export * from "./objectMapper";
12
- export * from "./ofMapper";
13
- export * from "./operationInFilesMapper";
14
- export * from "./operationInParameterMapper";
15
- export * from "./operationInParametersMapper";
16
- export * from "./operationInQueryMapper";
17
- export * from "./operationMapper";
18
- export * from "./operationMediaMapper";
19
- export * from "./operationRequestBodyMapper";
20
- export * from "./operationResponseMapper";
21
- export * from "./pathsMapper";
22
- export * from "./propertiesMapper";
23
- export * from "./schemaMapper";
4
+ export * from "./async-api/channelsMapper";
5
+ export * from "./async-api/generate";
6
+ export * from "./async-api/messageMapper";
7
+ export * from "./async-api/payloadMapper";
8
+ export * from "./async-api/responseMapper";
9
+ export * from "./default/anyMapper";
10
+ export * from "./default/classMapper";
11
+ export * from "./default/genericsMapper";
12
+ export * from "./default/inheritedClassMapper";
13
+ export * from "./default/itemMapper";
14
+ export * from "./default/lazyRefMapper";
15
+ export * from "./default/mapMapper";
16
+ export * from "./default/objectMapper";
17
+ export * from "./default/ofMapper";
18
+ export * from "./default/propertiesMapper";
19
+ export * from "./default/schemaMapper";
20
+ export * from "./open-spec/generate";
21
+ export * from "./open-spec/operationInFilesMapper";
22
+ export * from "./open-spec/operationInParameterMapper";
23
+ export * from "./open-spec/operationInParametersMapper";
24
+ export * from "./open-spec/operationInQueryMapper";
25
+ export * from "./open-spec/operationMapper";
26
+ export * from "./open-spec/operationMediaMapper";
27
+ export * from "./open-spec/operationRequestBodyMapper";
28
+ export * from "./open-spec/operationResponseMapper";
29
+ export * from "./open-spec/pathsMapper";
@@ -0,0 +1 @@
1
+ export {};
@@ -1,7 +1,7 @@
1
1
  import { OS3Schema } from "@tsed/openspec";
2
2
  import type { JSONSchema6 } from "json-schema";
3
- import { JsonParameter } from "../domain/JsonParameter";
4
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
3
+ import { JsonParameter } from "../../domain/JsonParameter";
4
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
5
5
  export type JsonParameterOptions = JsonSchemaOptions & {
6
6
  jsonParameter: JsonParameter;
7
7
  jsonSchema: JSONSchema6;
@@ -0,0 +1,3 @@
1
+ import { JsonParameter } from "../../domain/JsonParameter";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function operationInParametersMapper(parameters: JsonParameter[], options: JsonSchemaOptions): any[];
@@ -0,0 +1,3 @@
1
+ import { JsonOperation } from "../../domain/JsonOperation";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function operationMapper(jsonOperation: JsonOperation, { tags, defaultTags, ...options }?: JsonSchemaOptions): any;
@@ -0,0 +1,3 @@
1
+ import { JsonMedia } from "../../domain/JsonMedia";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function operationMediaMapper(jsonMedia: JsonMedia, options: JsonSchemaOptions): any;
@@ -1,3 +1,3 @@
1
- import { JsonParameter } from "../domain/JsonParameter";
2
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonParameter } from "../../domain/JsonParameter";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
3
  export declare function operationRequestBodyMapper(bodyParameters: JsonParameter[], { consumes, ...options }: JsonSchemaOptions): any;
@@ -0,0 +1,3 @@
1
+ import { JsonResponse } from "../../domain/JsonResponse";
2
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
3
+ export declare function operationResponseMapper(jsonResponse: JsonResponse, options?: JsonSchemaOptions): any;
@@ -1,2 +1,2 @@
1
- import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
+ import { JsonSchemaOptions } from "../../interfaces/JsonSchemaOptions";
2
2
  export declare function pathsMapper(model: any, { paths, rootPath, ...options }: JsonSchemaOptions): any;
@@ -0,0 +1,20 @@
1
+ export declare enum OperationVerbs {
2
+ ALL = "ALL",
3
+ GET = "GET",
4
+ POST = "POST",
5
+ PUT = "PUT",
6
+ PATCH = "PATCH",
7
+ HEAD = "HEAD",
8
+ DELETE = "DELETE",
9
+ OPTIONS = "OPTIONS",
10
+ TRACE = "TRACE",
11
+ PUBLISH = "PUBLISH",
12
+ SUBSCRIBE = "SUBSCRIBE",
13
+ CUSTOM = "CUSTOM"
14
+ }
15
+ export declare const OPERATION_HTTP_VERBS: OperationVerbs[];
16
+ export declare const OPERATION_WS_VERBS: OperationVerbs[];
17
+ /**
18
+ * @deprecated Use OperationVerbs instead of OperationMethods
19
+ */
20
+ export declare const OperationMethods: typeof OperationVerbs;
@@ -0,0 +1,60 @@
1
+ import { OperationVerbs } from "../../constants/OperationVerbs";
2
+ export interface RouteChainedDecorators {
3
+ <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T> | void;
4
+ /**
5
+ * @param string
6
+ * @constructor
7
+ */
8
+ Path(string: string): this;
9
+ /**
10
+ * Set the operation method
11
+ * @param method
12
+ */
13
+ Method(method: OperationVerbs | string): this;
14
+ /**
15
+ * Set the operation id
16
+ * @param id
17
+ */
18
+ Id(id: string): this;
19
+ /**
20
+ * Set the operation id
21
+ * @param name
22
+ */
23
+ Name(name: string): this;
24
+ /**
25
+ *
26
+ * @param description
27
+ */
28
+ Description(description: string): this;
29
+ /**
30
+ * Summary
31
+ * @constructor
32
+ * @param Summary
33
+ */
34
+ Summary(Summary: string): this;
35
+ Use(...args: any[]): this;
36
+ UseAfter(...args: any[]): this;
37
+ UseBefore(...args: any[]): this;
38
+ }
39
+ /**
40
+ * Describe a new route with a method and path.
41
+ *
42
+ * ```typescript
43
+ * @Controller('/')
44
+ * export class Ctrl {
45
+ *
46
+ * @Route('GET', '/')
47
+ * get() { }
48
+ * }
49
+ *
50
+ * ```
51
+ *
52
+ * @returns {Function}
53
+ * @param method
54
+ * @param path
55
+ * @param args
56
+ * @decorator
57
+ * @operation
58
+ */
59
+ export declare function Operation(method: string, path: string, ...args: any[]): RouteChainedDecorators;
60
+ export declare function Operation(...args: any[]): RouteChainedDecorators;
@@ -1,4 +1,4 @@
1
- import { OperationMethods } from "../../constants/httpMethods";
1
+ import { OperationVerbs } from "../../constants/OperationVerbs";
2
2
  /**
3
3
  * Declare new Operation with his path and http method.
4
4
  *
@@ -18,4 +18,4 @@ import { OperationMethods } from "../../constants/httpMethods";
18
18
  * @schema
19
19
  * @operation
20
20
  */
21
- export declare function OperationPath(method: OperationMethods | string, path?: string | RegExp): (...args: any[]) => any;
21
+ export declare function OperationPath(method: OperationVerbs | string, path?: string | RegExp): (...args: any[]) => any;
@@ -0,0 +1 @@
1
+ export declare function Publish(event: string): import("./operation").RouteChainedDecorators;
@@ -1,63 +1,8 @@
1
- import { OperationMethods } from "../../constants/httpMethods";
2
- export interface RouteChainedDecorators {
3
- <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>): TypedPropertyDescriptor<T> | void;
4
- /**
5
- * @param string
6
- * @constructor
7
- */
8
- Path(string: string): this;
9
- /**
10
- * Set the operation method
11
- * @param method
12
- */
13
- Method(method: OperationMethods | string): this;
14
- /**
15
- * Set the operation id
16
- * @param id
17
- */
18
- Id(id: string): this;
19
- /**
20
- * Set the operation id
21
- * @param name
22
- */
23
- Name(name: string): this;
24
- /**
25
- *
26
- * @param description
27
- */
28
- Description(description: string): this;
29
- /**
30
- * Summary
31
- * @constructor
32
- * @param Summary
33
- */
34
- Summary(Summary: string): this;
35
- Use(...args: any[]): this;
36
- UseAfter(...args: any[]): this;
37
- UseBefore(...args: any[]): this;
38
- }
1
+ import { Operation } from "./operation";
39
2
  /**
40
- * Describe a new route with a method and path.
41
- *
42
- * ```typescript
43
- * @Controller('/')
44
- * export class Ctrl {
45
- *
46
- * @Route('GET', '/')
47
- * get() { }
48
- * }
49
- *
50
- * ```
51
- *
52
- * @returns {Function}
53
- * @param method
54
- * @param path
55
- * @param args
56
- * @decorator
57
- * @operation
3
+ * @deprecated Use Operation instead of Route
58
4
  */
59
- export declare function Route(method: string, path: string, ...args: any[]): RouteChainedDecorators;
60
- export declare function Route(...args: any[]): RouteChainedDecorators;
5
+ export declare const Route: typeof Operation;
61
6
  /**
62
7
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
63
8
  *
@@ -73,7 +18,7 @@ export declare function Route(...args: any[]): RouteChainedDecorators;
73
18
  * @operation
74
19
  * @httpMethod
75
20
  */
76
- export declare function All(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
21
+ export declare function All(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
77
22
  /**
78
23
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
79
24
  *
@@ -89,7 +34,7 @@ export declare function All(path?: string | RegExp | any, ...args: any[]): Route
89
34
  * @operation
90
35
  * @httpMethod
91
36
  */
92
- export declare function Get(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
37
+ export declare function Get(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
93
38
  /**
94
39
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
95
40
  *
@@ -105,7 +50,7 @@ export declare function Get(path?: string | RegExp | any, ...args: any[]): Route
105
50
  * @operation
106
51
  * @httpMethod
107
52
  */
108
- export declare function Post(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
53
+ export declare function Post(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
109
54
  /**
110
55
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
111
56
  *
@@ -121,7 +66,7 @@ export declare function Post(path?: string | RegExp | any, ...args: any[]): Rout
121
66
  * @operation
122
67
  * @httpMethod
123
68
  */
124
- export declare function Put(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
69
+ export declare function Put(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
125
70
  /**
126
71
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
127
72
  *
@@ -137,7 +82,7 @@ export declare function Put(path?: string | RegExp | any, ...args: any[]): Route
137
82
  * @operation
138
83
  * @httpMethod
139
84
  */
140
- export declare function Delete(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
85
+ export declare function Delete(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
141
86
  /**
142
87
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
143
88
  *
@@ -153,7 +98,7 @@ export declare function Delete(path?: string | RegExp | any, ...args: any[]): Ro
153
98
  * @operation
154
99
  * @httpMethod
155
100
  */
156
- export declare function Head(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
101
+ export declare function Head(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
157
102
  /**
158
103
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
159
104
  *
@@ -169,7 +114,7 @@ export declare function Head(path?: string | RegExp | any, ...args: any[]): Rout
169
114
  * @operation
170
115
  * @httpMethod
171
116
  */
172
- export declare function Patch(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
117
+ export declare function Patch(path?: string | RegExp | any, ...args: any[]): import("./operation").RouteChainedDecorators;
173
118
  /**
174
119
  * This method is just like the `router.METHOD()` methods, except that it matches all HTTP methods (verbs).
175
120
  *
@@ -185,4 +130,4 @@ export declare function Patch(path?: string | RegExp | any, ...args: any[]): Rou
185
130
  * @operation
186
131
  * @httpMethod
187
132
  */
188
- export declare function Options(path?: string | RegExp | any, ...args: any[]): RouteChainedDecorators;
133
+ export declare function Options(path?: string | RegExp | unknown, ...args: unknown[]): import("./operation").RouteChainedDecorators;
@@ -0,0 +1 @@
1
+ export declare function Subscribe(event: string): import("./operation").RouteChainedDecorators;
@@ -47,4 +47,5 @@ export declare class JsonOperation extends JsonMap<JsonOperationOptions> {
47
47
  produces(produces: string[]): this;
48
48
  addProduce(produce: string): void;
49
49
  addOperationPath(method: string, path: string | RegExp, options?: any): this;
50
+ getAllowedOperationPath(allowedVerbs?: string[]): JsonMethodPath[];
50
51
  }
@@ -1,5 +1,6 @@
1
1
  export declare enum SpecTypes {
2
2
  JSON = "jsonschema",
3
3
  SWAGGER = "swagger2",
4
- OPENAPI = "openapi3"
4
+ OPENAPI = "openapi3",
5
+ ASYNCAPI = "asyncapi2"
5
6
  }
@@ -1,27 +1,33 @@
1
1
  /**
2
2
  * @file Automatically generated by barrelsby.
3
3
  */
4
- export * from "./components/anyMapper";
5
- export * from "./components/classMapper";
6
- export * from "./components/genericsMapper";
7
- export * from "./components/inheritedClassMapper";
8
- export * from "./components/itemMapper";
9
- export * from "./components/lazyRefMapper";
10
- export * from "./components/mapMapper";
11
- export * from "./components/objectMapper";
12
- export * from "./components/ofMapper";
13
- export * from "./components/operationInFilesMapper";
14
- export * from "./components/operationInParameterMapper";
15
- export * from "./components/operationInParametersMapper";
16
- export * from "./components/operationInQueryMapper";
17
- export * from "./components/operationMapper";
18
- export * from "./components/operationMediaMapper";
19
- export * from "./components/operationRequestBodyMapper";
20
- export * from "./components/operationResponseMapper";
21
- export * from "./components/pathsMapper";
22
- export * from "./components/propertiesMapper";
23
- export * from "./components/schemaMapper";
24
- export * from "./constants/httpMethods";
4
+ export * from "./components/async-api/channelsMapper";
5
+ export * from "./components/async-api/generate";
6
+ export * from "./components/async-api/messageMapper";
7
+ export * from "./components/async-api/payloadMapper";
8
+ export * from "./components/async-api/responseMapper";
9
+ export * from "./components/default/anyMapper";
10
+ export * from "./components/default/classMapper";
11
+ export * from "./components/default/genericsMapper";
12
+ export * from "./components/default/inheritedClassMapper";
13
+ export * from "./components/default/itemMapper";
14
+ export * from "./components/default/lazyRefMapper";
15
+ export * from "./components/default/mapMapper";
16
+ export * from "./components/default/objectMapper";
17
+ export * from "./components/default/ofMapper";
18
+ export * from "./components/default/propertiesMapper";
19
+ export * from "./components/default/schemaMapper";
20
+ export * from "./components/open-spec/generate";
21
+ export * from "./components/open-spec/operationInFilesMapper";
22
+ export * from "./components/open-spec/operationInParameterMapper";
23
+ export * from "./components/open-spec/operationInParametersMapper";
24
+ export * from "./components/open-spec/operationInQueryMapper";
25
+ export * from "./components/open-spec/operationMapper";
26
+ export * from "./components/open-spec/operationMediaMapper";
27
+ export * from "./components/open-spec/operationRequestBodyMapper";
28
+ export * from "./components/open-spec/operationResponseMapper";
29
+ export * from "./components/open-spec/pathsMapper";
30
+ export * from "./constants/OperationVerbs";
25
31
  export * from "./constants/httpStatusMessages";
26
32
  export * from "./decorators/class/children";
27
33
  export * from "./decorators/class/discriminatorValue";
@@ -86,16 +92,19 @@ export * from "./decorators/operations/header";
86
92
  export * from "./decorators/operations/in";
87
93
  export * from "./decorators/operations/inFile";
88
94
  export * from "./decorators/operations/location";
95
+ export * from "./decorators/operations/operation";
89
96
  export * from "./decorators/operations/operationId";
90
97
  export * from "./decorators/operations/operationPath";
91
98
  export * from "./decorators/operations/partial";
92
99
  export * from "./decorators/operations/path";
93
100
  export * from "./decorators/operations/produces";
101
+ export * from "./decorators/operations/publish";
94
102
  export * from "./decorators/operations/redirect";
95
103
  export * from "./decorators/operations/returns";
96
104
  export * from "./decorators/operations/route";
97
105
  export * from "./decorators/operations/security";
98
106
  export * from "./decorators/operations/status";
107
+ export * from "./decorators/operations/subscribe";
99
108
  export * from "./decorators/operations/summary";
100
109
  export * from "./decorators/operations/tags";
101
110
  export * from "./decorators/operations/view";
@@ -156,12 +165,14 @@ export * from "./utils/mapOpenSpec";
156
165
  export * from "./utils/mapOpenSpec2";
157
166
  export * from "./utils/mapOpenSpec3";
158
167
  export * from "./utils/mapOpenSpecInfo";
159
- export * from "./utils/mapRouteOptions";
168
+ export * from "./utils/mapOperationOptions";
160
169
  export * from "./utils/matchGroups";
161
170
  export * from "./utils/mergeSpec";
162
171
  export * from "./utils/operationIdFormatter";
163
172
  export * from "./utils/ref";
173
+ export * from "./utils/removeHiddenOperation";
164
174
  export * from "./utils/serializeEnumValues";
175
+ export * from "./utils/somethingOf";
165
176
  export * from "./utils/toJsonMapCollection";
166
177
  export * from "./utils/toJsonRegex";
167
178
  export * from "./utils/transformToOS2";
@@ -1,14 +1,13 @@
1
- import { OpenSpecHash, OS2Schema, OS3Schema } from "@tsed/openspec";
2
1
  import { SpecTypes } from "../domain/SpecTypes";
3
2
  export interface JsonSchemaOptions {
4
3
  /**
5
- * Map properties with the alias name. By default: false
4
+ * Map properties with the alias name. By default, false
6
5
  */
7
6
  useAlias?: boolean;
8
7
  /**
9
- * Reference to Schema Object.
8
+ * Reference to components Object.
10
9
  */
11
- schemas?: OpenSpecHash<OS3Schema | OS2Schema>;
10
+ components?: Record<string, any>;
12
11
  /**
13
12
  * Define Spec types level
14
13
  */
@@ -1,20 +1,21 @@
1
+ import { SpecTypes } from "../domain/SpecTypes";
1
2
  /**
2
3
  * @ignore
3
4
  */
4
5
  export interface JsonSchemaMapper {
5
- (schema: any, options: any, parent?: any): any;
6
+ (...args: any[]): any;
6
7
  }
7
8
  /**
8
9
  * @ignore
9
10
  */
10
- export declare function registerJsonSchemaMapper(type: string, mapper: JsonSchemaMapper): Map<string, JsonSchemaMapper>;
11
+ export declare function registerJsonSchemaMapper(type: string, mapper: JsonSchemaMapper, spec?: SpecTypes): Map<string, JsonSchemaMapper>;
11
12
  /**
12
13
  * @ignore
13
14
  */
14
- export declare function getJsonSchemaMapper(type: string): JsonSchemaMapper;
15
+ export declare function getJsonSchemaMapper(type: string, options: any): JsonSchemaMapper;
15
16
  /**
16
17
  * @ignore
17
18
  */
18
- export declare function execMapper(type: string, schema: any, options: any, parent?: any): any;
19
+ export declare function execMapper(type: string, args: any[], options: any, parent?: any): any;
19
20
  export declare function hasMapper(type: string): boolean;
20
- export declare function oneOfMapper(...types: string[]): string;
21
+ export declare function oneOfMapper(types: string[], options: any): string;
@@ -1,8 +1,10 @@
1
1
  import { Type } from "@tsed/core";
2
+ import { OperationVerbs } from "../constants/OperationVerbs";
2
3
  import { JsonMethodStore } from "../domain/JsonMethodStore";
3
4
  import { JsonOperationRoute } from "../domain/JsonOperationRoute";
4
5
  export interface GetOperationsRoutesOptions {
5
6
  withChildren?: boolean;
6
7
  basePath?: string;
8
+ allowedVerbs?: OperationVerbs[];
7
9
  }
8
10
  export declare function getOperationsRoutes<Entity extends JsonMethodStore = JsonMethodStore>(token: Type<any> | any, options?: GetOperationsRoutesOptions): JsonOperationRoute<Entity>[];
@@ -8,7 +8,11 @@ export interface SpecSerializerOptions extends JsonSchemaOptions {
8
8
  /**
9
9
  * Paths
10
10
  */
11
- paths?: any;
11
+ paths?: Record<string, any>;
12
+ /**
13
+ * Channels
14
+ */
15
+ channels?: Record<string, any>;
12
16
  /**
13
17
  * Root path. This paths will be added to all generated paths Object.
14
18
  */
@@ -1,4 +1,4 @@
1
- export declare function mapRouteOptions(args: any[]): {
1
+ export declare function mapOperationOptions(args: any[]): {
2
2
  path: undefined;
3
3
  method: undefined;
4
4
  use: any[];
@@ -1,4 +1,6 @@
1
+ import { JsonSchemaOptions } from "../interfaces/JsonSchemaOptions";
1
2
  /**
2
3
  * @ignore
3
4
  */
4
5
  export declare function operationIdFormatter(pattern?: string): (name: string, propertyKey: string, path?: string) => string;
6
+ export declare function getOperationId(path: string, { store, operationIdFormatter }: JsonSchemaOptions): any;
@@ -0,0 +1,2 @@
1
+ import { JsonMethodStore } from "../domain/JsonMethodStore";
2
+ export declare function removeHiddenOperation(operationStore: JsonMethodStore): boolean;
@@ -0,0 +1 @@
1
+ export declare function makeOf(key: string, schemes: unknown[]): unknown;