@financeable/aggregation 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (394) hide show
  1. package/.devcontainer/README.md +35 -0
  2. package/.devcontainer/devcontainer.json +45 -0
  3. package/FUNCTIONS.md +225 -0
  4. package/README.md +967 -0
  5. package/RUNTIMES.md +48 -0
  6. package/core.d.ts +10 -0
  7. package/core.d.ts.map +1 -0
  8. package/core.js +17 -0
  9. package/core.js.map +1 -0
  10. package/docs/sdks/applications/README.md +467 -0
  11. package/docs/sdks/financeable/README.md +5 -0
  12. package/financeable-typescript/.devcontainer/README.md +30 -0
  13. package/financeable-typescript/FUNCTIONS.md +205 -0
  14. package/financeable-typescript/README.md +895 -0
  15. package/financeable-typescript/RUNTIMES.md +22 -0
  16. package/financeable-typescript/docs/sdks/applications/README.md +427 -0
  17. package/financeable-typescript/docs/sdks/financeable/README.md +5 -0
  18. package/financeable-typescript/src/core.ts +13 -0
  19. package/financeable-typescript/src/funcs/applicationsCreate.ts +124 -0
  20. package/financeable-typescript/src/funcs/applicationsGet.ts +128 -0
  21. package/financeable-typescript/src/funcs/applicationsList.ts +126 -0
  22. package/financeable-typescript/src/hooks/hooks.ts +129 -0
  23. package/financeable-typescript/src/hooks/index.ts +6 -0
  24. package/financeable-typescript/src/hooks/types.ts +109 -0
  25. package/financeable-typescript/src/index.ts +7 -0
  26. package/financeable-typescript/src/lib/base64.ts +37 -0
  27. package/financeable-typescript/src/lib/config.ts +59 -0
  28. package/financeable-typescript/src/lib/dlv.ts +53 -0
  29. package/financeable-typescript/src/lib/encodings.ts +449 -0
  30. package/financeable-typescript/src/lib/env.ts +37 -0
  31. package/financeable-typescript/src/lib/files.ts +40 -0
  32. package/financeable-typescript/src/lib/http.ts +323 -0
  33. package/financeable-typescript/src/lib/is-plain-object.ts +43 -0
  34. package/financeable-typescript/src/lib/logger.ts +9 -0
  35. package/financeable-typescript/src/lib/matchers.ts +322 -0
  36. package/financeable-typescript/src/lib/primitives.ts +122 -0
  37. package/financeable-typescript/src/lib/retries.ts +219 -0
  38. package/financeable-typescript/src/lib/schemas.ts +86 -0
  39. package/financeable-typescript/src/lib/sdks.ts +392 -0
  40. package/financeable-typescript/src/lib/security.ts +227 -0
  41. package/financeable-typescript/src/lib/url.ts +33 -0
  42. package/financeable-typescript/src/models/components/addressattributes.ts +148 -0
  43. package/financeable-typescript/src/models/components/apierrorlinks.ts +65 -0
  44. package/financeable-typescript/src/models/components/applicationattributes.ts +128 -0
  45. package/financeable-typescript/src/models/components/applicationattributescreate.ts +90 -0
  46. package/financeable-typescript/src/models/components/applicationresourcebulksubmission.ts +1000 -0
  47. package/financeable-typescript/src/models/components/applicationstatus.ts +39 -0
  48. package/financeable-typescript/src/models/components/applicationtype.ts +33 -0
  49. package/financeable-typescript/src/models/components/assetattributes.ts +400 -0
  50. package/financeable-typescript/src/models/components/customerattributes.ts +171 -0
  51. package/financeable-typescript/src/models/components/customertitle.ts +35 -0
  52. package/financeable-typescript/src/models/components/errorsource.ts +79 -0
  53. package/financeable-typescript/src/models/components/forbiddenerror.ts +207 -0
  54. package/financeable-typescript/src/models/components/frequencytype.ts +40 -0
  55. package/financeable-typescript/src/models/components/index.ts +20 -0
  56. package/financeable-typescript/src/models/components/links.ts +72 -0
  57. package/financeable-typescript/src/models/components/loandetailsattributes.ts +187 -0
  58. package/financeable-typescript/src/models/components/repaymentstructure.ts +40 -0
  59. package/financeable-typescript/src/models/errors/apierror.ts +27 -0
  60. package/financeable-typescript/src/models/errors/createapplication.ts +76 -0
  61. package/financeable-typescript/src/models/errors/getapplication.ts +76 -0
  62. package/financeable-typescript/src/models/errors/getapplications.ts +76 -0
  63. package/financeable-typescript/src/models/errors/httpclienterrors.ts +62 -0
  64. package/financeable-typescript/src/models/errors/index.ts +10 -0
  65. package/financeable-typescript/src/models/errors/sdkvalidationerror.ts +97 -0
  66. package/financeable-typescript/src/models/operations/createapplication.ts +1649 -0
  67. package/financeable-typescript/src/models/operations/getapplication.ts +1829 -0
  68. package/financeable-typescript/src/models/operations/getapplications.ts +1790 -0
  69. package/financeable-typescript/src/models/operations/index.ts +7 -0
  70. package/financeable-typescript/src/sdk/applications.ts +55 -0
  71. package/financeable-typescript/src/sdk/index.ts +5 -0
  72. package/financeable-typescript/src/sdk/sdk.ts +13 -0
  73. package/financeable-typescript/src/types/blobs.ts +31 -0
  74. package/financeable-typescript/src/types/constdatetime.ts +15 -0
  75. package/financeable-typescript/src/types/enums.ts +16 -0
  76. package/financeable-typescript/src/types/fp.ts +50 -0
  77. package/financeable-typescript/src/types/index.ts +11 -0
  78. package/financeable-typescript/src/types/operations.ts +105 -0
  79. package/financeable-typescript/src/types/rfcdate.ts +54 -0
  80. package/financeable-typescript/src/types/streams.ts +21 -0
  81. package/funcs/applicationsCreate.d.ts +14 -0
  82. package/funcs/applicationsCreate.d.ts.map +1 -0
  83. package/funcs/applicationsCreate.js +105 -0
  84. package/funcs/applicationsCreate.js.map +1 -0
  85. package/funcs/applicationsGet.d.ts +13 -0
  86. package/funcs/applicationsGet.d.ts.map +1 -0
  87. package/funcs/applicationsGet.js +109 -0
  88. package/funcs/applicationsGet.js.map +1 -0
  89. package/funcs/applicationsList.d.ts +13 -0
  90. package/funcs/applicationsList.d.ts.map +1 -0
  91. package/funcs/applicationsList.js +107 -0
  92. package/funcs/applicationsList.js.map +1 -0
  93. package/hooks/hooks.d.ts +24 -0
  94. package/hooks/hooks.d.ts.map +1 -0
  95. package/hooks/hooks.js +84 -0
  96. package/hooks/hooks.js.map +1 -0
  97. package/hooks/index.d.ts +3 -0
  98. package/hooks/index.d.ts.map +1 -0
  99. package/hooks/index.js +22 -0
  100. package/hooks/index.js.map +1 -0
  101. package/hooks/types.d.ts +78 -0
  102. package/hooks/types.d.ts.map +1 -0
  103. package/hooks/types.js +6 -0
  104. package/hooks/types.js.map +1 -0
  105. package/index.d.ts +4 -0
  106. package/index.d.ts.map +1 -0
  107. package/index.js +46 -0
  108. package/index.js.map +1 -0
  109. package/jsr.json +27 -0
  110. package/lib/base64.d.ts +10 -0
  111. package/lib/base64.d.ts.map +1 -0
  112. package/lib/base64.js +71 -0
  113. package/lib/base64.js.map +1 -0
  114. package/lib/config.d.ts +33 -0
  115. package/lib/config.d.ts.map +1 -0
  116. package/lib/config.js +35 -0
  117. package/lib/config.js.map +1 -0
  118. package/lib/dlv.d.ts +14 -0
  119. package/lib/dlv.d.ts.map +1 -0
  120. package/lib/dlv.js +49 -0
  121. package/lib/dlv.js.map +1 -0
  122. package/lib/encodings.d.ts +52 -0
  123. package/lib/encodings.d.ts.map +1 -0
  124. package/lib/encodings.js +368 -0
  125. package/lib/encodings.js.map +1 -0
  126. package/lib/env.d.ts +14 -0
  127. package/lib/env.d.ts.map +1 -0
  128. package/lib/env.js +64 -0
  129. package/lib/env.js.map +1 -0
  130. package/lib/files.d.ts +8 -0
  131. package/lib/files.d.ts.map +1 -0
  132. package/lib/files.js +36 -0
  133. package/lib/files.js.map +1 -0
  134. package/lib/http.d.ts +67 -0
  135. package/lib/http.d.ts.map +1 -0
  136. package/lib/http.js +217 -0
  137. package/lib/http.js.map +1 -0
  138. package/lib/is-plain-object.d.ts +2 -0
  139. package/lib/is-plain-object.d.ts.map +1 -0
  140. package/lib/is-plain-object.js +41 -0
  141. package/lib/is-plain-object.js.map +1 -0
  142. package/lib/logger.d.ts +6 -0
  143. package/lib/logger.d.ts.map +1 -0
  144. package/lib/logger.js +6 -0
  145. package/lib/logger.js.map +1 -0
  146. package/lib/matchers.d.ts +64 -0
  147. package/lib/matchers.d.ts.map +1 -0
  148. package/lib/matchers.js +204 -0
  149. package/lib/matchers.js.map +1 -0
  150. package/lib/primitives.d.ts +23 -0
  151. package/lib/primitives.d.ts.map +1 -0
  152. package/lib/primitives.js +104 -0
  153. package/lib/primitives.js.map +1 -0
  154. package/lib/retries.d.ts +38 -0
  155. package/lib/retries.d.ts.map +1 -0
  156. package/lib/retries.js +153 -0
  157. package/lib/retries.js.map +1 -0
  158. package/lib/schemas.d.ts +19 -0
  159. package/lib/schemas.d.ts.map +1 -0
  160. package/lib/schemas.js +62 -0
  161. package/lib/schemas.js.map +1 -0
  162. package/lib/sdks.d.ts +60 -0
  163. package/lib/sdks.d.ts.map +1 -0
  164. package/lib/sdks.js +280 -0
  165. package/lib/sdks.js.map +1 -0
  166. package/lib/security.d.ts +79 -0
  167. package/lib/security.d.ts.map +1 -0
  168. package/lib/security.js +121 -0
  169. package/lib/security.js.map +1 -0
  170. package/lib/url.d.ts +5 -0
  171. package/lib/url.d.ts.map +1 -0
  172. package/lib/url.js +25 -0
  173. package/lib/url.js.map +1 -0
  174. package/models/components/addressattributes.d.ts +83 -0
  175. package/models/components/addressattributes.d.ts.map +1 -0
  176. package/models/components/addressattributes.js +117 -0
  177. package/models/components/addressattributes.js.map +1 -0
  178. package/models/components/apierrorlinks.d.ts +32 -0
  179. package/models/components/apierrorlinks.d.ts.map +1 -0
  180. package/models/components/apierrorlinks.js +69 -0
  181. package/models/components/apierrorlinks.js.map +1 -0
  182. package/models/components/applicationattributes.d.ts +69 -0
  183. package/models/components/applicationattributes.d.ts.map +1 -0
  184. package/models/components/applicationattributes.js +85 -0
  185. package/models/components/applicationattributes.js.map +1 -0
  186. package/models/components/applicationattributescreate.d.ts +43 -0
  187. package/models/components/applicationattributescreate.d.ts.map +1 -0
  188. package/models/components/applicationattributescreate.js +74 -0
  189. package/models/components/applicationattributescreate.js.map +1 -0
  190. package/models/components/applicationresourcebulksubmission.d.ts +456 -0
  191. package/models/components/applicationresourcebulksubmission.d.ts.map +1 -0
  192. package/models/components/applicationresourcebulksubmission.js +492 -0
  193. package/models/components/applicationresourcebulksubmission.js.map +1 -0
  194. package/models/components/applicationstatus.d.ts +46 -0
  195. package/models/components/applicationstatus.d.ts.map +1 -0
  196. package/models/components/applicationstatus.js +66 -0
  197. package/models/components/applicationstatus.js.map +1 -0
  198. package/models/components/applicationtype.d.ts +28 -0
  199. package/models/components/applicationtype.d.ts.map +1 -0
  200. package/models/components/applicationtype.js +60 -0
  201. package/models/components/applicationtype.js.map +1 -0
  202. package/models/components/assetattributes.d.ts +388 -0
  203. package/models/components/assetattributes.d.ts.map +1 -0
  204. package/models/components/assetattributes.js +244 -0
  205. package/models/components/assetattributes.js.map +1 -0
  206. package/models/components/customerattributes.d.ts +103 -0
  207. package/models/components/customerattributes.d.ts.map +1 -0
  208. package/models/components/customerattributes.js +120 -0
  209. package/models/components/customerattributes.js.map +1 -0
  210. package/models/components/customertitle.d.ts +34 -0
  211. package/models/components/customertitle.d.ts.map +1 -0
  212. package/models/components/customertitle.js +62 -0
  213. package/models/components/customertitle.js.map +1 -0
  214. package/models/components/errorsource.d.ts +42 -0
  215. package/models/components/errorsource.d.ts.map +1 -0
  216. package/models/components/errorsource.js +73 -0
  217. package/models/components/errorsource.js.map +1 -0
  218. package/models/components/forbiddenerror.d.ts +141 -0
  219. package/models/components/forbiddenerror.d.ts.map +1 -0
  220. package/models/components/forbiddenerror.js +158 -0
  221. package/models/components/forbiddenerror.js.map +1 -0
  222. package/models/components/frequencytype.d.ts +37 -0
  223. package/models/components/frequencytype.d.ts.map +1 -0
  224. package/models/components/frequencytype.js +64 -0
  225. package/models/components/frequencytype.js.map +1 -0
  226. package/models/components/index.d.ts +17 -0
  227. package/models/components/index.d.ts.map +1 -0
  228. package/models/components/index.js +36 -0
  229. package/models/components/index.js.map +1 -0
  230. package/models/components/links.d.ts +40 -0
  231. package/models/components/links.d.ts.map +1 -0
  232. package/models/components/links.js +72 -0
  233. package/models/components/links.js.map +1 -0
  234. package/models/components/loandetailsattributes.d.ts +112 -0
  235. package/models/components/loandetailsattributes.d.ts.map +1 -0
  236. package/models/components/loandetailsattributes.js +101 -0
  237. package/models/components/loandetailsattributes.js.map +1 -0
  238. package/models/components/repaymentstructure.d.ts +37 -0
  239. package/models/components/repaymentstructure.d.ts.map +1 -0
  240. package/models/components/repaymentstructure.js +64 -0
  241. package/models/components/repaymentstructure.js.map +1 -0
  242. package/models/errors/apierror.d.ts +8 -0
  243. package/models/errors/apierror.d.ts.map +1 -0
  244. package/models/errors/apierror.js +21 -0
  245. package/models/errors/apierror.js.map +1 -0
  246. package/models/errors/createapplication.d.ts +38 -0
  247. package/models/errors/createapplication.d.ts.map +1 -0
  248. package/models/errors/createapplication.js +81 -0
  249. package/models/errors/createapplication.js.map +1 -0
  250. package/models/errors/getapplication.d.ts +38 -0
  251. package/models/errors/getapplication.d.ts.map +1 -0
  252. package/models/errors/getapplication.js +81 -0
  253. package/models/errors/getapplication.js.map +1 -0
  254. package/models/errors/getapplications.d.ts +38 -0
  255. package/models/errors/getapplications.d.ts.map +1 -0
  256. package/models/errors/getapplications.js +81 -0
  257. package/models/errors/getapplications.js.map +1 -0
  258. package/models/errors/httpclienterrors.d.ts +44 -0
  259. package/models/errors/httpclienterrors.d.ts.map +1 -0
  260. package/models/errors/httpclienterrors.js +78 -0
  261. package/models/errors/httpclienterrors.js.map +1 -0
  262. package/models/errors/index.d.ts +7 -0
  263. package/models/errors/index.d.ts.map +1 -0
  264. package/models/errors/index.js +26 -0
  265. package/models/errors/index.js.map +1 -0
  266. package/models/errors/sdkvalidationerror.d.ts +20 -0
  267. package/models/errors/sdkvalidationerror.d.ts.map +1 -0
  268. package/models/errors/sdkvalidationerror.js +115 -0
  269. package/models/errors/sdkvalidationerror.js.map +1 -0
  270. package/models/operations/createapplication.d.ts +780 -0
  271. package/models/operations/createapplication.d.ts.map +1 -0
  272. package/models/operations/createapplication.js +834 -0
  273. package/models/operations/createapplication.js.map +1 -0
  274. package/models/operations/getapplication.d.ts +805 -0
  275. package/models/operations/getapplication.d.ts.map +1 -0
  276. package/models/operations/getapplication.js +861 -0
  277. package/models/operations/getapplication.js.map +1 -0
  278. package/models/operations/getapplications.d.ts +805 -0
  279. package/models/operations/getapplications.d.ts.map +1 -0
  280. package/models/operations/getapplications.js +864 -0
  281. package/models/operations/getapplications.js.map +1 -0
  282. package/models/operations/index.d.ts +4 -0
  283. package/models/operations/index.d.ts.map +1 -0
  284. package/models/operations/index.js +23 -0
  285. package/models/operations/index.js.map +1 -0
  286. package/package.json +30 -0
  287. package/sdk/applications.d.ts +18 -0
  288. package/sdk/applications.d.ts.map +1 -0
  289. package/sdk/applications.js +33 -0
  290. package/sdk/applications.js.map +1 -0
  291. package/sdk/index.d.ts +2 -0
  292. package/sdk/index.d.ts.map +1 -0
  293. package/sdk/index.js +21 -0
  294. package/sdk/index.js.map +1 -0
  295. package/sdk/sdk.d.ts +7 -0
  296. package/sdk/sdk.d.ts.map +1 -0
  297. package/sdk/sdk.js +15 -0
  298. package/sdk/sdk.js.map +1 -0
  299. package/src/core.ts +13 -0
  300. package/src/funcs/applicationsCreate.ts +128 -0
  301. package/src/funcs/applicationsGet.ts +132 -0
  302. package/src/funcs/applicationsList.ts +130 -0
  303. package/src/hooks/hooks.ts +129 -0
  304. package/src/hooks/index.ts +6 -0
  305. package/src/hooks/types.ts +110 -0
  306. package/src/index.ts +7 -0
  307. package/src/lib/base64.ts +37 -0
  308. package/src/lib/config.ts +59 -0
  309. package/src/lib/dlv.ts +53 -0
  310. package/src/lib/encodings.ts +483 -0
  311. package/src/lib/env.ts +37 -0
  312. package/src/lib/files.ts +40 -0
  313. package/src/lib/http.ts +323 -0
  314. package/src/lib/is-plain-object.ts +43 -0
  315. package/src/lib/logger.ts +9 -0
  316. package/src/lib/matchers.ts +322 -0
  317. package/src/lib/primitives.ts +136 -0
  318. package/src/lib/retries.ts +218 -0
  319. package/src/lib/schemas.ts +91 -0
  320. package/src/lib/sdks.ts +400 -0
  321. package/src/lib/security.ts +227 -0
  322. package/src/lib/url.ts +33 -0
  323. package/src/models/components/addressattributes.ts +148 -0
  324. package/src/models/components/apierrorlinks.ts +65 -0
  325. package/src/models/components/applicationattributes.ts +128 -0
  326. package/src/models/components/applicationattributescreate.ts +90 -0
  327. package/src/models/components/applicationresourcebulksubmission.ts +1000 -0
  328. package/src/models/components/applicationstatus.ts +39 -0
  329. package/src/models/components/applicationtype.ts +33 -0
  330. package/src/models/components/assetattributes.ts +400 -0
  331. package/src/models/components/customerattributes.ts +171 -0
  332. package/src/models/components/customertitle.ts +35 -0
  333. package/src/models/components/errorsource.ts +79 -0
  334. package/src/models/components/forbiddenerror.ts +207 -0
  335. package/src/models/components/frequencytype.ts +40 -0
  336. package/src/models/components/index.ts +20 -0
  337. package/src/models/components/links.ts +72 -0
  338. package/src/models/components/loandetailsattributes.ts +187 -0
  339. package/src/models/components/repaymentstructure.ts +40 -0
  340. package/src/models/errors/apierror.ts +27 -0
  341. package/src/models/errors/createapplication.ts +76 -0
  342. package/src/models/errors/getapplication.ts +76 -0
  343. package/src/models/errors/getapplications.ts +76 -0
  344. package/src/models/errors/httpclienterrors.ts +62 -0
  345. package/src/models/errors/index.ts +10 -0
  346. package/src/models/errors/sdkvalidationerror.ts +97 -0
  347. package/src/models/operations/createapplication.ts +1649 -0
  348. package/src/models/operations/getapplication.ts +1829 -0
  349. package/src/models/operations/getapplications.ts +1790 -0
  350. package/src/models/operations/index.ts +7 -0
  351. package/src/sdk/applications.ts +55 -0
  352. package/src/sdk/index.ts +5 -0
  353. package/src/sdk/sdk.ts +13 -0
  354. package/src/types/blobs.ts +31 -0
  355. package/src/types/constdatetime.ts +15 -0
  356. package/src/types/enums.ts +16 -0
  357. package/src/types/fp.ts +50 -0
  358. package/src/types/index.ts +11 -0
  359. package/src/types/operations.ts +105 -0
  360. package/src/types/rfcdate.ts +54 -0
  361. package/src/types/streams.ts +21 -0
  362. package/tsconfig.json +41 -0
  363. package/types/blobs.d.ts +4 -0
  364. package/types/blobs.d.ts.map +1 -0
  365. package/types/blobs.js +62 -0
  366. package/types/blobs.js.map +1 -0
  367. package/types/constdatetime.d.ts +3 -0
  368. package/types/constdatetime.d.ts.map +1 -0
  369. package/types/constdatetime.js +46 -0
  370. package/types/constdatetime.js.map +1 -0
  371. package/types/enums.d.ts +12 -0
  372. package/types/enums.d.ts.map +1 -0
  373. package/types/enums.js +10 -0
  374. package/types/enums.js.map +1 -0
  375. package/types/fp.d.ts +31 -0
  376. package/types/fp.d.ts.map +1 -0
  377. package/types/fp.js +37 -0
  378. package/types/fp.js.map +1 -0
  379. package/types/index.d.ts +8 -0
  380. package/types/index.d.ts.map +1 -0
  381. package/types/index.js +16 -0
  382. package/types/index.js.map +1 -0
  383. package/types/operations.d.ts +27 -0
  384. package/types/operations.d.ts.map +1 -0
  385. package/types/operations.js +83 -0
  386. package/types/operations.js.map +1 -0
  387. package/types/rfcdate.d.ts +21 -0
  388. package/types/rfcdate.d.ts.map +1 -0
  389. package/types/rfcdate.js +46 -0
  390. package/types/rfcdate.js.map +1 -0
  391. package/types/streams.d.ts +2 -0
  392. package/types/streams.d.ts.map +1 -0
  393. package/types/streams.js +18 -0
  394. package/types/streams.js.map +1 -0
package/RUNTIMES.md ADDED
@@ -0,0 +1,48 @@
1
+ # Supported JavaScript runtimes
2
+
3
+ This SDK is intended to be used in JavaScript runtimes that support ECMAScript 2020 or newer. The SDK uses the following features:
4
+
5
+ * [Web Fetch API][web-fetch]
6
+ * [Web Streams API][web-streams] and in particular `ReadableStream`
7
+ * [Async iterables][async-iter] using `Symbol.asyncIterator`
8
+
9
+ [web-fetch]: https://developer.mozilla.org/en-US/docs/Web/API/Fetch_API
10
+ [web-streams]: https://developer.mozilla.org/en-US/docs/Web/API/Streams_API
11
+ [async-iter]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Iteration_protocols#the_async_iterator_and_async_iterable_protocols
12
+
13
+ Runtime environments that are explicitly supported are:
14
+
15
+ - Evergreen browsers which include: Chrome, Safari, Edge, Firefox
16
+ - Node.js active and maintenance LTS releases
17
+ - Currently, this is v18 and v20
18
+ - Bun v1 and above
19
+ - Deno v1.39
20
+ - Note that Deno does not currently have native support for streaming file uploads backed by the filesystem ([issue link][deno-file-streaming])
21
+
22
+ [deno-file-streaming]: https://github.com/denoland/deno/issues/11018
23
+
24
+ ## Recommended TypeScript compiler options
25
+
26
+ The following `tsconfig.json` options are recommended for projects using this
27
+ SDK in order to get static type support for features like async iterables,
28
+ streams and `fetch`-related APIs ([`for await...of`][for-await-of],
29
+ [`AbortSignal`][abort-signal], [`Request`][request], [`Response`][response] and
30
+ so on):
31
+
32
+ [for-await-of]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/for-await...of
33
+ [abort-signal]: https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal
34
+ [request]: https://developer.mozilla.org/en-US/docs/Web/API/Request
35
+ [response]: https://developer.mozilla.org/en-US/docs/Web/API/Response
36
+
37
+ ```jsonc
38
+ {
39
+ "compilerOptions": {
40
+ "target": "es2020", // or higher
41
+ "lib": ["es2020", "dom", "dom.iterable"],
42
+ }
43
+ }
44
+ ```
45
+
46
+ While `target` can be set to older ECMAScript versions, it may result in extra,
47
+ unnecessary compatibility code being generated if you are not targeting old
48
+ runtimes.
package/core.d.ts ADDED
@@ -0,0 +1,10 @@
1
+ import { ClientSDK } from "./lib/sdks.js";
2
+ /**
3
+ * A minimal client to use when calling standalone SDK functions. Typically, an
4
+ * instance of this class would be instantiated once at the start of an
5
+ * application and passed around through some dependency injection mechanism to
6
+ * parts of an application that need to make SDK calls.
7
+ */
8
+ export declare class FinanceableCore extends ClientSDK {
9
+ }
10
+ //# sourceMappingURL=core.d.ts.map
package/core.d.ts.map ADDED
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core.d.ts","sourceRoot":"","sources":["src/core.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,SAAS,EAAE,MAAM,eAAe,CAAC;AAE1C;;;;;GAKG;AACH,qBAAa,eAAgB,SAAQ,SAAS;CAAG"}
package/core.js ADDED
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ /*
3
+ * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
4
+ */
5
+ Object.defineProperty(exports, "__esModule", { value: true });
6
+ exports.FinanceableCore = void 0;
7
+ const sdks_js_1 = require("./lib/sdks.js");
8
+ /**
9
+ * A minimal client to use when calling standalone SDK functions. Typically, an
10
+ * instance of this class would be instantiated once at the start of an
11
+ * application and passed around through some dependency injection mechanism to
12
+ * parts of an application that need to make SDK calls.
13
+ */
14
+ class FinanceableCore extends sdks_js_1.ClientSDK {
15
+ }
16
+ exports.FinanceableCore = FinanceableCore;
17
+ //# sourceMappingURL=core.js.map
package/core.js.map ADDED
@@ -0,0 +1 @@
1
+ {"version":3,"file":"core.js","sourceRoot":"","sources":["src/core.ts"],"names":[],"mappings":";AAAA;;GAEG;;;AAEH,2CAA0C;AAE1C;;;;;GAKG;AACH,MAAa,eAAgB,SAAQ,mBAAS;CAAG;AAAjD,0CAAiD"}
@@ -0,0 +1,467 @@
1
+ # Applications
2
+ (*applications*)
3
+
4
+ ## Overview
5
+
6
+ ### Available Operations
7
+
8
+ * [create](#create) - Create an application in the Financeable platform.
9
+ * [list](#list) - Retrieve a list of applications
10
+ * [get](#get) - Retrieve an application by its ID
11
+
12
+ ## create
13
+
14
+ Create an application in the Financeable platform.
15
+
16
+ ### Example Usage
17
+
18
+ ```typescript
19
+ import { Financeable } from "@financeable/aggregation";
20
+
21
+ const financeable = new Financeable();
22
+
23
+ async function run() {
24
+ const result = await financeable.applications.create({
25
+ data: {
26
+ type: "applications",
27
+ attributes: {
28
+ purpose: "Purchase of a motor vehicle",
29
+ applicationType: "consumer",
30
+ },
31
+ relationships: {
32
+ loanDetails: {
33
+ data: {
34
+ type: "loan-details",
35
+ attributes: {
36
+ repayments: 12,
37
+ repaymentFrequency: "monthly",
38
+ repaymentStructure: "group-payments",
39
+ loanAmount: "10280.95",
40
+ purpose: "Purchase of a motor vehicle",
41
+ term: 48,
42
+ balloon: 5,
43
+ deposit: "2500",
44
+ originationFee: 200,
45
+ rate: "0.15",
46
+ rateAdjustment: "-0.01",
47
+ },
48
+ },
49
+ },
50
+ customers: {
51
+ data: [
52
+ {
53
+ id: "<id>",
54
+ type: "customers",
55
+ attributes: {
56
+ title: "Mr",
57
+ firstName: "John",
58
+ lastName: "Smith",
59
+ dateOfBirth: "01-01-1990",
60
+ idExpiryDate: "01-01-2025",
61
+ idType: "licence",
62
+ idNumber: "12345678",
63
+ },
64
+ relationships: {
65
+ addresses: {
66
+ data: [
67
+ {
68
+ id: "<id>",
69
+ type: "addresses",
70
+ attributes: {
71
+ addressType: "residential",
72
+ fullAddress: "42 Wallaby Way, Sydney NSW 2000",
73
+ city: "Sydney",
74
+ postCode: "2000",
75
+ streetAddress: "42 Wallaby Way",
76
+ addressLine2: "",
77
+ streetNumber: "42",
78
+ streetType: "Way",
79
+ street: "Wallaby",
80
+ state: "NSW",
81
+ country: "Australia",
82
+ status: "current",
83
+ monthsAt: 24,
84
+ yearsAt: 2,
85
+ },
86
+ },
87
+ {
88
+ id: "<id>",
89
+ type: "addresses",
90
+ attributes: {
91
+ addressType: "residential",
92
+ fullAddress: "42 Wallaby Way, Sydney NSW 2000",
93
+ city: "Sydney",
94
+ postCode: "2000",
95
+ streetAddress: "42 Wallaby Way",
96
+ addressLine2: "",
97
+ streetNumber: "42",
98
+ streetType: "Way",
99
+ street: "Wallaby",
100
+ state: "NSW",
101
+ country: "Australia",
102
+ status: "current",
103
+ monthsAt: 24,
104
+ yearsAt: 2,
105
+ },
106
+ },
107
+ ],
108
+ },
109
+ },
110
+ },
111
+ ],
112
+ },
113
+ asset: {
114
+ data: {
115
+ id: "<id>",
116
+ type: "asset",
117
+ attributes: {
118
+ ageOfAsset: 3,
119
+ ageOfAssetAtEnd: 8,
120
+ condition: "USED",
121
+ assetType: "MOTOR_VEHICLE_(<4.5_TONNES)",
122
+ purpose: "VEHICLE",
123
+ assetValue: "35000.00",
124
+ make: "Toyota",
125
+ assetModel: "Camry",
126
+ registrationNumber: "ABC123",
127
+ registrationState: "VIC",
128
+ vin: "1HGCM82633A123456",
129
+ supplierName: "Mr and Mrs Smith",
130
+ supplierABN: "12345678901",
131
+ supplierAddress: "123 Car Street, Melbourne VIC 3000",
132
+ supplierPhone: "0412345678",
133
+ supplierContactName: "John Smith",
134
+ supplierEmail: "john.smith@mrandmrssmith.com.au",
135
+ privateSale: false,
136
+ typeOfSale: "DEALER",
137
+ description: "2020 Toyota Camry Hybrid SL, Silver, 45,000km",
138
+ netAssetValue: "32000.00",
139
+ isLuxury: false,
140
+ additionalFees: "995.00",
141
+ additionalTaxes: "0.00",
142
+ },
143
+ },
144
+ },
145
+ },
146
+ },
147
+ });
148
+
149
+ // Handle the result
150
+ console.log(result);
151
+ }
152
+
153
+ run();
154
+ ```
155
+
156
+ ### Standalone function
157
+
158
+ The standalone function version of this method:
159
+
160
+ ```typescript
161
+ import { FinanceableCore } from "@financeable/aggregation/core.js";
162
+ import { applicationsCreate } from "@financeable/aggregation/funcs/applicationsCreate.js";
163
+
164
+ // Use `FinanceableCore` for best tree-shaking performance.
165
+ // You can create one instance of it to use across an application.
166
+ const financeable = new FinanceableCore();
167
+
168
+ async function run() {
169
+ const res = await applicationsCreate(financeable, {
170
+ data: {
171
+ type: "applications",
172
+ attributes: {
173
+ purpose: "Purchase of a motor vehicle",
174
+ applicationType: "consumer",
175
+ },
176
+ relationships: {
177
+ loanDetails: {
178
+ data: {
179
+ type: "loan-details",
180
+ attributes: {
181
+ repayments: 12,
182
+ repaymentFrequency: "monthly",
183
+ repaymentStructure: "group-payments",
184
+ loanAmount: "10280.95",
185
+ purpose: "Purchase of a motor vehicle",
186
+ term: 48,
187
+ balloon: 5,
188
+ deposit: "2500",
189
+ originationFee: 200,
190
+ rate: "0.15",
191
+ rateAdjustment: "-0.01",
192
+ },
193
+ },
194
+ },
195
+ customers: {
196
+ data: [
197
+ {
198
+ id: "<id>",
199
+ type: "customers",
200
+ attributes: {
201
+ title: "Mr",
202
+ firstName: "John",
203
+ lastName: "Smith",
204
+ dateOfBirth: "01-01-1990",
205
+ idExpiryDate: "01-01-2025",
206
+ idType: "licence",
207
+ idNumber: "12345678",
208
+ },
209
+ relationships: {
210
+ addresses: {
211
+ data: [
212
+ {
213
+ id: "<id>",
214
+ type: "addresses",
215
+ attributes: {
216
+ addressType: "residential",
217
+ fullAddress: "42 Wallaby Way, Sydney NSW 2000",
218
+ city: "Sydney",
219
+ postCode: "2000",
220
+ streetAddress: "42 Wallaby Way",
221
+ addressLine2: "",
222
+ streetNumber: "42",
223
+ streetType: "Way",
224
+ street: "Wallaby",
225
+ state: "NSW",
226
+ country: "Australia",
227
+ status: "current",
228
+ monthsAt: 24,
229
+ yearsAt: 2,
230
+ },
231
+ },
232
+ {
233
+ id: "<id>",
234
+ type: "addresses",
235
+ attributes: {
236
+ addressType: "residential",
237
+ fullAddress: "42 Wallaby Way, Sydney NSW 2000",
238
+ city: "Sydney",
239
+ postCode: "2000",
240
+ streetAddress: "42 Wallaby Way",
241
+ addressLine2: "",
242
+ streetNumber: "42",
243
+ streetType: "Way",
244
+ street: "Wallaby",
245
+ state: "NSW",
246
+ country: "Australia",
247
+ status: "current",
248
+ monthsAt: 24,
249
+ yearsAt: 2,
250
+ },
251
+ },
252
+ ],
253
+ },
254
+ },
255
+ },
256
+ ],
257
+ },
258
+ asset: {
259
+ data: {
260
+ id: "<id>",
261
+ type: "asset",
262
+ attributes: {
263
+ ageOfAsset: 3,
264
+ ageOfAssetAtEnd: 8,
265
+ condition: "USED",
266
+ assetType: "MOTOR_VEHICLE_(<4.5_TONNES)",
267
+ purpose: "VEHICLE",
268
+ assetValue: "35000.00",
269
+ make: "Toyota",
270
+ assetModel: "Camry",
271
+ registrationNumber: "ABC123",
272
+ registrationState: "VIC",
273
+ vin: "1HGCM82633A123456",
274
+ supplierName: "Mr and Mrs Smith",
275
+ supplierABN: "12345678901",
276
+ supplierAddress: "123 Car Street, Melbourne VIC 3000",
277
+ supplierPhone: "0412345678",
278
+ supplierContactName: "John Smith",
279
+ supplierEmail: "john.smith@mrandmrssmith.com.au",
280
+ privateSale: false,
281
+ typeOfSale: "DEALER",
282
+ description: "2020 Toyota Camry Hybrid SL, Silver, 45,000km",
283
+ netAssetValue: "32000.00",
284
+ isLuxury: false,
285
+ additionalFees: "995.00",
286
+ additionalTaxes: "0.00",
287
+ },
288
+ },
289
+ },
290
+ },
291
+ },
292
+ });
293
+
294
+ if (!res.ok) {
295
+ throw res.error;
296
+ }
297
+
298
+ const { value: result } = res;
299
+
300
+ // Handle the result
301
+ console.log(result);
302
+ }
303
+
304
+ run();
305
+ ```
306
+
307
+ ### Parameters
308
+
309
+ | Parameter | Type | Required | Description |
310
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
311
+ | `request` | [components.ApplicationResourceBulkSubmission](../../models/components/applicationresourcebulksubmission.md) | :heavy_check_mark: | The request object to use for the request. |
312
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
313
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
314
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
315
+
316
+ ### Response
317
+
318
+ **Promise\<[operations.CreateApplicationResponseBody](../../models/operations/createapplicationresponsebody.md)\>**
319
+
320
+ ### Errors
321
+
322
+ | Error Type | Status Code | Content Type |
323
+ | ------------------------------------ | ------------------------------------ | ------------------------------------ |
324
+ | errors.CreateApplicationResponseBody | 403 | application/json |
325
+ | errors.APIError | 4XX, 5XX | \*/\* |
326
+
327
+ ## list
328
+
329
+ Retrieve a list of applications
330
+
331
+ ### Example Usage
332
+
333
+ ```typescript
334
+ import { Financeable } from "@financeable/aggregation";
335
+
336
+ const financeable = new Financeable();
337
+
338
+ async function run() {
339
+ const result = await financeable.applications.list({});
340
+
341
+ // Handle the result
342
+ console.log(result);
343
+ }
344
+
345
+ run();
346
+ ```
347
+
348
+ ### Standalone function
349
+
350
+ The standalone function version of this method:
351
+
352
+ ```typescript
353
+ import { FinanceableCore } from "@financeable/aggregation/core.js";
354
+ import { applicationsList } from "@financeable/aggregation/funcs/applicationsList.js";
355
+
356
+ // Use `FinanceableCore` for best tree-shaking performance.
357
+ // You can create one instance of it to use across an application.
358
+ const financeable = new FinanceableCore();
359
+
360
+ async function run() {
361
+ const res = await applicationsList(financeable, {});
362
+
363
+ if (!res.ok) {
364
+ throw res.error;
365
+ }
366
+
367
+ const { value: result } = res;
368
+
369
+ // Handle the result
370
+ console.log(result);
371
+ }
372
+
373
+ run();
374
+ ```
375
+
376
+ ### Parameters
377
+
378
+ | Parameter | Type | Required | Description |
379
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
380
+ | `request` | [operations.GetApplicationsRequest](../../models/operations/getapplicationsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
381
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
382
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
383
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
384
+
385
+ ### Response
386
+
387
+ **Promise\<[operations.GetApplicationsResponseBody](../../models/operations/getapplicationsresponsebody.md)\>**
388
+
389
+ ### Errors
390
+
391
+ | Error Type | Status Code | Content Type |
392
+ | ---------------------------------- | ---------------------------------- | ---------------------------------- |
393
+ | errors.GetApplicationsResponseBody | 403 | application/json |
394
+ | errors.APIError | 4XX, 5XX | \*/\* |
395
+
396
+ ## get
397
+
398
+ Retrieve an application by its ID
399
+
400
+ ### Example Usage
401
+
402
+ ```typescript
403
+ import { Financeable } from "@financeable/aggregation";
404
+
405
+ const financeable = new Financeable();
406
+
407
+ async function run() {
408
+ const result = await financeable.applications.get({
409
+ id: "<id>",
410
+ });
411
+
412
+ // Handle the result
413
+ console.log(result);
414
+ }
415
+
416
+ run();
417
+ ```
418
+
419
+ ### Standalone function
420
+
421
+ The standalone function version of this method:
422
+
423
+ ```typescript
424
+ import { FinanceableCore } from "@financeable/aggregation/core.js";
425
+ import { applicationsGet } from "@financeable/aggregation/funcs/applicationsGet.js";
426
+
427
+ // Use `FinanceableCore` for best tree-shaking performance.
428
+ // You can create one instance of it to use across an application.
429
+ const financeable = new FinanceableCore();
430
+
431
+ async function run() {
432
+ const res = await applicationsGet(financeable, {
433
+ id: "<id>",
434
+ });
435
+
436
+ if (!res.ok) {
437
+ throw res.error;
438
+ }
439
+
440
+ const { value: result } = res;
441
+
442
+ // Handle the result
443
+ console.log(result);
444
+ }
445
+
446
+ run();
447
+ ```
448
+
449
+ ### Parameters
450
+
451
+ | Parameter | Type | Required | Description |
452
+ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
453
+ | `request` | [operations.GetApplicationRequest](../../models/operations/getapplicationrequest.md) | :heavy_check_mark: | The request object to use for the request. |
454
+ | `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
455
+ | `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
456
+ | `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
457
+
458
+ ### Response
459
+
460
+ **Promise\<[operations.GetApplicationResponseBody](../../models/operations/getapplicationresponsebody.md)\>**
461
+
462
+ ### Errors
463
+
464
+ | Error Type | Status Code | Content Type |
465
+ | --------------------------------- | --------------------------------- | --------------------------------- |
466
+ | errors.GetApplicationResponseBody | 403 | application/json |
467
+ | errors.APIError | 4XX, 5XX | \*/\* |
@@ -0,0 +1,5 @@
1
+ # Financeable SDK
2
+
3
+ ## Overview
4
+
5
+ ### Available Operations
@@ -0,0 +1,30 @@
1
+
2
+ > **Remember to shutdown a GitHub Codespace when it is not in use!**
3
+
4
+ # Dev Containers Quick Start
5
+
6
+ The default location for usage snippets is the `samples` directory.
7
+
8
+ ## Running a Usage Sample
9
+
10
+ A sample usage example has been provided in a `root.ts` file. As you work with the SDK, it's expected that you will modify these samples to fit your needs. To execute this particular snippet, use the command below.
11
+
12
+ ```
13
+ ts-node root.ts
14
+ ```
15
+
16
+ ## Generating Additional Usage Samples
17
+
18
+ The speakeasy CLI allows you to generate more usage snippets. Here's how:
19
+
20
+ - To generate a sample for a specific operation by providing an operation ID, use:
21
+
22
+ ```
23
+ speakeasy generate usage -s ./spec.yaml -l typescript -i {INPUT_OPERATION_ID} -o ./samples
24
+ ```
25
+
26
+ - To generate samples for an entire namespace (like a tag or group name), use:
27
+
28
+ ```
29
+ speakeasy generate usage -s ./spec.yaml -l typescript -n {INPUT_TAG_NAME} -o ./samples
30
+ ```