@postpeer/node 0.7.0 → 0.8.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 (468) hide show
  1. package/CHANGELOG.md +7 -128
  2. package/LICENSE +1 -1
  3. package/README.md +92 -314
  4. package/dist/index.cjs +1709 -0
  5. package/dist/index.cjs.map +1 -0
  6. package/dist/index.d.cts +3484 -0
  7. package/dist/index.d.ts +3484 -0
  8. package/dist/index.js +1690 -0
  9. package/dist/index.js.map +1 -0
  10. package/package.json +58 -131
  11. package/api-promise.d.mts +0 -3
  12. package/api-promise.d.mts.map +0 -1
  13. package/api-promise.d.ts +0 -3
  14. package/api-promise.d.ts.map +0 -1
  15. package/api-promise.js +0 -6
  16. package/api-promise.js.map +0 -1
  17. package/api-promise.mjs +0 -3
  18. package/api-promise.mjs.map +0 -1
  19. package/client.d.mts +0 -190
  20. package/client.d.mts.map +0 -1
  21. package/client.d.ts +0 -190
  22. package/client.d.ts.map +0 -1
  23. package/client.js +0 -485
  24. package/client.js.map +0 -1
  25. package/client.mjs +0 -481
  26. package/client.mjs.map +0 -1
  27. package/core/api-promise.d.mts +0 -46
  28. package/core/api-promise.d.mts.map +0 -1
  29. package/core/api-promise.d.ts +0 -46
  30. package/core/api-promise.d.ts.map +0 -1
  31. package/core/api-promise.js +0 -74
  32. package/core/api-promise.js.map +0 -1
  33. package/core/api-promise.mjs +0 -70
  34. package/core/api-promise.mjs.map +0 -1
  35. package/core/error.d.mts +0 -46
  36. package/core/error.d.mts.map +0 -1
  37. package/core/error.d.ts +0 -46
  38. package/core/error.d.ts.map +0 -1
  39. package/core/error.js +0 -113
  40. package/core/error.js.map +0 -1
  41. package/core/error.mjs +0 -97
  42. package/core/error.mjs.map +0 -1
  43. package/core/resource.d.mts +0 -6
  44. package/core/resource.d.mts.map +0 -1
  45. package/core/resource.d.ts +0 -6
  46. package/core/resource.d.ts.map +0 -1
  47. package/core/resource.js +0 -11
  48. package/core/resource.js.map +0 -1
  49. package/core/resource.mjs +0 -7
  50. package/core/resource.mjs.map +0 -1
  51. package/core/uploads.d.mts +0 -3
  52. package/core/uploads.d.mts.map +0 -1
  53. package/core/uploads.d.ts +0 -3
  54. package/core/uploads.d.ts.map +0 -1
  55. package/core/uploads.js +0 -6
  56. package/core/uploads.js.map +0 -1
  57. package/core/uploads.mjs +0 -2
  58. package/core/uploads.mjs.map +0 -1
  59. package/error.d.mts +0 -3
  60. package/error.d.mts.map +0 -1
  61. package/error.d.ts +0 -3
  62. package/error.d.ts.map +0 -1
  63. package/error.js +0 -6
  64. package/error.js.map +0 -1
  65. package/error.mjs +0 -3
  66. package/error.mjs.map +0 -1
  67. package/index.d.mts +0 -6
  68. package/index.d.mts.map +0 -1
  69. package/index.d.ts +0 -6
  70. package/index.d.ts.map +0 -1
  71. package/index.js +0 -30
  72. package/index.js.map +0 -1
  73. package/index.mjs +0 -7
  74. package/index.mjs.map +0 -1
  75. package/internal/builtin-types.d.mts +0 -73
  76. package/internal/builtin-types.d.mts.map +0 -1
  77. package/internal/builtin-types.d.ts +0 -73
  78. package/internal/builtin-types.d.ts.map +0 -1
  79. package/internal/builtin-types.js +0 -4
  80. package/internal/builtin-types.js.map +0 -1
  81. package/internal/builtin-types.mjs +0 -3
  82. package/internal/builtin-types.mjs.map +0 -1
  83. package/internal/detect-platform.d.mts +0 -15
  84. package/internal/detect-platform.d.mts.map +0 -1
  85. package/internal/detect-platform.d.ts +0 -15
  86. package/internal/detect-platform.d.ts.map +0 -1
  87. package/internal/detect-platform.js +0 -162
  88. package/internal/detect-platform.js.map +0 -1
  89. package/internal/detect-platform.mjs +0 -157
  90. package/internal/detect-platform.mjs.map +0 -1
  91. package/internal/errors.d.mts +0 -3
  92. package/internal/errors.d.mts.map +0 -1
  93. package/internal/errors.d.ts +0 -3
  94. package/internal/errors.d.ts.map +0 -1
  95. package/internal/errors.js +0 -41
  96. package/internal/errors.js.map +0 -1
  97. package/internal/errors.mjs +0 -36
  98. package/internal/errors.mjs.map +0 -1
  99. package/internal/headers.d.mts +0 -20
  100. package/internal/headers.d.mts.map +0 -1
  101. package/internal/headers.d.ts +0 -20
  102. package/internal/headers.d.ts.map +0 -1
  103. package/internal/headers.js +0 -79
  104. package/internal/headers.js.map +0 -1
  105. package/internal/headers.mjs +0 -74
  106. package/internal/headers.mjs.map +0 -1
  107. package/internal/parse.d.mts +0 -12
  108. package/internal/parse.d.mts.map +0 -1
  109. package/internal/parse.d.ts +0 -12
  110. package/internal/parse.d.ts.map +0 -1
  111. package/internal/parse.js +0 -40
  112. package/internal/parse.js.map +0 -1
  113. package/internal/parse.mjs +0 -37
  114. package/internal/parse.mjs.map +0 -1
  115. package/internal/qs/formats.d.mts +0 -7
  116. package/internal/qs/formats.d.mts.map +0 -1
  117. package/internal/qs/formats.d.ts +0 -7
  118. package/internal/qs/formats.d.ts.map +0 -1
  119. package/internal/qs/formats.js +0 -13
  120. package/internal/qs/formats.js.map +0 -1
  121. package/internal/qs/formats.mjs +0 -9
  122. package/internal/qs/formats.mjs.map +0 -1
  123. package/internal/qs/index.d.mts +0 -10
  124. package/internal/qs/index.d.mts.map +0 -1
  125. package/internal/qs/index.d.ts +0 -10
  126. package/internal/qs/index.d.ts.map +0 -1
  127. package/internal/qs/index.js +0 -14
  128. package/internal/qs/index.js.map +0 -1
  129. package/internal/qs/index.mjs +0 -10
  130. package/internal/qs/index.mjs.map +0 -1
  131. package/internal/qs/stringify.d.mts +0 -3
  132. package/internal/qs/stringify.d.mts.map +0 -1
  133. package/internal/qs/stringify.d.ts +0 -3
  134. package/internal/qs/stringify.d.ts.map +0 -1
  135. package/internal/qs/stringify.js +0 -277
  136. package/internal/qs/stringify.js.map +0 -1
  137. package/internal/qs/stringify.mjs +0 -274
  138. package/internal/qs/stringify.mjs.map +0 -1
  139. package/internal/qs/types.d.mts +0 -57
  140. package/internal/qs/types.d.mts.map +0 -1
  141. package/internal/qs/types.d.ts +0 -57
  142. package/internal/qs/types.d.ts.map +0 -1
  143. package/internal/qs/types.js +0 -3
  144. package/internal/qs/types.js.map +0 -1
  145. package/internal/qs/types.mjs +0 -2
  146. package/internal/qs/types.mjs.map +0 -1
  147. package/internal/qs/utils.d.mts +0 -15
  148. package/internal/qs/utils.d.mts.map +0 -1
  149. package/internal/qs/utils.d.ts +0 -15
  150. package/internal/qs/utils.d.ts.map +0 -1
  151. package/internal/qs/utils.js +0 -230
  152. package/internal/qs/utils.js.map +0 -1
  153. package/internal/qs/utils.mjs +0 -217
  154. package/internal/qs/utils.mjs.map +0 -1
  155. package/internal/request-options.d.mts +0 -75
  156. package/internal/request-options.d.mts.map +0 -1
  157. package/internal/request-options.d.ts +0 -75
  158. package/internal/request-options.d.ts.map +0 -1
  159. package/internal/request-options.js +0 -14
  160. package/internal/request-options.js.map +0 -1
  161. package/internal/request-options.mjs +0 -10
  162. package/internal/request-options.mjs.map +0 -1
  163. package/internal/shim-types.d.mts +0 -17
  164. package/internal/shim-types.d.mts.map +0 -1
  165. package/internal/shim-types.d.ts +0 -17
  166. package/internal/shim-types.d.ts.map +0 -1
  167. package/internal/shim-types.js +0 -4
  168. package/internal/shim-types.js.map +0 -1
  169. package/internal/shim-types.mjs +0 -3
  170. package/internal/shim-types.mjs.map +0 -1
  171. package/internal/shims.d.mts +0 -26
  172. package/internal/shims.d.mts.map +0 -1
  173. package/internal/shims.d.ts +0 -26
  174. package/internal/shims.d.ts.map +0 -1
  175. package/internal/shims.js +0 -92
  176. package/internal/shims.js.map +0 -1
  177. package/internal/shims.mjs +0 -85
  178. package/internal/shims.mjs.map +0 -1
  179. package/internal/to-file.d.mts +0 -45
  180. package/internal/to-file.d.mts.map +0 -1
  181. package/internal/to-file.d.ts +0 -45
  182. package/internal/to-file.d.ts.map +0 -1
  183. package/internal/to-file.js +0 -91
  184. package/internal/to-file.js.map +0 -1
  185. package/internal/to-file.mjs +0 -88
  186. package/internal/to-file.mjs.map +0 -1
  187. package/internal/tslib.js +0 -81
  188. package/internal/tslib.mjs +0 -17
  189. package/internal/types.d.mts +0 -69
  190. package/internal/types.d.mts.map +0 -1
  191. package/internal/types.d.ts +0 -69
  192. package/internal/types.d.ts.map +0 -1
  193. package/internal/types.js +0 -4
  194. package/internal/types.js.map +0 -1
  195. package/internal/types.mjs +0 -3
  196. package/internal/types.mjs.map +0 -1
  197. package/internal/uploads.d.mts +0 -42
  198. package/internal/uploads.d.mts.map +0 -1
  199. package/internal/uploads.d.ts +0 -42
  200. package/internal/uploads.d.ts.map +0 -1
  201. package/internal/uploads.js +0 -141
  202. package/internal/uploads.js.map +0 -1
  203. package/internal/uploads.mjs +0 -131
  204. package/internal/uploads.mjs.map +0 -1
  205. package/internal/utils/base64.d.mts +0 -3
  206. package/internal/utils/base64.d.mts.map +0 -1
  207. package/internal/utils/base64.d.ts +0 -3
  208. package/internal/utils/base64.d.ts.map +0 -1
  209. package/internal/utils/base64.js +0 -38
  210. package/internal/utils/base64.js.map +0 -1
  211. package/internal/utils/base64.mjs +0 -33
  212. package/internal/utils/base64.mjs.map +0 -1
  213. package/internal/utils/bytes.d.mts +0 -4
  214. package/internal/utils/bytes.d.mts.map +0 -1
  215. package/internal/utils/bytes.d.ts +0 -4
  216. package/internal/utils/bytes.d.ts.map +0 -1
  217. package/internal/utils/bytes.js +0 -31
  218. package/internal/utils/bytes.js.map +0 -1
  219. package/internal/utils/bytes.mjs +0 -26
  220. package/internal/utils/bytes.mjs.map +0 -1
  221. package/internal/utils/env.d.mts +0 -9
  222. package/internal/utils/env.d.mts.map +0 -1
  223. package/internal/utils/env.d.ts +0 -9
  224. package/internal/utils/env.d.ts.map +0 -1
  225. package/internal/utils/env.js +0 -22
  226. package/internal/utils/env.js.map +0 -1
  227. package/internal/utils/env.mjs +0 -18
  228. package/internal/utils/env.mjs.map +0 -1
  229. package/internal/utils/log.d.mts +0 -37
  230. package/internal/utils/log.d.mts.map +0 -1
  231. package/internal/utils/log.d.ts +0 -37
  232. package/internal/utils/log.d.ts.map +0 -1
  233. package/internal/utils/log.js +0 -88
  234. package/internal/utils/log.js.map +0 -1
  235. package/internal/utils/log.mjs +0 -82
  236. package/internal/utils/log.mjs.map +0 -1
  237. package/internal/utils/path.d.mts +0 -15
  238. package/internal/utils/path.d.mts.map +0 -1
  239. package/internal/utils/path.d.ts +0 -15
  240. package/internal/utils/path.d.ts.map +0 -1
  241. package/internal/utils/path.js +0 -79
  242. package/internal/utils/path.js.map +0 -1
  243. package/internal/utils/path.mjs +0 -74
  244. package/internal/utils/path.mjs.map +0 -1
  245. package/internal/utils/query.d.mts +0 -2
  246. package/internal/utils/query.d.mts.map +0 -1
  247. package/internal/utils/query.d.ts +0 -2
  248. package/internal/utils/query.d.ts.map +0 -1
  249. package/internal/utils/query.js +0 -10
  250. package/internal/utils/query.js.map +0 -1
  251. package/internal/utils/query.mjs +0 -6
  252. package/internal/utils/query.mjs.map +0 -1
  253. package/internal/utils/sleep.d.mts +0 -2
  254. package/internal/utils/sleep.d.mts.map +0 -1
  255. package/internal/utils/sleep.d.ts +0 -2
  256. package/internal/utils/sleep.d.ts.map +0 -1
  257. package/internal/utils/sleep.js +0 -7
  258. package/internal/utils/sleep.js.map +0 -1
  259. package/internal/utils/sleep.mjs +0 -3
  260. package/internal/utils/sleep.mjs.map +0 -1
  261. package/internal/utils/uuid.d.mts +0 -5
  262. package/internal/utils/uuid.d.mts.map +0 -1
  263. package/internal/utils/uuid.d.ts +0 -5
  264. package/internal/utils/uuid.d.ts.map +0 -1
  265. package/internal/utils/uuid.js +0 -19
  266. package/internal/utils/uuid.js.map +0 -1
  267. package/internal/utils/uuid.mjs +0 -15
  268. package/internal/utils/uuid.mjs.map +0 -1
  269. package/internal/utils/values.d.mts +0 -18
  270. package/internal/utils/values.d.mts.map +0 -1
  271. package/internal/utils/values.d.ts +0 -18
  272. package/internal/utils/values.d.ts.map +0 -1
  273. package/internal/utils/values.js +0 -112
  274. package/internal/utils/values.js.map +0 -1
  275. package/internal/utils/values.mjs +0 -94
  276. package/internal/utils/values.mjs.map +0 -1
  277. package/internal/utils.d.mts +0 -8
  278. package/internal/utils.d.mts.map +0 -1
  279. package/internal/utils.d.ts +0 -8
  280. package/internal/utils.d.ts.map +0 -1
  281. package/internal/utils.js +0 -12
  282. package/internal/utils.js.map +0 -1
  283. package/internal/utils.mjs +0 -9
  284. package/internal/utils.mjs.map +0 -1
  285. package/resource.d.mts +0 -3
  286. package/resource.d.mts.map +0 -1
  287. package/resource.d.ts +0 -3
  288. package/resource.d.ts.map +0 -1
  289. package/resource.js +0 -6
  290. package/resource.js.map +0 -1
  291. package/resource.mjs +0 -3
  292. package/resource.mjs.map +0 -1
  293. package/resources/connect/connect.d.mts +0 -31
  294. package/resources/connect/connect.d.mts.map +0 -1
  295. package/resources/connect/connect.d.ts +0 -31
  296. package/resources/connect/connect.d.ts.map +0 -1
  297. package/resources/connect/connect.js +0 -24
  298. package/resources/connect/connect.js.map +0 -1
  299. package/resources/connect/connect.mjs +0 -19
  300. package/resources/connect/connect.mjs.map +0 -1
  301. package/resources/connect/index.d.mts +0 -3
  302. package/resources/connect/index.d.mts.map +0 -1
  303. package/resources/connect/index.d.ts +0 -3
  304. package/resources/connect/index.d.ts.map +0 -1
  305. package/resources/connect/index.js +0 -9
  306. package/resources/connect/index.js.map +0 -1
  307. package/resources/connect/index.mjs +0 -4
  308. package/resources/connect/index.mjs.map +0 -1
  309. package/resources/connect/integrations.d.mts +0 -78
  310. package/resources/connect/integrations.d.mts.map +0 -1
  311. package/resources/connect/integrations.d.ts +0 -78
  312. package/resources/connect/integrations.d.ts.map +0 -1
  313. package/resources/connect/integrations.js +0 -22
  314. package/resources/connect/integrations.js.map +0 -1
  315. package/resources/connect/integrations.mjs +0 -18
  316. package/resources/connect/integrations.mjs.map +0 -1
  317. package/resources/connect.d.mts +0 -2
  318. package/resources/connect.d.mts.map +0 -1
  319. package/resources/connect.d.ts +0 -2
  320. package/resources/connect.d.ts.map +0 -1
  321. package/resources/connect.js +0 -6
  322. package/resources/connect.js.map +0 -1
  323. package/resources/connect.mjs +0 -3
  324. package/resources/connect.mjs.map +0 -1
  325. package/resources/health.d.mts +0 -23
  326. package/resources/health.d.mts.map +0 -1
  327. package/resources/health.d.ts +0 -23
  328. package/resources/health.d.ts.map +0 -1
  329. package/resources/health.js +0 -21
  330. package/resources/health.js.map +0 -1
  331. package/resources/health.mjs +0 -17
  332. package/resources/health.mjs.map +0 -1
  333. package/resources/index.d.mts +0 -6
  334. package/resources/index.d.mts.map +0 -1
  335. package/resources/index.d.ts +0 -6
  336. package/resources/index.d.ts.map +0 -1
  337. package/resources/index.js +0 -15
  338. package/resources/index.js.map +0 -1
  339. package/resources/index.mjs +0 -7
  340. package/resources/index.mjs.map +0 -1
  341. package/resources/media.d.mts +0 -27
  342. package/resources/media.d.mts.map +0 -1
  343. package/resources/media.d.ts +0 -27
  344. package/resources/media.d.ts.map +0 -1
  345. package/resources/media.js +0 -15
  346. package/resources/media.js.map +0 -1
  347. package/resources/media.mjs +0 -11
  348. package/resources/media.mjs.map +0 -1
  349. package/resources/platforms.d.mts +0 -22
  350. package/resources/platforms.d.mts.map +0 -1
  351. package/resources/platforms.d.ts +0 -22
  352. package/resources/platforms.d.ts.map +0 -1
  353. package/resources/platforms.js +0 -15
  354. package/resources/platforms.js.map +0 -1
  355. package/resources/platforms.mjs +0 -11
  356. package/resources/platforms.mjs.map +0 -1
  357. package/resources/posts/index.d.mts +0 -3
  358. package/resources/posts/index.d.mts.map +0 -1
  359. package/resources/posts/index.d.ts +0 -3
  360. package/resources/posts/index.d.ts.map +0 -1
  361. package/resources/posts/index.js +0 -9
  362. package/resources/posts/index.js.map +0 -1
  363. package/resources/posts/index.mjs +0 -4
  364. package/resources/posts/index.mjs.map +0 -1
  365. package/resources/posts/posts.d.mts +0 -300
  366. package/resources/posts/posts.d.mts.map +0 -1
  367. package/resources/posts/posts.d.ts +0 -300
  368. package/resources/posts/posts.d.ts.map +0 -1
  369. package/resources/posts/posts.js +0 -69
  370. package/resources/posts/posts.js.map +0 -1
  371. package/resources/posts/posts.mjs +0 -64
  372. package/resources/posts/posts.mjs.map +0 -1
  373. package/resources/posts/scheduled.d.mts +0 -121
  374. package/resources/posts/scheduled.d.mts.map +0 -1
  375. package/resources/posts/scheduled.d.ts +0 -121
  376. package/resources/posts/scheduled.d.ts.map +0 -1
  377. package/resources/posts/scheduled.js +0 -49
  378. package/resources/posts/scheduled.js.map +0 -1
  379. package/resources/posts/scheduled.mjs +0 -45
  380. package/resources/posts/scheduled.mjs.map +0 -1
  381. package/resources/posts.d.mts +0 -2
  382. package/resources/posts.d.mts.map +0 -1
  383. package/resources/posts.d.ts +0 -2
  384. package/resources/posts.d.ts.map +0 -1
  385. package/resources/posts.js +0 -6
  386. package/resources/posts.js.map +0 -1
  387. package/resources/posts.mjs +0 -3
  388. package/resources/posts.mjs.map +0 -1
  389. package/resources.d.mts +0 -2
  390. package/resources.d.mts.map +0 -1
  391. package/resources.d.ts +0 -2
  392. package/resources.d.ts.map +0 -1
  393. package/resources.js +0 -5
  394. package/resources.js.map +0 -1
  395. package/resources.mjs +0 -2
  396. package/resources.mjs.map +0 -1
  397. package/src/api-promise.ts +0 -2
  398. package/src/client.ts +0 -789
  399. package/src/core/README.md +0 -3
  400. package/src/core/api-promise.ts +0 -92
  401. package/src/core/error.ts +0 -130
  402. package/src/core/resource.ts +0 -11
  403. package/src/core/uploads.ts +0 -2
  404. package/src/error.ts +0 -2
  405. package/src/index.ts +0 -22
  406. package/src/internal/README.md +0 -3
  407. package/src/internal/builtin-types.ts +0 -93
  408. package/src/internal/detect-platform.ts +0 -196
  409. package/src/internal/errors.ts +0 -33
  410. package/src/internal/headers.ts +0 -97
  411. package/src/internal/parse.ts +0 -56
  412. package/src/internal/qs/LICENSE.md +0 -13
  413. package/src/internal/qs/README.md +0 -3
  414. package/src/internal/qs/formats.ts +0 -10
  415. package/src/internal/qs/index.ts +0 -13
  416. package/src/internal/qs/stringify.ts +0 -385
  417. package/src/internal/qs/types.ts +0 -71
  418. package/src/internal/qs/utils.ts +0 -265
  419. package/src/internal/request-options.ts +0 -91
  420. package/src/internal/shim-types.ts +0 -26
  421. package/src/internal/shims.ts +0 -107
  422. package/src/internal/to-file.ts +0 -154
  423. package/src/internal/types.ts +0 -93
  424. package/src/internal/uploads.ts +0 -187
  425. package/src/internal/utils/base64.ts +0 -40
  426. package/src/internal/utils/bytes.ts +0 -32
  427. package/src/internal/utils/env.ts +0 -18
  428. package/src/internal/utils/log.ts +0 -129
  429. package/src/internal/utils/path.ts +0 -88
  430. package/src/internal/utils/query.ts +0 -7
  431. package/src/internal/utils/sleep.ts +0 -3
  432. package/src/internal/utils/uuid.ts +0 -17
  433. package/src/internal/utils/values.ts +0 -105
  434. package/src/internal/utils.ts +0 -9
  435. package/src/lib/.keep +0 -4
  436. package/src/resource.ts +0 -2
  437. package/src/resources/connect/connect.ts +0 -70
  438. package/src/resources/connect/index.ts +0 -9
  439. package/src/resources/connect/integrations.ts +0 -130
  440. package/src/resources/connect.ts +0 -3
  441. package/src/resources/health.ts +0 -36
  442. package/src/resources/index.ts +0 -16
  443. package/src/resources/media.ts +0 -38
  444. package/src/resources/platforms.ts +0 -39
  445. package/src/resources/posts/index.ts +0 -20
  446. package/src/resources/posts/posts.ts +0 -472
  447. package/src/resources/posts/scheduled.ts +0 -180
  448. package/src/resources/posts.ts +0 -3
  449. package/src/resources.ts +0 -1
  450. package/src/tsconfig.json +0 -11
  451. package/src/uploads.ts +0 -2
  452. package/src/version.ts +0 -1
  453. package/uploads.d.mts +0 -3
  454. package/uploads.d.mts.map +0 -1
  455. package/uploads.d.ts +0 -3
  456. package/uploads.d.ts.map +0 -1
  457. package/uploads.js +0 -6
  458. package/uploads.js.map +0 -1
  459. package/uploads.mjs +0 -3
  460. package/uploads.mjs.map +0 -1
  461. package/version.d.mts +0 -2
  462. package/version.d.mts.map +0 -1
  463. package/version.d.ts +0 -2
  464. package/version.d.ts.map +0 -1
  465. package/version.js +0 -5
  466. package/version.js.map +0 -1
  467. package/version.mjs +0 -2
  468. package/version.mjs.map +0 -1
@@ -1,472 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- import { APIResource } from '../../core/resource';
4
- import * as ScheduledAPI from './scheduled';
5
- import {
6
- Scheduled,
7
- ScheduledCancelResponse,
8
- ScheduledListParams,
9
- ScheduledListResponse,
10
- ScheduledRescheduleParams,
11
- ScheduledRescheduleResponse,
12
- } from './scheduled';
13
- import { APIPromise } from '../../core/api-promise';
14
- import { RequestOptions } from '../../internal/request-options';
15
- import { path } from '../../internal/utils/path';
16
-
17
- export class Posts extends APIResource {
18
- scheduled: ScheduledAPI.Scheduled = new ScheduledAPI.Scheduled(this._client);
19
-
20
- /**
21
- * Publish a post to one or more social media platforms
22
- *
23
- * @example
24
- * ```ts
25
- * const post = await client.posts.create({
26
- * content: 'Hello world!',
27
- * platforms: [
28
- * { platform: 'twitter', accountId: '<your-account-id>' },
29
- * ],
30
- * publishNow: true,
31
- * });
32
- * ```
33
- */
34
- create(body: PostCreateParams, options?: RequestOptions): APIPromise<PostCreateResponse> {
35
- return this._client.post('/v1/posts/', { body, ...options });
36
- }
37
-
38
- /**
39
- * Get a single post by ID
40
- *
41
- * @example
42
- * ```ts
43
- * const post = await client.posts.retrieve('postId');
44
- * ```
45
- */
46
- retrieve(postID: string, options?: RequestOptions): APIPromise<PostRetrieveResponse> {
47
- return this._client.get(path`/v1/posts/${postID}`, options);
48
- }
49
-
50
- /**
51
- * Returns a paginated list of posts. Filter by status, platform (OR logic), and
52
- * date ranges. Published posts include platformPostUrl per platform.
53
- *
54
- * @example
55
- * ```ts
56
- * const posts = await client.posts.list();
57
- * ```
58
- */
59
- list(
60
- query: PostListParams | null | undefined = {},
61
- options?: RequestOptions,
62
- ): APIPromise<PostListResponse> {
63
- return this._client.get('/v1/posts/', { query, ...options });
64
- }
65
-
66
- /**
67
- * Delete a post by ID
68
- *
69
- * @example
70
- * ```ts
71
- * const post = await client.posts.delete('postId');
72
- * ```
73
- */
74
- delete(postID: string, options?: RequestOptions): APIPromise<PostDeleteResponse> {
75
- return this._client.delete(path`/v1/posts/${postID}`, options);
76
- }
77
- }
78
-
79
- export type Status = 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
80
-
81
- export interface PostCreateResponse {
82
- platforms: Array<PostCreateResponse.Platform>;
83
-
84
- /**
85
- * id of the saved Post document
86
- */
87
- postId: string;
88
-
89
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
90
-
91
- /**
92
- * false only when every platform failed
93
- */
94
- success: boolean;
95
-
96
- /**
97
- * ISO 8601 datetime the post is scheduled for (only present for scheduled posts)
98
- */
99
- scheduledFor?: string;
100
- }
101
-
102
- export namespace PostCreateResponse {
103
- export interface Platform {
104
- platform:
105
- | 'twitter'
106
- | 'instagram'
107
- | 'youtube'
108
- | 'tiktok'
109
- | 'pinterest'
110
- | 'linkedin'
111
- | 'bluesky'
112
- | 'facebook'
113
- | 'threads';
114
-
115
- success: boolean;
116
-
117
- /**
118
- * Error message when success is false
119
- */
120
- error?: string;
121
-
122
- /**
123
- * Direct URL to the published post
124
- */
125
- platformPostUrl?: string;
126
-
127
- /**
128
- * Warning message when the post published but a non-critical follow-up action
129
- * failed
130
- */
131
- warningMessage?: string;
132
- }
133
- }
134
-
135
- export interface PostRetrieveResponse {
136
- post: PostRetrieveResponse.Post;
137
-
138
- success: boolean;
139
- }
140
-
141
- export namespace PostRetrieveResponse {
142
- export interface Post {
143
- content: string;
144
-
145
- createdAt: string;
146
-
147
- crosspostingEnabled: boolean;
148
-
149
- mediaItems: Array<Post.MediaItem>;
150
-
151
- platforms: Array<Post.Platform>;
152
-
153
- /**
154
- * MongoDB ObjectId of the Post document
155
- */
156
- postId: string;
157
-
158
- rawRequestBody: { [key: string]: unknown };
159
-
160
- /**
161
- * ISO 8601 scheduled datetime
162
- */
163
- scheduledFor: string | null;
164
-
165
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
166
-
167
- timezone: string;
168
-
169
- updatedAt: string;
170
- }
171
-
172
- export namespace Post {
173
- export interface MediaItem {
174
- filename: string;
175
-
176
- mimeType: string;
177
-
178
- size: number;
179
-
180
- type: 'image' | 'video' | 'gif';
181
-
182
- url: string;
183
- }
184
-
185
- export interface Platform {
186
- /**
187
- * Per-platform text override that was used for this platform. Null when the
188
- * top-level `content` was used.
189
- */
190
- content: string | null;
191
-
192
- errorMessage: string | null;
193
-
194
- platform:
195
- | 'twitter'
196
- | 'instagram'
197
- | 'youtube'
198
- | 'tiktok'
199
- | 'pinterest'
200
- | 'linkedin'
201
- | 'bluesky'
202
- | 'facebook'
203
- | 'threads';
204
-
205
- platformPostId: string | null;
206
-
207
- /**
208
- * Direct URL to the published post
209
- */
210
- platformPostUrl: string | null;
211
-
212
- publishedAt: string | null;
213
-
214
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
215
-
216
- warningMessage: string | null;
217
- }
218
- }
219
- }
220
-
221
- export interface PostListResponse {
222
- posts: Array<PostListResponse.Post>;
223
-
224
- success: boolean;
225
-
226
- /**
227
- * Total matched posts across all pages
228
- */
229
- total: number;
230
- }
231
-
232
- export namespace PostListResponse {
233
- export interface Post {
234
- content: string;
235
-
236
- createdAt: string;
237
-
238
- crosspostingEnabled: boolean;
239
-
240
- mediaItems: Array<Post.MediaItem>;
241
-
242
- platforms: Array<Post.Platform>;
243
-
244
- /**
245
- * MongoDB ObjectId of the Post document
246
- */
247
- postId: string;
248
-
249
- rawRequestBody: { [key: string]: unknown };
250
-
251
- /**
252
- * ISO 8601 scheduled datetime
253
- */
254
- scheduledFor: string | null;
255
-
256
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
257
-
258
- timezone: string;
259
-
260
- updatedAt: string;
261
- }
262
-
263
- export namespace Post {
264
- export interface MediaItem {
265
- filename: string;
266
-
267
- mimeType: string;
268
-
269
- size: number;
270
-
271
- type: 'image' | 'video' | 'gif';
272
-
273
- url: string;
274
- }
275
-
276
- export interface Platform {
277
- /**
278
- * Per-platform text override that was used for this platform. Null when the
279
- * top-level `content` was used.
280
- */
281
- content: string | null;
282
-
283
- errorMessage: string | null;
284
-
285
- platform:
286
- | 'twitter'
287
- | 'instagram'
288
- | 'youtube'
289
- | 'tiktok'
290
- | 'pinterest'
291
- | 'linkedin'
292
- | 'bluesky'
293
- | 'facebook'
294
- | 'threads';
295
-
296
- platformPostId: string | null;
297
-
298
- /**
299
- * Direct URL to the published post
300
- */
301
- platformPostUrl: string | null;
302
-
303
- publishedAt: string | null;
304
-
305
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
306
-
307
- warningMessage: string | null;
308
- }
309
- }
310
- }
311
-
312
- export interface PostDeleteResponse {
313
- success: boolean;
314
- }
315
-
316
- export interface PostCreateParams {
317
- /**
318
- * Post text body
319
- */
320
- content: string;
321
-
322
- /**
323
- * Target platform accounts to publish to
324
- */
325
- platforms: Array<PostCreateParams.Platform>;
326
-
327
- /**
328
- * Media attachments (images, videos, GIFs)
329
- */
330
- mediaItems?: Array<PostCreateParams.MediaItem>;
331
-
332
- /**
333
- * Publish immediately. Required when scheduledFor is omitted.
334
- */
335
- publishNow?: boolean;
336
-
337
- /**
338
- * ISO 8601 datetime to schedule the post for future publishing
339
- */
340
- scheduledFor?: string;
341
-
342
- /**
343
- * IANA timezone for the scheduled time (e.g. America/New_York). Defaults to UTC.
344
- */
345
- timezone?: string;
346
- }
347
-
348
- export namespace PostCreateParams {
349
- export interface Platform {
350
- /**
351
- * Integration.\_id — find yours via GET /connect/integrations
352
- */
353
- accountId: string;
354
-
355
- platform:
356
- | 'twitter'
357
- | 'instagram'
358
- | 'youtube'
359
- | 'tiktok'
360
- | 'pinterest'
361
- | 'linkedin'
362
- | 'bluesky'
363
- | 'facebook'
364
- | 'threads';
365
-
366
- /**
367
- * Optional per-platform text override. Use when you want to change the text for
368
- * this platform because different platforms talk differently. When omitted, the
369
- * top-level `content` is used.
370
- */
371
- content?: string;
372
-
373
- /**
374
- * Platform-specific options. See TwitterConfigurations, YouTubeConfigurations,
375
- * TikTokConfigurations, PinterestConfigurations, or LinkedInConfigurations in the
376
- * schema reference for available fields per platform.
377
- */
378
- platformSpecificData?: { [key: string]: unknown };
379
- }
380
-
381
- export interface MediaItem {
382
- type: 'image' | 'video' | 'gif';
383
-
384
- url: string;
385
-
386
- /**
387
- * Thumbnail image URL for video items. Supported on YouTube regular videos (not
388
- * Shorts). JPEG, PNG, or GIF, max 2 MB, min 640 px wide.
389
- */
390
- thumbnail?: string;
391
- }
392
- }
393
-
394
- export interface PostListParams {
395
- /**
396
- * ISO 8601 lower bound on createdAt
397
- */
398
- createdAfter?: string;
399
-
400
- /**
401
- * ISO 8601 upper bound on createdAt
402
- */
403
- createdBefore?: string;
404
-
405
- /**
406
- * Page size (max 100)
407
- */
408
- limit?: number;
409
-
410
- /**
411
- * Number of posts to skip
412
- */
413
- offset?: number;
414
-
415
- /**
416
- * Filter by platform (repeatable — OR logic)
417
- */
418
- platform?: Array<
419
- | 'twitter'
420
- | 'instagram'
421
- | 'youtube'
422
- | 'tiktok'
423
- | 'pinterest'
424
- | 'linkedin'
425
- | 'bluesky'
426
- | 'facebook'
427
- | 'threads'
428
- >;
429
-
430
- /**
431
- * Filter to posts targeting an integration bound to this profile. Pass "null"
432
- * (literal string) to filter to posts whose integrations have no profile.
433
- */
434
- profileId?: string;
435
-
436
- /**
437
- * ISO 8601 lower bound on scheduledFor
438
- */
439
- scheduledAfter?: string;
440
-
441
- /**
442
- * ISO 8601 upper bound on scheduledFor
443
- */
444
- scheduledBefore?: string;
445
-
446
- sort?: 'asc' | 'desc';
447
-
448
- status?: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
449
- }
450
-
451
- Posts.Scheduled = Scheduled;
452
-
453
- export declare namespace Posts {
454
- export {
455
- type Status as Status,
456
- type PostCreateResponse as PostCreateResponse,
457
- type PostRetrieveResponse as PostRetrieveResponse,
458
- type PostListResponse as PostListResponse,
459
- type PostDeleteResponse as PostDeleteResponse,
460
- type PostCreateParams as PostCreateParams,
461
- type PostListParams as PostListParams,
462
- };
463
-
464
- export {
465
- Scheduled as Scheduled,
466
- type ScheduledListResponse as ScheduledListResponse,
467
- type ScheduledCancelResponse as ScheduledCancelResponse,
468
- type ScheduledRescheduleResponse as ScheduledRescheduleResponse,
469
- type ScheduledListParams as ScheduledListParams,
470
- type ScheduledRescheduleParams as ScheduledRescheduleParams,
471
- };
472
- }
@@ -1,180 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- import { APIResource } from '../../core/resource';
4
- import { APIPromise } from '../../core/api-promise';
5
- import { RequestOptions } from '../../internal/request-options';
6
- import { path } from '../../internal/utils/path';
7
-
8
- export class Scheduled extends APIResource {
9
- /**
10
- * Returns a paginated list of scheduled posts. Use `limit` + `offset` to page
11
- * through the results.
12
- *
13
- * @example
14
- * ```ts
15
- * const scheduleds = await client.posts.scheduled.list();
16
- * ```
17
- */
18
- list(
19
- query: ScheduledListParams | null | undefined = {},
20
- options?: RequestOptions,
21
- ): APIPromise<ScheduledListResponse> {
22
- return this._client.get('/v1/posts/scheduled/', { query, ...options });
23
- }
24
-
25
- /**
26
- * Cancel a scheduled post (moves it back to draft)
27
- *
28
- * @example
29
- * ```ts
30
- * const response = await client.posts.scheduled.cancel(
31
- * 'postId',
32
- * );
33
- * ```
34
- */
35
- cancel(postID: string, options?: RequestOptions): APIPromise<ScheduledCancelResponse> {
36
- return this._client.delete(path`/v1/posts/scheduled/${postID}`, options);
37
- }
38
-
39
- /**
40
- * Reschedule a post to a new time
41
- *
42
- * @example
43
- * ```ts
44
- * const response = await client.posts.scheduled.reschedule(
45
- * 'postId',
46
- * { scheduledFor: '2019-12-27T18:11:19.117Z' },
47
- * );
48
- * ```
49
- */
50
- reschedule(
51
- postID: string,
52
- body: ScheduledRescheduleParams,
53
- options?: RequestOptions,
54
- ): APIPromise<ScheduledRescheduleResponse> {
55
- return this._client.patch(path`/v1/posts/scheduled/${postID}`, { body, ...options });
56
- }
57
- }
58
-
59
- export interface ScheduledListResponse {
60
- posts: Array<ScheduledListResponse.Post>;
61
-
62
- success: boolean;
63
-
64
- /**
65
- * Total matched scheduled posts across all pages
66
- */
67
- total: number;
68
- }
69
-
70
- export namespace ScheduledListResponse {
71
- export interface Post {
72
- /**
73
- * Post text body
74
- */
75
- content: string;
76
-
77
- createdAt: string;
78
-
79
- platforms: Array<Post.Platform>;
80
-
81
- /**
82
- * MongoDB ObjectId of the Post document
83
- */
84
- postId: string;
85
-
86
- /**
87
- * ISO 8601 scheduled datetime
88
- */
89
- scheduledFor: string | null;
90
-
91
- /**
92
- * IANA timezone for the scheduled time
93
- */
94
- timezone: string;
95
-
96
- /**
97
- * Media attachments
98
- */
99
- mediaItems?: Array<Post.MediaItem>;
100
- }
101
-
102
- export namespace Post {
103
- export interface Platform {
104
- platform:
105
- | 'twitter'
106
- | 'instagram'
107
- | 'youtube'
108
- | 'tiktok'
109
- | 'pinterest'
110
- | 'linkedin'
111
- | 'bluesky'
112
- | 'facebook'
113
- | 'threads';
114
-
115
- status: 'draft' | 'pending' | 'scheduled' | 'publishing' | 'published' | 'failed' | 'partial';
116
- }
117
-
118
- export interface MediaItem {
119
- type: 'image' | 'video' | 'gif';
120
-
121
- url: string;
122
-
123
- /**
124
- * Thumbnail image URL for video items. Supported on YouTube regular videos (not
125
- * Shorts). JPEG, PNG, or GIF, max 2 MB, min 640 px wide.
126
- */
127
- thumbnail?: string;
128
- }
129
- }
130
- }
131
-
132
- export interface ScheduledCancelResponse {
133
- message: string;
134
-
135
- success: boolean;
136
- }
137
-
138
- export interface ScheduledRescheduleResponse {
139
- message: string;
140
-
141
- scheduledFor: string;
142
-
143
- success: boolean;
144
- }
145
-
146
- export interface ScheduledListParams {
147
- /**
148
- * Page size (max 100)
149
- */
150
- limit?: number;
151
-
152
- /**
153
- * Number of scheduled posts to skip
154
- */
155
- offset?: number;
156
-
157
- sort?: 'asc' | 'desc';
158
- }
159
-
160
- export interface ScheduledRescheduleParams {
161
- /**
162
- * New ISO 8601 datetime to schedule the post
163
- */
164
- scheduledFor: string;
165
-
166
- /**
167
- * IANA timezone
168
- */
169
- timezone?: string;
170
- }
171
-
172
- export declare namespace Scheduled {
173
- export {
174
- type ScheduledListResponse as ScheduledListResponse,
175
- type ScheduledCancelResponse as ScheduledCancelResponse,
176
- type ScheduledRescheduleResponse as ScheduledRescheduleResponse,
177
- type ScheduledListParams as ScheduledListParams,
178
- type ScheduledRescheduleParams as ScheduledRescheduleParams,
179
- };
180
- }
@@ -1,3 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
-
3
- export * from './posts/index';
package/src/resources.ts DELETED
@@ -1 +0,0 @@
1
- export * from './resources/index';
package/src/tsconfig.json DELETED
@@ -1,11 +0,0 @@
1
- {
2
- // this config is included in the published src directory to prevent TS errors
3
- // from appearing when users go to source, and VSCode opens the source .ts file
4
- // via declaration maps
5
- "include": ["index.ts"],
6
- "compilerOptions": {
7
- "target": "ES2015",
8
- "lib": ["DOM", "DOM.Iterable", "ES2018"],
9
- "moduleResolution": "node"
10
- }
11
- }
package/src/uploads.ts DELETED
@@ -1,2 +0,0 @@
1
- /** @deprecated Import from ./core/uploads instead */
2
- export * from './core/uploads';
package/src/version.ts DELETED
@@ -1 +0,0 @@
1
- export const VERSION = '0.7.0'; // x-release-please-version
package/uploads.d.mts DELETED
@@ -1,3 +0,0 @@
1
- /** @deprecated Import from ./core/uploads instead */
2
- export * from "./core/uploads.mjs";
3
- //# sourceMappingURL=uploads.d.mts.map
package/uploads.d.mts.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"uploads.d.mts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,mCAA+B"}
package/uploads.d.ts DELETED
@@ -1,3 +0,0 @@
1
- /** @deprecated Import from ./core/uploads instead */
2
- export * from "./core/uploads.js";
3
- //# sourceMappingURL=uploads.d.ts.map
package/uploads.d.ts.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"uploads.d.ts","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":"AAAA,qDAAqD;AACrD,kCAA+B"}
package/uploads.js DELETED
@@ -1,6 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const tslib_1 = require("./internal/tslib.js");
4
- /** @deprecated Import from ./core/uploads instead */
5
- tslib_1.__exportStar(require("./core/uploads.js"), exports);
6
- //# sourceMappingURL=uploads.js.map
package/uploads.js.map DELETED
@@ -1 +0,0 @@
1
- {"version":3,"file":"uploads.js","sourceRoot":"","sources":["src/uploads.ts"],"names":[],"mappings":";;;AAAA,qDAAqD;AACrD,4DAA+B"}
package/uploads.mjs DELETED
@@ -1,3 +0,0 @@
1
- /** @deprecated Import from ./core/uploads instead */
2
- export * from "./core/uploads.mjs";
3
- //# sourceMappingURL=uploads.mjs.map