@ezpaarse-project/ezreeport-sdk-js 1.0.0-beta.1 → 1.0.0-beta.11

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 (307) hide show
  1. package/README.md +19 -752
  2. package/dist/browser/ezreeport-sdk-js.mjs +1054 -891
  3. package/dist/browser/ezreeport-sdk-js.mjs.map +1 -1
  4. package/dist/browser/ezreeport-sdk-js.umd.js +5 -3
  5. package/dist/browser/ezreeport-sdk-js.umd.js.map +1 -1
  6. package/dist/dist/browser/ezreeport-sdk-js.mjs +2426 -0
  7. package/dist/dist/browser/ezreeport-sdk-js.mjs.map +1 -0
  8. package/dist/dist/browser/ezreeport-sdk-js.umd.js +6 -0
  9. package/dist/dist/browser/ezreeport-sdk-js.umd.js.map +1 -0
  10. package/dist/dist/dist/browser/ezreeport-sdk-js.mjs +2426 -0
  11. package/dist/dist/dist/browser/ezreeport-sdk-js.mjs.map +1 -0
  12. package/dist/dist/dist/browser/ezreeport-sdk-js.umd.js +6 -0
  13. package/dist/dist/dist/browser/ezreeport-sdk-js.umd.js.map +1 -0
  14. package/dist/dist/dist/node/package.json +58 -0
  15. package/dist/dist/dist/node/src/index.js +43 -0
  16. package/dist/dist/dist/node/src/index.js.map +1 -0
  17. package/dist/dist/dist/node/src/lib/axios.js +95 -0
  18. package/dist/dist/dist/node/src/lib/axios.js.map +1 -0
  19. package/dist/dist/dist/node/src/lib/promises.js +41 -0
  20. package/dist/dist/dist/node/src/lib/promises.js.map +1 -0
  21. package/dist/dist/dist/node/src/lib/utils.js +24 -0
  22. package/dist/dist/dist/node/src/lib/utils.js.map +1 -0
  23. package/dist/dist/dist/node/src/modules/auth.js +111 -0
  24. package/dist/dist/dist/node/src/modules/auth.js.map +1 -0
  25. package/dist/dist/dist/node/src/modules/auth.public.js +11 -0
  26. package/dist/dist/dist/node/src/modules/auth.public.js.map +1 -0
  27. package/dist/dist/dist/node/src/modules/crons.js +128 -0
  28. package/dist/dist/dist/node/src/modules/crons.js.map +1 -0
  29. package/dist/dist/dist/node/src/modules/crons.public.js +11 -0
  30. package/dist/dist/dist/node/src/modules/crons.public.js.map +1 -0
  31. package/dist/dist/dist/node/src/modules/elastic.js +31 -0
  32. package/dist/dist/dist/node/src/modules/elastic.js.map +1 -0
  33. package/dist/dist/dist/node/src/modules/elastic.public.js +7 -0
  34. package/dist/dist/dist/node/src/modules/elastic.public.js.map +1 -0
  35. package/dist/dist/dist/node/src/modules/health.js +60 -0
  36. package/dist/dist/dist/node/src/modules/health.js.map +1 -0
  37. package/dist/dist/dist/node/src/modules/health.public.js +9 -0
  38. package/dist/dist/dist/node/src/modules/health.public.js.map +1 -0
  39. package/dist/dist/dist/node/src/modules/history.js +62 -0
  40. package/dist/dist/dist/node/src/modules/history.js.map +1 -0
  41. package/dist/dist/dist/node/src/modules/history.public.js +6 -0
  42. package/dist/dist/dist/node/src/modules/history.public.js.map +1 -0
  43. package/dist/dist/dist/node/src/modules/namespaces.js +15 -0
  44. package/dist/dist/dist/node/src/modules/namespaces.js.map +1 -0
  45. package/dist/dist/dist/node/src/modules/namespaces.public.js +3 -0
  46. package/dist/dist/dist/node/src/modules/namespaces.public.js.map +1 -0
  47. package/dist/dist/dist/node/src/modules/queues.js +179 -0
  48. package/dist/dist/dist/node/src/modules/queues.js.map +1 -0
  49. package/dist/dist/dist/node/src/modules/queues.public.js +13 -0
  50. package/dist/dist/dist/node/src/modules/queues.public.js.map +1 -0
  51. package/dist/dist/dist/node/src/modules/reports.js +267 -0
  52. package/dist/dist/dist/node/src/modules/reports.js.map +1 -0
  53. package/dist/dist/dist/node/src/modules/reports.public.js +13 -0
  54. package/dist/dist/dist/node/src/modules/reports.public.js.map +1 -0
  55. package/dist/dist/dist/node/src/modules/setup.js +35 -0
  56. package/dist/dist/dist/node/src/modules/setup.js.map +1 -0
  57. package/dist/dist/dist/node/src/modules/setup.public.js +12 -0
  58. package/dist/dist/dist/node/src/modules/setup.public.js.map +1 -0
  59. package/dist/dist/dist/node/src/modules/tasks.base.js +51 -0
  60. package/dist/dist/dist/node/src/modules/tasks.base.js.map +1 -0
  61. package/dist/dist/dist/node/src/modules/tasks.js +281 -0
  62. package/dist/dist/dist/node/src/modules/tasks.js.map +1 -0
  63. package/dist/dist/dist/node/src/modules/tasks.public.js +21 -0
  64. package/dist/dist/dist/node/src/modules/tasks.public.js.map +1 -0
  65. package/dist/dist/dist/node/src/modules/tasksActivity.js +62 -0
  66. package/dist/dist/dist/node/src/modules/tasksActivity.js.map +1 -0
  67. package/dist/dist/dist/node/src/modules/tasksActivity.public.js +6 -0
  68. package/dist/dist/dist/node/src/modules/tasksActivity.public.js.map +1 -0
  69. package/dist/dist/dist/node/src/modules/tasksPresets.js +102 -0
  70. package/dist/dist/dist/node/src/modules/tasksPresets.js.map +1 -0
  71. package/dist/dist/dist/node/src/modules/tasksPresets.public.js +10 -0
  72. package/dist/dist/dist/node/src/modules/tasksPresets.public.js.map +1 -0
  73. package/dist/dist/dist/node/src/modules/templates.js +136 -0
  74. package/dist/dist/dist/node/src/modules/templates.js.map +1 -0
  75. package/dist/dist/dist/node/src/modules/templates.public.js +11 -0
  76. package/dist/dist/dist/node/src/modules/templates.public.js.map +1 -0
  77. package/dist/dist/dist/test +0 -0
  78. package/dist/{types → dist/dist/types/src}/index.d.ts +10 -2
  79. package/dist/{types → dist/dist/types/src}/lib/axios.d.ts +3 -3
  80. package/dist/dist/dist/types/src/lib/promises.d.ts +21 -0
  81. package/dist/{types → dist/dist/types/src}/lib/utils.d.ts +5 -0
  82. package/dist/{types → dist/dist/types/src}/modules/auth.d.ts +4 -4
  83. package/dist/{types → dist/dist/types/src}/modules/crons.d.ts +32 -8
  84. package/dist/dist/dist/types/src/modules/crons.public.d.ts +1 -0
  85. package/dist/dist/dist/types/src/modules/elastic.d.ts +22 -0
  86. package/dist/dist/dist/types/src/modules/elastic.public.d.ts +1 -0
  87. package/dist/{types → dist/dist/types/src}/modules/namespaces.d.ts +10 -0
  88. package/dist/dist/dist/types/src/modules/queues.d.ts +120 -0
  89. package/dist/dist/dist/types/src/modules/queues.public.d.ts +1 -0
  90. package/dist/{types → dist/dist/types/src}/modules/reports.d.ts +27 -17
  91. package/dist/dist/dist/types/src/modules/tasks.d.ts +243 -0
  92. package/dist/dist/dist/types/src/modules/tasks.public.d.ts +2 -0
  93. package/dist/dist/dist/types/src/modules/tasksActivity.d.ts +36 -0
  94. package/dist/dist/dist/types/src/modules/tasksActivity.public.d.ts +5 -0
  95. package/dist/dist/dist/types/src/modules/tasksPresets.d.ts +83 -0
  96. package/dist/dist/dist/types/src/modules/tasksPresets.public.d.ts +1 -0
  97. package/dist/dist/dist/types/src/modules/templates.d.ts +153 -0
  98. package/dist/dist/node/package.json +58 -0
  99. package/dist/dist/node/src/index.js +43 -0
  100. package/dist/dist/node/src/index.js.map +1 -0
  101. package/dist/dist/node/src/lib/axios.js +95 -0
  102. package/dist/dist/node/src/lib/axios.js.map +1 -0
  103. package/dist/dist/node/src/lib/promises.js +41 -0
  104. package/dist/dist/node/src/lib/promises.js.map +1 -0
  105. package/dist/dist/node/src/lib/utils.js +24 -0
  106. package/dist/dist/node/src/lib/utils.js.map +1 -0
  107. package/dist/dist/node/src/modules/auth.js +111 -0
  108. package/dist/dist/node/src/modules/auth.js.map +1 -0
  109. package/dist/dist/node/src/modules/auth.public.js +11 -0
  110. package/dist/dist/node/src/modules/auth.public.js.map +1 -0
  111. package/dist/dist/node/src/modules/crons.js +128 -0
  112. package/dist/dist/node/src/modules/crons.js.map +1 -0
  113. package/dist/dist/node/src/modules/crons.public.js +11 -0
  114. package/dist/dist/node/src/modules/crons.public.js.map +1 -0
  115. package/dist/dist/node/src/modules/elastic.js +31 -0
  116. package/dist/dist/node/src/modules/elastic.js.map +1 -0
  117. package/dist/dist/node/src/modules/elastic.public.js +7 -0
  118. package/dist/dist/node/src/modules/elastic.public.js.map +1 -0
  119. package/dist/dist/node/src/modules/health.js +60 -0
  120. package/dist/dist/node/src/modules/health.js.map +1 -0
  121. package/dist/dist/node/src/modules/health.public.js +9 -0
  122. package/dist/dist/node/src/modules/health.public.js.map +1 -0
  123. package/dist/dist/node/src/modules/history.js +62 -0
  124. package/dist/dist/node/src/modules/history.js.map +1 -0
  125. package/dist/dist/node/src/modules/history.public.js +6 -0
  126. package/dist/dist/node/src/modules/history.public.js.map +1 -0
  127. package/dist/dist/node/src/modules/namespaces.js +15 -0
  128. package/dist/dist/node/src/modules/namespaces.js.map +1 -0
  129. package/dist/dist/node/src/modules/namespaces.public.js +3 -0
  130. package/dist/dist/node/src/modules/namespaces.public.js.map +1 -0
  131. package/dist/dist/node/src/modules/queues.js +179 -0
  132. package/dist/dist/node/src/modules/queues.js.map +1 -0
  133. package/dist/dist/node/src/modules/queues.public.js +13 -0
  134. package/dist/dist/node/src/modules/queues.public.js.map +1 -0
  135. package/dist/dist/node/src/modules/reports.js +267 -0
  136. package/dist/dist/node/src/modules/reports.js.map +1 -0
  137. package/dist/dist/node/src/modules/reports.public.js +13 -0
  138. package/dist/dist/node/src/modules/reports.public.js.map +1 -0
  139. package/dist/dist/node/src/modules/setup.js +35 -0
  140. package/dist/dist/node/src/modules/setup.js.map +1 -0
  141. package/dist/dist/node/src/modules/setup.public.js +12 -0
  142. package/dist/dist/node/src/modules/setup.public.js.map +1 -0
  143. package/dist/dist/node/src/modules/tasks.base.js +51 -0
  144. package/dist/dist/node/src/modules/tasks.base.js.map +1 -0
  145. package/dist/dist/node/src/modules/tasks.js +281 -0
  146. package/dist/dist/node/src/modules/tasks.js.map +1 -0
  147. package/dist/dist/node/src/modules/tasks.public.js +21 -0
  148. package/dist/dist/node/src/modules/tasks.public.js.map +1 -0
  149. package/dist/dist/node/src/modules/tasksActivity.js +62 -0
  150. package/dist/dist/node/src/modules/tasksActivity.js.map +1 -0
  151. package/dist/dist/node/src/modules/tasksActivity.public.js +6 -0
  152. package/dist/dist/node/src/modules/tasksActivity.public.js.map +1 -0
  153. package/dist/dist/node/src/modules/tasksPresets.js +102 -0
  154. package/dist/dist/node/src/modules/tasksPresets.js.map +1 -0
  155. package/dist/dist/node/src/modules/tasksPresets.public.js +10 -0
  156. package/dist/dist/node/src/modules/tasksPresets.public.js.map +1 -0
  157. package/dist/dist/node/src/modules/templates.js +136 -0
  158. package/dist/dist/node/src/modules/templates.js.map +1 -0
  159. package/dist/dist/node/src/modules/templates.public.js +11 -0
  160. package/dist/dist/node/src/modules/templates.public.js.map +1 -0
  161. package/dist/dist/test +0 -0
  162. package/dist/dist/types/src/index.d.ts +32 -0
  163. package/dist/dist/types/src/lib/axios.d.ts +51 -0
  164. package/dist/dist/types/src/lib/promises.d.ts +21 -0
  165. package/dist/dist/types/src/lib/utils.d.ts +27 -0
  166. package/dist/dist/types/src/modules/auth.d.ts +90 -0
  167. package/dist/dist/types/src/modules/auth.public.d.ts +1 -0
  168. package/dist/dist/types/src/modules/crons.d.ts +102 -0
  169. package/dist/dist/types/src/modules/crons.public.d.ts +1 -0
  170. package/dist/dist/types/src/modules/elastic.d.ts +22 -0
  171. package/dist/dist/types/src/modules/elastic.public.d.ts +1 -0
  172. package/dist/dist/types/src/modules/health.d.ts +53 -0
  173. package/dist/dist/types/src/modules/health.public.d.ts +1 -0
  174. package/dist/dist/types/src/modules/history.d.ts +38 -0
  175. package/dist/dist/types/src/modules/history.public.d.ts +1 -0
  176. package/dist/dist/types/src/modules/namespaces.d.ts +29 -0
  177. package/dist/dist/types/src/modules/namespaces.public.d.ts +1 -0
  178. package/dist/dist/types/src/modules/queues.d.ts +120 -0
  179. package/dist/dist/types/src/modules/queues.public.d.ts +1 -0
  180. package/dist/dist/types/src/modules/reports.d.ts +204 -0
  181. package/dist/dist/types/src/modules/reports.public.d.ts +1 -0
  182. package/dist/dist/types/src/modules/setup.d.ts +17 -0
  183. package/dist/dist/types/src/modules/setup.public.d.ts +2 -0
  184. package/dist/dist/types/src/modules/tasks.base.d.ts +48 -0
  185. package/dist/dist/types/src/modules/tasks.d.ts +243 -0
  186. package/dist/dist/types/src/modules/tasks.public.d.ts +2 -0
  187. package/dist/dist/types/src/modules/tasksActivity.d.ts +36 -0
  188. package/dist/dist/types/src/modules/tasksActivity.public.d.ts +5 -0
  189. package/dist/dist/types/src/modules/tasksPresets.d.ts +83 -0
  190. package/dist/dist/types/src/modules/tasksPresets.public.d.ts +1 -0
  191. package/dist/dist/types/src/modules/templates.d.ts +153 -0
  192. package/dist/dist/types/src/modules/templates.public.d.ts +1 -0
  193. package/dist/node/package.json +15 -13
  194. package/dist/node/src/index.js +43 -0
  195. package/dist/node/src/index.js.map +1 -0
  196. package/dist/node/src/lib/axios.js +95 -0
  197. package/dist/node/src/lib/axios.js.map +1 -0
  198. package/dist/node/src/lib/promises.js +41 -0
  199. package/dist/node/src/lib/promises.js.map +1 -0
  200. package/dist/node/src/lib/utils.js +24 -0
  201. package/dist/node/src/lib/utils.js.map +1 -0
  202. package/dist/node/src/modules/auth.js +114 -0
  203. package/dist/node/src/modules/auth.js.map +1 -0
  204. package/dist/node/src/modules/auth.public.js +11 -0
  205. package/dist/node/src/modules/auth.public.js.map +1 -0
  206. package/dist/node/src/modules/crons.js +128 -0
  207. package/dist/node/src/modules/crons.js.map +1 -0
  208. package/dist/node/src/modules/crons.public.js +11 -0
  209. package/dist/node/src/modules/crons.public.js.map +1 -0
  210. package/dist/node/src/modules/elastic.js +31 -0
  211. package/dist/node/src/modules/elastic.js.map +1 -0
  212. package/dist/node/src/modules/elastic.public.js +7 -0
  213. package/dist/node/src/modules/elastic.public.js.map +1 -0
  214. package/dist/node/src/modules/health.js +60 -0
  215. package/dist/node/src/modules/health.js.map +1 -0
  216. package/dist/node/src/modules/health.public.js +9 -0
  217. package/dist/node/src/modules/health.public.js.map +1 -0
  218. package/dist/node/src/modules/history.js +62 -0
  219. package/dist/node/src/modules/history.js.map +1 -0
  220. package/dist/node/src/modules/history.public.js +6 -0
  221. package/dist/node/src/modules/history.public.js.map +1 -0
  222. package/dist/node/src/modules/namespaces.js +15 -0
  223. package/dist/node/src/modules/namespaces.js.map +1 -0
  224. package/dist/node/src/modules/namespaces.public.js +3 -0
  225. package/dist/node/src/modules/namespaces.public.js.map +1 -0
  226. package/dist/node/src/modules/queues.js +179 -0
  227. package/dist/node/src/modules/queues.js.map +1 -0
  228. package/dist/node/src/modules/queues.public.js +13 -0
  229. package/dist/node/src/modules/queues.public.js.map +1 -0
  230. package/dist/node/src/modules/reports.js +267 -0
  231. package/dist/node/src/modules/reports.js.map +1 -0
  232. package/dist/node/src/modules/reports.public.js +13 -0
  233. package/dist/node/src/modules/reports.public.js.map +1 -0
  234. package/dist/node/src/modules/setup.js +35 -0
  235. package/dist/node/src/modules/setup.js.map +1 -0
  236. package/dist/node/src/modules/setup.public.js +12 -0
  237. package/dist/node/src/modules/setup.public.js.map +1 -0
  238. package/dist/node/src/modules/tasks.base.js +51 -0
  239. package/dist/node/src/modules/tasks.base.js.map +1 -0
  240. package/dist/node/src/modules/tasks.js +281 -0
  241. package/dist/node/src/modules/tasks.js.map +1 -0
  242. package/dist/node/src/modules/tasks.public.js +21 -0
  243. package/dist/node/src/modules/tasks.public.js.map +1 -0
  244. package/dist/node/src/modules/tasksActivity.js +62 -0
  245. package/dist/node/src/modules/tasksActivity.js.map +1 -0
  246. package/dist/node/src/modules/tasksActivity.public.js +6 -0
  247. package/dist/node/src/modules/tasksActivity.public.js.map +1 -0
  248. package/dist/node/src/modules/tasksPresets.js +102 -0
  249. package/dist/node/src/modules/tasksPresets.js.map +1 -0
  250. package/dist/node/src/modules/tasksPresets.public.js +10 -0
  251. package/dist/node/src/modules/tasksPresets.public.js.map +1 -0
  252. package/dist/node/src/modules/templates.js +136 -0
  253. package/dist/node/src/modules/templates.js.map +1 -0
  254. package/dist/node/src/modules/templates.public.js +11 -0
  255. package/dist/node/src/modules/templates.public.js.map +1 -0
  256. package/dist/types/src/index.d.ts +32 -0
  257. package/dist/types/src/lib/axios.d.ts +51 -0
  258. package/dist/types/src/lib/promises.d.ts +21 -0
  259. package/dist/types/src/lib/utils.d.ts +27 -0
  260. package/dist/types/src/modules/auth.d.ts +90 -0
  261. package/dist/types/src/modules/auth.public.d.ts +1 -0
  262. package/dist/types/src/modules/crons.d.ts +102 -0
  263. package/dist/types/src/modules/crons.public.d.ts +1 -0
  264. package/dist/types/src/modules/elastic.d.ts +22 -0
  265. package/dist/types/src/modules/elastic.public.d.ts +1 -0
  266. package/dist/types/src/modules/health.d.ts +53 -0
  267. package/dist/types/src/modules/health.public.d.ts +1 -0
  268. package/dist/types/src/modules/history.d.ts +38 -0
  269. package/dist/types/src/modules/history.public.d.ts +1 -0
  270. package/dist/types/src/modules/namespaces.d.ts +29 -0
  271. package/dist/types/src/modules/namespaces.public.d.ts +1 -0
  272. package/dist/types/src/modules/queues.d.ts +120 -0
  273. package/dist/types/src/modules/queues.public.d.ts +1 -0
  274. package/dist/types/src/modules/reports.d.ts +204 -0
  275. package/dist/types/src/modules/reports.public.d.ts +1 -0
  276. package/dist/types/src/modules/setup.d.ts +17 -0
  277. package/dist/types/src/modules/setup.public.d.ts +2 -0
  278. package/dist/types/src/modules/tasks.base.d.ts +48 -0
  279. package/dist/types/src/modules/tasks.d.ts +243 -0
  280. package/dist/types/src/modules/tasks.public.d.ts +2 -0
  281. package/dist/types/src/modules/tasksActivity.d.ts +36 -0
  282. package/dist/types/src/modules/tasksActivity.public.d.ts +5 -0
  283. package/dist/types/src/modules/tasksPresets.d.ts +83 -0
  284. package/dist/types/src/modules/tasksPresets.public.d.ts +1 -0
  285. package/dist/types/src/modules/templates.d.ts +153 -0
  286. package/dist/types/src/modules/templates.public.d.ts +1 -0
  287. package/package.json +14 -12
  288. package/CHANGELOG.md +0 -42
  289. package/dist/types/lib/promises.d.ts +0 -18
  290. package/dist/types/modules/crons.public.d.ts +0 -1
  291. package/dist/types/modules/institutions.d.ts +0 -56
  292. package/dist/types/modules/queues.d.ts +0 -93
  293. package/dist/types/modules/queues.public.d.ts +0 -1
  294. package/dist/types/modules/tasks.d.ts +0 -124
  295. package/dist/types/modules/tasks.public.d.ts +0 -2
  296. package/dist/types/modules/templates.d.ts +0 -120
  297. /package/dist/{types → dist/dist/types/src}/modules/auth.public.d.ts +0 -0
  298. /package/dist/{types → dist/dist/types/src}/modules/health.d.ts +0 -0
  299. /package/dist/{types → dist/dist/types/src}/modules/health.public.d.ts +0 -0
  300. /package/dist/{types → dist/dist/types/src}/modules/history.d.ts +0 -0
  301. /package/dist/{types → dist/dist/types/src}/modules/history.public.d.ts +0 -0
  302. /package/dist/{types → dist/dist/types/src}/modules/namespaces.public.d.ts +0 -0
  303. /package/dist/{types → dist/dist/types/src}/modules/reports.public.d.ts +0 -0
  304. /package/dist/{types → dist/dist/types/src}/modules/setup.d.ts +0 -0
  305. /package/dist/{types → dist/dist/types/src}/modules/setup.public.d.ts +0 -0
  306. /package/dist/{types → dist/dist/types/src}/modules/tasks.base.d.ts +0 -0
  307. /package/dist/{types → dist/dist/types/src}/modules/templates.public.d.ts +0 -0
@@ -0,0 +1,204 @@
1
+ /// <reference types="node" />
2
+ /// <reference types="node" />
3
+ import { Stream } from 'stream';
4
+ import { type Period, type RawPeriod } from '../lib/utils';
5
+ import { type FullJob, type Job, type Queue } from './queues';
6
+ import type { RawFullTask } from './tasks';
7
+ interface RawReportResultDetail {
8
+ createdAt: string;
9
+ destroyAt: string;
10
+ took: number;
11
+ taskId: string;
12
+ files: {
13
+ detail: string;
14
+ report?: string;
15
+ debug?: string;
16
+ };
17
+ sendingTo?: string[];
18
+ period?: RawPeriod;
19
+ runAs?: string;
20
+ stats?: object;
21
+ error?: {
22
+ message: string;
23
+ stack: string[];
24
+ cause?: {
25
+ type: string;
26
+ layout: number;
27
+ figure?: number;
28
+ };
29
+ };
30
+ meta?: unknown;
31
+ }
32
+ export interface ReportResultDetail extends Omit<RawReportResultDetail, 'createdAt' | 'destroyAt' | 'period'> {
33
+ createdAt: Date;
34
+ destroyAt: Date;
35
+ period?: Period;
36
+ }
37
+ interface RawReportResult {
38
+ success: boolean;
39
+ detail: RawReportResultDetail;
40
+ }
41
+ export interface ReportResult extends Omit<RawReportResult, 'detail'> {
42
+ detail: ReportResultDetail;
43
+ }
44
+ interface RawReportData {
45
+ task: RawFullTask;
46
+ origin: string;
47
+ writeHistory?: boolean;
48
+ customPeriod?: RawPeriod;
49
+ debug?: boolean;
50
+ }
51
+ type ReportJob = Job<RawReportData>;
52
+ type FullReportJob = FullJob<RawReportData, RawReportResult>;
53
+ /**
54
+ * Start generation of a report
55
+ *
56
+ * Needs `namespaces[namespaceId].tasks-post-task-_run` permission
57
+ *
58
+ * @param taskOrId Task or id of the task
59
+ * @param params Other params for overriding default
60
+ * @param namespaces
61
+ *
62
+ * @returns Job info to track progress
63
+ */
64
+ export declare const startGeneration: (taskOrId: RawFullTask | RawFullTask['id'], params?: {
65
+ /**
66
+ * Override targets of task. Also enable first level of debugging
67
+ * (disable generation history)
68
+ */
69
+ testEmails?: string[];
70
+ /**
71
+ * Override period, must match task's recurrence
72
+ */
73
+ period?: Period;
74
+ }, namespaces?: string[]) => Promise<import("../lib/axios").ApiResponse<ReportJob>>;
75
+ export type GenerationStartedEvent = {
76
+ id: string | number;
77
+ queue: string;
78
+ };
79
+ export type GenerationProgressEvent = {
80
+ progress: number;
81
+ status: FullReportJob['status'];
82
+ };
83
+ type GenerationEvents = {
84
+ 'started': [GenerationStartedEvent];
85
+ 'progress': [GenerationProgressEvent];
86
+ };
87
+ /**
88
+ * Start generation of a report and track progress
89
+ *
90
+ * Needs `namespaces[namespaceId].tasks-post-task-run`
91
+ * & `namespaces[namespaceId].queues-get-queue-jobs-jobId` permissions
92
+ *
93
+ * @param taskOrId Task or id of the task
94
+ * @param params Other params for overriding default
95
+ * @param namespaces
96
+ *
97
+ * @fires #started When generation started. See `GenerationStartedEvent`.
98
+ * @fires #progress When generation progress. See `GenerationProgressEvent`. Job's progress is
99
+ * between 0 and 1
100
+ *
101
+ * @throws If job's fails. **Not if generation fails !**
102
+ *
103
+ * @returns When generation ends, with detail
104
+ */
105
+ export declare const startAndListenGeneration: (taskOrId: string | RawFullTask, params?: {
106
+ /**
107
+ * Override targets of task. Also enable first level of debugging
108
+ * (disable generation history)
109
+ */
110
+ testEmails?: string[] | undefined;
111
+ /**
112
+ * Override period, must match task's recurrence
113
+ */
114
+ period?: Period | undefined;
115
+ } | undefined, namespaces?: string[] | undefined) => import("../lib/promises").EventfulPromise<ReportResult, GenerationEvents>;
116
+ interface ResponseTypeMap {
117
+ arraybuffer: ArrayBuffer;
118
+ blob: Blob;
119
+ json: object;
120
+ text: string;
121
+ stream: Stream;
122
+ }
123
+ /**
124
+ * Get report main file (the result) by giving the report's name
125
+ *
126
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename` permission
127
+ *
128
+ * @param name Name of the report
129
+ * @param ext The extension of the result (renderer dependent)
130
+ * @param namespaces
131
+ * @param responseType Wanted response type
132
+ *
133
+ * @returns The report's content
134
+ */
135
+ export declare const getReportFileByName: <Result extends keyof ResponseTypeMap = "text">(name: string, namespaces?: string[], responseType?: Result | undefined, ext?: string) => Promise<ResponseTypeMap[Result]>;
136
+ /**
137
+ * Get report main file (the result) by giving job's info
138
+ *
139
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename`
140
+ * & `namespaces[namespaceId].queues-get-queue-jobs-jobId ` permission
141
+ *
142
+ * @param queueOrName Queue or queue's name where job is
143
+ * @param jobOrId Job or job's id in queue
144
+ * @param namespaces
145
+ * @param responseType Wanted response type
146
+ *
147
+ * @returns The report's content
148
+ */
149
+ export declare const getReportFileByJob: <Result extends keyof ResponseTypeMap = "text">(queueName: Queue | Queue['name'], jobId: Job<RawReportData> | Job<RawReportData>['id'], namespaces?: string[], responseType?: Result | undefined) => Promise<ResponseTypeMap[Result]>;
150
+ /**
151
+ * Get report detail by giving the report's name
152
+ *
153
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename` permission
154
+ *
155
+ * @param name Name of the report
156
+ * @param namespaces
157
+ * @param responseType Wanted response type. **If provided with anything but `json` you will have to
158
+ * cast in your type to avoid auto-completion issues.**
159
+ *
160
+ * @returns The detail's content
161
+ */
162
+ export declare const getReportDetailByName: (name: string, namespaces?: string[], responseType?: keyof ResponseTypeMap) => Promise<ReportResult>;
163
+ /**
164
+ * Get report detail by giving job's info
165
+ *
166
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename`
167
+ * & `namespaces[namespaceId].queues-get-queue-jobs-jobId` permission
168
+ *
169
+ * @param queueOrName Queue or queue's name where job is
170
+ * @param jobOrId Job or job's id in queue
171
+ * @param namespaces
172
+ * @param responseType Wanted response type. **If provided with anything but `json` you will have to
173
+ * cast in your type to avoid auto-completion issues.**
174
+ *
175
+ * @returns The detail's content
176
+ */
177
+ export declare const getReportDetailByJob: (queueName: Queue | Queue['name'], jobId: Job<RawReportData> | Job<RawReportData>['id'], namespaces?: string[], responseType?: keyof ResponseTypeMap) => Promise<ReportResult>;
178
+ /**
179
+ * Get report debug file by giving the report's name
180
+ *
181
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename` permission
182
+ *
183
+ * @param name Name of the report
184
+ * @param namespaces
185
+ * @param responseType Wanted response type
186
+ *
187
+ * @returns The debug's content
188
+ */
189
+ export declare const getReportDebugByName: <Result extends keyof ResponseTypeMap = "json">(name: string, namespaces?: string[], responseType?: Result | undefined) => Promise<ResponseTypeMap[Result]>;
190
+ /**
191
+ * Get report debug file by giving job's info
192
+ *
193
+ * Needs `namespaces[namespaceId].reports-get-year-yearMonth-filename`
194
+ * & `namespaces[namespaceId].queues-get-queue-jobs-jobId ` permission
195
+ *
196
+ * @param queueOrName Queue or queue's name where job is
197
+ * @param jobOrId Job or job's id in queue
198
+ * @param namespaces
199
+ * @param responseType Wanted response type
200
+ *
201
+ * @returns The debug's content
202
+ */
203
+ export declare const getReportDebugByJob: <Result extends keyof ResponseTypeMap = "json">(queueName: Queue | Queue['name'], jobId: Job<RawReportData> | Job<RawReportData>['id'], namespaces?: string[], responseType?: Result | undefined) => Promise<ResponseTypeMap[Result]>;
204
+ export {};
@@ -0,0 +1 @@
1
+ export { type ReportResultDetail, type ReportResult, type GenerationStartedEvent, type GenerationProgressEvent, startGeneration, startAndListenGeneration, getReportFileByName, getReportFileByJob, getReportDetailByName, getReportDetailByJob, getReportDebugByName, getReportDebugByJob, } from './reports';
@@ -0,0 +1,17 @@
1
+ export { isLogged, login, logout } from './auth';
2
+ /**
3
+ * Set API url to axios
4
+ *
5
+ * @param url The url
6
+ */
7
+ export declare const setURL: (url: string) => void;
8
+ /**
9
+ * Unset API url from axios
10
+ */
11
+ export declare const unsetURL: () => void;
12
+ /**
13
+ * Check if API url is setup in axios
14
+ *
15
+ * @returns If API url is setup
16
+ */
17
+ export declare const isURLset: () => boolean;
@@ -0,0 +1,2 @@
1
+ export { setURL, unsetURL, isURLset, } from './setup';
2
+ export { isLogged, login, logout, } from './auth';
@@ -0,0 +1,48 @@
1
+ import { type RawNamespace, type Namespace } from './namespaces';
2
+ export declare enum Recurrence {
3
+ DAILY = "DAILY",
4
+ WEEKLY = "WEEKLY",
5
+ MONTHLY = "MONTHLY",
6
+ QUARTERLY = "QUARTERLY",
7
+ BIENNIAL = "BIENNIAL",
8
+ YEARLY = "YEARLY"
9
+ }
10
+ export interface RawTask {
11
+ id: string;
12
+ name: string;
13
+ namespaceId: string;
14
+ recurrence: Recurrence;
15
+ nextRun: string;
16
+ lastRun?: string;
17
+ enabled: boolean;
18
+ createdAt: string;
19
+ updatedAt?: string;
20
+ }
21
+ export interface Task extends Omit<RawTask, 'nextRun' | 'lastRun' | 'createdAt' | 'updatedAt'> {
22
+ nextRun: Date;
23
+ lastRun?: Date;
24
+ createdAt: Date;
25
+ updatedAt?: Date;
26
+ }
27
+ /**
28
+ * Transform raw data from JSON, to JS usable data
29
+ *
30
+ * @param task Raw task
31
+ *
32
+ * @returns Parsed task
33
+ */
34
+ export declare const parseTask: (task: RawTask) => Task;
35
+ export interface RawTaskWithNamespace extends Omit<RawTask, 'namespaceId'> {
36
+ namespace: RawNamespace;
37
+ }
38
+ export interface TaskWithNamespace extends Omit<Task, 'namespaceId'> {
39
+ namespace: Namespace;
40
+ }
41
+ /**
42
+ * Transform raw data from JSON, to JS usable data
43
+ *
44
+ * @param task Raw task with namespace
45
+ *
46
+ * @returns Parsed task with namespace
47
+ */
48
+ export declare const parseTaskWithNamespace: (task: RawTaskWithNamespace) => TaskWithNamespace;
@@ -0,0 +1,243 @@
1
+ import { type ApiResponse, type PaginatedApiResponse } from '../lib/axios';
2
+ import type { PaginationOpts } from '../lib/utils';
3
+ import { type Activity, type RawActivity } from './tasksActivity';
4
+ import type { Namespace } from './namespaces';
5
+ import { type Layout, type RawTemplate, type Template } from './templates';
6
+ import { type Task, type RawTaskWithNamespace, type TaskWithNamespace } from './tasks.base';
7
+ interface AdditionalRawTaskData {
8
+ template: {
9
+ fetchOptions?: {
10
+ filters?: Record<string, any>;
11
+ dateField?: string;
12
+ index: string;
13
+ };
14
+ inserts?: (Layout & {
15
+ at: number;
16
+ })[];
17
+ };
18
+ extends: RawTemplate;
19
+ lastExtended?: {
20
+ id: string;
21
+ tags: RawTemplate['tags'];
22
+ };
23
+ targets: string[];
24
+ activity: RawActivity[];
25
+ }
26
+ interface AdditionalTaskData extends Omit<AdditionalRawTaskData, 'activity' | 'extends' | 'lastExtended'> {
27
+ activity: Activity[];
28
+ extends: Template;
29
+ lastExtended?: {
30
+ id: Template['id'];
31
+ name: Template['name'];
32
+ tags: Template['tags'];
33
+ };
34
+ }
35
+ export interface RawFullTask extends RawTaskWithNamespace, AdditionalRawTaskData {
36
+ }
37
+ export interface FullTask extends TaskWithNamespace, AdditionalTaskData {
38
+ }
39
+ /**
40
+ * Input data for creating a new task
41
+ */
42
+ export interface InputTask extends Pick<FullTask, 'name' | 'template' | 'targets' | 'recurrence'> {
43
+ namespace?: Task['namespaceId'];
44
+ nextRun?: FullTask['nextRun'];
45
+ enabled?: FullTask['enabled'];
46
+ extends: string;
47
+ }
48
+ /**
49
+ * Partial input data for creating a new task with a preset
50
+ */
51
+ export interface PartialInputTask extends Pick<InputTask, 'targets' | 'name' | 'namespace'>, Partial<Omit<InputTask, 'targets' | 'name' | 'namespace' | 'template'>> {
52
+ template: Pick<InputTask['template'], 'fetchOptions'>;
53
+ }
54
+ export type TaskList = (Task & {
55
+ tags: Template['tags'];
56
+ _count: {
57
+ targets: number;
58
+ };
59
+ })[];
60
+ /**
61
+ * Get all available tasks
62
+ *
63
+ * Needs `namespaces[namespaceId].tasks-get` permission
64
+ *
65
+ * @param paginationOpts Options for pagination
66
+ * @param namespaces
67
+ *
68
+ * @returns All tasks' info
69
+ */
70
+ export declare const getAllTasks: (paginationOpts?: PaginationOpts, namespaces?: Namespace['id'][]) => Promise<PaginatedApiResponse<TaskList[number], 'id'>>;
71
+ /**
72
+ * Get targets of available tasks
73
+ *
74
+ * Needs `namespaces[namespaceId].tasks-get-_targets` permission
75
+ *
76
+ * @param namespaces
77
+ *
78
+ * @returns Targets' email
79
+ */
80
+ export declare const getAllTargets: (namespaces?: Namespace['id'][]) => Promise<ApiResponse<string[]>>;
81
+ /**
82
+ * Get available tasks of specific target
83
+ *
84
+ * Needs `namespaces[namespaceId].tasks-get-_targets-email-tasks` permission
85
+ *
86
+ * @param email The email of the target
87
+ * @param namespaces
88
+ *
89
+ * @returns Tasks where given email is a target
90
+ */
91
+ export declare const getTasksOfTarget: (email: string, namespaces?: Namespace['id'][]) => Promise<{
92
+ content: {
93
+ nextRun: Date;
94
+ lastRun?: Date | undefined;
95
+ createdAt: Date;
96
+ updatedAt?: Date | undefined;
97
+ name: string;
98
+ id: string;
99
+ namespaceId: string;
100
+ recurrence: import("./tasks.base").Recurrence;
101
+ enabled: boolean;
102
+ tags: {
103
+ name: string;
104
+ color?: string | undefined;
105
+ }[];
106
+ }[];
107
+ status: {
108
+ code: number;
109
+ message: string;
110
+ };
111
+ }>;
112
+ /**
113
+ * Unsubscribe a target from a task
114
+ *
115
+ * Needs `namespaces[namespaceId].tasks-get-_targets-email-tasks` permission
116
+ *
117
+ * @param email The email of the target
118
+ * @param taskOrId Task or Task's id
119
+ * @param namespaces
120
+ */
121
+ export declare const unsubTargetOfTask: (email: string, taskOrId: Task | Task['id'], namespaces?: Namespace['id'][]) => Promise<void>;
122
+ /**
123
+ * Create a new task
124
+ *
125
+ * Needs `namespaces[namespaceId].tasks-post` permission
126
+ *
127
+ * @param task Task's data
128
+ * @param namespaces
129
+ *
130
+ * @returns Created task's info
131
+ */
132
+ export declare const createTask: (task: InputTask, namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
133
+ /**
134
+ * Creates a new task from a preset
135
+ *
136
+ * Needs `namespaces[namespaceId].tasks-post-_from-preset-presetId` permission
137
+ *
138
+ * @param presetId The ID of the preset.
139
+ * @param partialTask The partial input task.
140
+ * @param namespaces
141
+ *
142
+ * @returns Created task's info
143
+ */
144
+ export declare const createTaskFromPreset: (presetId: string, partialTask: PartialInputTask, namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
145
+ /**
146
+ * Get task info
147
+ *
148
+ * Needs `namespaces[namespaceId].tasks-get-task` permission
149
+ *
150
+ * @param taskOrId Task or Task's id
151
+ * @param namespaces
152
+ *
153
+ * @returns Task's info
154
+ */
155
+ export declare const getTask: (taskOrId: Task | Task['id'], namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
156
+ /**
157
+ * Update or create a task
158
+ *
159
+ * Needs `namespaces[namespaceId].tasks-put-task` permission
160
+ *
161
+ * @param task Task's data **with id**
162
+ * @param namespaces
163
+ *
164
+ * @returns Updated/Created Task's info
165
+ */
166
+ export declare const upsertTask: (task: InputTask & {
167
+ id: Task['id'];
168
+ }, namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
169
+ /**
170
+ * Update a task
171
+ *
172
+ * Needs `namespaces[namespaceId].tasks-put-task` permission
173
+ *
174
+ * @param task Task's data **with id**
175
+ * @param namespaces
176
+ *
177
+ * @deprecated Use `upsertTask` instead
178
+ *
179
+ * @returns Updated Task's info
180
+ */
181
+ export declare const updateTask: (task: InputTask & {
182
+ id: Task['id'];
183
+ }, namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
184
+ /**
185
+ * Delete a task
186
+ *
187
+ * Needs `namespaces[namespaceId].tasks-delete-task` permission
188
+ *
189
+ * @param taskOrId Task or Task's id
190
+ * @param namespaces
191
+ */
192
+ export declare const deleteTask: (taskOrId: Task | Task['id'], namespaces?: Namespace['id'][]) => Promise<void>;
193
+ /**
194
+ * Shorthand to enable task
195
+ *
196
+ * Needs `namespaces[namespaceId].tasks-put-_task-enable` permission
197
+ *
198
+ * @param taskOrId Task or Task's id
199
+ * @param namespaces
200
+ *
201
+ * @returns Updated task's info
202
+ */
203
+ export declare const enableTask: (taskOrId: Task | Task['id'], namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
204
+ /**
205
+ * Shorthand to disable task
206
+ *
207
+ * Needs `namespaces[namespaceId].tasks-put-_task-disable` permission
208
+ *
209
+ * @param taskOrId Task or Task's id
210
+ * @param namespaces
211
+ *
212
+ * @returns Updated task's info
213
+ */
214
+ export declare const disableTask: (taskOrId: Task | Task['id'], namespaces?: Namespace['id'][]) => Promise<ApiResponse<FullTask>>;
215
+ /**
216
+ * Link a task to a template
217
+ *
218
+ * Needs `namespaces[namespaceId].tasks-put-task-_link-template` permission
219
+ *
220
+ * @param taskOrId Task or Task's id
221
+ * @param templateOrId Template or Template's id
222
+ * @param namespaces
223
+ *
224
+ * @returns Updated task's info
225
+ */
226
+ export declare const linkTaskToTemplate: (taskOrId: Task | Task['id'], templateOrId: Template | Template['id'], namespaces?: Namespace['id'][]) => Promise<{
227
+ content: FullTask;
228
+ status: {
229
+ code: number;
230
+ message: string;
231
+ };
232
+ }>;
233
+ /**
234
+ * Unlink a task to a template
235
+ *
236
+ * Needs `namespaces[namespaceId].tasks-delete-task-_link-template` permission
237
+ *
238
+ * @param taskOrId Task or Task's id
239
+ * @param templateOrId Template or Template's id
240
+ * @param namespaces
241
+ */
242
+ export declare const unlinkTaskToTemplate: (taskOrId: Task | Task['id'], templateOrId: Template | Template['id'], namespaces?: Namespace['id'][]) => Promise<void>;
243
+ export {};
@@ -0,0 +1,2 @@
1
+ export { type FullTask, type InputTask, type PartialInputTask, type TaskList, getAllTasks, getAllTargets, getTasksOfTarget, unsubTargetOfTask, getTask, createTask, createTaskFromPreset, updateTask, upsertTask, deleteTask, enableTask, disableTask, linkTaskToTemplate, unlinkTaskToTemplate, } from './tasks';
2
+ export { Recurrence, type Task, type TaskWithNamespace, } from './tasks.base';
@@ -0,0 +1,36 @@
1
+ import { type PaginatedApiResponse } from '../lib/axios';
2
+ import type { PaginationOpts } from '../lib/utils';
3
+ import { type TaskWithNamespace } from './tasks.base';
4
+ export interface RawActivity {
5
+ id: string;
6
+ taskId: string;
7
+ type: string;
8
+ message: string;
9
+ data?: object;
10
+ createdAt: string;
11
+ }
12
+ export interface Activity extends Omit<RawActivity, 'createdAt'> {
13
+ createdAt: Date;
14
+ }
15
+ export interface ActivityWithTask extends Omit<Activity, 'taskId'> {
16
+ task: TaskWithNamespace;
17
+ }
18
+ /**
19
+ * Transform raw data from JSON, to JS usable data
20
+ *
21
+ * @param entry Raw history entry
22
+ *
23
+ * @returns Parsed history entry
24
+ */
25
+ export declare const parseActivity: (entry: RawActivity) => Activity;
26
+ /**
27
+ * Get all available history entries
28
+ *
29
+ * Needs `namespaces[namespaceId].history-get` permission
30
+ *
31
+ * @param paginationOpts Options for pagination
32
+ * @param namespaces
33
+ *
34
+ * @returns All history entries' info
35
+ */
36
+ export declare const getAllEntries: (paginationOpts?: PaginationOpts, namespaces?: string[]) => Promise<PaginatedApiResponse<ActivityWithTask, 'id'>>;
@@ -0,0 +1,5 @@
1
+ export {
2
+ /** @deprecated Use `Activity` instead */
3
+ type Activity as History,
4
+ /** @deprecated Use `ActivityWithTask` instead */
5
+ type ActivityWithTask as HistoryWithTask, type Activity, type ActivityWithTask, getAllEntries, } from './tasksActivity';
@@ -0,0 +1,83 @@
1
+ import type { Recurrence } from './tasks.base';
2
+ import type { FullTemplate } from './templates';
3
+ import { type ApiResponse } from '../lib/axios';
4
+ interface RawTasksPreset {
5
+ id: string;
6
+ name: string;
7
+ recurrence: Recurrence;
8
+ tags: {
9
+ name: string;
10
+ color?: string;
11
+ }[];
12
+ createdAt: string;
13
+ updatedAt?: string;
14
+ }
15
+ export interface TasksPreset extends Omit<RawTasksPreset, 'createdAt' | 'updatedAt'> {
16
+ createdAt: Date;
17
+ updatedAt?: Date;
18
+ }
19
+ export interface RawFullTasksPreset extends Omit<RawTasksPreset, 'tags'> {
20
+ fetchOptions?: {
21
+ dateField?: string;
22
+ };
23
+ template: Pick<FullTemplate, 'id' | 'name' | 'tags' | 'createdAt' | 'updatedAt'>;
24
+ }
25
+ export interface FullTasksPreset extends Omit<RawFullTasksPreset, 'createdAt' | 'updatedAt'> {
26
+ createdAt: Date;
27
+ updatedAt?: Date;
28
+ }
29
+ export interface InputTasksPreset extends Pick<FullTasksPreset, 'name' | 'fetchOptions' | 'recurrence'> {
30
+ template: string;
31
+ }
32
+ /**
33
+ * Get all available tasks presets
34
+ *
35
+ * Needs `general.tasks-presets-get` permission
36
+ *
37
+ * @returns All presets' info
38
+ */
39
+ export declare const getAllTasksPresets: () => Promise<ApiResponse<TasksPreset[]>>;
40
+ /**
41
+ * Get tasks preset info
42
+ *
43
+ * Needs `general.tasks-presets-get-preset` permission
44
+ *
45
+ * @param presetOrId Preset or Preset's id
46
+ *
47
+ * @returns Preset info
48
+ */
49
+ export declare const getTasksPreset: (presetOrId: TasksPreset | TasksPreset['id']) => Promise<ApiResponse<FullTasksPreset>>;
50
+ /**
51
+ * Create a new tasks preset
52
+ *
53
+ * Needs `general.tasks-presets-post` permission
54
+ *
55
+ * @param preset Preset's data
56
+ * @param namespaces
57
+ *
58
+ * @returns Created preset's info
59
+ */
60
+ export declare const createTasksPreset: (preset: InputTasksPreset) => Promise<ApiResponse<FullTasksPreset>>;
61
+ /**
62
+ * Update or create a tasks preset
63
+ *
64
+ * Needs `general.tasks-presets-put-preset` permission
65
+ *
66
+ * @param preset Preset's data **with id**
67
+ * @param namespaces
68
+ *
69
+ * @returns Updated/Created Preset's info
70
+ */
71
+ export declare const upsertTasksPreset: (preset: InputTasksPreset & {
72
+ id: TasksPreset['id'];
73
+ }) => Promise<ApiResponse<FullTasksPreset>>;
74
+ /**
75
+ * Delete a tasks preset
76
+ *
77
+ * Needs `general.tasks-presets-delete-preset` permission
78
+ *
79
+ * @param presetOrId Preset or Preset's id
80
+ * @param namespaces
81
+ */
82
+ export declare const deleteTasksPreset: (presetOrId: TasksPreset | TasksPreset['id']) => Promise<void>;
83
+ export {};
@@ -0,0 +1 @@
1
+ export { type TasksPreset, type FullTasksPreset, type InputTasksPreset, getAllTasksPresets, getTasksPreset, createTasksPreset, upsertTasksPreset, deleteTasksPreset, } from './tasksPresets';