dub 0.10.0 → 0.20.2

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 (540) hide show
  1. package/.github/workflows/sdk_generation.yaml +26 -0
  2. package/.github/workflows/sdk_publish.yaml +15 -0
  3. package/.speakeasy/gen.lock +205 -0
  4. package/.speakeasy/gen.yaml +37 -0
  5. package/.speakeasy/workflow.yaml +12 -0
  6. package/README.md +292 -182
  7. package/docs/sdks/analytics/README.md +535 -0
  8. package/docs/sdks/dub/README.md +9 -0
  9. package/docs/sdks/links/README.md +415 -0
  10. package/docs/sdks/qrcodes/README.md +58 -0
  11. package/docs/sdks/tags/README.md +113 -0
  12. package/docs/sdks/workspaces/README.md +168 -0
  13. package/hooks/hooks.d.ts +20 -0
  14. package/hooks/hooks.d.ts.map +1 -0
  15. package/hooks/hooks.js +55 -0
  16. package/hooks/hooks.js.map +1 -0
  17. package/hooks/index.d.ts +3 -0
  18. package/hooks/index.d.ts.map +1 -0
  19. package/{_shims/auto/runtime-bun.js → hooks/index.js} +6 -5
  20. package/hooks/index.js.map +1 -0
  21. package/hooks/types.d.ts +59 -0
  22. package/hooks/types.d.ts.map +1 -0
  23. package/hooks/types.js +6 -0
  24. package/hooks/types.js.map +1 -0
  25. package/index.d.ts +4 -125
  26. package/index.d.ts.map +1 -1
  27. package/index.js +10 -103
  28. package/index.js.map +1 -1
  29. package/lib/base64.d.ts +10 -0
  30. package/lib/base64.d.ts.map +1 -0
  31. package/lib/base64.js +61 -0
  32. package/lib/base64.js.map +1 -0
  33. package/lib/config.d.ts +39 -0
  34. package/lib/config.d.ts.map +1 -0
  35. package/lib/config.js +39 -0
  36. package/lib/config.js.map +1 -0
  37. package/lib/encodings.d.ts +39 -0
  38. package/lib/encodings.d.ts.map +1 -0
  39. package/lib/encodings.js +311 -0
  40. package/lib/encodings.js.map +1 -0
  41. package/lib/http.d.ts +46 -0
  42. package/lib/http.d.ts.map +1 -0
  43. package/lib/http.js +143 -0
  44. package/lib/http.js.map +1 -0
  45. package/lib/retries.d.ts +18 -0
  46. package/lib/retries.d.ts.map +1 -0
  47. package/lib/retries.js +157 -0
  48. package/lib/retries.js.map +1 -0
  49. package/lib/schemas.d.ts +7 -0
  50. package/lib/schemas.d.ts.map +1 -0
  51. package/{shims/web.js → lib/schemas.js} +24 -6
  52. package/lib/schemas.js.map +1 -0
  53. package/lib/sdks.d.ts +39 -0
  54. package/lib/sdks.d.ts.map +1 -0
  55. package/lib/sdks.js +98 -0
  56. package/lib/sdks.js.map +1 -0
  57. package/lib/security.d.ts +57 -0
  58. package/lib/security.d.ts.map +1 -0
  59. package/lib/security.js +115 -0
  60. package/lib/security.js.map +1 -0
  61. package/lib/url.d.ts +4 -0
  62. package/lib/url.d.ts.map +1 -0
  63. package/lib/url.js +26 -0
  64. package/lib/url.js.map +1 -0
  65. package/models/components/index.d.ts +5 -0
  66. package/models/components/index.d.ts.map +1 -0
  67. package/{_shims/auto/runtime-node.js → models/components/index.js} +8 -5
  68. package/models/components/index.js.map +1 -0
  69. package/models/components/linkschema.d.ts +222 -0
  70. package/models/components/linkschema.d.ts.map +1 -0
  71. package/models/components/linkschema.js +189 -0
  72. package/models/components/linkschema.js.map +1 -0
  73. package/models/components/security.d.ts +16 -0
  74. package/models/components/security.d.ts.map +1 -0
  75. package/models/components/security.js +53 -0
  76. package/models/components/security.js.map +1 -0
  77. package/models/components/tagschema.d.ts +45 -0
  78. package/models/components/tagschema.d.ts.map +1 -0
  79. package/models/components/tagschema.js +76 -0
  80. package/models/components/tagschema.js.map +1 -0
  81. package/models/components/workspaceschema.d.ts +178 -0
  82. package/models/components/workspaceschema.d.ts.map +1 -0
  83. package/models/components/workspaceschema.js +190 -0
  84. package/models/components/workspaceschema.js.map +1 -0
  85. package/models/errors/badrequest.d.ts +65 -0
  86. package/models/errors/badrequest.d.ts.map +1 -0
  87. package/models/errors/badrequest.js +111 -0
  88. package/models/errors/badrequest.js.map +1 -0
  89. package/models/errors/conflict.d.ts +65 -0
  90. package/models/errors/conflict.d.ts.map +1 -0
  91. package/models/errors/conflict.js +111 -0
  92. package/models/errors/conflict.js.map +1 -0
  93. package/models/errors/forbidden.d.ts +65 -0
  94. package/models/errors/forbidden.d.ts.map +1 -0
  95. package/models/errors/forbidden.js +111 -0
  96. package/models/errors/forbidden.js.map +1 -0
  97. package/models/errors/index.d.ts +12 -0
  98. package/models/errors/index.d.ts.map +1 -0
  99. package/{_shims/auto/types-node.js → models/errors/index.js} +15 -5
  100. package/models/errors/index.js.map +1 -0
  101. package/models/errors/internalservererror.d.ts +65 -0
  102. package/models/errors/internalservererror.d.ts.map +1 -0
  103. package/models/errors/internalservererror.js +111 -0
  104. package/models/errors/internalservererror.js.map +1 -0
  105. package/models/errors/inviteexpired.d.ts +65 -0
  106. package/models/errors/inviteexpired.d.ts.map +1 -0
  107. package/models/errors/inviteexpired.js +111 -0
  108. package/models/errors/inviteexpired.js.map +1 -0
  109. package/models/errors/notfound.d.ts +65 -0
  110. package/models/errors/notfound.d.ts.map +1 -0
  111. package/models/errors/notfound.js +111 -0
  112. package/models/errors/notfound.js.map +1 -0
  113. package/models/errors/ratelimitexceeded.d.ts +65 -0
  114. package/models/errors/ratelimitexceeded.d.ts.map +1 -0
  115. package/models/errors/ratelimitexceeded.js +111 -0
  116. package/models/errors/ratelimitexceeded.js.map +1 -0
  117. package/models/errors/sdkerror.d.ts +7 -0
  118. package/models/errors/sdkerror.d.ts.map +1 -0
  119. package/models/errors/sdkerror.js +19 -0
  120. package/models/errors/sdkerror.js.map +1 -0
  121. package/models/errors/sdkvalidationerror.d.ts +17 -0
  122. package/models/errors/sdkvalidationerror.d.ts.map +1 -0
  123. package/models/errors/sdkvalidationerror.js +107 -0
  124. package/models/errors/sdkvalidationerror.js.map +1 -0
  125. package/models/errors/unauthorized.d.ts +65 -0
  126. package/models/errors/unauthorized.d.ts.map +1 -0
  127. package/models/errors/unauthorized.js +111 -0
  128. package/models/errors/unauthorized.js.map +1 -0
  129. package/models/errors/unprocessableentity.d.ts +65 -0
  130. package/models/errors/unprocessableentity.d.ts.map +1 -0
  131. package/models/errors/unprocessableentity.js +111 -0
  132. package/models/errors/unprocessableentity.js.map +1 -0
  133. package/models/operations/bulkcreatelinks.d.ts +146 -0
  134. package/models/operations/bulkcreatelinks.d.ts.map +1 -0
  135. package/models/operations/bulkcreatelinks.js +138 -0
  136. package/models/operations/bulkcreatelinks.js.map +1 -0
  137. package/models/operations/createlink.d.ts +146 -0
  138. package/models/operations/createlink.d.ts.map +1 -0
  139. package/models/operations/createlink.js +141 -0
  140. package/models/operations/createlink.js.map +1 -0
  141. package/models/operations/createtag.d.ts +39 -0
  142. package/models/operations/createtag.d.ts.map +1 -0
  143. package/models/operations/createtag.js +72 -0
  144. package/models/operations/createtag.js.map +1 -0
  145. package/models/operations/createworkspace.d.ts +22 -0
  146. package/models/operations/createworkspace.d.ts.map +1 -0
  147. package/models/operations/createworkspace.js +61 -0
  148. package/models/operations/createworkspace.js.map +1 -0
  149. package/models/operations/deletelink.d.ts +39 -0
  150. package/models/operations/deletelink.d.ts.map +1 -0
  151. package/models/operations/deletelink.js +75 -0
  152. package/models/operations/deletelink.js.map +1 -0
  153. package/models/operations/editlink.d.ts +166 -0
  154. package/models/operations/editlink.d.ts.map +1 -0
  155. package/models/operations/editlink.js +167 -0
  156. package/models/operations/editlink.js.map +1 -0
  157. package/models/operations/getbrowseranalytics.d.ts +378 -0
  158. package/models/operations/getbrowseranalytics.d.ts.map +1 -0
  159. package/models/operations/getbrowseranalytics.js +395 -0
  160. package/models/operations/getbrowseranalytics.js.map +1 -0
  161. package/models/operations/getcityanalytics.d.ts +641 -0
  162. package/models/operations/getcityanalytics.d.ts.map +1 -0
  163. package/models/operations/getcityanalytics.js +657 -0
  164. package/models/operations/getcityanalytics.js.map +1 -0
  165. package/models/operations/getclicksanalytics.d.ts +355 -0
  166. package/models/operations/getclicksanalytics.d.ts.map +1 -0
  167. package/models/operations/getclicksanalytics.js +369 -0
  168. package/models/operations/getclicksanalytics.js.map +1 -0
  169. package/models/operations/getcountryanalytics.d.ts +635 -0
  170. package/models/operations/getcountryanalytics.d.ts.map +1 -0
  171. package/models/operations/getcountryanalytics.js +653 -0
  172. package/models/operations/getcountryanalytics.js.map +1 -0
  173. package/models/operations/getdeviceanalytics.d.ts +378 -0
  174. package/models/operations/getdeviceanalytics.d.ts.map +1 -0
  175. package/models/operations/getdeviceanalytics.js +395 -0
  176. package/models/operations/getdeviceanalytics.js.map +1 -0
  177. package/models/operations/getlinkinfo.d.ts +25 -0
  178. package/models/operations/getlinkinfo.d.ts.map +1 -0
  179. package/models/operations/getlinkinfo.js +57 -0
  180. package/models/operations/getlinkinfo.js.map +1 -0
  181. package/models/operations/getlinks.d.ts +88 -0
  182. package/models/operations/getlinks.d.ts.map +1 -0
  183. package/models/operations/getlinks.js +108 -0
  184. package/models/operations/getlinks.js.map +1 -0
  185. package/models/operations/getlinkscount.d.ts +93 -0
  186. package/models/operations/getlinkscount.d.ts.map +1 -0
  187. package/models/operations/getlinkscount.js +105 -0
  188. package/models/operations/getlinkscount.js.map +1 -0
  189. package/models/operations/getosanalytics.d.ts +378 -0
  190. package/models/operations/getosanalytics.d.ts.map +1 -0
  191. package/models/operations/getosanalytics.js +395 -0
  192. package/models/operations/getosanalytics.js.map +1 -0
  193. package/models/operations/getqrcode.d.ts +60 -0
  194. package/models/operations/getqrcode.d.ts.map +1 -0
  195. package/models/operations/getqrcode.js +85 -0
  196. package/models/operations/getqrcode.js.map +1 -0
  197. package/models/operations/getrefereranalytics.d.ts +378 -0
  198. package/models/operations/getrefereranalytics.d.ts.map +1 -0
  199. package/models/operations/getrefereranalytics.js +395 -0
  200. package/models/operations/getrefereranalytics.js.map +1 -0
  201. package/models/operations/gettags.d.ts +10 -0
  202. package/models/operations/gettags.d.ts.map +1 -0
  203. package/{shims/node.js → models/operations/gettags.js} +12 -6
  204. package/models/operations/gettags.js.map +1 -0
  205. package/models/operations/gettimeseriesanalytics.d.ts +378 -0
  206. package/models/operations/gettimeseriesanalytics.d.ts.map +1 -0
  207. package/models/operations/gettimeseriesanalytics.js +395 -0
  208. package/models/operations/gettimeseriesanalytics.js.map +1 -0
  209. package/models/operations/gettoplinks.d.ts +378 -0
  210. package/models/operations/gettoplinks.d.ts.map +1 -0
  211. package/models/operations/gettoplinks.js +395 -0
  212. package/models/operations/gettoplinks.js.map +1 -0
  213. package/models/operations/gettopurls.d.ts +378 -0
  214. package/models/operations/gettopurls.d.ts.map +1 -0
  215. package/models/operations/gettopurls.js +395 -0
  216. package/models/operations/gettopurls.js.map +1 -0
  217. package/models/operations/getworkspace.d.ts +19 -0
  218. package/models/operations/getworkspace.d.ts.map +1 -0
  219. package/models/operations/getworkspace.js +53 -0
  220. package/models/operations/getworkspace.js.map +1 -0
  221. package/models/operations/index.d.ts +23 -0
  222. package/models/operations/index.d.ts.map +1 -0
  223. package/models/operations/index.js +42 -0
  224. package/models/operations/index.js.map +1 -0
  225. package/package.json +25 -98
  226. package/sdk/analytics.d.ts +78 -0
  227. package/sdk/analytics.d.ts.map +1 -0
  228. package/sdk/analytics.js +2044 -0
  229. package/sdk/analytics.js.map +1 -0
  230. package/sdk/index.d.ts +2 -0
  231. package/sdk/index.d.ts.map +1 -0
  232. package/{_shims/auto/runtime.js → sdk/index.js} +5 -5
  233. package/sdk/index.js.map +1 -0
  234. package/sdk/links.d.ts +58 -0
  235. package/sdk/links.d.ts.map +1 -0
  236. package/sdk/links.js +1309 -0
  237. package/sdk/links.js.map +1 -0
  238. package/sdk/qrcodes.d.ts +21 -0
  239. package/sdk/qrcodes.d.ts.map +1 -0
  240. package/sdk/qrcodes.js +249 -0
  241. package/sdk/qrcodes.js.map +1 -0
  242. package/sdk/sdk.d.ts +22 -0
  243. package/sdk/sdk.d.ts.map +1 -0
  244. package/sdk/sdk.js +59 -0
  245. package/sdk/sdk.js.map +1 -0
  246. package/sdk/tags.d.ts +23 -0
  247. package/sdk/tags.d.ts.map +1 -0
  248. package/sdk/tags.js +401 -0
  249. package/sdk/tags.js.map +1 -0
  250. package/sdk/workspaces.d.ts +30 -0
  251. package/sdk/workspaces.d.ts.map +1 -0
  252. package/sdk/workspaces.js +556 -0
  253. package/sdk/workspaces.js.map +1 -0
  254. package/src/hooks/hooks.ts +81 -0
  255. package/src/hooks/index.ts +6 -0
  256. package/src/hooks/types.ts +74 -0
  257. package/src/index.ts +8 -209
  258. package/src/lib/base64.ts +37 -0
  259. package/src/lib/config.ts +70 -0
  260. package/src/lib/encodings.ts +384 -0
  261. package/src/lib/http.ts +215 -0
  262. package/src/lib/retries.ts +226 -0
  263. package/src/lib/schemas.ts +22 -0
  264. package/src/lib/sdks.ts +139 -0
  265. package/src/lib/security.ts +180 -0
  266. package/src/lib/url.ts +31 -0
  267. package/src/models/components/index.ts +8 -0
  268. package/src/models/components/linkschema.ts +383 -0
  269. package/src/models/components/security.ts +40 -0
  270. package/src/models/components/tagschema.ts +79 -0
  271. package/src/models/components/workspaceschema.ts +316 -0
  272. package/src/models/errors/badrequest.ts +140 -0
  273. package/src/models/errors/conflict.ts +140 -0
  274. package/src/models/errors/forbidden.ts +140 -0
  275. package/src/models/errors/index.ts +15 -0
  276. package/src/models/errors/internalservererror.ts +140 -0
  277. package/src/models/errors/inviteexpired.ts +140 -0
  278. package/src/models/errors/notfound.ts +140 -0
  279. package/src/models/errors/ratelimitexceeded.ts +140 -0
  280. package/src/models/errors/sdkerror.ts +22 -0
  281. package/src/models/errors/sdkvalidationerror.ts +95 -0
  282. package/src/models/errors/unauthorized.ts +140 -0
  283. package/src/models/errors/unprocessableentity.ts +140 -0
  284. package/src/models/operations/bulkcreatelinks.ts +254 -0
  285. package/src/models/operations/createlink.ts +255 -0
  286. package/src/models/operations/createtag.ts +69 -0
  287. package/src/models/operations/createworkspace.ts +54 -0
  288. package/src/models/operations/deletelink.ts +84 -0
  289. package/src/models/operations/editlink.ts +300 -0
  290. package/src/models/operations/getbrowseranalytics.ts +484 -0
  291. package/src/models/operations/getcityanalytics.ts +744 -0
  292. package/src/models/operations/getclicksanalytics.ts +427 -0
  293. package/src/models/operations/getcountryanalytics.ts +743 -0
  294. package/src/models/operations/getdeviceanalytics.ts +480 -0
  295. package/src/models/operations/getlinkinfo.ts +53 -0
  296. package/src/models/operations/getlinks.ts +155 -0
  297. package/src/models/operations/getlinkscount.ts +157 -0
  298. package/src/models/operations/getosanalytics.ts +475 -0
  299. package/src/models/operations/getqrcode.ts +106 -0
  300. package/src/models/operations/getrefereranalytics.ts +484 -0
  301. package/src/models/operations/gettags.ts +18 -0
  302. package/src/models/operations/gettimeseriesanalytics.ts +476 -0
  303. package/src/models/operations/gettoplinks.ts +475 -0
  304. package/src/models/operations/gettopurls.ts +475 -0
  305. package/src/models/operations/getworkspace.ts +43 -0
  306. package/src/models/operations/index.ts +26 -0
  307. package/src/sdk/analytics.ts +2493 -0
  308. package/src/sdk/index.ts +5 -0
  309. package/src/sdk/links.ts +1617 -0
  310. package/src/sdk/qrcodes.ts +276 -0
  311. package/src/sdk/sdk.ts +66 -0
  312. package/src/sdk/tags.ts +470 -0
  313. package/src/sdk/workspaces.ts +670 -0
  314. package/src/types/blobs.ts +30 -0
  315. package/src/types/index.ts +8 -0
  316. package/src/types/operations.ts +25 -0
  317. package/src/types/rfcdate.ts +54 -0
  318. package/types/blobs.d.ts +4 -0
  319. package/types/blobs.d.ts.map +1 -0
  320. package/{resources/projects/projects.js → types/blobs.js} +23 -24
  321. package/types/blobs.js.map +1 -0
  322. package/types/index.d.ts +5 -0
  323. package/types/index.d.ts.map +1 -0
  324. package/types/index.js +14 -0
  325. package/types/index.js.map +1 -0
  326. package/types/operations.d.ts +13 -0
  327. package/types/operations.d.ts.map +1 -0
  328. package/types/operations.js +19 -0
  329. package/types/operations.js.map +1 -0
  330. package/types/rfcdate.d.ts +21 -0
  331. package/types/rfcdate.d.ts.map +1 -0
  332. package/types/rfcdate.js +46 -0
  333. package/types/rfcdate.js.map +1 -0
  334. package/CHANGELOG.md +0 -116
  335. package/LICENSE +0 -201
  336. package/_shims/MultipartBody.d.ts +0 -9
  337. package/_shims/MultipartBody.d.ts.map +0 -1
  338. package/_shims/MultipartBody.js +0 -16
  339. package/_shims/MultipartBody.js.map +0 -1
  340. package/_shims/MultipartBody.mjs +0 -12
  341. package/_shims/MultipartBody.mjs.map +0 -1
  342. package/_shims/README.md +0 -46
  343. package/_shims/auto/runtime-bun.d.ts +0 -5
  344. package/_shims/auto/runtime-bun.d.ts.map +0 -1
  345. package/_shims/auto/runtime-bun.js.map +0 -1
  346. package/_shims/auto/runtime-bun.mjs +0 -2
  347. package/_shims/auto/runtime-bun.mjs.map +0 -1
  348. package/_shims/auto/runtime-node.d.ts +0 -5
  349. package/_shims/auto/runtime-node.d.ts.map +0 -1
  350. package/_shims/auto/runtime-node.js.map +0 -1
  351. package/_shims/auto/runtime-node.mjs +0 -2
  352. package/_shims/auto/runtime-node.mjs.map +0 -1
  353. package/_shims/auto/runtime.d.ts +0 -5
  354. package/_shims/auto/runtime.d.ts.map +0 -1
  355. package/_shims/auto/runtime.js.map +0 -1
  356. package/_shims/auto/runtime.mjs +0 -2
  357. package/_shims/auto/runtime.mjs.map +0 -1
  358. package/_shims/auto/types-node.d.ts +0 -5
  359. package/_shims/auto/types-node.d.ts.map +0 -1
  360. package/_shims/auto/types-node.js.map +0 -1
  361. package/_shims/auto/types-node.mjs +0 -2
  362. package/_shims/auto/types-node.mjs.map +0 -1
  363. package/_shims/auto/types.d.ts +0 -101
  364. package/_shims/auto/types.js +0 -3
  365. package/_shims/auto/types.mjs +0 -3
  366. package/_shims/bun-runtime.d.ts +0 -6
  367. package/_shims/bun-runtime.d.ts.map +0 -1
  368. package/_shims/bun-runtime.js +0 -14
  369. package/_shims/bun-runtime.js.map +0 -1
  370. package/_shims/bun-runtime.mjs +0 -10
  371. package/_shims/bun-runtime.mjs.map +0 -1
  372. package/_shims/index.d.ts +0 -81
  373. package/_shims/index.js +0 -13
  374. package/_shims/index.mjs +0 -7
  375. package/_shims/manual-types.d.ts +0 -12
  376. package/_shims/manual-types.js +0 -3
  377. package/_shims/manual-types.mjs +0 -3
  378. package/_shims/node-runtime.d.ts +0 -3
  379. package/_shims/node-runtime.d.ts.map +0 -1
  380. package/_shims/node-runtime.js +0 -90
  381. package/_shims/node-runtime.js.map +0 -1
  382. package/_shims/node-runtime.mjs +0 -56
  383. package/_shims/node-runtime.mjs.map +0 -1
  384. package/_shims/node-types.d.ts +0 -42
  385. package/_shims/node-types.js +0 -3
  386. package/_shims/node-types.mjs +0 -3
  387. package/_shims/registry.d.ts +0 -37
  388. package/_shims/registry.d.ts.map +0 -1
  389. package/_shims/registry.js +0 -41
  390. package/_shims/registry.js.map +0 -1
  391. package/_shims/registry.mjs +0 -37
  392. package/_shims/registry.mjs.map +0 -1
  393. package/_shims/web-runtime.d.ts +0 -5
  394. package/_shims/web-runtime.d.ts.map +0 -1
  395. package/_shims/web-runtime.js +0 -78
  396. package/_shims/web-runtime.js.map +0 -1
  397. package/_shims/web-runtime.mjs +0 -71
  398. package/_shims/web-runtime.mjs.map +0 -1
  399. package/_shims/web-types.d.ts +0 -83
  400. package/_shims/web-types.js +0 -3
  401. package/_shims/web-types.mjs +0 -3
  402. package/core.d.ts +0 -237
  403. package/core.d.ts.map +0 -1
  404. package/core.js +0 -868
  405. package/core.js.map +0 -1
  406. package/core.mjs +0 -837
  407. package/core.mjs.map +0 -1
  408. package/error.d.ts +0 -53
  409. package/error.d.ts.map +0 -1
  410. package/error.js +0 -143
  411. package/error.js.map +0 -1
  412. package/error.mjs +0 -127
  413. package/error.mjs.map +0 -1
  414. package/index.d.mts +0 -127
  415. package/index.mjs +0 -90
  416. package/index.mjs.map +0 -1
  417. package/resource.d.ts +0 -6
  418. package/resource.d.ts.map +0 -1
  419. package/resource.js +0 -11
  420. package/resource.js.map +0 -1
  421. package/resource.mjs +0 -7
  422. package/resource.mjs.map +0 -1
  423. package/resources/index.d.ts +0 -4
  424. package/resources/index.d.ts.map +0 -1
  425. package/resources/index.js +0 -11
  426. package/resources/index.js.map +0 -1
  427. package/resources/index.mjs +0 -5
  428. package/resources/index.mjs.map +0 -1
  429. package/resources/links/bulk.d.ts +0 -274
  430. package/resources/links/bulk.d.ts.map +0 -1
  431. package/resources/links/bulk.js +0 -18
  432. package/resources/links/bulk.js.map +0 -1
  433. package/resources/links/bulk.mjs +0 -14
  434. package/resources/links/bulk.mjs.map +0 -1
  435. package/resources/links/index.d.ts +0 -4
  436. package/resources/links/index.d.ts.map +0 -1
  437. package/resources/links/index.js +0 -11
  438. package/resources/links/index.js.map +0 -1
  439. package/resources/links/index.mjs +0 -5
  440. package/resources/links/index.mjs.map +0 -1
  441. package/resources/links/info.d.ts +0 -186
  442. package/resources/links/info.d.ts.map +0 -1
  443. package/resources/links/info.js +0 -18
  444. package/resources/links/info.js.map +0 -1
  445. package/resources/links/info.mjs +0 -14
  446. package/resources/links/info.mjs.map +0 -1
  447. package/resources/links/links.d.ts +0 -916
  448. package/resources/links/links.d.ts.map +0 -1
  449. package/resources/links/links.js +0 -72
  450. package/resources/links/links.js.map +0 -1
  451. package/resources/links/links.mjs +0 -45
  452. package/resources/links/links.mjs.map +0 -1
  453. package/resources/projects/index.d.ts +0 -3
  454. package/resources/projects/index.d.ts.map +0 -1
  455. package/resources/projects/index.js +0 -9
  456. package/resources/projects/index.js.map +0 -1
  457. package/resources/projects/index.mjs +0 -4
  458. package/resources/projects/index.mjs.map +0 -1
  459. package/resources/projects/projects.d.ts +0 -200
  460. package/resources/projects/projects.d.ts.map +0 -1
  461. package/resources/projects/projects.js.map +0 -1
  462. package/resources/projects/projects.mjs +0 -26
  463. package/resources/projects/projects.mjs.map +0 -1
  464. package/resources/projects/tags.d.ts +0 -4
  465. package/resources/projects/tags.d.ts.map +0 -1
  466. package/resources/projects/tags.js +0 -9
  467. package/resources/projects/tags.js.map +0 -1
  468. package/resources/projects/tags.mjs +0 -5
  469. package/resources/projects/tags.mjs.map +0 -1
  470. package/resources/qr.d.ts +0 -45
  471. package/resources/qr.d.ts.map +0 -1
  472. package/resources/qr.js +0 -18
  473. package/resources/qr.js.map +0 -1
  474. package/resources/qr.mjs +0 -14
  475. package/resources/qr.mjs.map +0 -1
  476. package/shims/node.d.ts +0 -29
  477. package/shims/node.d.ts.map +0 -1
  478. package/shims/node.js.map +0 -1
  479. package/shims/node.mjs +0 -5
  480. package/shims/node.mjs.map +0 -1
  481. package/shims/web.d.ts +0 -26
  482. package/shims/web.d.ts.map +0 -1
  483. package/shims/web.js.map +0 -1
  484. package/shims/web.mjs +0 -5
  485. package/shims/web.mjs.map +0 -1
  486. package/src/_shims/MultipartBody.ts +0 -9
  487. package/src/_shims/README.md +0 -46
  488. package/src/_shims/auto/runtime-bun.ts +0 -4
  489. package/src/_shims/auto/runtime-node.ts +0 -4
  490. package/src/_shims/auto/runtime.ts +0 -4
  491. package/src/_shims/auto/types-node.ts +0 -4
  492. package/src/_shims/auto/types.d.ts +0 -101
  493. package/src/_shims/auto/types.js +0 -3
  494. package/src/_shims/auto/types.mjs +0 -3
  495. package/src/_shims/bun-runtime.ts +0 -14
  496. package/src/_shims/index.d.ts +0 -81
  497. package/src/_shims/index.js +0 -13
  498. package/src/_shims/index.mjs +0 -7
  499. package/src/_shims/manual-types.d.ts +0 -12
  500. package/src/_shims/manual-types.js +0 -3
  501. package/src/_shims/manual-types.mjs +0 -3
  502. package/src/_shims/node-runtime.ts +0 -83
  503. package/src/_shims/node-types.d.ts +0 -42
  504. package/src/_shims/node-types.js +0 -3
  505. package/src/_shims/node-types.mjs +0 -3
  506. package/src/_shims/registry.ts +0 -63
  507. package/src/_shims/web-runtime.ts +0 -103
  508. package/src/_shims/web-types.d.ts +0 -83
  509. package/src/_shims/web-types.js +0 -3
  510. package/src/_shims/web-types.mjs +0 -3
  511. package/src/core.ts +0 -1145
  512. package/src/error.ts +0 -146
  513. package/src/lib/.keep +0 -4
  514. package/src/resource.ts +0 -11
  515. package/src/resources/index.ts +0 -20
  516. package/src/resources/links/bulk.ts +0 -337
  517. package/src/resources/links/index.ts +0 -15
  518. package/src/resources/links/info.ts +0 -230
  519. package/src/resources/links/links.ts +0 -1135
  520. package/src/resources/projects/index.ts +0 -4
  521. package/src/resources/projects/projects.ts +0 -253
  522. package/src/resources/projects/tags.ts +0 -5
  523. package/src/resources/qr.ts +0 -64
  524. package/src/shims/node.ts +0 -50
  525. package/src/shims/web.ts +0 -50
  526. package/src/tsconfig.json +0 -11
  527. package/src/uploads.ts +0 -245
  528. package/src/version.ts +0 -1
  529. package/uploads.d.ts +0 -75
  530. package/uploads.d.ts.map +0 -1
  531. package/uploads.js +0 -163
  532. package/uploads.js.map +0 -1
  533. package/uploads.mjs +0 -150
  534. package/uploads.mjs.map +0 -1
  535. package/version.d.ts +0 -2
  536. package/version.d.ts.map +0 -1
  537. package/version.js +0 -5
  538. package/version.js.map +0 -1
  539. package/version.mjs +0 -2
  540. package/version.mjs.map +0 -1
@@ -1,1135 +0,0 @@
1
- // File generated from our OpenAPI spec by Stainless.
2
-
3
- import * as Core from "../../core";
4
- import { APIResource } from "../../resource";
5
- import * as LinksAPI from "./links";
6
- import * as BulkAPI from "./bulk";
7
- import * as InfoAPI from "./info";
8
-
9
- export class Links extends APIResource {
10
- info: InfoAPI.Info = new InfoAPI.Info(this._client);
11
- bulk: BulkAPI.Bulk = new BulkAPI.Bulk(this._client);
12
-
13
- /**
14
- * Create a new link for the authenticated project.
15
- */
16
- create(params: LinkCreateParams, options?: Core.RequestOptions): Core.APIPromise<LinkCreateResponse> {
17
- const { projectSlug = this._client.projectSlug, ...body } = params;
18
- return this._client.post('/links', { query: { projectSlug }, body, ...options });
19
- }
20
-
21
- /**
22
- * Edit a link for the authenticated project.
23
- */
24
- update(
25
- linkId: string,
26
- params: LinkUpdateParams,
27
- options?: Core.RequestOptions,
28
- ): Core.APIPromise<LinkUpdateResponse> {
29
- const { projectSlug = this._client.projectSlug, ...body } = params;
30
- return this._client.put(`/links/${linkId}`, { query: { projectSlug }, body, ...options });
31
- }
32
-
33
- /**
34
- * Retrieve a list of links for the authenticated project. The list will be
35
- * paginated and the provided query parameters allow filtering the returned links.
36
- */
37
- list(params: LinkListParams, options?: Core.RequestOptions): Core.APIPromise<LinkListResponse> {
38
- const { projectSlug = this._client.projectSlug, ...query } = params;
39
- return this._client.get('/links', { query: { projectSlug, ...query }, ...options });
40
- }
41
-
42
- /**
43
- * Delete a link for the authenticated project.
44
- */
45
- deleteLink(
46
- linkId: string,
47
- params: LinkDeleteLinkParams,
48
- options?: Core.RequestOptions,
49
- ): Core.APIPromise<LinkDeleteLinkResponse> {
50
- const { projectSlug = this._client.projectSlug } = params;
51
- return this._client.delete(`/links/${linkId}`, { query: { projectSlug }, ...options });
52
- }
53
- }
54
-
55
- export interface LinkCreateResponse {
56
- /**
57
- * The unique ID of the short link.
58
- */
59
- id: string;
60
-
61
- /**
62
- * The Android destination URL for the short link for Android device targeting.
63
- */
64
- android: string | null;
65
-
66
- /**
67
- * Whether the short link is archived.
68
- */
69
- archived: boolean;
70
-
71
- /**
72
- * The number of clicks on the short link.
73
- */
74
- clicks: number;
75
-
76
- /**
77
- * The comments for the short link.
78
- */
79
- comments: string | null;
80
-
81
- /**
82
- * The date and time when the short link was created.
83
- */
84
- createdAt: string;
85
-
86
- /**
87
- * The description of the short link generated via `api.dub.co/metatags`. Will be
88
- * used for Custom Social Media Cards if `proxy` is true.
89
- */
90
- description: string | null;
91
-
92
- /**
93
- * The domain of the short link. If not provided, the primary domain for the
94
- * project will be used (or `dub.sh` if the project has no domains).
95
- */
96
- domain: string;
97
-
98
- /**
99
- * The date and time when the short link will expire in ISO-8601 format. Must be in
100
- * the future.
101
- */
102
- expiresAt: string | null;
103
-
104
- /**
105
- * Geo targeting information for the short link in JSON format
106
- * `{[COUNTRY]: https://example.com }`. Learn more: https://d.to/geo
107
- */
108
- geo: Record<string, string> | null;
109
-
110
- /**
111
- * The image of the short link generated via `api.dub.co/metatags`. Will be used
112
- * for Custom Social Media Cards if `proxy` is true.
113
- */
114
- image: string | null;
115
-
116
- /**
117
- * The iOS destination URL for the short link for iOS device targeting.
118
- */
119
- ios: string | null;
120
-
121
- /**
122
- * The short link slug. If not provided, a random 7-character slug will be
123
- * generated.
124
- */
125
- key: string;
126
-
127
- /**
128
- * The date and time when the short link was last clicked.
129
- */
130
- lastClicked: string | null;
131
-
132
- /**
133
- * The password required to access the destination URL of the short link.
134
- */
135
- password: string | null;
136
-
137
- /**
138
- * The project ID of the short link.
139
- */
140
- projectId: string;
141
-
142
- /**
143
- * Whether the short link uses Custom Social Media Cards feature.
144
- */
145
- proxy: boolean;
146
-
147
- /**
148
- * Whether the short link's stats are publicly accessible.
149
- */
150
- publicStats: boolean;
151
-
152
- /**
153
- * The full URL of the QR code for the short link (e.g.
154
- * `https://api.dub.co/qr?url=https://dub.sh/try`).
155
- */
156
- qrCode: string;
157
-
158
- /**
159
- * Whether the short link uses link cloaking.
160
- */
161
- rewrite: boolean;
162
-
163
- /**
164
- * The full URL of the short link, including the https protocol (e.g.
165
- * `https://dub.sh/try`).
166
- */
167
- shortLink: string;
168
-
169
- /**
170
- * @deprecated: [DEPRECATED (use `tags` instead)]: The unique ID of the tag
171
- * assigned to the short link.
172
- */
173
- tagId: string | null;
174
-
175
- /**
176
- * The tags assigned to the short link.
177
- */
178
- tags: Array<LinkCreateResponse.Tag> | null;
179
-
180
- /**
181
- * The title of the short link generated via `api.dub.co/metatags`. Will be used
182
- * for Custom Social Media Cards if `proxy` is true.
183
- */
184
- title: string | null;
185
-
186
- /**
187
- * The date and time when the short link was last updated.
188
- */
189
- updatedAt: string;
190
-
191
- /**
192
- * The destination URL of the short link.
193
- */
194
- url: string;
195
-
196
- /**
197
- * The user ID of the creator of the short link.
198
- */
199
- userId: string;
200
-
201
- /**
202
- * The UTM campaign of the short link.
203
- */
204
- utm_campaign: string | null;
205
-
206
- /**
207
- * The UTM content of the short link.
208
- */
209
- utm_content: string | null;
210
-
211
- /**
212
- * The UTM medium of the short link.
213
- */
214
- utm_medium: string | null;
215
-
216
- /**
217
- * The UTM source of the short link.
218
- */
219
- utm_source: string | null;
220
-
221
- /**
222
- * The UTM term of the short link.
223
- */
224
- utm_term: string | null;
225
- }
226
-
227
- export namespace LinkCreateResponse {
228
- export interface Tag {
229
- /**
230
- * The unique ID of the tag.
231
- */
232
- id: string;
233
-
234
- /**
235
- * The color of the tag.
236
- */
237
- color: 'red' | 'yellow' | 'green' | 'blue' | 'purple' | 'pink' | 'brown';
238
-
239
- /**
240
- * The name of the tag.
241
- */
242
- name: string;
243
- }
244
- }
245
-
246
- export interface LinkUpdateResponse {
247
- /**
248
- * The unique ID of the short link.
249
- */
250
- id: string;
251
-
252
- /**
253
- * The Android destination URL for the short link for Android device targeting.
254
- */
255
- android: string | null;
256
-
257
- /**
258
- * Whether the short link is archived.
259
- */
260
- archived: boolean;
261
-
262
- /**
263
- * The number of clicks on the short link.
264
- */
265
- clicks: number;
266
-
267
- /**
268
- * The comments for the short link.
269
- */
270
- comments: string | null;
271
-
272
- /**
273
- * The date and time when the short link was created.
274
- */
275
- createdAt: string;
276
-
277
- /**
278
- * The description of the short link generated via `api.dub.co/metatags`. Will be
279
- * used for Custom Social Media Cards if `proxy` is true.
280
- */
281
- description: string | null;
282
-
283
- /**
284
- * The domain of the short link. If not provided, the primary domain for the
285
- * project will be used (or `dub.sh` if the project has no domains).
286
- */
287
- domain: string;
288
-
289
- /**
290
- * The date and time when the short link will expire in ISO-8601 format. Must be in
291
- * the future.
292
- */
293
- expiresAt: string | null;
294
-
295
- /**
296
- * Geo targeting information for the short link in JSON format
297
- * `{[COUNTRY]: https://example.com }`. Learn more: https://d.to/geo
298
- */
299
- geo: Record<string, string> | null;
300
-
301
- /**
302
- * The image of the short link generated via `api.dub.co/metatags`. Will be used
303
- * for Custom Social Media Cards if `proxy` is true.
304
- */
305
- image: string | null;
306
-
307
- /**
308
- * The iOS destination URL for the short link for iOS device targeting.
309
- */
310
- ios: string | null;
311
-
312
- /**
313
- * The short link slug. If not provided, a random 7-character slug will be
314
- * generated.
315
- */
316
- key: string;
317
-
318
- /**
319
- * The date and time when the short link was last clicked.
320
- */
321
- lastClicked: string | null;
322
-
323
- /**
324
- * The password required to access the destination URL of the short link.
325
- */
326
- password: string | null;
327
-
328
- /**
329
- * The project ID of the short link.
330
- */
331
- projectId: string;
332
-
333
- /**
334
- * Whether the short link uses Custom Social Media Cards feature.
335
- */
336
- proxy: boolean;
337
-
338
- /**
339
- * Whether the short link's stats are publicly accessible.
340
- */
341
- publicStats: boolean;
342
-
343
- /**
344
- * The full URL of the QR code for the short link (e.g.
345
- * `https://api.dub.co/qr?url=https://dub.sh/try`).
346
- */
347
- qrCode: string;
348
-
349
- /**
350
- * Whether the short link uses link cloaking.
351
- */
352
- rewrite: boolean;
353
-
354
- /**
355
- * The full URL of the short link, including the https protocol (e.g.
356
- * `https://dub.sh/try`).
357
- */
358
- shortLink: string;
359
-
360
- /**
361
- * @deprecated: [DEPRECATED (use `tags` instead)]: The unique ID of the tag
362
- * assigned to the short link.
363
- */
364
- tagId: string | null;
365
-
366
- /**
367
- * The tags assigned to the short link.
368
- */
369
- tags: Array<LinkUpdateResponse.Tag> | null;
370
-
371
- /**
372
- * The title of the short link generated via `api.dub.co/metatags`. Will be used
373
- * for Custom Social Media Cards if `proxy` is true.
374
- */
375
- title: string | null;
376
-
377
- /**
378
- * The date and time when the short link was last updated.
379
- */
380
- updatedAt: string;
381
-
382
- /**
383
- * The destination URL of the short link.
384
- */
385
- url: string;
386
-
387
- /**
388
- * The user ID of the creator of the short link.
389
- */
390
- userId: string;
391
-
392
- /**
393
- * The UTM campaign of the short link.
394
- */
395
- utm_campaign: string | null;
396
-
397
- /**
398
- * The UTM content of the short link.
399
- */
400
- utm_content: string | null;
401
-
402
- /**
403
- * The UTM medium of the short link.
404
- */
405
- utm_medium: string | null;
406
-
407
- /**
408
- * The UTM source of the short link.
409
- */
410
- utm_source: string | null;
411
-
412
- /**
413
- * The UTM term of the short link.
414
- */
415
- utm_term: string | null;
416
- }
417
-
418
- export namespace LinkUpdateResponse {
419
- export interface Tag {
420
- /**
421
- * The unique ID of the tag.
422
- */
423
- id: string;
424
-
425
- /**
426
- * The color of the tag.
427
- */
428
- color: 'red' | 'yellow' | 'green' | 'blue' | 'purple' | 'pink' | 'brown';
429
-
430
- /**
431
- * The name of the tag.
432
- */
433
- name: string;
434
- }
435
- }
436
-
437
- export type LinkListResponse = Array<LinkListResponse.LinkListResponseItem>;
438
-
439
- export namespace LinkListResponse {
440
- export interface LinkListResponseItem {
441
- /**
442
- * The unique ID of the short link.
443
- */
444
- id: string;
445
-
446
- /**
447
- * The Android destination URL for the short link for Android device targeting.
448
- */
449
- android: string | null;
450
-
451
- /**
452
- * Whether the short link is archived.
453
- */
454
- archived: boolean;
455
-
456
- /**
457
- * The number of clicks on the short link.
458
- */
459
- clicks: number;
460
-
461
- /**
462
- * The comments for the short link.
463
- */
464
- comments: string | null;
465
-
466
- /**
467
- * The date and time when the short link was created.
468
- */
469
- createdAt: string;
470
-
471
- /**
472
- * The description of the short link generated via `api.dub.co/metatags`. Will be
473
- * used for Custom Social Media Cards if `proxy` is true.
474
- */
475
- description: string | null;
476
-
477
- /**
478
- * The domain of the short link. If not provided, the primary domain for the
479
- * project will be used (or `dub.sh` if the project has no domains).
480
- */
481
- domain: string;
482
-
483
- /**
484
- * The date and time when the short link will expire in ISO-8601 format. Must be in
485
- * the future.
486
- */
487
- expiresAt: string | null;
488
-
489
- /**
490
- * Geo targeting information for the short link in JSON format
491
- * `{[COUNTRY]: https://example.com }`. Learn more: https://d.to/geo
492
- */
493
- geo: Record<string, string> | null;
494
-
495
- /**
496
- * The image of the short link generated via `api.dub.co/metatags`. Will be used
497
- * for Custom Social Media Cards if `proxy` is true.
498
- */
499
- image: string | null;
500
-
501
- /**
502
- * The iOS destination URL for the short link for iOS device targeting.
503
- */
504
- ios: string | null;
505
-
506
- /**
507
- * The short link slug. If not provided, a random 7-character slug will be
508
- * generated.
509
- */
510
- key: string;
511
-
512
- /**
513
- * The date and time when the short link was last clicked.
514
- */
515
- lastClicked: string | null;
516
-
517
- /**
518
- * The password required to access the destination URL of the short link.
519
- */
520
- password: string | null;
521
-
522
- /**
523
- * The project ID of the short link.
524
- */
525
- projectId: string;
526
-
527
- /**
528
- * Whether the short link uses Custom Social Media Cards feature.
529
- */
530
- proxy: boolean;
531
-
532
- /**
533
- * Whether the short link's stats are publicly accessible.
534
- */
535
- publicStats: boolean;
536
-
537
- /**
538
- * The full URL of the QR code for the short link (e.g.
539
- * `https://api.dub.co/qr?url=https://dub.sh/try`).
540
- */
541
- qrCode: string;
542
-
543
- /**
544
- * Whether the short link uses link cloaking.
545
- */
546
- rewrite: boolean;
547
-
548
- /**
549
- * The full URL of the short link, including the https protocol (e.g.
550
- * `https://dub.sh/try`).
551
- */
552
- shortLink: string;
553
-
554
- /**
555
- * @deprecated: [DEPRECATED (use `tags` instead)]: The unique ID of the tag
556
- * assigned to the short link.
557
- */
558
- tagId: string | null;
559
-
560
- /**
561
- * The tags assigned to the short link.
562
- */
563
- tags: Array<LinkListResponseItem.Tag> | null;
564
-
565
- /**
566
- * The title of the short link generated via `api.dub.co/metatags`. Will be used
567
- * for Custom Social Media Cards if `proxy` is true.
568
- */
569
- title: string | null;
570
-
571
- /**
572
- * The date and time when the short link was last updated.
573
- */
574
- updatedAt: string;
575
-
576
- /**
577
- * The destination URL of the short link.
578
- */
579
- url: string;
580
-
581
- /**
582
- * The user ID of the creator of the short link.
583
- */
584
- userId: string;
585
-
586
- /**
587
- * The UTM campaign of the short link.
588
- */
589
- utm_campaign: string | null;
590
-
591
- /**
592
- * The UTM content of the short link.
593
- */
594
- utm_content: string | null;
595
-
596
- /**
597
- * The UTM medium of the short link.
598
- */
599
- utm_medium: string | null;
600
-
601
- /**
602
- * The UTM source of the short link.
603
- */
604
- utm_source: string | null;
605
-
606
- /**
607
- * The UTM term of the short link.
608
- */
609
- utm_term: string | null;
610
- }
611
-
612
- export namespace LinkListResponseItem {
613
- export interface Tag {
614
- /**
615
- * The unique ID of the tag.
616
- */
617
- id: string;
618
-
619
- /**
620
- * The color of the tag.
621
- */
622
- color: 'red' | 'yellow' | 'green' | 'blue' | 'purple' | 'pink' | 'brown';
623
-
624
- /**
625
- * The name of the tag.
626
- */
627
- name: string;
628
- }
629
- }
630
- }
631
-
632
- export interface LinkDeleteLinkResponse {
633
- /**
634
- * The unique ID of the short link.
635
- */
636
- id: string;
637
-
638
- /**
639
- * The Android destination URL for the short link for Android device targeting.
640
- */
641
- android: string | null;
642
-
643
- /**
644
- * Whether the short link is archived.
645
- */
646
- archived: boolean;
647
-
648
- /**
649
- * The number of clicks on the short link.
650
- */
651
- clicks: number;
652
-
653
- /**
654
- * The comments for the short link.
655
- */
656
- comments: string | null;
657
-
658
- /**
659
- * The date and time when the short link was created.
660
- */
661
- createdAt: string;
662
-
663
- /**
664
- * The description of the short link generated via `api.dub.co/metatags`. Will be
665
- * used for Custom Social Media Cards if `proxy` is true.
666
- */
667
- description: string | null;
668
-
669
- /**
670
- * The domain of the short link. If not provided, the primary domain for the
671
- * project will be used (or `dub.sh` if the project has no domains).
672
- */
673
- domain: string;
674
-
675
- /**
676
- * The date and time when the short link will expire in ISO-8601 format. Must be in
677
- * the future.
678
- */
679
- expiresAt: string | null;
680
-
681
- /**
682
- * Geo targeting information for the short link in JSON format
683
- * `{[COUNTRY]: https://example.com }`. Learn more: https://d.to/geo
684
- */
685
- geo: Record<string, string> | null;
686
-
687
- /**
688
- * The image of the short link generated via `api.dub.co/metatags`. Will be used
689
- * for Custom Social Media Cards if `proxy` is true.
690
- */
691
- image: string | null;
692
-
693
- /**
694
- * The iOS destination URL for the short link for iOS device targeting.
695
- */
696
- ios: string | null;
697
-
698
- /**
699
- * The short link slug. If not provided, a random 7-character slug will be
700
- * generated.
701
- */
702
- key: string;
703
-
704
- /**
705
- * The date and time when the short link was last clicked.
706
- */
707
- lastClicked: string | null;
708
-
709
- /**
710
- * The password required to access the destination URL of the short link.
711
- */
712
- password: string | null;
713
-
714
- /**
715
- * The project ID of the short link.
716
- */
717
- projectId: string;
718
-
719
- /**
720
- * Whether the short link uses Custom Social Media Cards feature.
721
- */
722
- proxy: boolean;
723
-
724
- /**
725
- * Whether the short link's stats are publicly accessible.
726
- */
727
- publicStats: boolean;
728
-
729
- /**
730
- * The full URL of the QR code for the short link (e.g.
731
- * `https://api.dub.co/qr?url=https://dub.sh/try`).
732
- */
733
- qrCode: string;
734
-
735
- /**
736
- * Whether the short link uses link cloaking.
737
- */
738
- rewrite: boolean;
739
-
740
- /**
741
- * The full URL of the short link, including the https protocol (e.g.
742
- * `https://dub.sh/try`).
743
- */
744
- shortLink: string;
745
-
746
- /**
747
- * @deprecated: [DEPRECATED (use `tags` instead)]: The unique ID of the tag
748
- * assigned to the short link.
749
- */
750
- tagId: string | null;
751
-
752
- /**
753
- * The tags assigned to the short link.
754
- */
755
- tags: Array<LinkDeleteLinkResponse.Tag> | null;
756
-
757
- /**
758
- * The title of the short link generated via `api.dub.co/metatags`. Will be used
759
- * for Custom Social Media Cards if `proxy` is true.
760
- */
761
- title: string | null;
762
-
763
- /**
764
- * The date and time when the short link was last updated.
765
- */
766
- updatedAt: string;
767
-
768
- /**
769
- * The destination URL of the short link.
770
- */
771
- url: string;
772
-
773
- /**
774
- * The user ID of the creator of the short link.
775
- */
776
- userId: string;
777
-
778
- /**
779
- * The UTM campaign of the short link.
780
- */
781
- utm_campaign: string | null;
782
-
783
- /**
784
- * The UTM content of the short link.
785
- */
786
- utm_content: string | null;
787
-
788
- /**
789
- * The UTM medium of the short link.
790
- */
791
- utm_medium: string | null;
792
-
793
- /**
794
- * The UTM source of the short link.
795
- */
796
- utm_source: string | null;
797
-
798
- /**
799
- * The UTM term of the short link.
800
- */
801
- utm_term: string | null;
802
- }
803
-
804
- export namespace LinkDeleteLinkResponse {
805
- export interface Tag {
806
- /**
807
- * The unique ID of the tag.
808
- */
809
- id: string;
810
-
811
- /**
812
- * The color of the tag.
813
- */
814
- color: 'red' | 'yellow' | 'green' | 'blue' | 'purple' | 'pink' | 'brown';
815
-
816
- /**
817
- * The name of the tag.
818
- */
819
- name: string;
820
- }
821
- }
822
-
823
- export interface LinkCreateParams {
824
- /**
825
- * Query param: The slug for the project that the link belongs to. E.g. for
826
- * `app.dub.co/acme`, the projectSlug is `acme`.
827
- */
828
- projectSlug?: string;
829
-
830
- /**
831
- * Body param: The destination URL of the short link.
832
- */
833
- url: string;
834
-
835
- /**
836
- * Body param: The Android destination URL for the short link for Android device
837
- * targeting.
838
- */
839
- android?: string | null;
840
-
841
- /**
842
- * Body param: Whether the short link is archived.
843
- */
844
- archived?: boolean;
845
-
846
- /**
847
- * Body param: The comments for the short link.
848
- */
849
- comments?: string | null;
850
-
851
- /**
852
- * Body param: The description of the short link generated via
853
- * `api.dub.co/metatags`. Will be used for Custom Social Media Cards if `proxy` is
854
- * true.
855
- */
856
- description?: string | null;
857
-
858
- /**
859
- * Body param: The domain of the short link. If not provided, the primary domain
860
- * for the project will be used (or `dub.sh` if the project has no domains).
861
- */
862
- domain?: string;
863
-
864
- /**
865
- * Body param: The date and time when the short link will expire in ISO-8601
866
- * format. Must be in the future.
867
- */
868
- expiresAt?: string | null;
869
-
870
- /**
871
- * Body param: Geo targeting information for the short link in JSON format
872
- * `{[COUNTRY]: https://example.com }`.
873
- */
874
- geo?: Record<string, string> | null;
875
-
876
- /**
877
- * Body param: The image of the short link generated via `api.dub.co/metatags`.
878
- * Will be used for Custom Social Media Cards if `proxy` is true.
879
- */
880
- image?: string | null;
881
-
882
- /**
883
- * Body param: The iOS destination URL for the short link for iOS device targeting.
884
- */
885
- ios?: string | null;
886
-
887
- /**
888
- * Body param: The short link slug. If not provided, a random 7-character slug will
889
- * be generated.
890
- */
891
- key?: string;
892
-
893
- /**
894
- * Body param: The password required to access the destination URL of the short
895
- * link.
896
- */
897
- password?: string | null;
898
-
899
- /**
900
- * Body param: The prefix of the short link slug for randomly-generated keys (e.g.
901
- * if prefix is `/c/`, generated keys will be in the `/c/:key` format). Will be
902
- * ignored if `key` is provided.
903
- */
904
- prefix?: string;
905
-
906
- /**
907
- * Body param: Whether the short link uses Custom Social Media Cards feature.
908
- */
909
- proxy?: boolean;
910
-
911
- /**
912
- * Body param: Whether the short link's stats are publicly accessible.
913
- */
914
- publicStats?: boolean;
915
-
916
- /**
917
- * Body param: Whether the short link uses link cloaking.
918
- */
919
- rewrite?: boolean;
920
-
921
- /**
922
- * Body param: [DEPRECATED (use tagIds instead)]: The unique ID of the tag assigned
923
- * to the short link.
924
- */
925
- tagId?: string | null;
926
-
927
- /**
928
- * Body param: The unique IDs of the tags assigned to the short link.
929
- */
930
- tagIds?: string | Array<string>;
931
-
932
- /**
933
- * Body param: The title of the short link generated via `api.dub.co/metatags`.
934
- * Will be used for Custom Social Media Cards if `proxy` is true.
935
- */
936
- title?: string | null;
937
- }
938
-
939
- export interface LinkUpdateParams {
940
- /**
941
- * Query param: The slug for the project that the link belongs to. E.g. for
942
- * `app.dub.co/acme`, the projectSlug is `acme`.
943
- */
944
- projectSlug?: string;
945
-
946
- /**
947
- * Body param: The destination URL of the short link.
948
- */
949
- url: string;
950
-
951
- /**
952
- * Body param: The Android destination URL for the short link for Android device
953
- * targeting.
954
- */
955
- android?: string | null;
956
-
957
- /**
958
- * Body param: Whether the short link is archived.
959
- */
960
- archived?: boolean;
961
-
962
- /**
963
- * Body param: The comments for the short link.
964
- */
965
- comments?: string | null;
966
-
967
- /**
968
- * Body param: The description of the short link generated via
969
- * `api.dub.co/metatags`. Will be used for Custom Social Media Cards if `proxy` is
970
- * true.
971
- */
972
- description?: string | null;
973
-
974
- /**
975
- * Body param: The domain of the short link. If not provided, the primary domain
976
- * for the project will be used (or `dub.sh` if the project has no domains).
977
- */
978
- domain?: string;
979
-
980
- /**
981
- * Body param: The date and time when the short link will expire in ISO-8601
982
- * format. Must be in the future.
983
- */
984
- expiresAt?: string | null;
985
-
986
- /**
987
- * Body param: Geo targeting information for the short link in JSON format
988
- * `{[COUNTRY]: https://example.com }`.
989
- */
990
- geo?: Record<string, string> | null;
991
-
992
- /**
993
- * Body param: The image of the short link generated via `api.dub.co/metatags`.
994
- * Will be used for Custom Social Media Cards if `proxy` is true.
995
- */
996
- image?: string | null;
997
-
998
- /**
999
- * Body param: The iOS destination URL for the short link for iOS device targeting.
1000
- */
1001
- ios?: string | null;
1002
-
1003
- /**
1004
- * Body param: The short link slug. If not provided, a random 7-character slug will
1005
- * be generated.
1006
- */
1007
- key?: string;
1008
-
1009
- /**
1010
- * Body param: The password required to access the destination URL of the short
1011
- * link.
1012
- */
1013
- password?: string | null;
1014
-
1015
- /**
1016
- * Body param: The prefix of the short link slug for randomly-generated keys (e.g.
1017
- * if prefix is `/c/`, generated keys will be in the `/c/:key` format). Will be
1018
- * ignored if `key` is provided.
1019
- */
1020
- prefix?: string;
1021
-
1022
- /**
1023
- * Body param: Whether the short link uses Custom Social Media Cards feature.
1024
- */
1025
- proxy?: boolean;
1026
-
1027
- /**
1028
- * Body param: Whether the short link's stats are publicly accessible.
1029
- */
1030
- publicStats?: boolean;
1031
-
1032
- /**
1033
- * Body param: Whether the short link uses link cloaking.
1034
- */
1035
- rewrite?: boolean;
1036
-
1037
- /**
1038
- * Body param: [DEPRECATED (use tagIds instead)]: The unique ID of the tag assigned
1039
- * to the short link.
1040
- */
1041
- tagId?: string | null;
1042
-
1043
- /**
1044
- * Body param: The unique IDs of the tags assigned to the short link.
1045
- */
1046
- tagIds?: string | Array<string>;
1047
-
1048
- /**
1049
- * Body param: The title of the short link generated via `api.dub.co/metatags`.
1050
- * Will be used for Custom Social Media Cards if `proxy` is true.
1051
- */
1052
- title?: string | null;
1053
- }
1054
-
1055
- export interface LinkListParams {
1056
- /**
1057
- * The slug for the project that the link belongs to. E.g. for `app.dub.co/acme`,
1058
- * the projectSlug is `acme`.
1059
- */
1060
- projectSlug?: string;
1061
-
1062
- /**
1063
- * The domain to filter the links by. E.g. `ac.me`. If not provided, all links for
1064
- * the project will be returned.
1065
- */
1066
- domain?: string;
1067
-
1068
- /**
1069
- * The page number for pagination (each page contains 100 links).
1070
- */
1071
- page?: number;
1072
-
1073
- /**
1074
- * The search term to filter the links by. The search term will be matched against
1075
- * the short link slug and the destination url.
1076
- */
1077
- search?: string;
1078
-
1079
- /**
1080
- * Whether to include archived links in the response. Defaults to `false` if not
1081
- * provided.
1082
- */
1083
- showArchived?: boolean;
1084
-
1085
- /**
1086
- * The field to sort the links by. The default is `createdAt`, and sort order is
1087
- * always descending.
1088
- */
1089
- sort?: 'createdAt' | 'clicks' | 'lastClicked';
1090
-
1091
- /**
1092
- * [DEPRECATED (use tagIds instead)]: The tag ID to filter the links by.
1093
- */
1094
- tagId?: string;
1095
-
1096
- /**
1097
- * The tag IDs to filter the links by.
1098
- */
1099
- tagIds?: string | Array<string>;
1100
-
1101
- /**
1102
- * The user ID to filter the links by.
1103
- */
1104
- userId?: string;
1105
-
1106
- /**
1107
- * Whether to include tags in the response. Defaults to `false` if not provided.
1108
- */
1109
- withTags?: boolean;
1110
- }
1111
-
1112
- export interface LinkDeleteLinkParams {
1113
- /**
1114
- * The slug for the project that the link belongs to. E.g. for `app.dub.co/acme`,
1115
- * the projectSlug is `acme`.
1116
- */
1117
- projectSlug?: string;
1118
- }
1119
-
1120
- export namespace Links {
1121
- export import LinkCreateResponse = LinksAPI.LinkCreateResponse;
1122
- export import LinkUpdateResponse = LinksAPI.LinkUpdateResponse;
1123
- export import LinkListResponse = LinksAPI.LinkListResponse;
1124
- export import LinkDeleteLinkResponse = LinksAPI.LinkDeleteLinkResponse;
1125
- export import LinkCreateParams = LinksAPI.LinkCreateParams;
1126
- export import LinkUpdateParams = LinksAPI.LinkUpdateParams;
1127
- export import LinkListParams = LinksAPI.LinkListParams;
1128
- export import LinkDeleteLinkParams = LinksAPI.LinkDeleteLinkParams;
1129
- export import Info = InfoAPI.Info;
1130
- export import InfoRetrieveResponse = InfoAPI.InfoRetrieveResponse;
1131
- export import InfoRetrieveParams = InfoAPI.InfoRetrieveParams;
1132
- export import Bulk = BulkAPI.Bulk;
1133
- export import BulkCreateResponse = BulkAPI.BulkCreateResponse;
1134
- export import BulkCreateParams = BulkAPI.BulkCreateParams;
1135
- }