postgrid-node 0.5.0 → 0.6.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (422) hide show
  1. package/CHANGELOG.md +84 -0
  2. package/LICENSE +1 -1
  3. package/README.md +13 -10
  4. package/client.d.mts +30 -10
  5. package/client.d.mts.map +1 -1
  6. package/client.d.ts +30 -10
  7. package/client.d.ts.map +1 -1
  8. package/client.js +56 -10
  9. package/client.js.map +1 -1
  10. package/client.mjs +57 -11
  11. package/client.mjs.map +1 -1
  12. package/internal/parse.d.mts.map +1 -1
  13. package/internal/parse.d.ts.map +1 -1
  14. package/internal/parse.js +5 -0
  15. package/internal/parse.js.map +1 -1
  16. package/internal/parse.mjs +5 -0
  17. package/internal/parse.mjs.map +1 -1
  18. package/internal/types.d.mts +6 -6
  19. package/internal/types.d.mts.map +1 -1
  20. package/internal/types.d.ts +6 -6
  21. package/internal/types.d.ts.map +1 -1
  22. package/internal/utils/env.js +2 -2
  23. package/internal/utils/env.js.map +1 -1
  24. package/internal/utils/env.mjs +2 -2
  25. package/internal/utils/env.mjs.map +1 -1
  26. package/internal/utils/log.d.mts.map +1 -1
  27. package/internal/utils/log.d.ts.map +1 -1
  28. package/internal/utils/log.js +3 -2
  29. package/internal/utils/log.js.map +1 -1
  30. package/internal/utils/log.mjs +3 -2
  31. package/internal/utils/log.mjs.map +1 -1
  32. package/internal/utils/query.d.mts +5 -0
  33. package/internal/utils/query.d.mts.map +1 -0
  34. package/internal/utils/query.d.ts +5 -0
  35. package/internal/utils/query.d.ts.map +1 -0
  36. package/internal/utils/query.js +23 -0
  37. package/internal/utils/query.js.map +1 -0
  38. package/internal/utils/query.mjs +20 -0
  39. package/internal/utils/query.mjs.map +1 -0
  40. package/internal/utils.d.mts +1 -0
  41. package/internal/utils.d.ts +1 -0
  42. package/internal/utils.js +1 -0
  43. package/internal/utils.js.map +1 -1
  44. package/internal/utils.mjs +1 -0
  45. package/package.json +7 -1
  46. package/resources/address-verification.d.mts +1689 -15
  47. package/resources/address-verification.d.mts.map +1 -1
  48. package/resources/address-verification.d.ts +1689 -15
  49. package/resources/address-verification.d.ts.map +1 -1
  50. package/resources/address-verification.js +200 -0
  51. package/resources/address-verification.js.map +1 -1
  52. package/resources/address-verification.mjs +200 -0
  53. package/resources/address-verification.mjs.map +1 -1
  54. package/resources/index.d.mts +3 -3
  55. package/resources/index.d.mts.map +1 -1
  56. package/resources/index.d.ts +3 -3
  57. package/resources/index.d.ts.map +1 -1
  58. package/resources/index.js.map +1 -1
  59. package/resources/index.mjs +1 -1
  60. package/resources/index.mjs.map +1 -1
  61. package/resources/intl-address-verification.d.mts +956 -35
  62. package/resources/intl-address-verification.d.mts.map +1 -1
  63. package/resources/intl-address-verification.d.ts +956 -35
  64. package/resources/intl-address-verification.d.ts.map +1 -1
  65. package/resources/intl-address-verification.js +121 -27
  66. package/resources/intl-address-verification.js.map +1 -1
  67. package/resources/intl-address-verification.mjs +121 -27
  68. package/resources/intl-address-verification.mjs.map +1 -1
  69. package/resources/print-mail/boxes.d.mts +995 -0
  70. package/resources/print-mail/boxes.d.mts.map +1 -0
  71. package/resources/print-mail/boxes.d.ts +995 -0
  72. package/resources/print-mail/boxes.d.ts.map +1 -0
  73. package/resources/print-mail/boxes.js +103 -0
  74. package/resources/print-mail/boxes.js.map +1 -0
  75. package/resources/print-mail/boxes.mjs +99 -0
  76. package/resources/print-mail/boxes.mjs.map +1 -0
  77. package/resources/print-mail/campaigns.d.mts +923 -34
  78. package/resources/print-mail/campaigns.d.mts.map +1 -1
  79. package/resources/print-mail/campaigns.d.ts +923 -34
  80. package/resources/print-mail/campaigns.d.ts.map +1 -1
  81. package/resources/print-mail/campaigns.js +10 -3
  82. package/resources/print-mail/campaigns.js.map +1 -1
  83. package/resources/print-mail/campaigns.mjs +10 -3
  84. package/resources/print-mail/campaigns.mjs.map +1 -1
  85. package/resources/print-mail/cheques.d.mts +35 -5
  86. package/resources/print-mail/cheques.d.mts.map +1 -1
  87. package/resources/print-mail/cheques.d.ts +35 -5
  88. package/resources/print-mail/cheques.d.ts.map +1 -1
  89. package/resources/print-mail/cheques.js +32 -0
  90. package/resources/print-mail/cheques.js.map +1 -1
  91. package/resources/print-mail/cheques.mjs +32 -0
  92. package/resources/print-mail/cheques.mjs.map +1 -1
  93. package/resources/print-mail/contacts.d.mts +138 -3
  94. package/resources/print-mail/contacts.d.mts.map +1 -1
  95. package/resources/print-mail/contacts.d.ts +138 -3
  96. package/resources/print-mail/contacts.d.ts.map +1 -1
  97. package/resources/print-mail/contacts.js.map +1 -1
  98. package/resources/print-mail/contacts.mjs.map +1 -1
  99. package/resources/print-mail/index.d.mts +12 -7
  100. package/resources/print-mail/index.d.mts.map +1 -1
  101. package/resources/print-mail/index.d.ts +12 -7
  102. package/resources/print-mail/index.d.ts.map +1 -1
  103. package/resources/print-mail/index.js +15 -5
  104. package/resources/print-mail/index.js.map +1 -1
  105. package/resources/print-mail/index.mjs +6 -1
  106. package/resources/print-mail/index.mjs.map +1 -1
  107. package/resources/print-mail/letters.d.mts +36 -6
  108. package/resources/print-mail/letters.d.mts.map +1 -1
  109. package/resources/print-mail/letters.d.ts +36 -6
  110. package/resources/print-mail/letters.d.ts.map +1 -1
  111. package/resources/print-mail/letters.js +32 -0
  112. package/resources/print-mail/letters.js.map +1 -1
  113. package/resources/print-mail/letters.mjs +32 -0
  114. package/resources/print-mail/letters.mjs.map +1 -1
  115. package/resources/print-mail/mailing-list-imports.d.mts +5 -1
  116. package/resources/print-mail/mailing-list-imports.d.mts.map +1 -1
  117. package/resources/print-mail/mailing-list-imports.d.ts +5 -1
  118. package/resources/print-mail/mailing-list-imports.d.ts.map +1 -1
  119. package/resources/print-mail/mailing-list-imports.js +4 -0
  120. package/resources/print-mail/mailing-list-imports.js.map +1 -1
  121. package/resources/print-mail/mailing-list-imports.mjs +4 -0
  122. package/resources/print-mail/mailing-list-imports.mjs.map +1 -1
  123. package/resources/print-mail/mailing-lists.d.mts +5 -1
  124. package/resources/print-mail/mailing-lists.d.mts.map +1 -1
  125. package/resources/print-mail/mailing-lists.d.ts +5 -1
  126. package/resources/print-mail/mailing-lists.d.ts.map +1 -1
  127. package/resources/print-mail/mailing-lists.js +4 -0
  128. package/resources/print-mail/mailing-lists.js.map +1 -1
  129. package/resources/print-mail/mailing-lists.mjs +4 -0
  130. package/resources/print-mail/mailing-lists.mjs.map +1 -1
  131. package/resources/print-mail/postcards.d.mts +63 -13
  132. package/resources/print-mail/postcards.d.mts.map +1 -1
  133. package/resources/print-mail/postcards.d.ts +63 -13
  134. package/resources/print-mail/postcards.d.ts.map +1 -1
  135. package/resources/print-mail/postcards.js +33 -0
  136. package/resources/print-mail/postcards.js.map +1 -1
  137. package/resources/print-mail/postcards.mjs +33 -0
  138. package/resources/print-mail/postcards.mjs.map +1 -1
  139. package/resources/print-mail/print-mail.d.mts +42 -159
  140. package/resources/print-mail/print-mail.d.mts.map +1 -1
  141. package/resources/print-mail/print-mail.d.ts +42 -159
  142. package/resources/print-mail/print-mail.d.ts.map +1 -1
  143. package/resources/print-mail/print-mail.js +36 -16
  144. package/resources/print-mail/print-mail.js.map +1 -1
  145. package/resources/print-mail/print-mail.mjs +36 -16
  146. package/resources/print-mail/print-mail.mjs.map +1 -1
  147. package/resources/print-mail/reports/exports.d.mts +7 -0
  148. package/resources/print-mail/reports/exports.d.mts.map +1 -1
  149. package/resources/print-mail/reports/exports.d.ts +7 -0
  150. package/resources/print-mail/reports/exports.d.ts.map +1 -1
  151. package/resources/print-mail/reports/exports.js +7 -0
  152. package/resources/print-mail/reports/exports.js.map +1 -1
  153. package/resources/print-mail/reports/exports.mjs +7 -0
  154. package/resources/print-mail/reports/exports.mjs.map +1 -1
  155. package/resources/print-mail/reports/reports.d.mts +7 -0
  156. package/resources/print-mail/reports/reports.d.mts.map +1 -1
  157. package/resources/print-mail/reports/reports.d.ts +7 -0
  158. package/resources/print-mail/reports/reports.d.ts.map +1 -1
  159. package/resources/print-mail/reports/reports.js +7 -0
  160. package/resources/print-mail/reports/reports.js.map +1 -1
  161. package/resources/print-mail/reports/reports.mjs +7 -0
  162. package/resources/print-mail/reports/reports.mjs.map +1 -1
  163. package/resources/print-mail/reports/samples.d.mts +7 -0
  164. package/resources/print-mail/reports/samples.d.mts.map +1 -1
  165. package/resources/print-mail/reports/samples.d.ts +7 -0
  166. package/resources/print-mail/reports/samples.d.ts.map +1 -1
  167. package/resources/print-mail/reports/samples.js +7 -0
  168. package/resources/print-mail/reports/samples.js.map +1 -1
  169. package/resources/print-mail/reports/samples.mjs +7 -0
  170. package/resources/print-mail/reports/samples.mjs.map +1 -1
  171. package/resources/print-mail/self-mailers.d.mts +25 -12
  172. package/resources/print-mail/self-mailers.d.mts.map +1 -1
  173. package/resources/print-mail/self-mailers.d.ts +25 -12
  174. package/resources/print-mail/self-mailers.d.ts.map +1 -1
  175. package/resources/print-mail/self-mailers.js +17 -0
  176. package/resources/print-mail/self-mailers.js.map +1 -1
  177. package/resources/print-mail/self-mailers.mjs +17 -0
  178. package/resources/print-mail/self-mailers.mjs.map +1 -1
  179. package/resources/print-mail/snap-packs.d.mts +1060 -0
  180. package/resources/print-mail/snap-packs.d.mts.map +1 -0
  181. package/resources/print-mail/snap-packs.d.ts +1060 -0
  182. package/resources/print-mail/snap-packs.d.ts.map +1 -0
  183. package/resources/print-mail/snap-packs.js +117 -0
  184. package/resources/print-mail/snap-packs.js.map +1 -0
  185. package/resources/print-mail/snap-packs.mjs +113 -0
  186. package/resources/print-mail/snap-packs.mjs.map +1 -0
  187. package/resources/print-mail/sub-organizations.d.mts +29 -17
  188. package/resources/print-mail/sub-organizations.d.mts.map +1 -1
  189. package/resources/print-mail/sub-organizations.d.ts +29 -17
  190. package/resources/print-mail/sub-organizations.d.ts.map +1 -1
  191. package/resources/print-mail/sub-organizations.js +26 -14
  192. package/resources/print-mail/sub-organizations.js.map +1 -1
  193. package/resources/print-mail/sub-organizations.mjs +26 -14
  194. package/resources/print-mail/sub-organizations.mjs.map +1 -1
  195. package/resources/print-mail/targeted-list-builds/filters.d.mts +92 -0
  196. package/resources/print-mail/targeted-list-builds/filters.d.mts.map +1 -0
  197. package/resources/print-mail/targeted-list-builds/filters.d.ts +92 -0
  198. package/resources/print-mail/targeted-list-builds/filters.d.ts.map +1 -0
  199. package/resources/print-mail/targeted-list-builds/filters.js +60 -0
  200. package/resources/print-mail/targeted-list-builds/filters.js.map +1 -0
  201. package/resources/print-mail/targeted-list-builds/filters.mjs +56 -0
  202. package/resources/print-mail/targeted-list-builds/filters.mjs.map +1 -0
  203. package/resources/print-mail/targeted-list-builds/index.d.mts +3 -0
  204. package/resources/print-mail/targeted-list-builds/index.d.mts.map +1 -0
  205. package/resources/print-mail/targeted-list-builds/index.d.ts +3 -0
  206. package/resources/print-mail/targeted-list-builds/index.d.ts.map +1 -0
  207. package/resources/print-mail/targeted-list-builds/index.js +9 -0
  208. package/resources/print-mail/targeted-list-builds/index.js.map +1 -0
  209. package/resources/print-mail/targeted-list-builds/index.mjs +4 -0
  210. package/resources/print-mail/targeted-list-builds/index.mjs.map +1 -0
  211. package/resources/print-mail/targeted-list-builds/targeted-list-builds.d.mts +1633 -0
  212. package/resources/print-mail/targeted-list-builds/targeted-list-builds.d.mts.map +1 -0
  213. package/resources/print-mail/targeted-list-builds/targeted-list-builds.d.ts +1633 -0
  214. package/resources/print-mail/targeted-list-builds/targeted-list-builds.d.ts.map +1 -0
  215. package/resources/print-mail/targeted-list-builds/targeted-list-builds.js +154 -0
  216. package/resources/print-mail/targeted-list-builds/targeted-list-builds.js.map +1 -0
  217. package/resources/print-mail/targeted-list-builds/targeted-list-builds.mjs +149 -0
  218. package/resources/print-mail/targeted-list-builds/targeted-list-builds.mjs.map +1 -0
  219. package/resources/print-mail/targeted-list-builds.d.mts +2 -0
  220. package/resources/print-mail/targeted-list-builds.d.mts.map +1 -0
  221. package/resources/print-mail/targeted-list-builds.d.ts +2 -0
  222. package/resources/print-mail/targeted-list-builds.d.ts.map +1 -0
  223. package/resources/print-mail/targeted-list-builds.js +6 -0
  224. package/resources/print-mail/targeted-list-builds.js.map +1 -0
  225. package/resources/print-mail/targeted-list-builds.mjs +3 -0
  226. package/resources/print-mail/targeted-list-builds.mjs.map +1 -0
  227. package/resources/print-mail/template-editor-sessions.d.mts +355 -0
  228. package/resources/print-mail/template-editor-sessions.d.mts.map +1 -0
  229. package/resources/print-mail/template-editor-sessions.d.ts +355 -0
  230. package/resources/print-mail/template-editor-sessions.d.ts.map +1 -0
  231. package/resources/print-mail/template-editor-sessions.js +78 -0
  232. package/resources/print-mail/template-editor-sessions.js.map +1 -0
  233. package/resources/print-mail/template-editor-sessions.mjs +74 -0
  234. package/resources/print-mail/template-editor-sessions.mjs.map +1 -0
  235. package/resources/print-mail/trackers.d.mts +409 -0
  236. package/resources/print-mail/trackers.d.mts.map +1 -0
  237. package/resources/print-mail/trackers.d.ts +409 -0
  238. package/resources/print-mail/trackers.d.ts.map +1 -0
  239. package/resources/print-mail/trackers.js +116 -0
  240. package/resources/print-mail/trackers.js.map +1 -0
  241. package/resources/print-mail/trackers.mjs +112 -0
  242. package/resources/print-mail/trackers.mjs.map +1 -0
  243. package/resources/print-mail/virtual-mailboxes/index.d.mts +3 -0
  244. package/resources/print-mail/virtual-mailboxes/index.d.mts.map +1 -0
  245. package/resources/print-mail/virtual-mailboxes/index.d.ts +3 -0
  246. package/resources/print-mail/virtual-mailboxes/index.d.ts.map +1 -0
  247. package/resources/print-mail/virtual-mailboxes/index.js +9 -0
  248. package/resources/print-mail/virtual-mailboxes/index.js.map +1 -0
  249. package/resources/print-mail/virtual-mailboxes/index.mjs +4 -0
  250. package/resources/print-mail/virtual-mailboxes/index.mjs.map +1 -0
  251. package/resources/print-mail/virtual-mailboxes/items.d.mts +235 -0
  252. package/resources/print-mail/virtual-mailboxes/items.d.mts.map +1 -0
  253. package/resources/print-mail/virtual-mailboxes/items.d.ts +235 -0
  254. package/resources/print-mail/virtual-mailboxes/items.d.ts.map +1 -0
  255. package/resources/print-mail/virtual-mailboxes/items.js +69 -0
  256. package/resources/print-mail/virtual-mailboxes/items.js.map +1 -0
  257. package/resources/print-mail/virtual-mailboxes/items.mjs +65 -0
  258. package/resources/print-mail/virtual-mailboxes/items.mjs.map +1 -0
  259. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.d.mts +334 -0
  260. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.d.mts.map +1 -0
  261. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.d.ts +334 -0
  262. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.d.ts.map +1 -0
  263. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.js +92 -0
  264. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.js.map +1 -0
  265. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.mjs +87 -0
  266. package/resources/print-mail/virtual-mailboxes/virtual-mailboxes.mjs.map +1 -0
  267. package/resources/print-mail/virtual-mailboxes.d.mts +2 -0
  268. package/resources/print-mail/virtual-mailboxes.d.mts.map +1 -0
  269. package/resources/print-mail/virtual-mailboxes.d.ts +2 -0
  270. package/resources/print-mail/virtual-mailboxes.d.ts.map +1 -0
  271. package/resources/print-mail/{order-profiles.js → virtual-mailboxes.js} +2 -2
  272. package/resources/print-mail/virtual-mailboxes.js.map +1 -0
  273. package/resources/print-mail/virtual-mailboxes.mjs +3 -0
  274. package/resources/print-mail/virtual-mailboxes.mjs.map +1 -0
  275. package/src/client.ts +116 -26
  276. package/src/internal/parse.ts +6 -0
  277. package/src/internal/types.ts +6 -8
  278. package/src/internal/utils/env.ts +2 -2
  279. package/src/internal/utils/log.ts +2 -1
  280. package/src/internal/utils/query.ts +23 -0
  281. package/src/internal/utils.ts +1 -0
  282. package/src/resources/address-verification.ts +2190 -24
  283. package/src/resources/index.ts +24 -5
  284. package/src/resources/intl-address-verification.ts +1219 -43
  285. package/src/resources/print-mail/boxes.ts +1324 -0
  286. package/src/resources/print-mail/campaigns.ts +1449 -59
  287. package/src/resources/print-mail/cheques.ts +42 -4
  288. package/src/resources/print-mail/contacts.ts +167 -4
  289. package/src/resources/print-mail/index.ts +79 -4
  290. package/src/resources/print-mail/letters.ts +43 -5
  291. package/src/resources/print-mail/mailing-list-imports.ts +5 -1
  292. package/src/resources/print-mail/mailing-lists.ts +5 -1
  293. package/src/resources/print-mail/postcards.ts +74 -12
  294. package/src/resources/print-mail/print-mail.ts +245 -239
  295. package/src/resources/print-mail/reports/exports.ts +7 -0
  296. package/src/resources/print-mail/reports/reports.ts +7 -0
  297. package/src/resources/print-mail/reports/samples.ts +7 -0
  298. package/src/resources/print-mail/self-mailers.ts +28 -12
  299. package/src/resources/print-mail/snap-packs.ts +1484 -0
  300. package/src/resources/print-mail/sub-organizations.ts +35 -23
  301. package/src/resources/print-mail/targeted-list-builds/filters.ts +113 -0
  302. package/src/resources/print-mail/targeted-list-builds/index.ts +16 -0
  303. package/src/resources/print-mail/targeted-list-builds/targeted-list-builds.ts +2158 -0
  304. package/{resources/print-mail/order-profiles.mjs → src/resources/print-mail/targeted-list-builds.ts} +2 -2
  305. package/src/resources/print-mail/template-editor-sessions.ts +435 -0
  306. package/src/resources/print-mail/trackers.ts +513 -0
  307. package/src/resources/print-mail/virtual-mailboxes/index.ts +22 -0
  308. package/src/resources/print-mail/virtual-mailboxes/items.ts +296 -0
  309. package/src/resources/print-mail/virtual-mailboxes/virtual-mailboxes.ts +434 -0
  310. package/src/resources/print-mail/{order-profiles.ts → virtual-mailboxes.ts} +1 -1
  311. package/src/version.ts +1 -1
  312. package/version.d.mts +1 -1
  313. package/version.d.ts +1 -1
  314. package/version.js +1 -1
  315. package/version.mjs +1 -1
  316. package/internal/qs/formats.d.mts +0 -7
  317. package/internal/qs/formats.d.mts.map +0 -1
  318. package/internal/qs/formats.d.ts +0 -7
  319. package/internal/qs/formats.d.ts.map +0 -1
  320. package/internal/qs/formats.js +0 -13
  321. package/internal/qs/formats.js.map +0 -1
  322. package/internal/qs/formats.mjs +0 -9
  323. package/internal/qs/formats.mjs.map +0 -1
  324. package/internal/qs/index.d.mts +0 -10
  325. package/internal/qs/index.d.mts.map +0 -1
  326. package/internal/qs/index.d.ts +0 -10
  327. package/internal/qs/index.d.ts.map +0 -1
  328. package/internal/qs/index.js +0 -14
  329. package/internal/qs/index.js.map +0 -1
  330. package/internal/qs/index.mjs +0 -10
  331. package/internal/qs/index.mjs.map +0 -1
  332. package/internal/qs/stringify.d.mts +0 -3
  333. package/internal/qs/stringify.d.mts.map +0 -1
  334. package/internal/qs/stringify.d.ts +0 -3
  335. package/internal/qs/stringify.d.ts.map +0 -1
  336. package/internal/qs/stringify.js +0 -277
  337. package/internal/qs/stringify.js.map +0 -1
  338. package/internal/qs/stringify.mjs +0 -274
  339. package/internal/qs/stringify.mjs.map +0 -1
  340. package/internal/qs/types.d.mts +0 -57
  341. package/internal/qs/types.d.mts.map +0 -1
  342. package/internal/qs/types.d.ts +0 -57
  343. package/internal/qs/types.d.ts.map +0 -1
  344. package/internal/qs/types.js +0 -3
  345. package/internal/qs/types.js.map +0 -1
  346. package/internal/qs/types.mjs +0 -2
  347. package/internal/qs/types.mjs.map +0 -1
  348. package/internal/qs/utils.d.mts +0 -15
  349. package/internal/qs/utils.d.mts.map +0 -1
  350. package/internal/qs/utils.d.ts +0 -15
  351. package/internal/qs/utils.d.ts.map +0 -1
  352. package/internal/qs/utils.js +0 -230
  353. package/internal/qs/utils.js.map +0 -1
  354. package/internal/qs/utils.mjs +0 -217
  355. package/internal/qs/utils.mjs.map +0 -1
  356. package/resources/print-mail/order-profiles/cheques.d.mts +0 -387
  357. package/resources/print-mail/order-profiles/cheques.d.mts.map +0 -1
  358. package/resources/print-mail/order-profiles/cheques.d.ts +0 -387
  359. package/resources/print-mail/order-profiles/cheques.d.ts.map +0 -1
  360. package/resources/print-mail/order-profiles/cheques.js +0 -98
  361. package/resources/print-mail/order-profiles/cheques.js.map +0 -1
  362. package/resources/print-mail/order-profiles/cheques.mjs +0 -94
  363. package/resources/print-mail/order-profiles/cheques.mjs.map +0 -1
  364. package/resources/print-mail/order-profiles/index.d.mts +0 -6
  365. package/resources/print-mail/order-profiles/index.d.mts.map +0 -1
  366. package/resources/print-mail/order-profiles/index.d.ts +0 -6
  367. package/resources/print-mail/order-profiles/index.d.ts.map +0 -1
  368. package/resources/print-mail/order-profiles/index.js +0 -15
  369. package/resources/print-mail/order-profiles/index.js.map +0 -1
  370. package/resources/print-mail/order-profiles/index.mjs +0 -7
  371. package/resources/print-mail/order-profiles/index.mjs.map +0 -1
  372. package/resources/print-mail/order-profiles/letters.d.mts +0 -324
  373. package/resources/print-mail/order-profiles/letters.d.mts.map +0 -1
  374. package/resources/print-mail/order-profiles/letters.d.ts +0 -324
  375. package/resources/print-mail/order-profiles/letters.d.ts.map +0 -1
  376. package/resources/print-mail/order-profiles/letters.js +0 -105
  377. package/resources/print-mail/order-profiles/letters.js.map +0 -1
  378. package/resources/print-mail/order-profiles/letters.mjs +0 -101
  379. package/resources/print-mail/order-profiles/letters.mjs.map +0 -1
  380. package/resources/print-mail/order-profiles/order-profiles.d.mts +0 -22
  381. package/resources/print-mail/order-profiles/order-profiles.d.mts.map +0 -1
  382. package/resources/print-mail/order-profiles/order-profiles.d.ts +0 -22
  383. package/resources/print-mail/order-profiles/order-profiles.d.ts.map +0 -1
  384. package/resources/print-mail/order-profiles/order-profiles.js +0 -29
  385. package/resources/print-mail/order-profiles/order-profiles.js.map +0 -1
  386. package/resources/print-mail/order-profiles/order-profiles.mjs +0 -24
  387. package/resources/print-mail/order-profiles/order-profiles.mjs.map +0 -1
  388. package/resources/print-mail/order-profiles/postcards.d.mts +0 -254
  389. package/resources/print-mail/order-profiles/postcards.d.mts.map +0 -1
  390. package/resources/print-mail/order-profiles/postcards.d.ts +0 -254
  391. package/resources/print-mail/order-profiles/postcards.d.ts.map +0 -1
  392. package/resources/print-mail/order-profiles/postcards.js +0 -97
  393. package/resources/print-mail/order-profiles/postcards.js.map +0 -1
  394. package/resources/print-mail/order-profiles/postcards.mjs +0 -93
  395. package/resources/print-mail/order-profiles/postcards.mjs.map +0 -1
  396. package/resources/print-mail/order-profiles/self-mailers.d.mts +0 -259
  397. package/resources/print-mail/order-profiles/self-mailers.d.mts.map +0 -1
  398. package/resources/print-mail/order-profiles/self-mailers.d.ts +0 -259
  399. package/resources/print-mail/order-profiles/self-mailers.d.ts.map +0 -1
  400. package/resources/print-mail/order-profiles/self-mailers.js +0 -95
  401. package/resources/print-mail/order-profiles/self-mailers.js.map +0 -1
  402. package/resources/print-mail/order-profiles/self-mailers.mjs +0 -91
  403. package/resources/print-mail/order-profiles/self-mailers.mjs.map +0 -1
  404. package/resources/print-mail/order-profiles.d.mts +0 -2
  405. package/resources/print-mail/order-profiles.d.mts.map +0 -1
  406. package/resources/print-mail/order-profiles.d.ts +0 -2
  407. package/resources/print-mail/order-profiles.d.ts.map +0 -1
  408. package/resources/print-mail/order-profiles.js.map +0 -1
  409. package/resources/print-mail/order-profiles.mjs.map +0 -1
  410. package/src/internal/qs/LICENSE.md +0 -13
  411. package/src/internal/qs/README.md +0 -3
  412. package/src/internal/qs/formats.ts +0 -10
  413. package/src/internal/qs/index.ts +0 -13
  414. package/src/internal/qs/stringify.ts +0 -385
  415. package/src/internal/qs/types.ts +0 -71
  416. package/src/internal/qs/utils.ts +0 -265
  417. package/src/resources/print-mail/order-profiles/cheques.ts +0 -589
  418. package/src/resources/print-mail/order-profiles/index.ts +0 -47
  419. package/src/resources/print-mail/order-profiles/letters.ts +0 -489
  420. package/src/resources/print-mail/order-profiles/order-profiles.ts +0 -113
  421. package/src/resources/print-mail/order-profiles/postcards.ts +0 -404
  422. package/src/resources/print-mail/order-profiles/self-mailers.ts +0 -415
package/CHANGELOG.md CHANGED
@@ -1,5 +1,89 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.6.1 (2026-05-14)
4
+
5
+ Full Changelog: [v0.6.0...v0.6.1](https://github.com/postgrid/postgrid-node/compare/v0.6.0...v0.6.1)
6
+
7
+ ### Chores
8
+
9
+ * update SDK settings ([de6da44](https://github.com/postgrid/postgrid-node/commit/de6da449bf818f26da3d68bde705fa9d850c63f3))
10
+
11
+ ## 0.6.0 (2026-05-13)
12
+
13
+ Full Changelog: [v0.5.2...v0.6.0](https://github.com/postgrid/postgrid-node/compare/v0.5.2...v0.6.0)
14
+
15
+ ### Features
16
+
17
+ * **api:** Generate OpenAPI spec from master, Complete AV endpoints, Deprecate order profiles ([67bb8b7](https://github.com/postgrid/postgrid-node/commit/67bb8b7333288443ffbf34c6de27d086affde747))
18
+ * **api:** sheikh's updates ([1fc2ef8](https://github.com/postgrid/postgrid-node/commit/1fc2ef827f76271263dacb177f3decaae8952f65))
19
+ * support setting headers via env ([4db92ef](https://github.com/postgrid/postgrid-node/commit/4db92ef57767c45c53cef4550eea6677e36b4bf7))
20
+ * Testing new GHA workflow ([08e8358](https://github.com/postgrid/postgrid-node/commit/08e8358dcd5e65f39d0f6d7271351af5211bd23f))
21
+
22
+
23
+ ### Chores
24
+
25
+ * **format:** run eslint and prettier separately ([cdad39f](https://github.com/postgrid/postgrid-node/commit/cdad39f28d68b35eabe04d8c0b5a6a186aa1e3b4))
26
+ * **formatter:** run prettier and eslint separately ([0e9df35](https://github.com/postgrid/postgrid-node/commit/0e9df3511c18468aa53b59d868a24f7d541a09d1))
27
+ * **internal:** codegen related update ([7fe5def](https://github.com/postgrid/postgrid-node/commit/7fe5def69f1a20ca7a915e4b489ae315d3816478))
28
+ * **internal:** more robust bootstrap script ([c8c6500](https://github.com/postgrid/postgrid-node/commit/c8c6500182176ce3706350b3d10ea47dd0c75f5d))
29
+ * redact api-key headers in debug logs ([0db98d1](https://github.com/postgrid/postgrid-node/commit/0db98d1fb30abbecca2a22afee2a44c397837f32))
30
+
31
+ ## 0.5.2 (2026-04-08)
32
+
33
+ Full Changelog: [v0.5.1...v0.5.2](https://github.com/postgrid/postgrid-node/compare/v0.5.1...v0.5.2)
34
+
35
+ ### Chores
36
+
37
+ * **internal:** codegen related update ([07b2754](https://github.com/postgrid/postgrid-node/commit/07b2754b6c9de728e5f5d54bb8e156911bbbd640))
38
+
39
+ ## 0.5.1 (2026-03-24)
40
+
41
+ Full Changelog: [v0.5.0...v0.5.1](https://github.com/postgrid/postgrid-node/compare/v0.5.0...v0.5.1)
42
+
43
+ ### Bug Fixes
44
+
45
+ * **client:** avoid memory leak with abort signals ([c27adce](https://github.com/postgrid/postgrid-node/commit/c27adced033eb5a2fcda3a2998f75edcdd7400a2))
46
+ * **client:** avoid removing abort listener too early ([b5b7d6e](https://github.com/postgrid/postgrid-node/commit/b5b7d6e89b3c118b2bb79cc58b357bc880a3ad54))
47
+ * **client:** preserve URL params already embedded in path ([24c231e](https://github.com/postgrid/postgrid-node/commit/24c231ed84c1e49315002c8e02fc14fa1d9b9a09))
48
+ * **docs/contributing:** correct pnpm link command ([6dbc868](https://github.com/postgrid/postgrid-node/commit/6dbc86804e251b99dcf2d8ccc951043a1e2cb71e))
49
+ * **docs:** remove extraneous example object fields ([71d6fdf](https://github.com/postgrid/postgrid-node/commit/71d6fdf04c36d6c86a07da4779c5a96ccada0f1d))
50
+ * fix request delays for retrying to be more respectful of high requested delays ([2949209](https://github.com/postgrid/postgrid-node/commit/29492093772c6e99d1e0d7454b94a9a78070e6ce))
51
+ * **mcp:** correct code tool API endpoint ([a69fda5](https://github.com/postgrid/postgrid-node/commit/a69fda59f36bdab6b0189a492a8fb8053939f412))
52
+ * **mcp:** return correct lines on typescript errors ([81982d6](https://github.com/postgrid/postgrid-node/commit/81982d6d50b27ef9a5580f7d0e178fc096e8ff4d))
53
+
54
+
55
+ ### Chores
56
+
57
+ * break long lines in snippets into multiline ([f66b5c2](https://github.com/postgrid/postgrid-node/commit/f66b5c28b18bb506d4cbed6667215af5a6eaa799))
58
+ * **ci:** skip lint on metadata-only changes ([ed86a3a](https://github.com/postgrid/postgrid-node/commit/ed86a3aa624697655e16cce359a3e1baae999777))
59
+ * **ci:** skip uploading artifacts on stainless-internal branches ([1164e40](https://github.com/postgrid/postgrid-node/commit/1164e4053e2fa237daa11f4df3113447c0455a5e))
60
+ * **ci:** upgrade `actions/github-script` ([ff6b463](https://github.com/postgrid/postgrid-node/commit/ff6b4638495611a098d8b035442944f2484d44fc))
61
+ * **client:** do not parse responses with empty content-length ([d619307](https://github.com/postgrid/postgrid-node/commit/d61930741f51c62e583f31074c1aa465c1e18207))
62
+ * **client:** fix logger property type ([c1592ab](https://github.com/postgrid/postgrid-node/commit/c1592ab37ba7aa9a1c3da022b42ba98b5aa189d0))
63
+ * **client:** restructure abort controller binding ([7f5512d](https://github.com/postgrid/postgrid-node/commit/7f5512d60ff37c68a839f80ef7d4df0bc363fb50))
64
+ * **docs:** add missing descriptions ([4df4baf](https://github.com/postgrid/postgrid-node/commit/4df4bafab42048bd31eb55ef5a6499f73925264f))
65
+ * fix typo in descriptions ([00cac03](https://github.com/postgrid/postgrid-node/commit/00cac03fae7750b0f627c2f15442de2d92711025))
66
+ * **internal/client:** fix form-urlencoded requests ([bc3444a](https://github.com/postgrid/postgrid-node/commit/bc3444a04024c65778a2611ea102e288665d40d5))
67
+ * **internal:** avoid type checking errors with ts-reset ([5457196](https://github.com/postgrid/postgrid-node/commit/5457196acf1411e4e2044338c74a8769f92abaaf))
68
+ * **internal:** codegen related update ([22d0aec](https://github.com/postgrid/postgrid-node/commit/22d0aec76590e53ab5da540e3f73406342a950ac))
69
+ * **internal:** codegen related update ([5c3a9b7](https://github.com/postgrid/postgrid-node/commit/5c3a9b79198ef3bc912462e1fb524819ffa8ef91))
70
+ * **internal:** codegen related update ([b90ade6](https://github.com/postgrid/postgrid-node/commit/b90ade6630f6f254eebe74ee16ca365a96759f87))
71
+ * **internal:** configure pnpm minimumReleaseAge to 1 day ([28aacd5](https://github.com/postgrid/postgrid-node/commit/28aacd557705eba61ee5ced975c1828d6f08f801))
72
+ * **internal:** fix pagination internals not accepting option promises ([69e80b4](https://github.com/postgrid/postgrid-node/commit/69e80b4dfe3447ec5a705c0e3f3f42f74c817bba))
73
+ * **internal:** move stringifyQuery implementation to internal function ([51e05e6](https://github.com/postgrid/postgrid-node/commit/51e05e6462aa5d1d14756495cb515b00a64fa84c))
74
+ * **internal:** remove mock server code ([cc0bca1](https://github.com/postgrid/postgrid-node/commit/cc0bca11e774882e65c8d5d8f9cbe0e12e76c7a6))
75
+ * **internal:** tweak CI branches ([2c3fddb](https://github.com/postgrid/postgrid-node/commit/2c3fddb40341708e5b84e9f6b56c51ad4facda22))
76
+ * **internal:** update `actions/checkout` version ([ec11eeb](https://github.com/postgrid/postgrid-node/commit/ec11eeb0c7c2332a07c7c88775e5b22305755abb))
77
+ * **internal:** update dependencies to address dependabot vulnerabilities ([b831c88](https://github.com/postgrid/postgrid-node/commit/b831c88574eed47b1f92a64a62a05bdf22036be2))
78
+ * **internal:** update gitignore ([ec3c14a](https://github.com/postgrid/postgrid-node/commit/ec3c14afa8bad62fa6b57d93763ee985cd975821))
79
+ * **internal:** update lock file ([e0ccd78](https://github.com/postgrid/postgrid-node/commit/e0ccd783e74a12ff4f48bee59ffb9119dfe69dfd))
80
+ * **internal:** upgrade babel, qs, js-yaml ([82d5417](https://github.com/postgrid/postgrid-node/commit/82d54171f2b0e60f84d8ce931df0dfcaa5b716a1))
81
+ * **internal:** upgrade brace-expansion and @babel/helpers ([c2e9be4](https://github.com/postgrid/postgrid-node/commit/c2e9be4f690eacaea859716658e99e53ea898d68))
82
+ * **internal:** upgrade eslint ([d4721a3](https://github.com/postgrid/postgrid-node/commit/d4721a3f0feeffa66fdcc698998d8714d208f6d4))
83
+ * **internal:** upgrade pnpm ([83c6be7](https://github.com/postgrid/postgrid-node/commit/83c6be7abe9b9d61d341fd8bb6f7d2b66bc9eb28))
84
+ * **internal:** upgrade pnpm version ([a425792](https://github.com/postgrid/postgrid-node/commit/a425792362a6a88464aa6ab49963fdac1a7f95dc))
85
+ * update mock server docs ([7fc0707](https://github.com/postgrid/postgrid-node/commit/7fc0707639e12f9915aaecd5b659ea3086e3f105))
86
+
3
87
  ## 0.5.0 (2025-11-14)
4
88
 
5
89
  Full Changelog: [v0.4.2...v0.5.0](https://github.com/postgrid/postgrid-node/compare/v0.4.2...v0.5.0)
package/LICENSE CHANGED
@@ -186,7 +186,7 @@
186
186
  same "printed page" as the copyright notice for easier
187
187
  identification within third-party archives.
188
188
 
189
- Copyright 2025 PostGrid
189
+ Copyright 2026 PostGrid
190
190
 
191
191
  Licensed under the Apache License, Version 2.0 (the "License");
192
192
  you may not use this file except in compliance with the License.
package/README.md CHANGED
@@ -46,7 +46,8 @@ const client = new PostGrid({
46
46
  });
47
47
 
48
48
  const params: PostGrid.AddressVerificationVerifyParams = { address: 'address' };
49
- const response: PostGrid.AddressVerificationVerifyResponse = await client.addressVerification.verify(params);
49
+ const response: PostGrid.AddressVerificationVerifyResponse =
50
+ await client.addressVerification.verify(params);
50
51
  ```
51
52
 
52
53
  Documentation for each method, request param, and response field are available in docstrings and will appear on hover in most modern editors.
@@ -59,15 +60,17 @@ a subclass of `APIError` will be thrown:
59
60
 
60
61
  <!-- prettier-ignore -->
61
62
  ```ts
62
- const response = await client.addressVerification.verify({ address: 'address' }).catch(async (err) => {
63
- if (err instanceof PostGrid.APIError) {
64
- console.log(err.status); // 400
65
- console.log(err.name); // BadRequestError
66
- console.log(err.headers); // {server: 'nginx', ...}
67
- } else {
68
- throw err;
69
- }
70
- });
63
+ const response = await client.addressVerification
64
+ .verify({ address: 'address' })
65
+ .catch(async (err) => {
66
+ if (err instanceof PostGrid.APIError) {
67
+ console.log(err.status); // 400
68
+ console.log(err.name); // BadRequestError
69
+ console.log(err.headers); // {server: 'nginx', ...}
70
+ } else {
71
+ throw err;
72
+ }
73
+ });
71
74
  ```
72
75
 
73
76
  Error codes are as follows:
package/client.d.mts CHANGED
@@ -8,9 +8,9 @@ import { type SkipLimitParams, SkipLimitResponse } from "./core/pagination.mjs";
8
8
  import * as Uploads from "./core/uploads.mjs";
9
9
  import * as API from "./resources/index.mjs";
10
10
  import { APIPromise } from "./core/api-promise.mjs";
11
- import { AddressVerification, AddressVerificationVerifyParams, AddressVerificationVerifyResponse, Errors as AddressVerificationAPIErrors, Status } from "./resources/address-verification.mjs";
12
- import { IntlAddressVerification, IntlAddressVerificationVerifyParams, IntlAddressVerificationVerifyResponse } from "./resources/intl-address-verification.mjs";
13
- import { ContactCreateWithCompanyName, ContactCreateWithFirstName, PrintMail } from "./resources/print-mail/print-mail.mjs";
11
+ import { AddressVerification, AddressVerificationAutocompleteParams, AddressVerificationAutocompleteResponse, AddressVerificationBatchVerificationParams, AddressVerificationBatchVerificationResponse, AddressVerificationGetAutocompletePreviewsParams, AddressVerificationGetAutocompletePreviewsResponse, AddressVerificationGetLookupInfoResponse, AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams, AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse, AddressVerificationLookupZipCodeFromCityOrStateParams, AddressVerificationLookupZipCodeFromCityOrStateResponse, AddressVerificationParseAnAddressParams, AddressVerificationParseAnAddressResponse, AddressVerificationSuggestAddressesParams, AddressVerificationSuggestAddressesResponse, AddressVerificationVerifyParams, AddressVerificationVerifyResponse, Errors as AddressVerificationAPIErrors, Status } from "./resources/address-verification.mjs";
12
+ import { IntlAddressVerification, IntlAddressVerificationAutocompleteParams, IntlAddressVerificationAutocompleteResponse, IntlAddressVerificationBatchVerificationParams, IntlAddressVerificationBatchVerificationResponse, IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams, IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse, IntlAddressVerificationGetAutocompletePreviewsParams, IntlAddressVerificationGetAutocompletePreviewsResponse, IntlAddressVerificationVerifyParams, IntlAddressVerificationVerifyResponse } from "./resources/intl-address-verification.mjs";
13
+ import { PrintMail } from "./resources/print-mail/print-mail.mjs";
14
14
  import { type Fetch } from "./internal/builtin-types.mjs";
15
15
  import { HeadersLike, NullableHeaders } from "./internal/headers.mjs";
16
16
  import { FinalRequestOptions, RequestOptions } from "./internal/request-options.mjs";
@@ -95,7 +95,7 @@ export declare class PostGrid {
95
95
  baseURL: string;
96
96
  maxRetries: number;
97
97
  timeout: number;
98
- logger: Logger | undefined;
98
+ logger: Logger;
99
99
  logLevel: LogLevel | undefined;
100
100
  fetchOptions: MergedRequestInit | undefined;
101
101
  private fetch;
@@ -124,7 +124,10 @@ export declare class PostGrid {
124
124
  protected authHeaders(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
125
125
  protected addressVerificationAPIKeyAuth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
126
126
  protected printMailAPIKeyAuth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
127
- protected stringifyQuery(query: Record<string, unknown>): string;
127
+ /**
128
+ * Basic re-implementation of `qs.stringify` for primitive types.
129
+ */
130
+ protected stringifyQuery(query: object | Record<string, unknown>): string;
128
131
  private getUserAgent;
129
132
  protected defaultIdempotencyKey(): string;
130
133
  protected makeStatusError(status: number, error: Object, message: string | undefined, headers: Headers): Errors.APIError;
@@ -151,8 +154,8 @@ export declare class PostGrid {
151
154
  private methodRequest;
152
155
  request<Rsp>(options: PromiseOrValue<FinalRequestOptions>, remainingRetries?: number | null): APIPromise<Rsp>;
153
156
  private makeRequest;
154
- getAPIList<Item, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(path: string, Page: new (...args: any[]) => PageClass, opts?: RequestOptions): Pagination.PagePromise<PageClass, Item>;
155
- requestAPIList<Item = unknown, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(Page: new (...args: ConstructorParameters<typeof Pagination.AbstractPage>) => PageClass, options: FinalRequestOptions): Pagination.PagePromise<PageClass, Item>;
157
+ getAPIList<Item, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(path: string, Page: new (...args: any[]) => PageClass, opts?: PromiseOrValue<RequestOptions>): Pagination.PagePromise<PageClass, Item>;
158
+ requestAPIList<Item = unknown, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(Page: new (...args: ConstructorParameters<typeof Pagination.AbstractPage>) => PageClass, options: PromiseOrValue<FinalRequestOptions>): Pagination.PagePromise<PageClass, Item>;
156
159
  fetchWithTimeout(url: RequestInfo, init: RequestInit | undefined, ms: number, controller: AbortController): Promise<Response>;
157
160
  private shouldRetry;
158
161
  private retryRequest;
@@ -165,6 +168,7 @@ export declare class PostGrid {
165
168
  timeout: number;
166
169
  }>;
167
170
  private buildHeaders;
171
+ private _makeAbort;
168
172
  private buildBody;
169
173
  static PostGrid: typeof PostGrid;
170
174
  static DEFAULT_TIMEOUT: number;
@@ -182,7 +186,23 @@ export declare class PostGrid {
182
186
  static PermissionDeniedError: typeof Errors.PermissionDeniedError;
183
187
  static UnprocessableEntityError: typeof Errors.UnprocessableEntityError;
184
188
  static toFile: typeof Uploads.toFile;
189
+ /**
190
+ * Standard Address Verification API.
191
+ *
192
+ * Provides endpoints to verify and standardize addresses across US and Canada,
193
+ * supporting both structured and freeform inputs.
194
+ *
195
+ * Note that this uses a different set of lookups than our international API.
196
+ *
197
+ */
185
198
  addressVerification: API.AddressVerification;
199
+ /**
200
+ * International Address Verification API.
201
+ *
202
+ * Provides endpoints to verify and standardize international addresses,
203
+ * supporting both structured and freeform inputs.
204
+ *
205
+ */
186
206
  intlAddressVerification: API.IntlAddressVerification;
187
207
  printMail: API.PrintMail;
188
208
  }
@@ -190,8 +210,8 @@ export declare namespace PostGrid {
190
210
  export type RequestOptions = Opts.RequestOptions;
191
211
  export import SkipLimit = Pagination.SkipLimit;
192
212
  export { type SkipLimitParams as SkipLimitParams, type SkipLimitResponse as SkipLimitResponse };
193
- export { AddressVerification as AddressVerification, type AddressVerificationAPIErrors as Errors, type Status as Status, type AddressVerificationVerifyResponse as AddressVerificationVerifyResponse, type AddressVerificationVerifyParams as AddressVerificationVerifyParams, };
194
- export { IntlAddressVerification as IntlAddressVerification, type IntlAddressVerificationVerifyResponse as IntlAddressVerificationVerifyResponse, type IntlAddressVerificationVerifyParams as IntlAddressVerificationVerifyParams, };
195
- export { PrintMail as PrintMail, type ContactCreateWithCompanyName as ContactCreateWithCompanyName, type ContactCreateWithFirstName as ContactCreateWithFirstName, };
213
+ export { AddressVerification as AddressVerification, type AddressVerificationAPIErrors as Errors, type Status as Status, type AddressVerificationAutocompleteResponse as AddressVerificationAutocompleteResponse, type AddressVerificationBatchVerificationResponse as AddressVerificationBatchVerificationResponse, type AddressVerificationGetAutocompletePreviewsResponse as AddressVerificationGetAutocompletePreviewsResponse, type AddressVerificationGetLookupInfoResponse as AddressVerificationGetLookupInfoResponse, type AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse as AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse, type AddressVerificationLookupZipCodeFromCityOrStateResponse as AddressVerificationLookupZipCodeFromCityOrStateResponse, type AddressVerificationParseAnAddressResponse as AddressVerificationParseAnAddressResponse, type AddressVerificationSuggestAddressesResponse as AddressVerificationSuggestAddressesResponse, type AddressVerificationVerifyResponse as AddressVerificationVerifyResponse, type AddressVerificationAutocompleteParams as AddressVerificationAutocompleteParams, type AddressVerificationBatchVerificationParams as AddressVerificationBatchVerificationParams, type AddressVerificationGetAutocompletePreviewsParams as AddressVerificationGetAutocompletePreviewsParams, type AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams as AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams, type AddressVerificationLookupZipCodeFromCityOrStateParams as AddressVerificationLookupZipCodeFromCityOrStateParams, type AddressVerificationParseAnAddressParams as AddressVerificationParseAnAddressParams, type AddressVerificationSuggestAddressesParams as AddressVerificationSuggestAddressesParams, type AddressVerificationVerifyParams as AddressVerificationVerifyParams, };
214
+ export { IntlAddressVerification as IntlAddressVerification, type IntlAddressVerificationAutocompleteResponse as IntlAddressVerificationAutocompleteResponse, type IntlAddressVerificationBatchVerificationResponse as IntlAddressVerificationBatchVerificationResponse, type IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse as IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse, type IntlAddressVerificationGetAutocompletePreviewsResponse as IntlAddressVerificationGetAutocompletePreviewsResponse, type IntlAddressVerificationVerifyResponse as IntlAddressVerificationVerifyResponse, type IntlAddressVerificationAutocompleteParams as IntlAddressVerificationAutocompleteParams, type IntlAddressVerificationBatchVerificationParams as IntlAddressVerificationBatchVerificationParams, type IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams as IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams, type IntlAddressVerificationGetAutocompletePreviewsParams as IntlAddressVerificationGetAutocompletePreviewsParams, type IntlAddressVerificationVerifyParams as IntlAddressVerificationVerifyParams, };
215
+ export { PrintMail as PrintMail };
196
216
  }
197
217
  //# sourceMappingURL=client.d.mts.map
package/client.d.mts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.mts","sourceRoot":"","sources":["src/client.ts"],"names":[],"mappings":"OAEO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAY;OAC3C,KAAK,EAAc,cAAc,EAAE,iBAAiB,EAAE,oBAAoB,EAAE;YAIvE,EAAE,MAAM,EAAE,QAAQ,EAAE;OAKzB,KAAK,IAAI;OAGT,KAAK,MAAM;OACX,KAAK,UAAU;OACf,EAAgB,KAAK,eAAe,EAAE,iBAAiB,EAAE;OACzD,KAAK,OAAO;OACZ,KAAK,GAAG;OACR,EAAE,UAAU,EAAE;OACd,EACL,mBAAmB,EACnB,+BAA+B,EAC/B,iCAAiC,EACjC,MAAM,IAAI,4BAA4B,EACtC,MAAM,EACP;OACM,EACL,uBAAuB,EACvB,mCAAmC,EACnC,qCAAqC,EACtC;OACM,EACL,4BAA4B,EAC5B,0BAA0B,EAC1B,SAAS,EACV;OACM,EAAE,KAAK,KAAK,EAAE;OACd,EAAE,WAAW,EAAE,eAAe,EAAgB;OAC9C,EAAE,mBAAmB,EAAE,cAAc,EAAE;OAEvC,EACL,KAAK,QAAQ,EACb,KAAK,MAAM,EAIZ;AAGD,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,yBAAy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AA4D,EACjI,KAAK,oDAAoD,IAAI,oDAAoD,EACjH,KAAK,mCAAmC,IAAI,mCAAmC,GAChF,CAAC;IAEF,OAAO,EAAE,SAAS,IAAI,SAAS,EAAE,CAAC;CACnC"}
package/client.d.ts CHANGED
@@ -8,9 +8,9 @@ import { type SkipLimitParams, SkipLimitResponse } from "./core/pagination.js";
8
8
  import * as Uploads from "./core/uploads.js";
9
9
  import * as API from "./resources/index.js";
10
10
  import { APIPromise } from "./core/api-promise.js";
11
- import { AddressVerification, AddressVerificationVerifyParams, AddressVerificationVerifyResponse, Errors as AddressVerificationAPIErrors, Status } from "./resources/address-verification.js";
12
- import { IntlAddressVerification, IntlAddressVerificationVerifyParams, IntlAddressVerificationVerifyResponse } from "./resources/intl-address-verification.js";
13
- import { ContactCreateWithCompanyName, ContactCreateWithFirstName, PrintMail } from "./resources/print-mail/print-mail.js";
11
+ import { AddressVerification, AddressVerificationAutocompleteParams, AddressVerificationAutocompleteResponse, AddressVerificationBatchVerificationParams, AddressVerificationBatchVerificationResponse, AddressVerificationGetAutocompletePreviewsParams, AddressVerificationGetAutocompletePreviewsResponse, AddressVerificationGetLookupInfoResponse, AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams, AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse, AddressVerificationLookupZipCodeFromCityOrStateParams, AddressVerificationLookupZipCodeFromCityOrStateResponse, AddressVerificationParseAnAddressParams, AddressVerificationParseAnAddressResponse, AddressVerificationSuggestAddressesParams, AddressVerificationSuggestAddressesResponse, AddressVerificationVerifyParams, AddressVerificationVerifyResponse, Errors as AddressVerificationAPIErrors, Status } from "./resources/address-verification.js";
12
+ import { IntlAddressVerification, IntlAddressVerificationAutocompleteParams, IntlAddressVerificationAutocompleteResponse, IntlAddressVerificationBatchVerificationParams, IntlAddressVerificationBatchVerificationResponse, IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams, IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse, IntlAddressVerificationGetAutocompletePreviewsParams, IntlAddressVerificationGetAutocompletePreviewsResponse, IntlAddressVerificationVerifyParams, IntlAddressVerificationVerifyResponse } from "./resources/intl-address-verification.js";
13
+ import { PrintMail } from "./resources/print-mail/print-mail.js";
14
14
  import { type Fetch } from "./internal/builtin-types.js";
15
15
  import { HeadersLike, NullableHeaders } from "./internal/headers.js";
16
16
  import { FinalRequestOptions, RequestOptions } from "./internal/request-options.js";
@@ -95,7 +95,7 @@ export declare class PostGrid {
95
95
  baseURL: string;
96
96
  maxRetries: number;
97
97
  timeout: number;
98
- logger: Logger | undefined;
98
+ logger: Logger;
99
99
  logLevel: LogLevel | undefined;
100
100
  fetchOptions: MergedRequestInit | undefined;
101
101
  private fetch;
@@ -124,7 +124,10 @@ export declare class PostGrid {
124
124
  protected authHeaders(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
125
125
  protected addressVerificationAPIKeyAuth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
126
126
  protected printMailAPIKeyAuth(opts: FinalRequestOptions): Promise<NullableHeaders | undefined>;
127
- protected stringifyQuery(query: Record<string, unknown>): string;
127
+ /**
128
+ * Basic re-implementation of `qs.stringify` for primitive types.
129
+ */
130
+ protected stringifyQuery(query: object | Record<string, unknown>): string;
128
131
  private getUserAgent;
129
132
  protected defaultIdempotencyKey(): string;
130
133
  protected makeStatusError(status: number, error: Object, message: string | undefined, headers: Headers): Errors.APIError;
@@ -151,8 +154,8 @@ export declare class PostGrid {
151
154
  private methodRequest;
152
155
  request<Rsp>(options: PromiseOrValue<FinalRequestOptions>, remainingRetries?: number | null): APIPromise<Rsp>;
153
156
  private makeRequest;
154
- getAPIList<Item, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(path: string, Page: new (...args: any[]) => PageClass, opts?: RequestOptions): Pagination.PagePromise<PageClass, Item>;
155
- requestAPIList<Item = unknown, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(Page: new (...args: ConstructorParameters<typeof Pagination.AbstractPage>) => PageClass, options: FinalRequestOptions): Pagination.PagePromise<PageClass, Item>;
157
+ getAPIList<Item, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(path: string, Page: new (...args: any[]) => PageClass, opts?: PromiseOrValue<RequestOptions>): Pagination.PagePromise<PageClass, Item>;
158
+ requestAPIList<Item = unknown, PageClass extends Pagination.AbstractPage<Item> = Pagination.AbstractPage<Item>>(Page: new (...args: ConstructorParameters<typeof Pagination.AbstractPage>) => PageClass, options: PromiseOrValue<FinalRequestOptions>): Pagination.PagePromise<PageClass, Item>;
156
159
  fetchWithTimeout(url: RequestInfo, init: RequestInit | undefined, ms: number, controller: AbortController): Promise<Response>;
157
160
  private shouldRetry;
158
161
  private retryRequest;
@@ -165,6 +168,7 @@ export declare class PostGrid {
165
168
  timeout: number;
166
169
  }>;
167
170
  private buildHeaders;
171
+ private _makeAbort;
168
172
  private buildBody;
169
173
  static PostGrid: typeof PostGrid;
170
174
  static DEFAULT_TIMEOUT: number;
@@ -182,7 +186,23 @@ export declare class PostGrid {
182
186
  static PermissionDeniedError: typeof Errors.PermissionDeniedError;
183
187
  static UnprocessableEntityError: typeof Errors.UnprocessableEntityError;
184
188
  static toFile: typeof Uploads.toFile;
189
+ /**
190
+ * Standard Address Verification API.
191
+ *
192
+ * Provides endpoints to verify and standardize addresses across US and Canada,
193
+ * supporting both structured and freeform inputs.
194
+ *
195
+ * Note that this uses a different set of lookups than our international API.
196
+ *
197
+ */
185
198
  addressVerification: API.AddressVerification;
199
+ /**
200
+ * International Address Verification API.
201
+ *
202
+ * Provides endpoints to verify and standardize international addresses,
203
+ * supporting both structured and freeform inputs.
204
+ *
205
+ */
186
206
  intlAddressVerification: API.IntlAddressVerification;
187
207
  printMail: API.PrintMail;
188
208
  }
@@ -190,8 +210,8 @@ export declare namespace PostGrid {
190
210
  export type RequestOptions = Opts.RequestOptions;
191
211
  export import SkipLimit = Pagination.SkipLimit;
192
212
  export { type SkipLimitParams as SkipLimitParams, type SkipLimitResponse as SkipLimitResponse };
193
- export { AddressVerification as AddressVerification, type AddressVerificationAPIErrors as Errors, type Status as Status, type AddressVerificationVerifyResponse as AddressVerificationVerifyResponse, type AddressVerificationVerifyParams as AddressVerificationVerifyParams, };
194
- export { IntlAddressVerification as IntlAddressVerification, type IntlAddressVerificationVerifyResponse as IntlAddressVerificationVerifyResponse, type IntlAddressVerificationVerifyParams as IntlAddressVerificationVerifyParams, };
195
- export { PrintMail as PrintMail, type ContactCreateWithCompanyName as ContactCreateWithCompanyName, type ContactCreateWithFirstName as ContactCreateWithFirstName, };
213
+ export { AddressVerification as AddressVerification, type AddressVerificationAPIErrors as Errors, type Status as Status, type AddressVerificationAutocompleteResponse as AddressVerificationAutocompleteResponse, type AddressVerificationBatchVerificationResponse as AddressVerificationBatchVerificationResponse, type AddressVerificationGetAutocompletePreviewsResponse as AddressVerificationGetAutocompletePreviewsResponse, type AddressVerificationGetLookupInfoResponse as AddressVerificationGetLookupInfoResponse, type AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse as AddressVerificationLookupCityOrStateFromPostalOrZipCodeResponse, type AddressVerificationLookupZipCodeFromCityOrStateResponse as AddressVerificationLookupZipCodeFromCityOrStateResponse, type AddressVerificationParseAnAddressResponse as AddressVerificationParseAnAddressResponse, type AddressVerificationSuggestAddressesResponse as AddressVerificationSuggestAddressesResponse, type AddressVerificationVerifyResponse as AddressVerificationVerifyResponse, type AddressVerificationAutocompleteParams as AddressVerificationAutocompleteParams, type AddressVerificationBatchVerificationParams as AddressVerificationBatchVerificationParams, type AddressVerificationGetAutocompletePreviewsParams as AddressVerificationGetAutocompletePreviewsParams, type AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams as AddressVerificationLookupCityOrStateFromPostalOrZipCodeParams, type AddressVerificationLookupZipCodeFromCityOrStateParams as AddressVerificationLookupZipCodeFromCityOrStateParams, type AddressVerificationParseAnAddressParams as AddressVerificationParseAnAddressParams, type AddressVerificationSuggestAddressesParams as AddressVerificationSuggestAddressesParams, type AddressVerificationVerifyParams as AddressVerificationVerifyParams, };
214
+ export { IntlAddressVerification as IntlAddressVerification, type IntlAddressVerificationAutocompleteResponse as IntlAddressVerificationAutocompleteResponse, type IntlAddressVerificationBatchVerificationResponse as IntlAddressVerificationBatchVerificationResponse, type IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse as IntlAddressVerificationGetAutocompleteAdvancedPreviewsResponse, type IntlAddressVerificationGetAutocompletePreviewsResponse as IntlAddressVerificationGetAutocompletePreviewsResponse, type IntlAddressVerificationVerifyResponse as IntlAddressVerificationVerifyResponse, type IntlAddressVerificationAutocompleteParams as IntlAddressVerificationAutocompleteParams, type IntlAddressVerificationBatchVerificationParams as IntlAddressVerificationBatchVerificationParams, type IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams as IntlAddressVerificationGetAutocompleteAdvancedPreviewsParams, type IntlAddressVerificationGetAutocompletePreviewsParams as IntlAddressVerificationGetAutocompletePreviewsParams, type IntlAddressVerificationVerifyParams as IntlAddressVerificationVerifyParams, };
215
+ export { PrintMail as PrintMail };
196
216
  }
197
217
  //# sourceMappingURL=client.d.ts.map
package/client.d.ts.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["src/client.ts"],"names":[],"mappings":"OAEO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAY;OAC3C,KAAK,EAAc,cAAc,EAAE,iBAAiB,EAAE,oBAAoB,EAAE;YAIvE,EAAE,MAAM,EAAE,QAAQ,EAAE;OAKzB,KAAK,IAAI;OAGT,KAAK,MAAM;OACX,KAAK,UAAU;OACf,EAAgB,KAAK,eAAe,EAAE,iBAAiB,EAAE;OACzD,KAAK,OAAO;OACZ,KAAK,GAAG;OACR,EAAE,UAAU,EAAE;OACd,EACL,mBAAmB,EACnB,+BAA+B,EAC/B,iCAAiC,EACjC,MAAM,IAAI,4BAA4B,EACtC,MAAM,EACP;OACM,EACL,uBAAuB,EACvB,mCA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AuB,EAClD,KAAK,2CAA2C,IAAI,2CAA2C,EAC/F,KAAK,gDAAgD,IAAI,gDAAgD,EACzG,KAAK,8DAA8D,IAAI,8DAA8D,EACrI,KAAK,sDAAsD,IAAI,sDAAsD,EACrH,KAAK,qCAAqC,IAAI,qCAAqC,EACnF,KAAK,yCAAyC,IAAI,yCAAyC,EAC3F,KAAK,8CAA8C,IAAI,8CAA8C,EACrG,KAAK,4DAA4D,IAAI,4DAA4D,EACjI,KAAK,oDAAoD,IAAI,oDAAoD,EACjH,KAAK,mCAAmC,IAAI,mCAAmC,GAChF,CAAC;IAEF,OAAO,EAAE,SAAS,IAAI,SAAS,EAAE,CAAC;CACnC"}
package/client.js CHANGED
@@ -11,7 +11,7 @@ const errors_1 = require("./internal/errors.js");
11
11
  const detect_platform_1 = require("./internal/detect-platform.js");
12
12
  const Shims = tslib_1.__importStar(require("./internal/shims.js"));
13
13
  const Opts = tslib_1.__importStar(require("./internal/request-options.js"));
14
- const qs = tslib_1.__importStar(require("./internal/qs/index.js"));
14
+ const query_1 = require("./internal/utils/query.js");
15
15
  const version_1 = require("./version.js");
16
16
  const Errors = tslib_1.__importStar(require("./core/error.js"));
17
17
  const Pagination = tslib_1.__importStar(require("./core/pagination.js"));
@@ -45,7 +45,23 @@ class PostGrid {
45
45
  constructor({ baseURL = (0, env_1.readEnv)('POSTGRID_BASE_URL'), addressVerificationAPIKey = (0, env_1.readEnv)('POSTGRID_ADDRESS_VERIFICATION_API_KEY') ?? null, printMailAPIKey = (0, env_1.readEnv)('POSTGRID_PRINT_MAIL_API_KEY') ?? null, ...opts } = {}) {
46
46
  _PostGrid_instances.add(this);
47
47
  _PostGrid_encoder.set(this, void 0);
48
+ /**
49
+ * Standard Address Verification API.
50
+ *
51
+ * Provides endpoints to verify and standardize addresses across US and Canada,
52
+ * supporting both structured and freeform inputs.
53
+ *
54
+ * Note that this uses a different set of lookups than our international API.
55
+ *
56
+ */
48
57
  this.addressVerification = new API.AddressVerification(this);
58
+ /**
59
+ * International Address Verification API.
60
+ *
61
+ * Provides endpoints to verify and standardize international addresses,
62
+ * supporting both structured and freeform inputs.
63
+ *
64
+ */
49
65
  this.intlAddressVerification = new API.IntlAddressVerification(this);
50
66
  this.printMail = new API.PrintMail(this);
51
67
  const options = {
@@ -68,6 +84,17 @@ class PostGrid {
68
84
  this.maxRetries = options.maxRetries ?? 2;
69
85
  this.fetch = options.fetch ?? Shims.getDefaultFetch();
70
86
  tslib_1.__classPrivateFieldSet(this, _PostGrid_encoder, Opts.FallbackEncoder, "f");
87
+ const customHeadersEnv = (0, env_1.readEnv)('POSTGRID_CUSTOM_HEADERS');
88
+ if (customHeadersEnv) {
89
+ const parsed = {};
90
+ for (const line of customHeadersEnv.split('\n')) {
91
+ const colon = line.indexOf(':');
92
+ if (colon >= 0) {
93
+ parsed[line.substring(0, colon).trim()] = line.substring(colon + 1).trim();
94
+ }
95
+ }
96
+ options.defaultHeaders = { ...parsed, ...options.defaultHeaders };
97
+ }
71
98
  this._options = options;
72
99
  this.addressVerificationAPIKey = addressVerificationAPIKey;
73
100
  this.printMailAPIKey = printMailAPIKey;
@@ -127,8 +154,11 @@ class PostGrid {
127
154
  }
128
155
  return (0, headers_1.buildHeaders)([{ 'X-API-Key': this.printMailAPIKey }]);
129
156
  }
157
+ /**
158
+ * Basic re-implementation of `qs.stringify` for primitive types.
159
+ */
130
160
  stringifyQuery(query) {
131
- return qs.stringify(query, { arrayFormat: 'comma' });
161
+ return (0, query_1.stringifyQuery)(query);
132
162
  }
133
163
  getUserAgent() {
134
164
  return `${this.constructor.name}/JS ${version_1.VERSION}`;
@@ -145,8 +175,9 @@ class PostGrid {
145
175
  new URL(path)
146
176
  : new URL(baseURL + (baseURL.endsWith('/') && path.startsWith('/') ? path.slice(1) : path));
147
177
  const defaultQuery = this.defaultQuery();
148
- if (!(0, values_2.isEmptyObj)(defaultQuery)) {
149
- query = { ...defaultQuery, ...query };
178
+ const pathQuery = Object.fromEntries(url.searchParams);
179
+ if (!(0, values_2.isEmptyObj)(defaultQuery) || !(0, values_2.isEmptyObj)(pathQuery)) {
180
+ query = { ...pathQuery, ...defaultQuery, ...query };
150
181
  }
151
182
  if (typeof query === 'object' && query && !Array.isArray(query)) {
152
183
  url.search = this.stringifyQuery(query);
@@ -302,7 +333,9 @@ class PostGrid {
302
333
  return { response, options, controller, requestLogID, retryOfRequestLogID, startTime };
303
334
  }
304
335
  getAPIList(path, Page, opts) {
305
- return this.requestAPIList(Page, { method: 'get', path, ...opts });
336
+ return this.requestAPIList(Page, opts && 'then' in opts ?
337
+ opts.then((opts) => ({ method: 'get', path, ...opts }))
338
+ : { method: 'get', path, ...opts });
306
339
  }
307
340
  requestAPIList(Page, options) {
308
341
  const request = this.makeRequest(options, null, undefined);
@@ -310,9 +343,10 @@ class PostGrid {
310
343
  }
311
344
  async fetchWithTimeout(url, init, ms, controller) {
312
345
  const { signal, method, ...options } = init || {};
346
+ const abort = this._makeAbort(controller);
313
347
  if (signal)
314
- signal.addEventListener('abort', () => controller.abort());
315
- const timeout = setTimeout(() => controller.abort(), ms);
348
+ signal.addEventListener('abort', abort, { once: true });
349
+ const timeout = setTimeout(abort, ms);
316
350
  const isReadableBody = (globalThis.ReadableStream && options.body instanceof globalThis.ReadableStream) ||
317
351
  (typeof options.body === 'object' && options.body !== null && Symbol.asyncIterator in options.body);
318
352
  const fetchOptions = {
@@ -377,9 +411,9 @@ class PostGrid {
377
411
  timeoutMillis = Date.parse(retryAfterHeader) - Date.now();
378
412
  }
379
413
  }
380
- // If the API asks us to wait a certain amount of time (and it's a reasonable amount),
381
- // just do what it says, but otherwise calculate a default
382
- if (!(timeoutMillis && 0 <= timeoutMillis && timeoutMillis < 60 * 1000)) {
414
+ // If the API asks us to wait a certain amount of time, just do what it
415
+ // says, but otherwise calculate a default
416
+ if (timeoutMillis === undefined) {
383
417
  const maxRetries = options.maxRetries ?? this.maxRetries;
384
418
  timeoutMillis = this.calculateDefaultRetryTimeoutMillis(retriesRemaining, maxRetries);
385
419
  }
@@ -441,6 +475,11 @@ class PostGrid {
441
475
  this.validateHeaders(headers);
442
476
  return headers.values;
443
477
  }
478
+ _makeAbort(controller) {
479
+ // note: we can't just inline this method inside `fetchWithTimeout()` because then the closure
480
+ // would capture all request options, and cause a memory leak.
481
+ return () => controller.abort();
482
+ }
444
483
  buildBody({ options: { body, headers: rawHeaders } }) {
445
484
  if (!body) {
446
485
  return { bodyHeaders: undefined, body: undefined };
@@ -469,6 +508,13 @@ class PostGrid {
469
508
  (Symbol.iterator in body && 'next' in body && typeof body.next === 'function'))) {
470
509
  return { bodyHeaders: undefined, body: Shims.ReadableStreamFrom(body) };
471
510
  }
511
+ else if (typeof body === 'object' &&
512
+ headers.values.get('content-type') === 'application/x-www-form-urlencoded') {
513
+ return {
514
+ bodyHeaders: { 'content-type': 'application/x-www-form-urlencoded' },
515
+ body: this.stringifyQuery(body),
516
+ };
517
+ }
472
518
  else {
473
519
  return tslib_1.__classPrivateFieldGet(this, _PostGrid_encoder, "f").call(this, { body, headers });
474
520
  }