@keystrokehq/erpnext 0.1.1 → 0.1.3

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 (339) hide show
  1. package/dist/action.cjs.map +1 -1
  2. package/dist/action.mjs.map +1 -1
  3. package/dist/actions/add-comment.cjs +6 -6
  4. package/dist/actions/add-comment.cjs.map +1 -1
  5. package/dist/actions/add-comment.d.cts +7 -19
  6. package/dist/actions/add-comment.d.mts +7 -19
  7. package/dist/actions/add-comment.mjs +6 -6
  8. package/dist/actions/add-comment.mjs.map +1 -1
  9. package/dist/actions/add-tag.cjs +1 -1
  10. package/dist/actions/add-tag.cjs.map +1 -1
  11. package/dist/actions/add-tag.d.cts +3 -5
  12. package/dist/actions/add-tag.d.mts +3 -5
  13. package/dist/actions/add-tag.mjs +1 -1
  14. package/dist/actions/add-tag.mjs.map +1 -1
  15. package/dist/actions/apply-workflow.cjs +5 -5
  16. package/dist/actions/apply-workflow.cjs.map +1 -1
  17. package/dist/actions/apply-workflow.d.cts +5 -9
  18. package/dist/actions/apply-workflow.d.cts.map +1 -1
  19. package/dist/actions/apply-workflow.d.mts +5 -9
  20. package/dist/actions/apply-workflow.d.mts.map +1 -1
  21. package/dist/actions/apply-workflow.mjs +5 -5
  22. package/dist/actions/apply-workflow.mjs.map +1 -1
  23. package/dist/actions/cancel-document.cjs +3 -3
  24. package/dist/actions/cancel-document.cjs.map +1 -1
  25. package/dist/actions/cancel-document.d.cts +4 -7
  26. package/dist/actions/cancel-document.d.cts.map +1 -1
  27. package/dist/actions/cancel-document.d.mts +4 -7
  28. package/dist/actions/cancel-document.d.mts.map +1 -1
  29. package/dist/actions/cancel-document.mjs +3 -3
  30. package/dist/actions/cancel-document.mjs.map +1 -1
  31. package/dist/actions/create-document.cjs +9 -9
  32. package/dist/actions/create-document.cjs.map +1 -1
  33. package/dist/actions/create-document.d.cts +11 -22
  34. package/dist/actions/create-document.d.mts +11 -22
  35. package/dist/actions/create-document.mjs +9 -9
  36. package/dist/actions/create-document.mjs.map +1 -1
  37. package/dist/actions/create-timesheet.cjs +3 -3
  38. package/dist/actions/create-timesheet.cjs.map +1 -1
  39. package/dist/actions/create-timesheet.d.cts +5 -14
  40. package/dist/actions/create-timesheet.d.mts +5 -14
  41. package/dist/actions/create-timesheet.mjs +3 -3
  42. package/dist/actions/create-timesheet.mjs.map +1 -1
  43. package/dist/actions/delete-document.cjs +1 -1
  44. package/dist/actions/delete-document.cjs.map +1 -1
  45. package/dist/actions/delete-document.d.cts +2 -4
  46. package/dist/actions/delete-document.d.mts +2 -4
  47. package/dist/actions/delete-document.mjs +1 -1
  48. package/dist/actions/delete-document.mjs.map +1 -1
  49. package/dist/actions/download-file.cjs +2 -2
  50. package/dist/actions/download-file.cjs.map +1 -1
  51. package/dist/actions/download-file.d.cts +3 -9
  52. package/dist/actions/download-file.d.mts +3 -9
  53. package/dist/actions/download-file.mjs +2 -2
  54. package/dist/actions/download-file.mjs.map +1 -1
  55. package/dist/actions/download-pdf.cjs +2 -2
  56. package/dist/actions/download-pdf.cjs.map +1 -1
  57. package/dist/actions/download-pdf.d.cts +3 -9
  58. package/dist/actions/download-pdf.d.mts +3 -9
  59. package/dist/actions/download-pdf.mjs +2 -2
  60. package/dist/actions/download-pdf.mjs.map +1 -1
  61. package/dist/actions/get-all-languages.cjs +4 -4
  62. package/dist/actions/get-all-languages.cjs.map +1 -1
  63. package/dist/actions/get-all-languages.d.cts +5 -10
  64. package/dist/actions/get-all-languages.d.mts +5 -10
  65. package/dist/actions/get-all-languages.mjs +4 -4
  66. package/dist/actions/get-all-languages.mjs.map +1 -1
  67. package/dist/actions/get-all-roles.cjs +1 -1
  68. package/dist/actions/get-all-roles.cjs.map +1 -1
  69. package/dist/actions/get-all-roles.d.cts +2 -4
  70. package/dist/actions/get-all-roles.d.cts.map +1 -1
  71. package/dist/actions/get-all-roles.d.mts +2 -4
  72. package/dist/actions/get-all-roles.d.mts.map +1 -1
  73. package/dist/actions/get-all-roles.mjs +1 -1
  74. package/dist/actions/get-all-roles.mjs.map +1 -1
  75. package/dist/actions/get-client.cjs +9 -9
  76. package/dist/actions/get-client.cjs.map +1 -1
  77. package/dist/actions/get-client.d.cts +11 -23
  78. package/dist/actions/get-client.d.mts +11 -23
  79. package/dist/actions/get-client.mjs +9 -9
  80. package/dist/actions/get-client.mjs.map +1 -1
  81. package/dist/actions/get-count.cjs +2 -2
  82. package/dist/actions/get-count.cjs.map +1 -1
  83. package/dist/actions/get-count.d.cts +4 -6
  84. package/dist/actions/get-count.d.mts +4 -6
  85. package/dist/actions/get-count.mjs +2 -2
  86. package/dist/actions/get-count.mjs.map +1 -1
  87. package/dist/actions/get-doc-with-meta.cjs +22 -22
  88. package/dist/actions/get-doc-with-meta.cjs.map +1 -1
  89. package/dist/actions/get-doc-with-meta.d.cts +23 -45
  90. package/dist/actions/get-doc-with-meta.d.mts +23 -45
  91. package/dist/actions/get-doc-with-meta.mjs +22 -22
  92. package/dist/actions/get-doc-with-meta.mjs.map +1 -1
  93. package/dist/actions/get-doctype-meta.cjs +4 -4
  94. package/dist/actions/get-doctype-meta.cjs.map +1 -1
  95. package/dist/actions/get-doctype-meta.d.cts +5 -9
  96. package/dist/actions/get-doctype-meta.d.cts.map +1 -1
  97. package/dist/actions/get-doctype-meta.d.mts +5 -9
  98. package/dist/actions/get-doctype-meta.d.mts.map +1 -1
  99. package/dist/actions/get-doctype-meta.mjs +4 -4
  100. package/dist/actions/get-doctype-meta.mjs.map +1 -1
  101. package/dist/actions/get-document.cjs +8 -8
  102. package/dist/actions/get-document.cjs.map +1 -1
  103. package/dist/actions/get-document.d.cts +9 -20
  104. package/dist/actions/get-document.d.mts +9 -20
  105. package/dist/actions/get-document.mjs +8 -8
  106. package/dist/actions/get-document.mjs.map +1 -1
  107. package/dist/actions/get-exchange-rate.cjs +1 -1
  108. package/dist/actions/get-exchange-rate.cjs.map +1 -1
  109. package/dist/actions/get-exchange-rate.d.cts +2 -4
  110. package/dist/actions/get-exchange-rate.d.mts +2 -4
  111. package/dist/actions/get-exchange-rate.mjs +1 -1
  112. package/dist/actions/get-exchange-rate.mjs.map +1 -1
  113. package/dist/actions/get-fiscal-year.cjs +2 -2
  114. package/dist/actions/get-fiscal-year.cjs.map +1 -1
  115. package/dist/actions/get-fiscal-year.d.cts +3 -9
  116. package/dist/actions/get-fiscal-year.d.mts +3 -9
  117. package/dist/actions/get-fiscal-year.mjs +2 -2
  118. package/dist/actions/get-fiscal-year.mjs.map +1 -1
  119. package/dist/actions/get-framework-version.cjs +1 -1
  120. package/dist/actions/get-framework-version.cjs.map +1 -1
  121. package/dist/actions/get-framework-version.d.cts +3 -5
  122. package/dist/actions/get-framework-version.d.cts.map +1 -1
  123. package/dist/actions/get-framework-version.d.mts +3 -5
  124. package/dist/actions/get-framework-version.d.mts.map +1 -1
  125. package/dist/actions/get-framework-version.mjs +1 -1
  126. package/dist/actions/get-framework-version.mjs.map +1 -1
  127. package/dist/actions/get-item-details.cjs +28 -28
  128. package/dist/actions/get-item-details.cjs.map +1 -1
  129. package/dist/actions/get-item-details.d.cts +29 -60
  130. package/dist/actions/get-item-details.d.mts +29 -60
  131. package/dist/actions/get-item-details.mjs +28 -28
  132. package/dist/actions/get-item-details.mjs.map +1 -1
  133. package/dist/actions/get-list.cjs +2 -2
  134. package/dist/actions/get-list.cjs.map +1 -1
  135. package/dist/actions/get-list.d.cts +5 -7
  136. package/dist/actions/get-list.d.cts.map +1 -1
  137. package/dist/actions/get-list.d.mts +5 -7
  138. package/dist/actions/get-list.d.mts.map +1 -1
  139. package/dist/actions/get-list.mjs +2 -2
  140. package/dist/actions/get-list.mjs.map +1 -1
  141. package/dist/actions/get-logged-user.cjs +1 -1
  142. package/dist/actions/get-logged-user.cjs.map +1 -1
  143. package/dist/actions/get-logged-user.d.cts +2 -4
  144. package/dist/actions/get-logged-user.d.cts.map +1 -1
  145. package/dist/actions/get-logged-user.d.mts +2 -4
  146. package/dist/actions/get-logged-user.d.mts.map +1 -1
  147. package/dist/actions/get-logged-user.mjs +1 -1
  148. package/dist/actions/get-logged-user.mjs.map +1 -1
  149. package/dist/actions/get-party-details.cjs +37 -37
  150. package/dist/actions/get-party-details.cjs.map +1 -1
  151. package/dist/actions/get-party-details.d.cts +38 -78
  152. package/dist/actions/get-party-details.d.mts +38 -78
  153. package/dist/actions/get-party-details.mjs +37 -37
  154. package/dist/actions/get-party-details.mjs.map +1 -1
  155. package/dist/actions/get-payment-entry.cjs +27 -27
  156. package/dist/actions/get-payment-entry.cjs.map +1 -1
  157. package/dist/actions/get-payment-entry.d.cts +28 -60
  158. package/dist/actions/get-payment-entry.d.mts +28 -60
  159. package/dist/actions/get-payment-entry.mjs +27 -27
  160. package/dist/actions/get-payment-entry.mjs.map +1 -1
  161. package/dist/actions/get-stock-balance.cjs +1 -1
  162. package/dist/actions/get-stock-balance.cjs.map +1 -1
  163. package/dist/actions/get-stock-balance.d.cts +2 -4
  164. package/dist/actions/get-stock-balance.d.mts +2 -4
  165. package/dist/actions/get-stock-balance.mjs +1 -1
  166. package/dist/actions/get-stock-balance.mjs.map +1 -1
  167. package/dist/actions/get-timezones.cjs +2 -2
  168. package/dist/actions/get-timezones.cjs.map +1 -1
  169. package/dist/actions/get-timezones.d.cts +3 -7
  170. package/dist/actions/get-timezones.d.cts.map +1 -1
  171. package/dist/actions/get-timezones.d.mts +3 -7
  172. package/dist/actions/get-timezones.d.mts.map +1 -1
  173. package/dist/actions/get-timezones.mjs +2 -2
  174. package/dist/actions/get-timezones.mjs.map +1 -1
  175. package/dist/actions/get-user-roles.cjs +1 -1
  176. package/dist/actions/get-user-roles.cjs.map +1 -1
  177. package/dist/actions/get-user-roles.d.cts +2 -4
  178. package/dist/actions/get-user-roles.d.mts +2 -4
  179. package/dist/actions/get-user-roles.mjs +1 -1
  180. package/dist/actions/get-user-roles.mjs.map +1 -1
  181. package/dist/actions/get-value.cjs +2 -2
  182. package/dist/actions/get-value.cjs.map +1 -1
  183. package/dist/actions/get-value.d.cts +3 -5
  184. package/dist/actions/get-value.d.cts.map +1 -1
  185. package/dist/actions/get-value.d.mts +3 -5
  186. package/dist/actions/get-value.d.mts.map +1 -1
  187. package/dist/actions/get-value.mjs +2 -2
  188. package/dist/actions/get-value.mjs.map +1 -1
  189. package/dist/actions/get-workflow-transitions.cjs +8 -8
  190. package/dist/actions/get-workflow-transitions.cjs.map +1 -1
  191. package/dist/actions/get-workflow-transitions.d.cts +10 -19
  192. package/dist/actions/get-workflow-transitions.d.mts +10 -19
  193. package/dist/actions/get-workflow-transitions.mjs +8 -8
  194. package/dist/actions/get-workflow-transitions.mjs.map +1 -1
  195. package/dist/actions/insert-document.cjs +1 -1
  196. package/dist/actions/insert-document.cjs.map +1 -1
  197. package/dist/actions/insert-document.d.cts +2 -4
  198. package/dist/actions/insert-document.d.cts.map +1 -1
  199. package/dist/actions/insert-document.d.mts +2 -4
  200. package/dist/actions/insert-document.d.mts.map +1 -1
  201. package/dist/actions/insert-document.mjs +1 -1
  202. package/dist/actions/insert-document.mjs.map +1 -1
  203. package/dist/actions/insert-many.cjs +4 -4
  204. package/dist/actions/insert-many.cjs.map +1 -1
  205. package/dist/actions/insert-many.d.cts +5 -11
  206. package/dist/actions/insert-many.d.mts +5 -11
  207. package/dist/actions/insert-many.mjs +4 -4
  208. package/dist/actions/insert-many.mjs.map +1 -1
  209. package/dist/actions/list-doctypes.cjs +1 -1
  210. package/dist/actions/list-doctypes.cjs.map +1 -1
  211. package/dist/actions/list-doctypes.d.cts +3 -5
  212. package/dist/actions/list-doctypes.d.cts.map +1 -1
  213. package/dist/actions/list-doctypes.d.mts +3 -5
  214. package/dist/actions/list-doctypes.d.mts.map +1 -1
  215. package/dist/actions/list-doctypes.mjs +1 -1
  216. package/dist/actions/list-doctypes.mjs.map +1 -1
  217. package/dist/actions/list-documents.cjs +1 -1
  218. package/dist/actions/list-documents.cjs.map +1 -1
  219. package/dist/actions/list-documents.d.cts +3 -5
  220. package/dist/actions/list-documents.d.cts.map +1 -1
  221. package/dist/actions/list-documents.d.mts +3 -5
  222. package/dist/actions/list-documents.d.mts.map +1 -1
  223. package/dist/actions/list-documents.mjs +1 -1
  224. package/dist/actions/list-documents.mjs.map +1 -1
  225. package/dist/actions/list-employees.cjs +1 -1
  226. package/dist/actions/list-employees.cjs.map +1 -1
  227. package/dist/actions/list-employees.d.cts +2 -7
  228. package/dist/actions/list-employees.d.mts +2 -7
  229. package/dist/actions/list-employees.mjs +1 -1
  230. package/dist/actions/list-employees.mjs.map +1 -1
  231. package/dist/actions/list-projects.cjs +1 -1
  232. package/dist/actions/list-projects.cjs.map +1 -1
  233. package/dist/actions/list-projects.d.cts +3 -5
  234. package/dist/actions/list-projects.d.cts.map +1 -1
  235. package/dist/actions/list-projects.d.mts +3 -5
  236. package/dist/actions/list-projects.d.mts.map +1 -1
  237. package/dist/actions/list-projects.mjs +1 -1
  238. package/dist/actions/list-projects.mjs.map +1 -1
  239. package/dist/actions/list-timesheets.cjs +1 -1
  240. package/dist/actions/list-timesheets.cjs.map +1 -1
  241. package/dist/actions/list-timesheets.d.cts +3 -5
  242. package/dist/actions/list-timesheets.d.cts.map +1 -1
  243. package/dist/actions/list-timesheets.d.mts +3 -5
  244. package/dist/actions/list-timesheets.d.mts.map +1 -1
  245. package/dist/actions/list-timesheets.mjs +1 -1
  246. package/dist/actions/list-timesheets.mjs.map +1 -1
  247. package/dist/actions/list-webhooks.cjs +5 -5
  248. package/dist/actions/list-webhooks.cjs.map +1 -1
  249. package/dist/actions/list-webhooks.d.cts +6 -15
  250. package/dist/actions/list-webhooks.d.mts +6 -15
  251. package/dist/actions/list-webhooks.mjs +5 -5
  252. package/dist/actions/list-webhooks.mjs.map +1 -1
  253. package/dist/actions/make-delivery-note.cjs +12 -12
  254. package/dist/actions/make-delivery-note.cjs.map +1 -1
  255. package/dist/actions/make-delivery-note.d.cts +13 -28
  256. package/dist/actions/make-delivery-note.d.cts.map +1 -1
  257. package/dist/actions/make-delivery-note.d.mts +13 -28
  258. package/dist/actions/make-delivery-note.d.mts.map +1 -1
  259. package/dist/actions/make-delivery-note.mjs +12 -12
  260. package/dist/actions/make-delivery-note.mjs.map +1 -1
  261. package/dist/actions/make-purchase-order.cjs +23 -23
  262. package/dist/actions/make-purchase-order.cjs.map +1 -1
  263. package/dist/actions/make-purchase-order.d.cts +24 -52
  264. package/dist/actions/make-purchase-order.d.mts +24 -52
  265. package/dist/actions/make-purchase-order.mjs +23 -23
  266. package/dist/actions/make-purchase-order.mjs.map +1 -1
  267. package/dist/actions/make-sales-invoice.cjs +14 -14
  268. package/dist/actions/make-sales-invoice.cjs.map +1 -1
  269. package/dist/actions/make-sales-invoice.d.cts +15 -32
  270. package/dist/actions/make-sales-invoice.d.cts.map +1 -1
  271. package/dist/actions/make-sales-invoice.d.mts +15 -32
  272. package/dist/actions/make-sales-invoice.d.mts.map +1 -1
  273. package/dist/actions/make-sales-invoice.mjs +14 -14
  274. package/dist/actions/make-sales-invoice.mjs.map +1 -1
  275. package/dist/actions/make-stock-entry.cjs +11 -11
  276. package/dist/actions/make-stock-entry.cjs.map +1 -1
  277. package/dist/actions/make-stock-entry.d.cts +12 -24
  278. package/dist/actions/make-stock-entry.d.mts +12 -24
  279. package/dist/actions/make-stock-entry.mjs +11 -11
  280. package/dist/actions/make-stock-entry.mjs.map +1 -1
  281. package/dist/actions/ping.cjs +1 -1
  282. package/dist/actions/ping.cjs.map +1 -1
  283. package/dist/actions/ping.d.cts +2 -4
  284. package/dist/actions/ping.d.cts.map +1 -1
  285. package/dist/actions/ping.d.mts +2 -4
  286. package/dist/actions/ping.d.mts.map +1 -1
  287. package/dist/actions/ping.mjs +1 -1
  288. package/dist/actions/ping.mjs.map +1 -1
  289. package/dist/actions/rename-doc.cjs +1 -1
  290. package/dist/actions/rename-doc.cjs.map +1 -1
  291. package/dist/actions/rename-doc.d.cts +2 -4
  292. package/dist/actions/rename-doc.d.mts +2 -4
  293. package/dist/actions/rename-doc.mjs +1 -1
  294. package/dist/actions/rename-doc.mjs.map +1 -1
  295. package/dist/actions/save-docs.cjs +6 -6
  296. package/dist/actions/save-docs.cjs.map +1 -1
  297. package/dist/actions/save-docs.d.cts +7 -13
  298. package/dist/actions/save-docs.d.cts.map +1 -1
  299. package/dist/actions/save-docs.d.mts +7 -13
  300. package/dist/actions/save-docs.d.mts.map +1 -1
  301. package/dist/actions/save-docs.mjs +6 -6
  302. package/dist/actions/save-docs.mjs.map +1 -1
  303. package/dist/actions/save-document.cjs +3 -3
  304. package/dist/actions/save-document.cjs.map +1 -1
  305. package/dist/actions/save-document.d.cts +4 -10
  306. package/dist/actions/save-document.d.mts +4 -10
  307. package/dist/actions/save-document.mjs +3 -3
  308. package/dist/actions/save-document.mjs.map +1 -1
  309. package/dist/actions/search-global.cjs +8 -8
  310. package/dist/actions/search-global.cjs.map +1 -1
  311. package/dist/actions/search-global.d.cts +10 -19
  312. package/dist/actions/search-global.d.mts +10 -19
  313. package/dist/actions/search-global.mjs +8 -8
  314. package/dist/actions/search-global.mjs.map +1 -1
  315. package/dist/actions/search-link.cjs +3 -3
  316. package/dist/actions/search-link.cjs.map +1 -1
  317. package/dist/actions/search-link.d.cts +4 -10
  318. package/dist/actions/search-link.d.mts +4 -10
  319. package/dist/actions/search-link.mjs +3 -3
  320. package/dist/actions/search-link.mjs.map +1 -1
  321. package/dist/actions/set-value.cjs +9 -9
  322. package/dist/actions/set-value.cjs.map +1 -1
  323. package/dist/actions/set-value.d.cts +16 -35
  324. package/dist/actions/set-value.d.mts +16 -35
  325. package/dist/actions/set-value.mjs +9 -9
  326. package/dist/actions/set-value.mjs.map +1 -1
  327. package/dist/actions/submit-document.cjs +2 -2
  328. package/dist/actions/submit-document.cjs.map +1 -1
  329. package/dist/actions/submit-document.d.cts +3 -14
  330. package/dist/actions/submit-document.d.mts +3 -14
  331. package/dist/actions/submit-document.mjs +2 -2
  332. package/dist/actions/submit-document.mjs.map +1 -1
  333. package/dist/actions/update-document.cjs +10 -10
  334. package/dist/actions/update-document.cjs.map +1 -1
  335. package/dist/actions/update-document.d.cts +13 -23
  336. package/dist/actions/update-document.d.mts +13 -23
  337. package/dist/actions/update-document.mjs +10 -10
  338. package/dist/actions/update-document.mjs.map +1 -1
  339. package/package.json +1 -1
@@ -8,48 +8,29 @@ declare const ErpnextSetValueInput: z.ZodObject<{
8
8
  fieldname: z.ZodString;
9
9
  }, z.core.$strip>;
10
10
  declare const ErpnextSetValueOutput: z.ZodObject<{
11
- docs: z.ZodPreprocess<z.ZodOptional<z.ZodArray<z.ZodObject<{
12
- name: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
13
- owner: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
14
- doctype: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
15
- creation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
16
- modified: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
17
- modified_by: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
11
+ docs: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
12
+ name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
13
+ owner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
14
+ doctype: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
+ creation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
16
+ modified: z.ZodOptional<z.ZodNullable<z.ZodString>>;
17
+ modified_by: z.ZodOptional<z.ZodNullable<z.ZodString>>;
18
18
  }, z.core.$loose>>>>;
19
- message: z.ZodPreprocess<z.ZodOptional<z.ZodObject<{
20
- name: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
21
- owner: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
22
- doctype: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
23
- creation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
24
- modified: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
25
- modified_by: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
19
+ message: z.ZodOptional<z.ZodNullable<z.ZodObject<{
20
+ name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
21
+ owner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
22
+ doctype: z.ZodOptional<z.ZodNullable<z.ZodString>>;
23
+ creation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
24
+ modified: z.ZodOptional<z.ZodNullable<z.ZodString>>;
25
+ modified_by: z.ZodOptional<z.ZodNullable<z.ZodString>>;
26
26
  }, z.core.$loose>>>;
27
- }, z.core.$strip>;
27
+ }, z.core.$loose>;
28
28
  declare const erpnextSetValue: import("@keystrokehq/action").WorkflowActionDefinition<{
29
29
  name: string;
30
30
  value: string | number | boolean;
31
31
  doctype: string;
32
32
  fieldname: string;
33
- }, {
34
- docs?: {
35
- [x: string]: unknown;
36
- name?: string | undefined;
37
- owner?: string | undefined;
38
- doctype?: string | undefined;
39
- creation?: string | undefined;
40
- modified?: string | undefined;
41
- modified_by?: string | undefined;
42
- }[] | undefined;
43
- message?: {
44
- [x: string]: unknown;
45
- name?: string | undefined;
46
- owner?: string | undefined;
47
- doctype?: string | undefined;
48
- creation?: string | undefined;
49
- modified?: string | undefined;
50
- modified_by?: string | undefined;
51
- } | undefined;
52
- }, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
33
+ }, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
53
34
  //#endregion
54
35
  export { erpnextSetValue };
55
36
  //# sourceMappingURL=set-value.d.mts.map
@@ -13,12 +13,12 @@ const ErpnextSetValueInput = z.object({
13
13
  fieldname: z.string().describe("The field name to set (e.g., 'description', 'status').")
14
14
  }).describe("Request parameters for setting a field value on a document in ERPNext.");
15
15
  const ErpnextSetValue_DocumentDataSchema = z.object({
16
- name: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The name/ID of the document.").optional()),
17
- owner: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The owner of the document.").optional()),
18
- doctype: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The DocType of the document.").optional()),
19
- creation: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("Creation timestamp of the document.").optional()),
20
- modified: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("Last modified timestamp of the document.").optional()),
21
- modified_by: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("User who last modified the document.").optional())
16
+ name: z.string().describe("The name/ID of the document.").nullable().optional(),
17
+ owner: z.string().describe("The owner of the document.").nullable().optional(),
18
+ doctype: z.string().describe("The DocType of the document.").nullable().optional(),
19
+ creation: z.string().describe("Creation timestamp of the document.").nullable().optional(),
20
+ modified: z.string().describe("Last modified timestamp of the document.").nullable().optional(),
21
+ modified_by: z.string().describe("User who last modified the document.").nullable().optional()
22
22
  }).passthrough().describe("Represents a document returned from the API.");
23
23
  const erpnextSetValue = action("ERPNEXT_SET_VALUE", {
24
24
  slug: "erpnext-set-value",
@@ -26,9 +26,9 @@ const erpnextSetValue = action("ERPNEXT_SET_VALUE", {
26
26
  description: "Tool to set a specific field value on a document in ERPNext. Use when you need to update a single field without retrieving or modifying the entire document.",
27
27
  input: ErpnextSetValueInput,
28
28
  output: z.object({
29
- docs: z.preprocess((value) => value === null ? void 0 : value, z.array(ErpnextSetValue_DocumentDataSchema).describe("List of documents returned by the API (used in some Frappe API responses).").optional()),
30
- message: z.preprocess((value) => value === null ? void 0 : value, ErpnextSetValue_DocumentDataSchema.optional())
31
- }).describe("Response from ERPNext after setting a field value.")
29
+ docs: z.array(ErpnextSetValue_DocumentDataSchema).describe("List of documents returned by the API (used in some Frappe API responses).").nullable().optional(),
30
+ message: ErpnextSetValue_DocumentDataSchema.nullable().optional()
31
+ }).passthrough().describe("Response from ERPNext after setting a field value.")
32
32
  });
33
33
  //#endregion
34
34
  export { erpnextSetValue };
@@ -1 +1 @@
1
- {"version":3,"file":"set-value.mjs","names":[],"sources":["../../src/actions/set-value.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSetValueInput = z.object({\n name: z.string().describe(\"The document name/ID to update.\"),\n value: z.union([z.string(), z.number().int(), z.number(), z.boolean()]),\n doctype: z.string().describe(\"The DocType name (e.g., 'ToDo', 'Task', 'User', 'Customer').\"),\n fieldname: z.string().describe(\"The field name to set (e.g., 'description', 'status').\"),\n}).describe(\"Request parameters for setting a field value on a document in ERPNext.\");\nconst ErpnextSetValue_DocumentDataSchema = z.object({\n name: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The name/ID of the document.\").optional()),\n owner: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The owner of the document.\").optional()),\n doctype: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The DocType of the document.\").optional()),\n creation: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Creation timestamp of the document.\").optional()),\n modified: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Last modified timestamp of the document.\").optional()),\n modified_by: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"User who last modified the document.\").optional()),\n}).passthrough().describe(\"Represents a document returned from the API.\");\nexport const ErpnextSetValueOutput = z.object({\n docs: z.preprocess((value) => (value === null ? undefined : value), z.array(ErpnextSetValue_DocumentDataSchema).describe(\"List of documents returned by the API (used in some Frappe API responses).\").optional()),\n message: z.preprocess((value) => (value === null ? undefined : value), ErpnextSetValue_DocumentDataSchema.optional()),\n}).describe(\"Response from ERPNext after setting a field value.\");\n\nexport const erpnextSetValue = action(\"ERPNEXT_SET_VALUE\", {\n slug: \"erpnext-set-value\",\n name: \"Set Value\",\n description: \"Tool to set a specific field value on a document in ERPNext. Use when you need to update a single field without retrieving or modifying the entire document.\",\n input: ErpnextSetValueInput,\n output: ErpnextSetValueOutput,\n});\n"],"mappings":";;;AAIA,MAAa,uBAAuB,EAAE,OAAO;CAC3C,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,iCAAiC;CAC3D,OAAO,EAAE,MAAM;EAAC,EAAE,OAAO;EAAG,EAAE,OAAO,CAAC,CAAC,IAAI;EAAG,EAAE,OAAO;EAAG,EAAE,QAAQ;CAAC,CAAC;CACtE,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,8DAA8D;CAC3F,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS,wDAAwD;AACzF,CAAC,CAAC,CAAC,SAAS,wEAAwE;AACpF,MAAM,qCAAqC,EAAE,OAAO;CAClD,MAAM,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,8BAA8B,CAAC,CAAC,SAAS,CAAC;CAClI,OAAO,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,4BAA4B,CAAC,CAAC,SAAS,CAAC;CACjI,SAAS,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,8BAA8B,CAAC,CAAC,SAAS,CAAC;CACrI,UAAU,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,qCAAqC,CAAC,CAAC,SAAS,CAAC;CAC7I,UAAU,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC;CAClJ,aAAa,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS,CAAC;AACnJ,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,8CAA8C;AAMxE,MAAa,kBAAkB,OAAO,qBAAqB;CACzD,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAVmC,EAAE,OAAO;EAC5C,MAAM,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,MAAM,kCAAkC,CAAC,CAAC,SAAS,4EAA4E,CAAC,CAAC,SAAS,CAAC;EACjN,SAAS,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,mCAAmC,SAAS,CAAC;CACtH,CAAC,CAAC,CAAC,SAAS,oDAOF;AACV,CAAC"}
1
+ {"version":3,"file":"set-value.mjs","names":[],"sources":["../../src/actions/set-value.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSetValueInput = z.object({\n name: z.string().describe(\"The document name/ID to update.\"),\n value: z.union([z.string(), z.number().int(), z.number(), z.boolean()]),\n doctype: z.string().describe(\"The DocType name (e.g., 'ToDo', 'Task', 'User', 'Customer').\"),\n fieldname: z.string().describe(\"The field name to set (e.g., 'description', 'status').\"),\n}).describe(\"Request parameters for setting a field value on a document in ERPNext.\");\nconst ErpnextSetValue_DocumentDataSchema = z.object({\n name: z.string().describe(\"The name/ID of the document.\").nullable().optional(),\n owner: z.string().describe(\"The owner of the document.\").nullable().optional(),\n doctype: z.string().describe(\"The DocType of the document.\").nullable().optional(),\n creation: z.string().describe(\"Creation timestamp of the document.\").nullable().optional(),\n modified: z.string().describe(\"Last modified timestamp of the document.\").nullable().optional(),\n modified_by: z.string().describe(\"User who last modified the document.\").nullable().optional(),\n}).passthrough().describe(\"Represents a document returned from the API.\");\nexport const ErpnextSetValueOutput = z.object({\n docs: z.array(ErpnextSetValue_DocumentDataSchema).describe(\"List of documents returned by the API (used in some Frappe API responses).\").nullable().optional(),\n message: ErpnextSetValue_DocumentDataSchema.nullable().optional(),\n}).passthrough().describe(\"Response from ERPNext after setting a field value.\");\n\nexport const erpnextSetValue = action(\"ERPNEXT_SET_VALUE\", {\n slug: \"erpnext-set-value\",\n name: \"Set Value\",\n description: \"Tool to set a specific field value on a document in ERPNext. Use when you need to update a single field without retrieving or modifying the entire document.\",\n input: ErpnextSetValueInput,\n output: ErpnextSetValueOutput,\n});\n"],"mappings":";;;AAIA,MAAa,uBAAuB,EAAE,OAAO;CAC3C,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,iCAAiC;CAC3D,OAAO,EAAE,MAAM;EAAC,EAAE,OAAO;EAAG,EAAE,OAAO,CAAC,CAAC,IAAI;EAAG,EAAE,OAAO;EAAG,EAAE,QAAQ;CAAC,CAAC;CACtE,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,8DAA8D;CAC3F,WAAW,EAAE,OAAO,CAAC,CAAC,SAAS,wDAAwD;AACzF,CAAC,CAAC,CAAC,SAAS,wEAAwE;AACpF,MAAM,qCAAqC,EAAE,OAAO;CAClD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,8BAA8B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9E,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS,4BAA4B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC7E,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,8BAA8B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjF,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,qCAAqC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACzF,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9F,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AAC/F,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,8CAA8C;AAMxE,MAAa,kBAAkB,OAAO,qBAAqB;CACzD,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAVmC,EAAE,OAAO;EAC5C,MAAM,EAAE,MAAM,kCAAkC,CAAC,CAAC,SAAS,4EAA4E,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EAC7J,SAAS,mCAAmC,SAAS,CAAC,CAAC,SAAS;CAClE,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,oDAOhB;AACV,CAAC"}
@@ -11,8 +11,8 @@ const ErpnextSubmitDocument_DocumentMetadataSchema = zod.z.object({
11
11
  modified: zod.z.string().describe("ISO timestamp when document was last modified.").nullable(),
12
12
  docstatus: zod.z.number().int().describe("Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.").nullable(),
13
13
  modified_by: zod.z.string().describe("User who last modified the document.").nullable()
14
- }).describe("Core metadata fields present in all Frappe documents.");
15
- const ErpnextSubmitDocumentOutput = zod.z.object({ message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable() }).describe("Response from submitting a document in ERPNext/Frappe.");
14
+ }).passthrough().describe("Core metadata fields present in all Frappe documents.");
15
+ const ErpnextSubmitDocumentOutput = zod.z.object({ message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable() }).passthrough().describe("Response from submitting a document in ERPNext/Frappe.");
16
16
  const erpnextSubmitDocument = require_action.action("ERPNEXT_SUBMIT_DOCUMENT", {
17
17
  slug: "erpnext-submit-document",
18
18
  name: "Submit Document",
@@ -1 +1 @@
1
- {"version":3,"file":"submit-document.cjs","names":["z","action"],"sources":["../../src/actions/submit-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSubmitDocumentInput = z.object({\n doc: z.string().describe(\"JSON-stringified complete document object to submit. Must include: (1) 'doctype' field specifying the document type (e.g., 'Journal Entry', 'Sales Invoice'), (2) 'name' field with the document ID, (3) all required fields for the DocType, (4) all child table records if applicable (as arrays of objects), (5) timestamp fields ('modified', 'creation') matching current server state. The document must be in draft state (docstatus=0) and the DocType must be submittable. Fetch the complete document first using GET endpoint to ensure all fields and timestamps are current.\"),\n}).describe(\"Request parameters for submitting a document in ERPNext/Frappe.\");\nconst ErpnextSubmitDocument_DocumentMetadataSchema = z.object({\n idx: z.number().int().describe(\"Index/sequence number of the document.\").nullable(),\n name: z.string().describe(\"Unique document identifier/name.\").nullable(),\n owner: z.string().describe(\"User who created the document.\").nullable(),\n doctype: z.string().describe(\"Document type (e.g., 'Sales Invoice', 'Journal Entry').\").nullable(),\n creation: z.string().describe(\"ISO timestamp when document was created.\").nullable(),\n modified: z.string().describe(\"ISO timestamp when document was last modified.\").nullable(),\n docstatus: z.number().int().describe(\"Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.\").nullable(),\n modified_by: z.string().describe(\"User who last modified the document.\").nullable(),\n}).describe(\"Core metadata fields present in all Frappe documents.\");\nexport const ErpnextSubmitDocumentOutput = z.object({\n message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable(),\n}).describe(\"Response from submitting a document in ERPNext/Frappe.\");\n\nexport const erpnextSubmitDocument = action(\"ERPNEXT_SUBMIT_DOCUMENT\", {\n slug: \"erpnext-submit-document\",\n name: \"Submit Document\",\n description: \"Submit a draft document in ERPNext/Frappe to change its status from Draft to Submitted. Use for submittable DocTypes like Sales Invoice, Purchase Order, Journal Entry, etc. Document must exist in draft state (docstatus=0) before submission.\",\n input: ErpnextSubmitDocumentInput,\n output: ErpnextSubmitDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6BA,IAAAA,EAAE,OAAO,EACjD,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2jBAA2jB,EACtlB,CAAC,CAAC,CAAC,SAAS,iEAAiE;AAC7E,MAAM,+CAA+CA,IAAAA,EAAE,OAAO;CAC5D,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;CAClF,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACvE,OAAOA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS;CACtE,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS;CACjG,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS;CACnF,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS;CACzF,WAAWA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uFAAuF,CAAC,CAAC,SAAS;CACvI,aAAaA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS;AACpF,CAAC,CAAC,CAAC,SAAS,uDAAuD;AACnE,MAAa,8BAA8BA,IAAAA,EAAE,OAAO,EAClD,SAAS,6CAA6C,SAAS,EACjE,CAAC,CAAC,CAAC,SAAS,wDAAwD;AAEpE,MAAa,wBAAwBC,eAAAA,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
1
+ {"version":3,"file":"submit-document.cjs","names":["z","action"],"sources":["../../src/actions/submit-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSubmitDocumentInput = z.object({\n doc: z.string().describe(\"JSON-stringified complete document object to submit. Must include: (1) 'doctype' field specifying the document type (e.g., 'Journal Entry', 'Sales Invoice'), (2) 'name' field with the document ID, (3) all required fields for the DocType, (4) all child table records if applicable (as arrays of objects), (5) timestamp fields ('modified', 'creation') matching current server state. The document must be in draft state (docstatus=0) and the DocType must be submittable. Fetch the complete document first using GET endpoint to ensure all fields and timestamps are current.\"),\n}).describe(\"Request parameters for submitting a document in ERPNext/Frappe.\");\nconst ErpnextSubmitDocument_DocumentMetadataSchema = z.object({\n idx: z.number().int().describe(\"Index/sequence number of the document.\").nullable(),\n name: z.string().describe(\"Unique document identifier/name.\").nullable(),\n owner: z.string().describe(\"User who created the document.\").nullable(),\n doctype: z.string().describe(\"Document type (e.g., 'Sales Invoice', 'Journal Entry').\").nullable(),\n creation: z.string().describe(\"ISO timestamp when document was created.\").nullable(),\n modified: z.string().describe(\"ISO timestamp when document was last modified.\").nullable(),\n docstatus: z.number().int().describe(\"Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.\").nullable(),\n modified_by: z.string().describe(\"User who last modified the document.\").nullable(),\n}).passthrough().describe(\"Core metadata fields present in all Frappe documents.\");\nexport const ErpnextSubmitDocumentOutput = z.object({\n message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable(),\n}).passthrough().describe(\"Response from submitting a document in ERPNext/Frappe.\");\n\nexport const erpnextSubmitDocument = action(\"ERPNEXT_SUBMIT_DOCUMENT\", {\n slug: \"erpnext-submit-document\",\n name: \"Submit Document\",\n description: \"Submit a draft document in ERPNext/Frappe to change its status from Draft to Submitted. Use for submittable DocTypes like Sales Invoice, Purchase Order, Journal Entry, etc. Document must exist in draft state (docstatus=0) before submission.\",\n input: ErpnextSubmitDocumentInput,\n output: ErpnextSubmitDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6BA,IAAAA,EAAE,OAAO,EACjD,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2jBAA2jB,EACtlB,CAAC,CAAC,CAAC,SAAS,iEAAiE;AAC7E,MAAM,+CAA+CA,IAAAA,EAAE,OAAO;CAC5D,KAAKA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;CAClF,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACvE,OAAOA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS;CACtE,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS;CACjG,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS;CACnF,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS;CACzF,WAAWA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uFAAuF,CAAC,CAAC,SAAS;CACvI,aAAaA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS;AACpF,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,uDAAuD;AACjF,MAAa,8BAA8BA,IAAAA,EAAE,OAAO,EAClD,SAAS,6CAA6C,SAAS,EACjE,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,wDAAwD;AAElF,MAAa,wBAAwBC,eAAAA,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
@@ -14,22 +14,11 @@ declare const ErpnextSubmitDocumentOutput: z.ZodObject<{
14
14
  modified: z.ZodNullable<z.ZodString>;
15
15
  docstatus: z.ZodNullable<z.ZodNumber>;
16
16
  modified_by: z.ZodNullable<z.ZodString>;
17
- }, z.core.$strip>>;
18
- }, z.core.$strip>;
17
+ }, z.core.$loose>>;
18
+ }, z.core.$loose>;
19
19
  declare const erpnextSubmitDocument: import("@keystrokehq/action").WorkflowActionDefinition<{
20
20
  doc: string;
21
- }, {
22
- message: {
23
- idx: number | null;
24
- name: string | null;
25
- owner: string | null;
26
- doctype: string | null;
27
- creation: string | null;
28
- modified: string | null;
29
- docstatus: number | null;
30
- modified_by: string | null;
31
- } | null;
32
- }, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
21
+ }, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
33
22
  //#endregion
34
23
  export { erpnextSubmitDocument };
35
24
  //# sourceMappingURL=submit-document.d.cts.map
@@ -14,22 +14,11 @@ declare const ErpnextSubmitDocumentOutput: z.ZodObject<{
14
14
  modified: z.ZodNullable<z.ZodString>;
15
15
  docstatus: z.ZodNullable<z.ZodNumber>;
16
16
  modified_by: z.ZodNullable<z.ZodString>;
17
- }, z.core.$strip>>;
18
- }, z.core.$strip>;
17
+ }, z.core.$loose>>;
18
+ }, z.core.$loose>;
19
19
  declare const erpnextSubmitDocument: import("@keystrokehq/action").WorkflowActionDefinition<{
20
20
  doc: string;
21
- }, {
22
- message: {
23
- idx: number | null;
24
- name: string | null;
25
- owner: string | null;
26
- doctype: string | null;
27
- creation: string | null;
28
- modified: string | null;
29
- docstatus: number | null;
30
- modified_by: string | null;
31
- } | null;
32
- }, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
21
+ }, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
33
22
  //#endregion
34
23
  export { erpnextSubmitDocument };
35
24
  //# sourceMappingURL=submit-document.d.mts.map
@@ -11,13 +11,13 @@ const ErpnextSubmitDocument_DocumentMetadataSchema = z.object({
11
11
  modified: z.string().describe("ISO timestamp when document was last modified.").nullable(),
12
12
  docstatus: z.number().int().describe("Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.").nullable(),
13
13
  modified_by: z.string().describe("User who last modified the document.").nullable()
14
- }).describe("Core metadata fields present in all Frappe documents.");
14
+ }).passthrough().describe("Core metadata fields present in all Frappe documents.");
15
15
  const erpnextSubmitDocument = action("ERPNEXT_SUBMIT_DOCUMENT", {
16
16
  slug: "erpnext-submit-document",
17
17
  name: "Submit Document",
18
18
  description: "Submit a draft document in ERPNext/Frappe to change its status from Draft to Submitted. Use for submittable DocTypes like Sales Invoice, Purchase Order, Journal Entry, etc. Document must exist in draft state (docstatus=0) before submission.",
19
19
  input: ErpnextSubmitDocumentInput,
20
- output: z.object({ message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable() }).describe("Response from submitting a document in ERPNext/Frappe.")
20
+ output: z.object({ message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable() }).passthrough().describe("Response from submitting a document in ERPNext/Frappe.")
21
21
  });
22
22
  //#endregion
23
23
  export { erpnextSubmitDocument };
@@ -1 +1 @@
1
- {"version":3,"file":"submit-document.mjs","names":[],"sources":["../../src/actions/submit-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSubmitDocumentInput = z.object({\n doc: z.string().describe(\"JSON-stringified complete document object to submit. Must include: (1) 'doctype' field specifying the document type (e.g., 'Journal Entry', 'Sales Invoice'), (2) 'name' field with the document ID, (3) all required fields for the DocType, (4) all child table records if applicable (as arrays of objects), (5) timestamp fields ('modified', 'creation') matching current server state. The document must be in draft state (docstatus=0) and the DocType must be submittable. Fetch the complete document first using GET endpoint to ensure all fields and timestamps are current.\"),\n}).describe(\"Request parameters for submitting a document in ERPNext/Frappe.\");\nconst ErpnextSubmitDocument_DocumentMetadataSchema = z.object({\n idx: z.number().int().describe(\"Index/sequence number of the document.\").nullable(),\n name: z.string().describe(\"Unique document identifier/name.\").nullable(),\n owner: z.string().describe(\"User who created the document.\").nullable(),\n doctype: z.string().describe(\"Document type (e.g., 'Sales Invoice', 'Journal Entry').\").nullable(),\n creation: z.string().describe(\"ISO timestamp when document was created.\").nullable(),\n modified: z.string().describe(\"ISO timestamp when document was last modified.\").nullable(),\n docstatus: z.number().int().describe(\"Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.\").nullable(),\n modified_by: z.string().describe(\"User who last modified the document.\").nullable(),\n}).describe(\"Core metadata fields present in all Frappe documents.\");\nexport const ErpnextSubmitDocumentOutput = z.object({\n message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable(),\n}).describe(\"Response from submitting a document in ERPNext/Frappe.\");\n\nexport const erpnextSubmitDocument = action(\"ERPNEXT_SUBMIT_DOCUMENT\", {\n slug: \"erpnext-submit-document\",\n name: \"Submit Document\",\n description: \"Submit a draft document in ERPNext/Frappe to change its status from Draft to Submitted. Use for submittable DocTypes like Sales Invoice, Purchase Order, Journal Entry, etc. Document must exist in draft state (docstatus=0) before submission.\",\n input: ErpnextSubmitDocumentInput,\n output: ErpnextSubmitDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6B,EAAE,OAAO,EACjD,KAAK,EAAE,OAAO,CAAC,CAAC,SAAS,2jBAA2jB,EACtlB,CAAC,CAAC,CAAC,SAAS,iEAAiE;AAC7E,MAAM,+CAA+C,EAAE,OAAO;CAC5D,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;CAClF,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACvE,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS;CACtE,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS;CACjG,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS;CACnF,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS;CACzF,WAAW,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uFAAuF,CAAC,CAAC,SAAS;CACvI,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS;AACpF,CAAC,CAAC,CAAC,SAAS,uDAAuD;AAKnE,MAAa,wBAAwB,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QATyC,EAAE,OAAO,EAClD,SAAS,6CAA6C,SAAS,EACjE,CAAC,CAAC,CAAC,SAAS,wDAOF;AACV,CAAC"}
1
+ {"version":3,"file":"submit-document.mjs","names":[],"sources":["../../src/actions/submit-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextSubmitDocumentInput = z.object({\n doc: z.string().describe(\"JSON-stringified complete document object to submit. Must include: (1) 'doctype' field specifying the document type (e.g., 'Journal Entry', 'Sales Invoice'), (2) 'name' field with the document ID, (3) all required fields for the DocType, (4) all child table records if applicable (as arrays of objects), (5) timestamp fields ('modified', 'creation') matching current server state. The document must be in draft state (docstatus=0) and the DocType must be submittable. Fetch the complete document first using GET endpoint to ensure all fields and timestamps are current.\"),\n}).describe(\"Request parameters for submitting a document in ERPNext/Frappe.\");\nconst ErpnextSubmitDocument_DocumentMetadataSchema = z.object({\n idx: z.number().int().describe(\"Index/sequence number of the document.\").nullable(),\n name: z.string().describe(\"Unique document identifier/name.\").nullable(),\n owner: z.string().describe(\"User who created the document.\").nullable(),\n doctype: z.string().describe(\"Document type (e.g., 'Sales Invoice', 'Journal Entry').\").nullable(),\n creation: z.string().describe(\"ISO timestamp when document was created.\").nullable(),\n modified: z.string().describe(\"ISO timestamp when document was last modified.\").nullable(),\n docstatus: z.number().int().describe(\"Document status: 0=Draft, 1=Submitted, 2=Cancelled. After submission, this will be 1.\").nullable(),\n modified_by: z.string().describe(\"User who last modified the document.\").nullable(),\n}).passthrough().describe(\"Core metadata fields present in all Frappe documents.\");\nexport const ErpnextSubmitDocumentOutput = z.object({\n message: ErpnextSubmitDocument_DocumentMetadataSchema.nullable(),\n}).passthrough().describe(\"Response from submitting a document in ERPNext/Frappe.\");\n\nexport const erpnextSubmitDocument = action(\"ERPNEXT_SUBMIT_DOCUMENT\", {\n slug: \"erpnext-submit-document\",\n name: \"Submit Document\",\n description: \"Submit a draft document in ERPNext/Frappe to change its status from Draft to Submitted. Use for submittable DocTypes like Sales Invoice, Purchase Order, Journal Entry, etc. Document must exist in draft state (docstatus=0) before submission.\",\n input: ErpnextSubmitDocumentInput,\n output: ErpnextSubmitDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6B,EAAE,OAAO,EACjD,KAAK,EAAE,OAAO,CAAC,CAAC,SAAS,2jBAA2jB,EACtlB,CAAC,CAAC,CAAC,SAAS,iEAAiE;AAC7E,MAAM,+CAA+C,EAAE,OAAO;CAC5D,KAAK,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,wCAAwC,CAAC,CAAC,SAAS;CAClF,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS;CACvE,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS;CACtE,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS;CACjG,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS;CACnF,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS;CACzF,WAAW,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uFAAuF,CAAC,CAAC,SAAS;CACvI,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,sCAAsC,CAAC,CAAC,SAAS;AACpF,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,uDAAuD;AAKjF,MAAa,wBAAwB,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QATyC,EAAE,OAAO,EAClD,SAAS,6CAA6C,SAAS,EACjE,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,wDAOhB;AACV,CAAC"}
@@ -3,19 +3,19 @@ let zod = require("zod");
3
3
  //#region src/actions/update-document.ts
4
4
  const ErpnextUpdateDocumentInput = zod.z.object({
5
5
  name: zod.z.string().describe("The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo)."),
6
- fields: zod.z.object({}).describe("Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema."),
6
+ fields: zod.z.record(zod.z.string(), zod.z.unknown()).describe("Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema."),
7
7
  doctype: zod.z.string().describe("The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.")
8
8
  }).describe("Request model for updating an ERPNext document.");
9
9
  const ErpnextUpdateDocument_DocumentDataSchema = zod.z.object({
10
- name: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("The name (ID) of the document.").optional()),
11
- owner: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("The user who owns this document.").optional()),
12
- doctype: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("The DocType of this document.").optional()),
13
- creation: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("Timestamp when the document was created.").optional()),
14
- modified: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("Timestamp when the document was last modified.").optional()),
15
- docstatus: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.number().int().describe("Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).").optional()),
16
- modified_by: zod.z.preprocess((value) => value === null ? void 0 : value, zod.z.string().describe("The user who last modified this document.").optional())
17
- }).describe("Model representing the document data returned in the response.");
18
- const ErpnextUpdateDocumentOutput = zod.z.object({ data: zod.z.preprocess((value) => value === null ? void 0 : value, ErpnextUpdateDocument_DocumentDataSchema.optional()) }).describe("Response model returned after updating an ERPNext document.");
10
+ name: zod.z.string().describe("The name (ID) of the document.").nullable().optional(),
11
+ owner: zod.z.string().describe("The user who owns this document.").nullable().optional(),
12
+ doctype: zod.z.string().describe("The DocType of this document.").nullable().optional(),
13
+ creation: zod.z.string().describe("Timestamp when the document was created.").nullable().optional(),
14
+ modified: zod.z.string().describe("Timestamp when the document was last modified.").nullable().optional(),
15
+ docstatus: zod.z.number().int().describe("Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).").nullable().optional(),
16
+ modified_by: zod.z.string().describe("The user who last modified this document.").nullable().optional()
17
+ }).passthrough().describe("Model representing the document data returned in the response.");
18
+ const ErpnextUpdateDocumentOutput = zod.z.object({ data: ErpnextUpdateDocument_DocumentDataSchema.nullable().optional() }).passthrough().describe("Response model returned after updating an ERPNext document.");
19
19
  const erpnextUpdateDocument = require_action.action("ERPNEXT_UPDATE_DOCUMENT", {
20
20
  slug: "erpnext-update-document",
21
21
  name: "Update ERPNext document",
@@ -1 +1 @@
1
- {"version":3,"file":"update-document.cjs","names":["z","action"],"sources":["../../src/actions/update-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextUpdateDocumentInput = z.object({\n name: z.string().describe(\"The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo).\"),\n fields: z.object({}).describe(\"Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema.\"),\n doctype: z.string().describe(\"The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.\"),\n}).describe(\"Request model for updating an ERPNext document.\");\nconst ErpnextUpdateDocument_DocumentDataSchema = z.object({\n name: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The name (ID) of the document.\").optional()),\n owner: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The user who owns this document.\").optional()),\n doctype: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The DocType of this document.\").optional()),\n creation: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Timestamp when the document was created.\").optional()),\n modified: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Timestamp when the document was last modified.\").optional()),\n docstatus: z.preprocess((value) => (value === null ? undefined : value), z.number().int().describe(\"Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).\").optional()),\n modified_by: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The user who last modified this document.\").optional()),\n}).describe(\"Model representing the document data returned in the response.\");\nexport const ErpnextUpdateDocumentOutput = z.object({\n data: z.preprocess((value) => (value === null ? undefined : value), ErpnextUpdateDocument_DocumentDataSchema.optional()),\n}).describe(\"Response model returned after updating an ERPNext document.\");\n\nexport const erpnextUpdateDocument = action(\"ERPNEXT_UPDATE_DOCUMENT\", {\n slug: \"erpnext-update-document\",\n name: \"Update ERPNext document\",\n description: \"Tool to update a specific ERPNext document. Acts like a PATCH request - only send the fields you want to change, not the whole document. Use when you need to modify specific fields of an existing document.\",\n input: ErpnextUpdateDocumentInput,\n output: ErpnextUpdateDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6BA,IAAAA,EAAE,OAAO;CACjD,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0HAA0H;CACpJ,QAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,8KAA8K;CAC5M,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wJAAwJ;AACvL,CAAC,CAAC,CAAC,SAAS,iDAAiD;AAC7D,MAAM,2CAA2CA,IAAAA,EAAE,OAAO;CACxD,MAAMA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS,CAAC;CACpI,OAAOA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS,CAAC;CACvI,SAASA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC;CACtI,UAAUA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC;CAClJ,UAAUA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS,CAAC;CACxJ,WAAWA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,gEAAgE,CAAC,CAAC,SAAS,CAAC;CAC/K,aAAaA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC;AACxJ,CAAC,CAAC,CAAC,SAAS,gEAAgE;AAC5E,MAAa,8BAA8BA,IAAAA,EAAE,OAAO,EAClD,MAAMA,IAAAA,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,yCAAyC,SAAS,CAAC,EACzH,CAAC,CAAC,CAAC,SAAS,6DAA6D;AAEzE,MAAa,wBAAwBC,eAAAA,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
1
+ {"version":3,"file":"update-document.cjs","names":["z","action"],"sources":["../../src/actions/update-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextUpdateDocumentInput = z.object({\n name: z.string().describe(\"The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo).\"),\n fields: z.record(z.string(), z.unknown()).describe(\"Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema.\"),\n doctype: z.string().describe(\"The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.\"),\n}).describe(\"Request model for updating an ERPNext document.\");\nconst ErpnextUpdateDocument_DocumentDataSchema = z.object({\n name: z.string().describe(\"The name (ID) of the document.\").nullable().optional(),\n owner: z.string().describe(\"The user who owns this document.\").nullable().optional(),\n doctype: z.string().describe(\"The DocType of this document.\").nullable().optional(),\n creation: z.string().describe(\"Timestamp when the document was created.\").nullable().optional(),\n modified: z.string().describe(\"Timestamp when the document was last modified.\").nullable().optional(),\n docstatus: z.number().int().describe(\"Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).\").nullable().optional(),\n modified_by: z.string().describe(\"The user who last modified this document.\").nullable().optional(),\n}).passthrough().describe(\"Model representing the document data returned in the response.\");\nexport const ErpnextUpdateDocumentOutput = z.object({\n data: ErpnextUpdateDocument_DocumentDataSchema.nullable().optional(),\n}).passthrough().describe(\"Response model returned after updating an ERPNext document.\");\n\nexport const erpnextUpdateDocument = action(\"ERPNEXT_UPDATE_DOCUMENT\", {\n slug: \"erpnext-update-document\",\n name: \"Update ERPNext document\",\n description: \"Tool to update a specific ERPNext document. Acts like a PATCH request - only send the fields you want to change, not the whole document. Use when you need to modify specific fields of an existing document.\",\n input: ErpnextUpdateDocumentInput,\n output: ErpnextUpdateDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6BA,IAAAA,EAAE,OAAO;CACjD,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0HAA0H;CACpJ,QAAQA,IAAAA,EAAE,OAAOA,IAAAA,EAAE,OAAO,GAAGA,IAAAA,EAAE,QAAQ,CAAC,CAAC,CAAC,SAAS,8KAA8K;CACjO,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,wJAAwJ;AACvL,CAAC,CAAC,CAAC,SAAS,iDAAiD;AAC7D,MAAM,2CAA2CA,IAAAA,EAAE,OAAO;CACxD,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAChF,OAAOA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACnF,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAClF,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9F,UAAUA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACpG,WAAWA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,gEAAgE,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC3H,aAAaA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACpG,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,gEAAgE;AAC1F,MAAa,8BAA8BA,IAAAA,EAAE,OAAO,EAClD,MAAM,yCAAyC,SAAS,CAAC,CAAC,SAAS,EACrE,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6DAA6D;AAEvF,MAAa,wBAAwBC,eAAAA,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
@@ -3,35 +3,25 @@ import { z } from "zod";
3
3
  //#region src/actions/update-document.d.ts
4
4
  declare const ErpnextUpdateDocumentInput: z.ZodObject<{
5
5
  name: z.ZodString;
6
- fields: z.ZodObject<{}, z.core.$strip>;
6
+ fields: z.ZodRecord<z.ZodString, z.ZodUnknown>;
7
7
  doctype: z.ZodString;
8
8
  }, z.core.$strip>;
9
9
  declare const ErpnextUpdateDocumentOutput: z.ZodObject<{
10
- data: z.ZodPreprocess<z.ZodOptional<z.ZodObject<{
11
- name: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
12
- owner: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
13
- doctype: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
14
- creation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
15
- modified: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
16
- docstatus: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
17
- modified_by: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
18
- }, z.core.$strip>>>;
19
- }, z.core.$strip>;
10
+ data: z.ZodOptional<z.ZodNullable<z.ZodObject<{
11
+ name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
12
+ owner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
13
+ doctype: z.ZodOptional<z.ZodNullable<z.ZodString>>;
14
+ creation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
+ modified: z.ZodOptional<z.ZodNullable<z.ZodString>>;
16
+ docstatus: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
17
+ modified_by: z.ZodOptional<z.ZodNullable<z.ZodString>>;
18
+ }, z.core.$loose>>>;
19
+ }, z.core.$loose>;
20
20
  declare const erpnextUpdateDocument: import("@keystrokehq/action").WorkflowActionDefinition<{
21
21
  name: string;
22
- fields: Record<string, never>;
22
+ fields: Record<string, unknown>;
23
23
  doctype: string;
24
- }, {
25
- data?: {
26
- name?: string | undefined;
27
- owner?: string | undefined;
28
- doctype?: string | undefined;
29
- creation?: string | undefined;
30
- modified?: string | undefined;
31
- docstatus?: number | undefined;
32
- modified_by?: string | undefined;
33
- } | undefined;
34
- }, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
24
+ }, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
35
25
  //#endregion
36
26
  export { erpnextUpdateDocument };
37
27
  //# sourceMappingURL=update-document.d.cts.map
@@ -3,35 +3,25 @@ import { z } from "zod";
3
3
  //#region src/actions/update-document.d.ts
4
4
  declare const ErpnextUpdateDocumentInput: z.ZodObject<{
5
5
  name: z.ZodString;
6
- fields: z.ZodObject<{}, z.core.$strip>;
6
+ fields: z.ZodRecord<z.ZodString, z.ZodUnknown>;
7
7
  doctype: z.ZodString;
8
8
  }, z.core.$strip>;
9
9
  declare const ErpnextUpdateDocumentOutput: z.ZodObject<{
10
- data: z.ZodPreprocess<z.ZodOptional<z.ZodObject<{
11
- name: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
12
- owner: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
13
- doctype: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
14
- creation: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
15
- modified: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
16
- docstatus: z.ZodPreprocess<z.ZodOptional<z.ZodNumber>>;
17
- modified_by: z.ZodPreprocess<z.ZodOptional<z.ZodString>>;
18
- }, z.core.$strip>>>;
19
- }, z.core.$strip>;
10
+ data: z.ZodOptional<z.ZodNullable<z.ZodObject<{
11
+ name: z.ZodOptional<z.ZodNullable<z.ZodString>>;
12
+ owner: z.ZodOptional<z.ZodNullable<z.ZodString>>;
13
+ doctype: z.ZodOptional<z.ZodNullable<z.ZodString>>;
14
+ creation: z.ZodOptional<z.ZodNullable<z.ZodString>>;
15
+ modified: z.ZodOptional<z.ZodNullable<z.ZodString>>;
16
+ docstatus: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
17
+ modified_by: z.ZodOptional<z.ZodNullable<z.ZodString>>;
18
+ }, z.core.$loose>>>;
19
+ }, z.core.$loose>;
20
20
  declare const erpnextUpdateDocument: import("@keystrokehq/action").WorkflowActionDefinition<{
21
21
  name: string;
22
- fields: Record<string, never>;
22
+ fields: Record<string, unknown>;
23
23
  doctype: string;
24
- }, {
25
- data?: {
26
- name?: string | undefined;
27
- owner?: string | undefined;
28
- doctype?: string | undefined;
29
- creation?: string | undefined;
30
- modified?: string | undefined;
31
- docstatus?: number | undefined;
32
- modified_by?: string | undefined;
33
- } | undefined;
34
- }, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
24
+ }, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
35
25
  //#endregion
36
26
  export { erpnextUpdateDocument };
37
27
  //# sourceMappingURL=update-document.d.mts.map
@@ -3,24 +3,24 @@ import { z } from "zod";
3
3
  //#region src/actions/update-document.ts
4
4
  const ErpnextUpdateDocumentInput = z.object({
5
5
  name: z.string().describe("The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo)."),
6
- fields: z.object({}).describe("Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema."),
6
+ fields: z.record(z.string(), z.unknown()).describe("Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema."),
7
7
  doctype: z.string().describe("The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.")
8
8
  }).describe("Request model for updating an ERPNext document.");
9
9
  const ErpnextUpdateDocument_DocumentDataSchema = z.object({
10
- name: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The name (ID) of the document.").optional()),
11
- owner: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The user who owns this document.").optional()),
12
- doctype: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The DocType of this document.").optional()),
13
- creation: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("Timestamp when the document was created.").optional()),
14
- modified: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("Timestamp when the document was last modified.").optional()),
15
- docstatus: z.preprocess((value) => value === null ? void 0 : value, z.number().int().describe("Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).").optional()),
16
- modified_by: z.preprocess((value) => value === null ? void 0 : value, z.string().describe("The user who last modified this document.").optional())
17
- }).describe("Model representing the document data returned in the response.");
10
+ name: z.string().describe("The name (ID) of the document.").nullable().optional(),
11
+ owner: z.string().describe("The user who owns this document.").nullable().optional(),
12
+ doctype: z.string().describe("The DocType of this document.").nullable().optional(),
13
+ creation: z.string().describe("Timestamp when the document was created.").nullable().optional(),
14
+ modified: z.string().describe("Timestamp when the document was last modified.").nullable().optional(),
15
+ docstatus: z.number().int().describe("Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).").nullable().optional(),
16
+ modified_by: z.string().describe("The user who last modified this document.").nullable().optional()
17
+ }).passthrough().describe("Model representing the document data returned in the response.");
18
18
  const erpnextUpdateDocument = action("ERPNEXT_UPDATE_DOCUMENT", {
19
19
  slug: "erpnext-update-document",
20
20
  name: "Update ERPNext document",
21
21
  description: "Tool to update a specific ERPNext document. Acts like a PATCH request - only send the fields you want to change, not the whole document. Use when you need to modify specific fields of an existing document.",
22
22
  input: ErpnextUpdateDocumentInput,
23
- output: z.object({ data: z.preprocess((value) => value === null ? void 0 : value, ErpnextUpdateDocument_DocumentDataSchema.optional()) }).describe("Response model returned after updating an ERPNext document.")
23
+ output: z.object({ data: ErpnextUpdateDocument_DocumentDataSchema.nullable().optional() }).passthrough().describe("Response model returned after updating an ERPNext document.")
24
24
  });
25
25
  //#endregion
26
26
  export { erpnextUpdateDocument };
@@ -1 +1 @@
1
- {"version":3,"file":"update-document.mjs","names":[],"sources":["../../src/actions/update-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextUpdateDocumentInput = z.object({\n name: z.string().describe(\"The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo).\"),\n fields: z.object({}).describe(\"Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema.\"),\n doctype: z.string().describe(\"The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.\"),\n}).describe(\"Request model for updating an ERPNext document.\");\nconst ErpnextUpdateDocument_DocumentDataSchema = z.object({\n name: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The name (ID) of the document.\").optional()),\n owner: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The user who owns this document.\").optional()),\n doctype: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The DocType of this document.\").optional()),\n creation: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Timestamp when the document was created.\").optional()),\n modified: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"Timestamp when the document was last modified.\").optional()),\n docstatus: z.preprocess((value) => (value === null ? undefined : value), z.number().int().describe(\"Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).\").optional()),\n modified_by: z.preprocess((value) => (value === null ? undefined : value), z.string().describe(\"The user who last modified this document.\").optional()),\n}).describe(\"Model representing the document data returned in the response.\");\nexport const ErpnextUpdateDocumentOutput = z.object({\n data: z.preprocess((value) => (value === null ? undefined : value), ErpnextUpdateDocument_DocumentDataSchema.optional()),\n}).describe(\"Response model returned after updating an ERPNext document.\");\n\nexport const erpnextUpdateDocument = action(\"ERPNEXT_UPDATE_DOCUMENT\", {\n slug: \"erpnext-update-document\",\n name: \"Update ERPNext document\",\n description: \"Tool to update a specific ERPNext document. Acts like a PATCH request - only send the fields you want to change, not the whole document. Use when you need to modify specific fields of an existing document.\",\n input: ErpnextUpdateDocumentInput,\n output: ErpnextUpdateDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6B,EAAE,OAAO;CACjD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,0HAA0H;CACpJ,QAAQ,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,8KAA8K;CAC5M,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,wJAAwJ;AACvL,CAAC,CAAC,CAAC,SAAS,iDAAiD;AAC7D,MAAM,2CAA2C,EAAE,OAAO;CACxD,MAAM,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS,CAAC;CACpI,OAAO,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS,CAAC;CACvI,SAAS,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC;CACtI,UAAU,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC;CAClJ,UAAU,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS,CAAC;CACxJ,WAAW,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,gEAAgE,CAAC,CAAC,SAAS,CAAC;CAC/K,aAAa,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC;AACxJ,CAAC,CAAC,CAAC,SAAS,gEAAgE;AAK5E,MAAa,wBAAwB,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QATyC,EAAE,OAAO,EAClD,MAAM,EAAE,YAAY,UAAW,UAAU,OAAO,SAAY,OAAQ,yCAAyC,SAAS,CAAC,EACzH,CAAC,CAAC,CAAC,SAAS,6DAOF;AACV,CAAC"}
1
+ {"version":3,"file":"update-document.mjs","names":[],"sources":["../../src/actions/update-document.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const ErpnextUpdateDocumentInput = z.object({\n name: z.string().describe(\"The name (ID) of the document you'd like to update. For example EMP001 (of type Employee), or 4klj4teijs (of type ToDo).\"),\n fields: z.record(z.string(), z.unknown()).describe(\"Dictionary of field names and their new values. Only include the fields you want to update - acts like a PATCH request. Field names and types must match the DocType schema.\"),\n doctype: z.string().describe(\"The DocType you'd like to update. For example Customer, Supplier, Employee, Account, Lead, Company, Sales Invoice, Purchase Invoice, Stock Entry, etc.\"),\n}).describe(\"Request model for updating an ERPNext document.\");\nconst ErpnextUpdateDocument_DocumentDataSchema = z.object({\n name: z.string().describe(\"The name (ID) of the document.\").nullable().optional(),\n owner: z.string().describe(\"The user who owns this document.\").nullable().optional(),\n doctype: z.string().describe(\"The DocType of this document.\").nullable().optional(),\n creation: z.string().describe(\"Timestamp when the document was created.\").nullable().optional(),\n modified: z.string().describe(\"Timestamp when the document was last modified.\").nullable().optional(),\n docstatus: z.number().int().describe(\"Document status indicator (0=Draft, 1=Submitted, 2=Cancelled).\").nullable().optional(),\n modified_by: z.string().describe(\"The user who last modified this document.\").nullable().optional(),\n}).passthrough().describe(\"Model representing the document data returned in the response.\");\nexport const ErpnextUpdateDocumentOutput = z.object({\n data: ErpnextUpdateDocument_DocumentDataSchema.nullable().optional(),\n}).passthrough().describe(\"Response model returned after updating an ERPNext document.\");\n\nexport const erpnextUpdateDocument = action(\"ERPNEXT_UPDATE_DOCUMENT\", {\n slug: \"erpnext-update-document\",\n name: \"Update ERPNext document\",\n description: \"Tool to update a specific ERPNext document. Acts like a PATCH request - only send the fields you want to change, not the whole document. Use when you need to modify specific fields of an existing document.\",\n input: ErpnextUpdateDocumentInput,\n output: ErpnextUpdateDocumentOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA6B,EAAE,OAAO;CACjD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,0HAA0H;CACpJ,QAAQ,EAAE,OAAO,EAAE,OAAO,GAAG,EAAE,QAAQ,CAAC,CAAC,CAAC,SAAS,8KAA8K;CACjO,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,wJAAwJ;AACvL,CAAC,CAAC,CAAC,SAAS,iDAAiD;AAC7D,MAAM,2CAA2C,EAAE,OAAO;CACxD,MAAM,EAAE,OAAO,CAAC,CAAC,SAAS,gCAAgC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAChF,OAAO,EAAE,OAAO,CAAC,CAAC,SAAS,kCAAkC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACnF,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAClF,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9F,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,gDAAgD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACpG,WAAW,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,gEAAgE,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC3H,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACpG,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,gEAAgE;AAK1F,MAAa,wBAAwB,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QATyC,EAAE,OAAO,EAClD,MAAM,yCAAyC,SAAS,CAAC,CAAC,SAAS,EACrE,CAAC,CAAC,CAAC,YAAY,CAAC,CAAC,SAAS,6DAOhB;AACV,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@keystrokehq/erpnext",
3
- "version": "0.1.1",
3
+ "version": "0.1.3",
4
4
  "publishConfig": {
5
5
  "access": "public",
6
6
  "registry": "https://registry.npmjs.org"