dub 0.24.3 → 0.24.4

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 (80) hide show
  1. package/README.md +1 -0
  2. package/docs/sdks/links/README.md +3 -0
  3. package/lib/config.d.ts +2 -2
  4. package/lib/config.js +2 -2
  5. package/models/components/linkschema.d.ts +6 -0
  6. package/models/components/linkschema.d.ts.map +1 -1
  7. package/models/components/linkschema.js +4 -0
  8. package/models/components/linkschema.js.map +1 -1
  9. package/models/operations/bulkcreatelinks.d.ts +12 -6
  10. package/models/operations/bulkcreatelinks.d.ts.map +1 -1
  11. package/models/operations/bulkcreatelinks.js +8 -4
  12. package/models/operations/bulkcreatelinks.js.map +1 -1
  13. package/models/operations/createlink.d.ts +12 -6
  14. package/models/operations/createlink.d.ts.map +1 -1
  15. package/models/operations/createlink.js +8 -4
  16. package/models/operations/createlink.js.map +1 -1
  17. package/models/operations/editlink.d.ts +12 -6
  18. package/models/operations/editlink.d.ts.map +1 -1
  19. package/models/operations/editlink.js +8 -4
  20. package/models/operations/editlink.js.map +1 -1
  21. package/models/operations/getbrowseranalytics.d.ts +12 -0
  22. package/models/operations/getbrowseranalytics.d.ts.map +1 -1
  23. package/models/operations/getbrowseranalytics.js +8 -0
  24. package/models/operations/getbrowseranalytics.js.map +1 -1
  25. package/models/operations/getcityanalytics.d.ts +12 -0
  26. package/models/operations/getcityanalytics.d.ts.map +1 -1
  27. package/models/operations/getcityanalytics.js +8 -0
  28. package/models/operations/getcityanalytics.js.map +1 -1
  29. package/models/operations/getclicksanalytics.d.ts +12 -0
  30. package/models/operations/getclicksanalytics.d.ts.map +1 -1
  31. package/models/operations/getclicksanalytics.js +8 -0
  32. package/models/operations/getclicksanalytics.js.map +1 -1
  33. package/models/operations/getcountryanalytics.d.ts +12 -0
  34. package/models/operations/getcountryanalytics.d.ts.map +1 -1
  35. package/models/operations/getcountryanalytics.js +8 -0
  36. package/models/operations/getcountryanalytics.js.map +1 -1
  37. package/models/operations/getdeviceanalytics.d.ts +12 -0
  38. package/models/operations/getdeviceanalytics.d.ts.map +1 -1
  39. package/models/operations/getdeviceanalytics.js +8 -0
  40. package/models/operations/getdeviceanalytics.js.map +1 -1
  41. package/models/operations/getosanalytics.d.ts +12 -0
  42. package/models/operations/getosanalytics.d.ts.map +1 -1
  43. package/models/operations/getosanalytics.js +8 -0
  44. package/models/operations/getosanalytics.js.map +1 -1
  45. package/models/operations/getrefereranalytics.d.ts +12 -0
  46. package/models/operations/getrefereranalytics.d.ts.map +1 -1
  47. package/models/operations/getrefereranalytics.js +8 -0
  48. package/models/operations/getrefereranalytics.js.map +1 -1
  49. package/models/operations/gettimeseriesanalytics.d.ts +12 -0
  50. package/models/operations/gettimeseriesanalytics.d.ts.map +1 -1
  51. package/models/operations/gettimeseriesanalytics.js +8 -0
  52. package/models/operations/gettimeseriesanalytics.js.map +1 -1
  53. package/models/operations/gettoplinks.d.ts +12 -0
  54. package/models/operations/gettoplinks.d.ts.map +1 -1
  55. package/models/operations/gettoplinks.js +8 -0
  56. package/models/operations/gettoplinks.js.map +1 -1
  57. package/models/operations/gettopurls.d.ts +12 -0
  58. package/models/operations/gettopurls.d.ts.map +1 -1
  59. package/models/operations/gettopurls.js +8 -0
  60. package/models/operations/gettopurls.js.map +1 -1
  61. package/package.json +1 -1
  62. package/sdk/analytics.d.ts.map +1 -1
  63. package/sdk/analytics.js +50 -0
  64. package/sdk/analytics.js.map +1 -1
  65. package/src/lib/config.ts +2 -2
  66. package/src/models/components/linkschema.ts +10 -0
  67. package/src/models/operations/bulkcreatelinks.ts +20 -10
  68. package/src/models/operations/createlink.ts +20 -10
  69. package/src/models/operations/editlink.ts +20 -10
  70. package/src/models/operations/getbrowseranalytics.ts +20 -0
  71. package/src/models/operations/getcityanalytics.ts +20 -0
  72. package/src/models/operations/getclicksanalytics.ts +20 -0
  73. package/src/models/operations/getcountryanalytics.ts +20 -0
  74. package/src/models/operations/getdeviceanalytics.ts +20 -0
  75. package/src/models/operations/getosanalytics.ts +20 -0
  76. package/src/models/operations/getrefereranalytics.ts +20 -0
  77. package/src/models/operations/gettimeseriesanalytics.ts +20 -0
  78. package/src/models/operations/gettoplinks.ts +20 -0
  79. package/src/models/operations/gettopurls.ts +20 -0
  80. package/src/sdk/analytics.ts +50 -0
@@ -271,6 +271,10 @@ export type EditLinkGeo = {
271
271
  };
272
272
 
273
273
  export type EditLinkRequestBody = {
274
+ /**
275
+ * The destination URL of the short link.
276
+ */
277
+ url: string;
274
278
  /**
275
279
  * The domain of the short link. If not provided, the primary domain for the workspace will be used (or `dub.sh` if the workspace has no domains).
276
280
  */
@@ -280,13 +284,13 @@ export type EditLinkRequestBody = {
280
284
  */
281
285
  key?: string | undefined;
282
286
  /**
283
- * The prefix of the short link slug for randomly-generated keys (e.g. if prefix is `/c/`, generated keys will be in the `/c/:key` format). Will be ignored if `key` is provided.
287
+ * This is the ID of the link in your database. If set, it can be used to identify the link in the future. Must be prefixed with 'ext_' when passed as a query parameter.
284
288
  */
285
- prefix?: string | undefined;
289
+ externalId?: string | null | undefined;
286
290
  /**
287
- * The destination URL of the short link.
291
+ * The prefix of the short link slug for randomly-generated keys (e.g. if prefix is `/c/`, generated keys will be in the `/c/:key` format). Will be ignored if `key` is provided.
288
292
  */
289
- url: string;
293
+ prefix?: string | undefined;
290
294
  /**
291
295
  * Whether the short link is archived.
292
296
  */
@@ -1925,10 +1929,11 @@ export namespace EditLinkGeo$ {
1925
1929
  /** @internal */
1926
1930
  export namespace EditLinkRequestBody$ {
1927
1931
  export type Inbound = {
1932
+ url: string;
1928
1933
  domain?: string | undefined;
1929
1934
  key?: string | undefined;
1935
+ externalId?: string | null | undefined;
1930
1936
  prefix?: string | undefined;
1931
- url: string;
1932
1937
  archived?: boolean | undefined;
1933
1938
  publicStats?: boolean | undefined;
1934
1939
  tagId?: string | null | undefined;
@@ -1950,10 +1955,11 @@ export namespace EditLinkRequestBody$ {
1950
1955
 
1951
1956
  export const inboundSchema: z.ZodType<EditLinkRequestBody, z.ZodTypeDef, Inbound> = z
1952
1957
  .object({
1958
+ url: z.string(),
1953
1959
  domain: z.string().optional(),
1954
1960
  key: z.string().optional(),
1961
+ externalId: z.nullable(z.string()).optional(),
1955
1962
  prefix: z.string().optional(),
1956
- url: z.string(),
1957
1963
  archived: z.boolean().default(false),
1958
1964
  publicStats: z.boolean().default(false),
1959
1965
  tagId: z.nullable(z.string()).optional(),
@@ -1974,10 +1980,11 @@ export namespace EditLinkRequestBody$ {
1974
1980
  })
1975
1981
  .transform((v) => {
1976
1982
  return {
1983
+ url: v.url,
1977
1984
  ...(v.domain === undefined ? null : { domain: v.domain }),
1978
1985
  ...(v.key === undefined ? null : { key: v.key }),
1986
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
1979
1987
  ...(v.prefix === undefined ? null : { prefix: v.prefix }),
1980
- url: v.url,
1981
1988
  archived: v.archived,
1982
1989
  publicStats: v.publicStats,
1983
1990
  ...(v.tagId === undefined ? null : { tagId: v.tagId }),
@@ -1999,10 +2006,11 @@ export namespace EditLinkRequestBody$ {
1999
2006
  });
2000
2007
 
2001
2008
  export type Outbound = {
2009
+ url: string;
2002
2010
  domain?: string | undefined;
2003
2011
  key?: string | undefined;
2012
+ externalId?: string | null | undefined;
2004
2013
  prefix?: string | undefined;
2005
- url: string;
2006
2014
  archived: boolean;
2007
2015
  publicStats: boolean;
2008
2016
  tagId?: string | null | undefined;
@@ -2024,10 +2032,11 @@ export namespace EditLinkRequestBody$ {
2024
2032
 
2025
2033
  export const outboundSchema: z.ZodType<Outbound, z.ZodTypeDef, EditLinkRequestBody> = z
2026
2034
  .object({
2035
+ url: z.string(),
2027
2036
  domain: z.string().optional(),
2028
2037
  key: z.string().optional(),
2038
+ externalId: z.nullable(z.string()).optional(),
2029
2039
  prefix: z.string().optional(),
2030
- url: z.string(),
2031
2040
  archived: z.boolean().default(false),
2032
2041
  publicStats: z.boolean().default(false),
2033
2042
  tagId: z.nullable(z.string()).optional(),
@@ -2048,10 +2057,11 @@ export namespace EditLinkRequestBody$ {
2048
2057
  })
2049
2058
  .transform((v) => {
2050
2059
  return {
2060
+ url: v.url,
2051
2061
  ...(v.domain === undefined ? null : { domain: v.domain }),
2052
2062
  ...(v.key === undefined ? null : { key: v.key }),
2063
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
2053
2064
  ...(v.prefix === undefined ? null : { prefix: v.prefix }),
2054
- url: v.url,
2055
2065
  archived: v.archived,
2056
2066
  publicStats: v.publicStats,
2057
2067
  ...(v.tagId === undefined ? null : { tagId: v.tagId }),
@@ -291,6 +291,14 @@ export type GetBrowserAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -363,6 +371,8 @@ export namespace GetBrowserAnalyticsRequest$ {
363
371
  export type Inbound = {
364
372
  domain?: string | undefined;
365
373
  key?: string | undefined;
374
+ linkId?: string | undefined;
375
+ externalId?: string | undefined;
366
376
  interval?: GetBrowserAnalyticsQueryParamInterval | undefined;
367
377
  country?: GetBrowserAnalyticsQueryParamCountry | undefined;
368
378
  city?: string | undefined;
@@ -380,6 +390,8 @@ export namespace GetBrowserAnalyticsRequest$ {
380
390
  .object({
381
391
  domain: z.string().optional(),
382
392
  key: z.string().optional(),
393
+ linkId: z.string().optional(),
394
+ externalId: z.string().optional(),
383
395
  interval: GetBrowserAnalyticsQueryParamInterval$.optional(),
384
396
  country: GetBrowserAnalyticsQueryParamCountry$.optional(),
385
397
  city: z.string().optional(),
@@ -396,6 +408,8 @@ export namespace GetBrowserAnalyticsRequest$ {
396
408
  return {
397
409
  ...(v.domain === undefined ? null : { domain: v.domain }),
398
410
  ...(v.key === undefined ? null : { key: v.key }),
411
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
412
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
399
413
  ...(v.interval === undefined ? null : { interval: v.interval }),
400
414
  ...(v.country === undefined ? null : { country: v.country }),
401
415
  ...(v.city === undefined ? null : { city: v.city }),
@@ -413,6 +427,8 @@ export namespace GetBrowserAnalyticsRequest$ {
413
427
  export type Outbound = {
414
428
  domain?: string | undefined;
415
429
  key?: string | undefined;
430
+ linkId?: string | undefined;
431
+ externalId?: string | undefined;
416
432
  interval?: GetBrowserAnalyticsQueryParamInterval | undefined;
417
433
  country?: GetBrowserAnalyticsQueryParamCountry | undefined;
418
434
  city?: string | undefined;
@@ -430,6 +446,8 @@ export namespace GetBrowserAnalyticsRequest$ {
430
446
  .object({
431
447
  domain: z.string().optional(),
432
448
  key: z.string().optional(),
449
+ linkId: z.string().optional(),
450
+ externalId: z.string().optional(),
433
451
  interval: GetBrowserAnalyticsQueryParamInterval$.optional(),
434
452
  country: GetBrowserAnalyticsQueryParamCountry$.optional(),
435
453
  city: z.string().optional(),
@@ -446,6 +464,8 @@ export namespace GetBrowserAnalyticsRequest$ {
446
464
  return {
447
465
  ...(v.domain === undefined ? null : { domain: v.domain }),
448
466
  ...(v.key === undefined ? null : { key: v.key }),
467
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
468
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
449
469
  ...(v.interval === undefined ? null : { interval: v.interval }),
450
470
  ...(v.country === undefined ? null : { country: v.country }),
451
471
  ...(v.city === undefined ? null : { city: v.city }),
@@ -291,6 +291,14 @@ export type GetCityAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -628,6 +636,8 @@ export namespace GetCityAnalyticsRequest$ {
628
636
  export type Inbound = {
629
637
  domain?: string | undefined;
630
638
  key?: string | undefined;
639
+ linkId?: string | undefined;
640
+ externalId?: string | undefined;
631
641
  interval?: GetCityAnalyticsQueryParamInterval | undefined;
632
642
  country?: GetCityAnalyticsQueryParamCountry | undefined;
633
643
  city?: string | undefined;
@@ -645,6 +655,8 @@ export namespace GetCityAnalyticsRequest$ {
645
655
  .object({
646
656
  domain: z.string().optional(),
647
657
  key: z.string().optional(),
658
+ linkId: z.string().optional(),
659
+ externalId: z.string().optional(),
648
660
  interval: GetCityAnalyticsQueryParamInterval$.optional(),
649
661
  country: GetCityAnalyticsQueryParamCountry$.optional(),
650
662
  city: z.string().optional(),
@@ -661,6 +673,8 @@ export namespace GetCityAnalyticsRequest$ {
661
673
  return {
662
674
  ...(v.domain === undefined ? null : { domain: v.domain }),
663
675
  ...(v.key === undefined ? null : { key: v.key }),
676
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
677
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
664
678
  ...(v.interval === undefined ? null : { interval: v.interval }),
665
679
  ...(v.country === undefined ? null : { country: v.country }),
666
680
  ...(v.city === undefined ? null : { city: v.city }),
@@ -678,6 +692,8 @@ export namespace GetCityAnalyticsRequest$ {
678
692
  export type Outbound = {
679
693
  domain?: string | undefined;
680
694
  key?: string | undefined;
695
+ linkId?: string | undefined;
696
+ externalId?: string | undefined;
681
697
  interval?: GetCityAnalyticsQueryParamInterval | undefined;
682
698
  country?: GetCityAnalyticsQueryParamCountry | undefined;
683
699
  city?: string | undefined;
@@ -695,6 +711,8 @@ export namespace GetCityAnalyticsRequest$ {
695
711
  .object({
696
712
  domain: z.string().optional(),
697
713
  key: z.string().optional(),
714
+ linkId: z.string().optional(),
715
+ externalId: z.string().optional(),
698
716
  interval: GetCityAnalyticsQueryParamInterval$.optional(),
699
717
  country: GetCityAnalyticsQueryParamCountry$.optional(),
700
718
  city: z.string().optional(),
@@ -711,6 +729,8 @@ export namespace GetCityAnalyticsRequest$ {
711
729
  return {
712
730
  ...(v.domain === undefined ? null : { domain: v.domain }),
713
731
  ...(v.key === undefined ? null : { key: v.key }),
732
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
733
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
714
734
  ...(v.interval === undefined ? null : { interval: v.interval }),
715
735
  ...(v.country === undefined ? null : { country: v.country }),
716
736
  ...(v.city === undefined ? null : { city: v.city }),
@@ -289,6 +289,14 @@ export type GetClicksAnalyticsRequest = {
289
289
  * The short link slug.
290
290
  */
291
291
  key?: string | undefined;
292
+ /**
293
+ * The unique ID of the short link on Dub.
294
+ */
295
+ linkId?: string | undefined;
296
+ /**
297
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
298
+ */
299
+ externalId?: string | undefined;
292
300
  /**
293
301
  * The interval to retrieve analytics for.
294
302
  */
@@ -346,6 +354,8 @@ export namespace GetClicksAnalyticsRequest$ {
346
354
  export type Inbound = {
347
355
  domain?: string | undefined;
348
356
  key?: string | undefined;
357
+ linkId?: string | undefined;
358
+ externalId?: string | undefined;
349
359
  interval?: Interval | undefined;
350
360
  country?: Country | undefined;
351
361
  city?: string | undefined;
@@ -363,6 +373,8 @@ export namespace GetClicksAnalyticsRequest$ {
363
373
  .object({
364
374
  domain: z.string().optional(),
365
375
  key: z.string().optional(),
376
+ linkId: z.string().optional(),
377
+ externalId: z.string().optional(),
366
378
  interval: Interval$.optional(),
367
379
  country: Country$.optional(),
368
380
  city: z.string().optional(),
@@ -379,6 +391,8 @@ export namespace GetClicksAnalyticsRequest$ {
379
391
  return {
380
392
  ...(v.domain === undefined ? null : { domain: v.domain }),
381
393
  ...(v.key === undefined ? null : { key: v.key }),
394
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
395
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
382
396
  ...(v.interval === undefined ? null : { interval: v.interval }),
383
397
  ...(v.country === undefined ? null : { country: v.country }),
384
398
  ...(v.city === undefined ? null : { city: v.city }),
@@ -396,6 +410,8 @@ export namespace GetClicksAnalyticsRequest$ {
396
410
  export type Outbound = {
397
411
  domain?: string | undefined;
398
412
  key?: string | undefined;
413
+ linkId?: string | undefined;
414
+ externalId?: string | undefined;
399
415
  interval?: Interval | undefined;
400
416
  country?: Country | undefined;
401
417
  city?: string | undefined;
@@ -413,6 +429,8 @@ export namespace GetClicksAnalyticsRequest$ {
413
429
  .object({
414
430
  domain: z.string().optional(),
415
431
  key: z.string().optional(),
432
+ linkId: z.string().optional(),
433
+ externalId: z.string().optional(),
416
434
  interval: Interval$.optional(),
417
435
  country: Country$.optional(),
418
436
  city: z.string().optional(),
@@ -429,6 +447,8 @@ export namespace GetClicksAnalyticsRequest$ {
429
447
  return {
430
448
  ...(v.domain === undefined ? null : { domain: v.domain }),
431
449
  ...(v.key === undefined ? null : { key: v.key }),
450
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
451
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
432
452
  ...(v.interval === undefined ? null : { interval: v.interval }),
433
453
  ...(v.country === undefined ? null : { country: v.country }),
434
454
  ...(v.city === undefined ? null : { city: v.city }),
@@ -291,6 +291,14 @@ export type GetCountryAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -624,6 +632,8 @@ export namespace GetCountryAnalyticsRequest$ {
624
632
  export type Inbound = {
625
633
  domain?: string | undefined;
626
634
  key?: string | undefined;
635
+ linkId?: string | undefined;
636
+ externalId?: string | undefined;
627
637
  interval?: GetCountryAnalyticsQueryParamInterval | undefined;
628
638
  country?: GetCountryAnalyticsQueryParamCountry | undefined;
629
639
  city?: string | undefined;
@@ -641,6 +651,8 @@ export namespace GetCountryAnalyticsRequest$ {
641
651
  .object({
642
652
  domain: z.string().optional(),
643
653
  key: z.string().optional(),
654
+ linkId: z.string().optional(),
655
+ externalId: z.string().optional(),
644
656
  interval: GetCountryAnalyticsQueryParamInterval$.optional(),
645
657
  country: GetCountryAnalyticsQueryParamCountry$.optional(),
646
658
  city: z.string().optional(),
@@ -657,6 +669,8 @@ export namespace GetCountryAnalyticsRequest$ {
657
669
  return {
658
670
  ...(v.domain === undefined ? null : { domain: v.domain }),
659
671
  ...(v.key === undefined ? null : { key: v.key }),
672
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
673
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
660
674
  ...(v.interval === undefined ? null : { interval: v.interval }),
661
675
  ...(v.country === undefined ? null : { country: v.country }),
662
676
  ...(v.city === undefined ? null : { city: v.city }),
@@ -674,6 +688,8 @@ export namespace GetCountryAnalyticsRequest$ {
674
688
  export type Outbound = {
675
689
  domain?: string | undefined;
676
690
  key?: string | undefined;
691
+ linkId?: string | undefined;
692
+ externalId?: string | undefined;
677
693
  interval?: GetCountryAnalyticsQueryParamInterval | undefined;
678
694
  country?: GetCountryAnalyticsQueryParamCountry | undefined;
679
695
  city?: string | undefined;
@@ -691,6 +707,8 @@ export namespace GetCountryAnalyticsRequest$ {
691
707
  .object({
692
708
  domain: z.string().optional(),
693
709
  key: z.string().optional(),
710
+ linkId: z.string().optional(),
711
+ externalId: z.string().optional(),
694
712
  interval: GetCountryAnalyticsQueryParamInterval$.optional(),
695
713
  country: GetCountryAnalyticsQueryParamCountry$.optional(),
696
714
  city: z.string().optional(),
@@ -707,6 +725,8 @@ export namespace GetCountryAnalyticsRequest$ {
707
725
  return {
708
726
  ...(v.domain === undefined ? null : { domain: v.domain }),
709
727
  ...(v.key === undefined ? null : { key: v.key }),
728
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
729
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
710
730
  ...(v.interval === undefined ? null : { interval: v.interval }),
711
731
  ...(v.country === undefined ? null : { country: v.country }),
712
732
  ...(v.city === undefined ? null : { city: v.city }),
@@ -291,6 +291,14 @@ export type GetDeviceAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -363,6 +371,8 @@ export namespace GetDeviceAnalyticsRequest$ {
363
371
  export type Inbound = {
364
372
  domain?: string | undefined;
365
373
  key?: string | undefined;
374
+ linkId?: string | undefined;
375
+ externalId?: string | undefined;
366
376
  interval?: GetDeviceAnalyticsQueryParamInterval | undefined;
367
377
  country?: GetDeviceAnalyticsQueryParamCountry | undefined;
368
378
  city?: string | undefined;
@@ -380,6 +390,8 @@ export namespace GetDeviceAnalyticsRequest$ {
380
390
  .object({
381
391
  domain: z.string().optional(),
382
392
  key: z.string().optional(),
393
+ linkId: z.string().optional(),
394
+ externalId: z.string().optional(),
383
395
  interval: GetDeviceAnalyticsQueryParamInterval$.optional(),
384
396
  country: GetDeviceAnalyticsQueryParamCountry$.optional(),
385
397
  city: z.string().optional(),
@@ -396,6 +408,8 @@ export namespace GetDeviceAnalyticsRequest$ {
396
408
  return {
397
409
  ...(v.domain === undefined ? null : { domain: v.domain }),
398
410
  ...(v.key === undefined ? null : { key: v.key }),
411
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
412
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
399
413
  ...(v.interval === undefined ? null : { interval: v.interval }),
400
414
  ...(v.country === undefined ? null : { country: v.country }),
401
415
  ...(v.city === undefined ? null : { city: v.city }),
@@ -413,6 +427,8 @@ export namespace GetDeviceAnalyticsRequest$ {
413
427
  export type Outbound = {
414
428
  domain?: string | undefined;
415
429
  key?: string | undefined;
430
+ linkId?: string | undefined;
431
+ externalId?: string | undefined;
416
432
  interval?: GetDeviceAnalyticsQueryParamInterval | undefined;
417
433
  country?: GetDeviceAnalyticsQueryParamCountry | undefined;
418
434
  city?: string | undefined;
@@ -430,6 +446,8 @@ export namespace GetDeviceAnalyticsRequest$ {
430
446
  .object({
431
447
  domain: z.string().optional(),
432
448
  key: z.string().optional(),
449
+ linkId: z.string().optional(),
450
+ externalId: z.string().optional(),
433
451
  interval: GetDeviceAnalyticsQueryParamInterval$.optional(),
434
452
  country: GetDeviceAnalyticsQueryParamCountry$.optional(),
435
453
  city: z.string().optional(),
@@ -446,6 +464,8 @@ export namespace GetDeviceAnalyticsRequest$ {
446
464
  return {
447
465
  ...(v.domain === undefined ? null : { domain: v.domain }),
448
466
  ...(v.key === undefined ? null : { key: v.key }),
467
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
468
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
449
469
  ...(v.interval === undefined ? null : { interval: v.interval }),
450
470
  ...(v.country === undefined ? null : { country: v.country }),
451
471
  ...(v.city === undefined ? null : { city: v.city }),
@@ -291,6 +291,14 @@ export type GetOSAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -363,6 +371,8 @@ export namespace GetOSAnalyticsRequest$ {
363
371
  export type Inbound = {
364
372
  domain?: string | undefined;
365
373
  key?: string | undefined;
374
+ linkId?: string | undefined;
375
+ externalId?: string | undefined;
366
376
  interval?: GetOSAnalyticsQueryParamInterval | undefined;
367
377
  country?: GetOSAnalyticsQueryParamCountry | undefined;
368
378
  city?: string | undefined;
@@ -380,6 +390,8 @@ export namespace GetOSAnalyticsRequest$ {
380
390
  .object({
381
391
  domain: z.string().optional(),
382
392
  key: z.string().optional(),
393
+ linkId: z.string().optional(),
394
+ externalId: z.string().optional(),
383
395
  interval: GetOSAnalyticsQueryParamInterval$.optional(),
384
396
  country: GetOSAnalyticsQueryParamCountry$.optional(),
385
397
  city: z.string().optional(),
@@ -396,6 +408,8 @@ export namespace GetOSAnalyticsRequest$ {
396
408
  return {
397
409
  ...(v.domain === undefined ? null : { domain: v.domain }),
398
410
  ...(v.key === undefined ? null : { key: v.key }),
411
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
412
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
399
413
  ...(v.interval === undefined ? null : { interval: v.interval }),
400
414
  ...(v.country === undefined ? null : { country: v.country }),
401
415
  ...(v.city === undefined ? null : { city: v.city }),
@@ -413,6 +427,8 @@ export namespace GetOSAnalyticsRequest$ {
413
427
  export type Outbound = {
414
428
  domain?: string | undefined;
415
429
  key?: string | undefined;
430
+ linkId?: string | undefined;
431
+ externalId?: string | undefined;
416
432
  interval?: GetOSAnalyticsQueryParamInterval | undefined;
417
433
  country?: GetOSAnalyticsQueryParamCountry | undefined;
418
434
  city?: string | undefined;
@@ -430,6 +446,8 @@ export namespace GetOSAnalyticsRequest$ {
430
446
  .object({
431
447
  domain: z.string().optional(),
432
448
  key: z.string().optional(),
449
+ linkId: z.string().optional(),
450
+ externalId: z.string().optional(),
433
451
  interval: GetOSAnalyticsQueryParamInterval$.optional(),
434
452
  country: GetOSAnalyticsQueryParamCountry$.optional(),
435
453
  city: z.string().optional(),
@@ -446,6 +464,8 @@ export namespace GetOSAnalyticsRequest$ {
446
464
  return {
447
465
  ...(v.domain === undefined ? null : { domain: v.domain }),
448
466
  ...(v.key === undefined ? null : { key: v.key }),
467
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
468
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
449
469
  ...(v.interval === undefined ? null : { interval: v.interval }),
450
470
  ...(v.country === undefined ? null : { country: v.country }),
451
471
  ...(v.city === undefined ? null : { city: v.city }),
@@ -291,6 +291,14 @@ export type GetRefererAnalyticsRequest = {
291
291
  * The short link slug.
292
292
  */
293
293
  key?: string | undefined;
294
+ /**
295
+ * The unique ID of the short link on Dub.
296
+ */
297
+ linkId?: string | undefined;
298
+ /**
299
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
300
+ */
301
+ externalId?: string | undefined;
294
302
  /**
295
303
  * The interval to retrieve analytics for.
296
304
  */
@@ -363,6 +371,8 @@ export namespace GetRefererAnalyticsRequest$ {
363
371
  export type Inbound = {
364
372
  domain?: string | undefined;
365
373
  key?: string | undefined;
374
+ linkId?: string | undefined;
375
+ externalId?: string | undefined;
366
376
  interval?: GetRefererAnalyticsQueryParamInterval | undefined;
367
377
  country?: GetRefererAnalyticsQueryParamCountry | undefined;
368
378
  city?: string | undefined;
@@ -380,6 +390,8 @@ export namespace GetRefererAnalyticsRequest$ {
380
390
  .object({
381
391
  domain: z.string().optional(),
382
392
  key: z.string().optional(),
393
+ linkId: z.string().optional(),
394
+ externalId: z.string().optional(),
383
395
  interval: GetRefererAnalyticsQueryParamInterval$.optional(),
384
396
  country: GetRefererAnalyticsQueryParamCountry$.optional(),
385
397
  city: z.string().optional(),
@@ -396,6 +408,8 @@ export namespace GetRefererAnalyticsRequest$ {
396
408
  return {
397
409
  ...(v.domain === undefined ? null : { domain: v.domain }),
398
410
  ...(v.key === undefined ? null : { key: v.key }),
411
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
412
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
399
413
  ...(v.interval === undefined ? null : { interval: v.interval }),
400
414
  ...(v.country === undefined ? null : { country: v.country }),
401
415
  ...(v.city === undefined ? null : { city: v.city }),
@@ -413,6 +427,8 @@ export namespace GetRefererAnalyticsRequest$ {
413
427
  export type Outbound = {
414
428
  domain?: string | undefined;
415
429
  key?: string | undefined;
430
+ linkId?: string | undefined;
431
+ externalId?: string | undefined;
416
432
  interval?: GetRefererAnalyticsQueryParamInterval | undefined;
417
433
  country?: GetRefererAnalyticsQueryParamCountry | undefined;
418
434
  city?: string | undefined;
@@ -430,6 +446,8 @@ export namespace GetRefererAnalyticsRequest$ {
430
446
  .object({
431
447
  domain: z.string().optional(),
432
448
  key: z.string().optional(),
449
+ linkId: z.string().optional(),
450
+ externalId: z.string().optional(),
433
451
  interval: GetRefererAnalyticsQueryParamInterval$.optional(),
434
452
  country: GetRefererAnalyticsQueryParamCountry$.optional(),
435
453
  city: z.string().optional(),
@@ -446,6 +464,8 @@ export namespace GetRefererAnalyticsRequest$ {
446
464
  return {
447
465
  ...(v.domain === undefined ? null : { domain: v.domain }),
448
466
  ...(v.key === undefined ? null : { key: v.key }),
467
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
468
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
449
469
  ...(v.interval === undefined ? null : { interval: v.interval }),
450
470
  ...(v.country === undefined ? null : { country: v.country }),
451
471
  ...(v.city === undefined ? null : { city: v.city }),
@@ -289,6 +289,14 @@ export type GetTimeseriesAnalyticsRequest = {
289
289
  * The short link slug.
290
290
  */
291
291
  key?: string | undefined;
292
+ /**
293
+ * The unique ID of the short link on Dub.
294
+ */
295
+ linkId?: string | undefined;
296
+ /**
297
+ * This is the ID of the link in the your database. Must be prefixed with 'ext_' when passed as a query parameter.
298
+ */
299
+ externalId?: string | undefined;
292
300
  /**
293
301
  * The interval to retrieve analytics for.
294
302
  */
@@ -359,6 +367,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
359
367
  export type Inbound = {
360
368
  domain?: string | undefined;
361
369
  key?: string | undefined;
370
+ linkId?: string | undefined;
371
+ externalId?: string | undefined;
362
372
  interval?: QueryParamInterval | undefined;
363
373
  country?: QueryParamCountry | undefined;
364
374
  city?: string | undefined;
@@ -376,6 +386,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
376
386
  .object({
377
387
  domain: z.string().optional(),
378
388
  key: z.string().optional(),
389
+ linkId: z.string().optional(),
390
+ externalId: z.string().optional(),
379
391
  interval: QueryParamInterval$.optional(),
380
392
  country: QueryParamCountry$.optional(),
381
393
  city: z.string().optional(),
@@ -392,6 +404,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
392
404
  return {
393
405
  ...(v.domain === undefined ? null : { domain: v.domain }),
394
406
  ...(v.key === undefined ? null : { key: v.key }),
407
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
408
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
395
409
  ...(v.interval === undefined ? null : { interval: v.interval }),
396
410
  ...(v.country === undefined ? null : { country: v.country }),
397
411
  ...(v.city === undefined ? null : { city: v.city }),
@@ -409,6 +423,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
409
423
  export type Outbound = {
410
424
  domain?: string | undefined;
411
425
  key?: string | undefined;
426
+ linkId?: string | undefined;
427
+ externalId?: string | undefined;
412
428
  interval?: QueryParamInterval | undefined;
413
429
  country?: QueryParamCountry | undefined;
414
430
  city?: string | undefined;
@@ -427,6 +443,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
427
443
  .object({
428
444
  domain: z.string().optional(),
429
445
  key: z.string().optional(),
446
+ linkId: z.string().optional(),
447
+ externalId: z.string().optional(),
430
448
  interval: QueryParamInterval$.optional(),
431
449
  country: QueryParamCountry$.optional(),
432
450
  city: z.string().optional(),
@@ -443,6 +461,8 @@ export namespace GetTimeseriesAnalyticsRequest$ {
443
461
  return {
444
462
  ...(v.domain === undefined ? null : { domain: v.domain }),
445
463
  ...(v.key === undefined ? null : { key: v.key }),
464
+ ...(v.linkId === undefined ? null : { linkId: v.linkId }),
465
+ ...(v.externalId === undefined ? null : { externalId: v.externalId }),
446
466
  ...(v.interval === undefined ? null : { interval: v.interval }),
447
467
  ...(v.country === undefined ? null : { country: v.country }),
448
468
  ...(v.city === undefined ? null : { city: v.city }),