@codeqr/ts 0.9.0 → 0.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +509 -0
- package/LICENSE +1 -1
- package/README.md +12 -1
- package/api-promise.d.mts +1 -0
- package/api-promise.d.mts.map +1 -1
- package/api-promise.d.ts +1 -0
- package/api-promise.d.ts.map +1 -1
- package/api-promise.mjs +1 -0
- package/api-promise.mjs.map +1 -1
- package/client.d.mts +8 -7
- package/client.d.mts.map +1 -1
- package/client.d.ts +8 -7
- package/client.d.ts.map +1 -1
- package/client.js +43 -10
- package/client.js.map +1 -1
- package/client.mjs +43 -10
- package/client.mjs.map +1 -1
- package/core/api-promise.d.mts.map +1 -1
- package/core/api-promise.d.ts.map +1 -1
- package/core/api-promise.mjs.map +1 -1
- package/core/error.mjs.map +1 -1
- package/core/resource.d.mts.map +1 -1
- package/core/resource.d.ts.map +1 -1
- package/core/uploads.d.mts.map +1 -1
- package/core/uploads.d.ts.map +1 -1
- package/core/uploads.mjs.map +1 -1
- package/error.d.mts +1 -0
- package/error.d.mts.map +1 -1
- package/error.d.ts +1 -0
- package/error.d.ts.map +1 -1
- package/error.mjs +1 -0
- package/error.mjs.map +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts.map +1 -1
- package/index.mjs.map +1 -1
- package/internal/detect-platform.mjs.map +1 -1
- package/internal/headers.mjs.map +1 -1
- package/internal/parse.d.mts.map +1 -1
- package/internal/parse.d.ts.map +1 -1
- package/internal/parse.js +5 -0
- package/internal/parse.js.map +1 -1
- package/internal/parse.mjs +5 -0
- package/internal/parse.mjs.map +1 -1
- package/internal/qs/formats.d.mts.map +1 -1
- package/internal/qs/formats.d.ts.map +1 -1
- package/internal/qs/index.d.mts +2 -2
- package/internal/qs/index.d.mts.map +1 -1
- package/internal/qs/index.d.ts +2 -2
- package/internal/qs/index.d.ts.map +1 -1
- package/internal/qs/index.mjs.map +1 -1
- package/internal/qs/stringify.d.mts.map +1 -1
- package/internal/qs/stringify.d.ts.map +1 -1
- package/internal/qs/stringify.mjs.map +1 -1
- package/internal/qs/utils.d.mts.map +1 -1
- package/internal/qs/utils.d.ts.map +1 -1
- package/internal/qs/utils.mjs.map +1 -1
- package/internal/request-options.d.mts.map +1 -1
- package/internal/request-options.d.ts.map +1 -1
- package/internal/shims.d.mts +6 -0
- package/internal/shims.d.mts.map +1 -1
- package/internal/shims.d.ts +6 -0
- package/internal/shims.d.ts.map +1 -1
- package/internal/to-file.d.mts.map +1 -1
- package/internal/to-file.d.ts.map +1 -1
- package/internal/to-file.mjs.map +1 -1
- package/internal/types.d.mts +10 -10
- package/internal/types.d.mts.map +1 -1
- package/internal/types.d.ts +10 -10
- package/internal/types.d.ts.map +1 -1
- package/internal/uploads.d.mts.map +1 -1
- package/internal/uploads.d.ts.map +1 -1
- package/internal/uploads.mjs.map +1 -1
- package/internal/utils/base64.mjs.map +1 -1
- package/internal/utils/env.js +2 -2
- package/internal/utils/env.js.map +1 -1
- package/internal/utils/env.mjs +2 -2
- package/internal/utils/env.mjs.map +1 -1
- package/internal/utils/log.d.mts.map +1 -1
- package/internal/utils/log.d.ts.map +1 -1
- package/internal/utils/log.js +2 -0
- package/internal/utils/log.js.map +1 -1
- package/internal/utils/log.mjs +2 -0
- package/internal/utils/log.mjs.map +1 -1
- package/internal/utils/path.mjs.map +1 -1
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils/values.mjs.map +1 -1
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.mts.map +1 -1
- package/internal/utils.d.ts +1 -0
- package/internal/utils.d.ts.map +1 -1
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/internal/utils.mjs.map +1 -1
- package/package.json +12 -1
- package/resource.d.mts +1 -0
- package/resource.d.mts.map +1 -1
- package/resource.d.ts +1 -0
- package/resource.d.ts.map +1 -1
- package/resource.mjs +1 -0
- package/resource.mjs.map +1 -1
- package/resources/analytics.d.mts +23 -3
- package/resources/analytics.d.mts.map +1 -1
- package/resources/analytics.d.ts +23 -3
- package/resources/analytics.d.ts.map +1 -1
- package/resources/analytics.mjs.map +1 -1
- package/resources/domains.d.mts +27 -27
- package/resources/domains.d.mts.map +1 -1
- package/resources/domains.d.ts +27 -27
- package/resources/domains.d.ts.map +1 -1
- package/resources/domains.js +8 -8
- package/resources/domains.js.map +1 -1
- package/resources/domains.mjs +8 -8
- package/resources/domains.mjs.map +1 -1
- package/resources/events.d.mts +53 -137
- package/resources/events.d.mts.map +1 -1
- package/resources/events.d.ts +53 -137
- package/resources/events.d.ts.map +1 -1
- package/resources/events.mjs.map +1 -1
- package/resources/index.d.mts +4 -4
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +4 -4
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs.map +1 -1
- package/resources/links/bulk.d.mts +16 -26
- package/resources/links/bulk.d.mts.map +1 -1
- package/resources/links/bulk.d.ts +16 -26
- package/resources/links/bulk.d.ts.map +1 -1
- package/resources/links/bulk.js +0 -14
- package/resources/links/bulk.js.map +1 -1
- package/resources/links/bulk.mjs +0 -14
- package/resources/links/bulk.mjs.map +1 -1
- package/resources/links/index.d.mts +2 -2
- package/resources/links/index.d.mts.map +1 -1
- package/resources/links/index.d.ts +2 -2
- package/resources/links/index.d.ts.map +1 -1
- package/resources/links/index.js.map +1 -1
- package/resources/links/index.mjs +1 -1
- package/resources/links/index.mjs.map +1 -1
- package/resources/links/links.d.mts +232 -988
- package/resources/links/links.d.mts.map +1 -1
- package/resources/links/links.d.ts +232 -988
- package/resources/links/links.d.ts.map +1 -1
- package/resources/links/links.js +16 -42
- package/resources/links/links.js.map +1 -1
- package/resources/links/links.mjs +16 -42
- package/resources/links/links.mjs.map +1 -1
- package/resources/links.d.mts.map +1 -1
- package/resources/links.d.ts.map +1 -1
- package/resources/links.mjs.map +1 -1
- package/resources/projects.d.mts +0 -4
- package/resources/projects.d.mts.map +1 -1
- package/resources/projects.d.ts +0 -4
- package/resources/projects.d.ts.map +1 -1
- package/resources/projects.js +0 -7
- package/resources/projects.js.map +1 -1
- package/resources/projects.mjs +0 -7
- package/resources/projects.mjs.map +1 -1
- package/resources/qrcodes/bulk.d.mts +111 -38
- package/resources/qrcodes/bulk.d.mts.map +1 -1
- package/resources/qrcodes/bulk.d.ts +111 -38
- package/resources/qrcodes/bulk.d.ts.map +1 -1
- package/resources/qrcodes/bulk.js +0 -14
- package/resources/qrcodes/bulk.js.map +1 -1
- package/resources/qrcodes/bulk.mjs +0 -14
- package/resources/qrcodes/bulk.mjs.map +1 -1
- package/resources/qrcodes/index.d.mts +2 -2
- package/resources/qrcodes/index.d.mts.map +1 -1
- package/resources/qrcodes/index.d.ts +2 -2
- package/resources/qrcodes/index.d.ts.map +1 -1
- package/resources/qrcodes/index.js.map +1 -1
- package/resources/qrcodes/index.mjs +1 -1
- package/resources/qrcodes/index.mjs.map +1 -1
- package/resources/qrcodes/qrcodes.d.mts +442 -855
- package/resources/qrcodes/qrcodes.d.mts.map +1 -1
- package/resources/qrcodes/qrcodes.d.ts +442 -855
- package/resources/qrcodes/qrcodes.d.ts.map +1 -1
- package/resources/qrcodes/qrcodes.js +12 -42
- package/resources/qrcodes/qrcodes.js.map +1 -1
- package/resources/qrcodes/qrcodes.mjs +12 -42
- package/resources/qrcodes/qrcodes.mjs.map +1 -1
- package/resources/qrcodes.d.mts.map +1 -1
- package/resources/qrcodes.d.ts.map +1 -1
- package/resources/qrcodes.mjs.map +1 -1
- package/resources/tags.d.mts +19 -15
- package/resources/tags.d.mts.map +1 -1
- package/resources/tags.d.ts +19 -15
- package/resources/tags.d.ts.map +1 -1
- package/resources/tags.js +7 -7
- package/resources/tags.js.map +1 -1
- package/resources/tags.mjs +7 -7
- package/resources/tags.mjs.map +1 -1
- package/resources/track.d.mts +10 -9
- package/resources/track.d.mts.map +1 -1
- package/resources/track.d.ts +10 -9
- package/resources/track.d.ts.map +1 -1
- package/resources/track.mjs.map +1 -1
- package/resources.d.mts.map +1 -1
- package/resources.d.ts.map +1 -1
- package/resources.mjs.map +1 -1
- package/src/client.ts +53 -29
- package/src/internal/parse.ts +6 -0
- package/src/internal/types.ts +6 -8
- package/src/internal/utils/env.ts +2 -2
- package/src/internal/utils/log.ts +2 -0
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/resources/analytics.ts +33 -3
- package/src/resources/domains.ts +38 -38
- package/src/resources/events.ts +90 -143
- package/src/resources/index.ts +4 -10
- package/src/resources/links/bulk.ts +30 -37
- package/src/resources/links/index.ts +2 -11
- package/src/resources/links/links.ts +227 -1538
- package/src/resources/projects.ts +0 -8
- package/src/resources/qrcodes/bulk.ts +151 -50
- package/src/resources/qrcodes/index.ts +2 -11
- package/src/resources/qrcodes/qrcodes.ts +405 -1083
- package/src/resources/tags.ts +23 -18
- package/src/resources/track.ts +10 -9
- package/src/version.ts +1 -1
- package/uploads.d.mts +1 -0
- package/uploads.d.mts.map +1 -1
- package/uploads.d.ts +1 -0
- package/uploads.d.ts.map +1 -1
- package/uploads.mjs +1 -0
- package/uploads.mjs.map +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
package/src/resources/events.ts
CHANGED
|
@@ -131,9 +131,6 @@ export namespace EventListResponse {
|
|
|
131
131
|
*/
|
|
132
132
|
id: string;
|
|
133
133
|
|
|
134
|
-
/**
|
|
135
|
-
* The Android destination URL for the short link for Android device targeting.
|
|
136
|
-
*/
|
|
137
134
|
android: string | null;
|
|
138
135
|
|
|
139
136
|
/**
|
|
@@ -141,17 +138,10 @@ export namespace EventListResponse {
|
|
|
141
138
|
*/
|
|
142
139
|
clicks: number;
|
|
143
140
|
|
|
144
|
-
/**
|
|
145
|
-
* The comments for the short link.
|
|
146
|
-
*/
|
|
147
141
|
comments: string | null;
|
|
148
142
|
|
|
149
143
|
createdAt: string;
|
|
150
144
|
|
|
151
|
-
/**
|
|
152
|
-
* The description of the short link generated via `api.codeqr.io/metatags`. Will
|
|
153
|
-
* be used for custom link preview if `proxy` is true.
|
|
154
|
-
*/
|
|
155
145
|
description: string | null;
|
|
156
146
|
|
|
157
147
|
/**
|
|
@@ -160,16 +150,8 @@ export namespace EventListResponse {
|
|
|
160
150
|
*/
|
|
161
151
|
domain: string;
|
|
162
152
|
|
|
163
|
-
/**
|
|
164
|
-
* The URL to redirect to when the short link expires.
|
|
165
|
-
*/
|
|
166
153
|
expiredUrl: string | null;
|
|
167
154
|
|
|
168
|
-
/**
|
|
169
|
-
* This is the ID of the link in your database.
|
|
170
|
-
*/
|
|
171
|
-
externalId: string | null;
|
|
172
|
-
|
|
173
155
|
/**
|
|
174
156
|
* Whether the link is filled or not.
|
|
175
157
|
*/
|
|
@@ -180,26 +162,12 @@ export namespace EventListResponse {
|
|
|
180
162
|
*/
|
|
181
163
|
flexible: boolean;
|
|
182
164
|
|
|
183
|
-
/**
|
|
184
|
-
* The unique ID of the folder assigned to the short link.
|
|
185
|
-
*/
|
|
186
165
|
folderId: string | null;
|
|
187
166
|
|
|
188
|
-
/**
|
|
189
|
-
* Geographic targeting information for the short link in JSON format
|
|
190
|
-
* `{[COUNTRY]: https://example.com }`. Learn more: https://codeqr.link/geo
|
|
191
|
-
*/
|
|
192
167
|
geo: { [key: string]: string } | null;
|
|
193
168
|
|
|
194
|
-
/**
|
|
195
|
-
* The image of the short link generated via `api.codeqr.io/metatags`. Will be used
|
|
196
|
-
* for custom link preview if `proxy` is true.
|
|
197
|
-
*/
|
|
198
169
|
image: string | null;
|
|
199
170
|
|
|
200
|
-
/**
|
|
201
|
-
* The iOS destination URL for the short link for iOS device targeting.
|
|
202
|
-
*/
|
|
203
171
|
ios: string | null;
|
|
204
172
|
|
|
205
173
|
/**
|
|
@@ -213,21 +181,13 @@ export namespace EventListResponse {
|
|
|
213
181
|
*/
|
|
214
182
|
key: string;
|
|
215
183
|
|
|
216
|
-
lastClicked: string;
|
|
217
|
-
|
|
218
184
|
/**
|
|
219
185
|
* The number of leads generated by the short link.
|
|
220
186
|
*/
|
|
221
187
|
leads: number;
|
|
222
188
|
|
|
223
|
-
/**
|
|
224
|
-
* The notification token of the short link.
|
|
225
|
-
*/
|
|
226
189
|
notificationToken: string | null;
|
|
227
190
|
|
|
228
|
-
/**
|
|
229
|
-
* The password required to access the short link destination URL.
|
|
230
|
-
*/
|
|
231
191
|
password: string | null;
|
|
232
192
|
|
|
233
193
|
/**
|
|
@@ -250,62 +210,40 @@ export namespace EventListResponse {
|
|
|
250
210
|
*/
|
|
251
211
|
sales: number;
|
|
252
212
|
|
|
253
|
-
/**
|
|
254
|
-
* @deprecated [DEPRECATED (use `tags` instead)]: The unique ID of the tag assigned
|
|
255
|
-
* to the short link.
|
|
256
|
-
*/
|
|
257
213
|
tagId: string | null;
|
|
258
214
|
|
|
259
|
-
/**
|
|
260
|
-
* The tags assigned to the short link.
|
|
261
|
-
*/
|
|
262
215
|
tags: Array<TagsAPI.Tag> | null;
|
|
263
216
|
|
|
264
|
-
/**
|
|
265
|
-
* The title of the short link generated via `api.codeqr.io/metatags`. Will be used
|
|
266
|
-
* for custom link preview if `proxy` is true.
|
|
267
|
-
*/
|
|
268
217
|
title: string | null;
|
|
269
218
|
|
|
270
219
|
updatedAt: string;
|
|
271
220
|
|
|
272
|
-
userId: string | null;
|
|
273
|
-
|
|
274
221
|
/**
|
|
275
|
-
*
|
|
222
|
+
* Whether this link should be used as a reusable template.
|
|
276
223
|
*/
|
|
224
|
+
useAsTemplate: boolean;
|
|
225
|
+
|
|
277
226
|
utm_campaign: string | null;
|
|
278
227
|
|
|
279
|
-
/**
|
|
280
|
-
* The UTM content of the short link.
|
|
281
|
-
*/
|
|
282
228
|
utm_content: string | null;
|
|
283
229
|
|
|
284
|
-
/**
|
|
285
|
-
* The UTM medium of the short link.
|
|
286
|
-
*/
|
|
287
230
|
utm_medium: string | null;
|
|
288
231
|
|
|
289
|
-
/**
|
|
290
|
-
* The UTM source of the short link.
|
|
291
|
-
*/
|
|
292
232
|
utm_source: string | null;
|
|
293
233
|
|
|
294
|
-
/**
|
|
295
|
-
* The UTM term of the short link.
|
|
296
|
-
*/
|
|
297
234
|
utm_term: string | null;
|
|
298
235
|
|
|
299
|
-
/**
|
|
300
|
-
* The video of the short link.
|
|
301
|
-
*/
|
|
302
236
|
video: string | null;
|
|
303
237
|
|
|
304
238
|
archived?: boolean;
|
|
305
239
|
|
|
306
240
|
doIndex?: boolean;
|
|
307
241
|
|
|
308
|
-
expiresAt?: string;
|
|
242
|
+
expiresAt?: string | null;
|
|
243
|
+
|
|
244
|
+
externalId?: string | null;
|
|
245
|
+
|
|
246
|
+
lastClicked?: string | null;
|
|
309
247
|
|
|
310
248
|
/**
|
|
311
249
|
* The ID of the page to redirect to before the link destination.
|
|
@@ -329,6 +267,8 @@ export namespace EventListResponse {
|
|
|
329
267
|
|
|
330
268
|
rewrite?: boolean;
|
|
331
269
|
|
|
270
|
+
rules?: Array<Link.Rule> | null;
|
|
271
|
+
|
|
332
272
|
/**
|
|
333
273
|
* The complete URL of the short link, including the https protocol (for example,
|
|
334
274
|
* `https://codeqr.link/try`).
|
|
@@ -338,6 +278,27 @@ export namespace EventListResponse {
|
|
|
338
278
|
trackConversion?: boolean;
|
|
339
279
|
|
|
340
280
|
url?: string;
|
|
281
|
+
|
|
282
|
+
userId?: string | null;
|
|
283
|
+
}
|
|
284
|
+
|
|
285
|
+
export namespace Link {
|
|
286
|
+
export interface Rule {
|
|
287
|
+
attribute:
|
|
288
|
+
| 'device'
|
|
289
|
+
| 'country'
|
|
290
|
+
| 'utm_source'
|
|
291
|
+
| 'utm_medium'
|
|
292
|
+
| 'utm_campaign'
|
|
293
|
+
| 'referrer'
|
|
294
|
+
| 'language';
|
|
295
|
+
|
|
296
|
+
operator: 'equals' | 'not_equals';
|
|
297
|
+
|
|
298
|
+
url: string;
|
|
299
|
+
|
|
300
|
+
value: string;
|
|
301
|
+
}
|
|
341
302
|
}
|
|
342
303
|
}
|
|
343
304
|
|
|
@@ -666,9 +627,6 @@ export namespace EventListResponse {
|
|
|
666
627
|
*/
|
|
667
628
|
id: string;
|
|
668
629
|
|
|
669
|
-
/**
|
|
670
|
-
* The Android destination URL for the short link for Android device targeting.
|
|
671
|
-
*/
|
|
672
630
|
android: string | null;
|
|
673
631
|
|
|
674
632
|
/**
|
|
@@ -676,17 +634,10 @@ export namespace EventListResponse {
|
|
|
676
634
|
*/
|
|
677
635
|
clicks: number;
|
|
678
636
|
|
|
679
|
-
/**
|
|
680
|
-
* The comments for the short link.
|
|
681
|
-
*/
|
|
682
637
|
comments: string | null;
|
|
683
638
|
|
|
684
639
|
createdAt: string;
|
|
685
640
|
|
|
686
|
-
/**
|
|
687
|
-
* The description of the short link generated via `api.codeqr.io/metatags`. Will
|
|
688
|
-
* be used for custom link preview if `proxy` is true.
|
|
689
|
-
*/
|
|
690
641
|
description: string | null;
|
|
691
642
|
|
|
692
643
|
/**
|
|
@@ -695,16 +646,8 @@ export namespace EventListResponse {
|
|
|
695
646
|
*/
|
|
696
647
|
domain: string;
|
|
697
648
|
|
|
698
|
-
/**
|
|
699
|
-
* The URL to redirect to when the short link expires.
|
|
700
|
-
*/
|
|
701
649
|
expiredUrl: string | null;
|
|
702
650
|
|
|
703
|
-
/**
|
|
704
|
-
* This is the ID of the link in your database.
|
|
705
|
-
*/
|
|
706
|
-
externalId: string | null;
|
|
707
|
-
|
|
708
651
|
/**
|
|
709
652
|
* Whether the link is filled or not.
|
|
710
653
|
*/
|
|
@@ -715,26 +658,12 @@ export namespace EventListResponse {
|
|
|
715
658
|
*/
|
|
716
659
|
flexible: boolean;
|
|
717
660
|
|
|
718
|
-
/**
|
|
719
|
-
* The unique ID of the folder assigned to the short link.
|
|
720
|
-
*/
|
|
721
661
|
folderId: string | null;
|
|
722
662
|
|
|
723
|
-
/**
|
|
724
|
-
* Geographic targeting information for the short link in JSON format
|
|
725
|
-
* `{[COUNTRY]: https://example.com }`. Learn more: https://codeqr.link/geo
|
|
726
|
-
*/
|
|
727
663
|
geo: { [key: string]: string } | null;
|
|
728
664
|
|
|
729
|
-
/**
|
|
730
|
-
* The image of the short link generated via `api.codeqr.io/metatags`. Will be used
|
|
731
|
-
* for custom link preview if `proxy` is true.
|
|
732
|
-
*/
|
|
733
665
|
image: string | null;
|
|
734
666
|
|
|
735
|
-
/**
|
|
736
|
-
* The iOS destination URL for the short link for iOS device targeting.
|
|
737
|
-
*/
|
|
738
667
|
ios: string | null;
|
|
739
668
|
|
|
740
669
|
/**
|
|
@@ -748,21 +677,13 @@ export namespace EventListResponse {
|
|
|
748
677
|
*/
|
|
749
678
|
key: string;
|
|
750
679
|
|
|
751
|
-
lastClicked: string;
|
|
752
|
-
|
|
753
680
|
/**
|
|
754
681
|
* The number of leads generated by the short link.
|
|
755
682
|
*/
|
|
756
683
|
leads: number;
|
|
757
684
|
|
|
758
|
-
/**
|
|
759
|
-
* The notification token of the short link.
|
|
760
|
-
*/
|
|
761
685
|
notificationToken: string | null;
|
|
762
686
|
|
|
763
|
-
/**
|
|
764
|
-
* The password required to access the short link destination URL.
|
|
765
|
-
*/
|
|
766
687
|
password: string | null;
|
|
767
688
|
|
|
768
689
|
/**
|
|
@@ -785,62 +706,40 @@ export namespace EventListResponse {
|
|
|
785
706
|
*/
|
|
786
707
|
sales: number;
|
|
787
708
|
|
|
788
|
-
/**
|
|
789
|
-
* @deprecated [DEPRECATED (use `tags` instead)]: The unique ID of the tag assigned
|
|
790
|
-
* to the short link.
|
|
791
|
-
*/
|
|
792
709
|
tagId: string | null;
|
|
793
710
|
|
|
794
|
-
/**
|
|
795
|
-
* The tags assigned to the short link.
|
|
796
|
-
*/
|
|
797
711
|
tags: Array<TagsAPI.Tag> | null;
|
|
798
712
|
|
|
799
|
-
/**
|
|
800
|
-
* The title of the short link generated via `api.codeqr.io/metatags`. Will be used
|
|
801
|
-
* for custom link preview if `proxy` is true.
|
|
802
|
-
*/
|
|
803
713
|
title: string | null;
|
|
804
714
|
|
|
805
715
|
updatedAt: string;
|
|
806
716
|
|
|
807
|
-
userId: string | null;
|
|
808
|
-
|
|
809
717
|
/**
|
|
810
|
-
*
|
|
718
|
+
* Whether this link should be used as a reusable template.
|
|
811
719
|
*/
|
|
720
|
+
useAsTemplate: boolean;
|
|
721
|
+
|
|
812
722
|
utm_campaign: string | null;
|
|
813
723
|
|
|
814
|
-
/**
|
|
815
|
-
* The UTM content of the short link.
|
|
816
|
-
*/
|
|
817
724
|
utm_content: string | null;
|
|
818
725
|
|
|
819
|
-
/**
|
|
820
|
-
* The UTM medium of the short link.
|
|
821
|
-
*/
|
|
822
726
|
utm_medium: string | null;
|
|
823
727
|
|
|
824
|
-
/**
|
|
825
|
-
* The UTM source of the short link.
|
|
826
|
-
*/
|
|
827
728
|
utm_source: string | null;
|
|
828
729
|
|
|
829
|
-
/**
|
|
830
|
-
* The UTM term of the short link.
|
|
831
|
-
*/
|
|
832
730
|
utm_term: string | null;
|
|
833
731
|
|
|
834
|
-
/**
|
|
835
|
-
* The video of the short link.
|
|
836
|
-
*/
|
|
837
732
|
video: string | null;
|
|
838
733
|
|
|
839
734
|
archived?: boolean;
|
|
840
735
|
|
|
841
736
|
doIndex?: boolean;
|
|
842
737
|
|
|
843
|
-
expiresAt?: string;
|
|
738
|
+
expiresAt?: string | null;
|
|
739
|
+
|
|
740
|
+
externalId?: string | null;
|
|
741
|
+
|
|
742
|
+
lastClicked?: string | null;
|
|
844
743
|
|
|
845
744
|
/**
|
|
846
745
|
* The ID of the page to redirect to before the link destination.
|
|
@@ -864,6 +763,8 @@ export namespace EventListResponse {
|
|
|
864
763
|
|
|
865
764
|
rewrite?: boolean;
|
|
866
765
|
|
|
766
|
+
rules?: Array<Link.Rule> | null;
|
|
767
|
+
|
|
867
768
|
/**
|
|
868
769
|
* The complete URL of the short link, including the https protocol (for example,
|
|
869
770
|
* `https://codeqr.link/try`).
|
|
@@ -873,13 +774,34 @@ export namespace EventListResponse {
|
|
|
873
774
|
trackConversion?: boolean;
|
|
874
775
|
|
|
875
776
|
url?: string;
|
|
777
|
+
|
|
778
|
+
userId?: string | null;
|
|
779
|
+
}
|
|
780
|
+
|
|
781
|
+
export namespace Link {
|
|
782
|
+
export interface Rule {
|
|
783
|
+
attribute:
|
|
784
|
+
| 'device'
|
|
785
|
+
| 'country'
|
|
786
|
+
| 'utm_source'
|
|
787
|
+
| 'utm_medium'
|
|
788
|
+
| 'utm_campaign'
|
|
789
|
+
| 'referrer'
|
|
790
|
+
| 'language';
|
|
791
|
+
|
|
792
|
+
operator: 'equals' | 'not_equals';
|
|
793
|
+
|
|
794
|
+
url: string;
|
|
795
|
+
|
|
796
|
+
value: string;
|
|
797
|
+
}
|
|
876
798
|
}
|
|
877
799
|
|
|
878
800
|
export interface Sale {
|
|
879
801
|
/**
|
|
880
|
-
* The amount of the sale in
|
|
881
|
-
*
|
|
882
|
-
*
|
|
802
|
+
* The amount of the sale in the smallest unit of `currency` — cents for
|
|
803
|
+
* two-decimal currencies, the full integer for zero-decimal ones (e.g. `1437`
|
|
804
|
+
* JPY), thousandths for three-decimal ones (e.g. `1437` KWD fils).
|
|
883
805
|
*/
|
|
884
806
|
amount: number;
|
|
885
807
|
|
|
@@ -1030,6 +952,31 @@ export interface EventListParams {
|
|
|
1030
952
|
* The URL to retrieve analytics for.
|
|
1031
953
|
*/
|
|
1032
954
|
url?: string;
|
|
955
|
+
|
|
956
|
+
/**
|
|
957
|
+
* UTM campaign to filter analytics by.
|
|
958
|
+
*/
|
|
959
|
+
utm_campaign?: string;
|
|
960
|
+
|
|
961
|
+
/**
|
|
962
|
+
* UTM content to filter analytics by.
|
|
963
|
+
*/
|
|
964
|
+
utm_content?: string;
|
|
965
|
+
|
|
966
|
+
/**
|
|
967
|
+
* UTM medium to filter analytics by.
|
|
968
|
+
*/
|
|
969
|
+
utm_medium?: string;
|
|
970
|
+
|
|
971
|
+
/**
|
|
972
|
+
* UTM source to filter analytics by.
|
|
973
|
+
*/
|
|
974
|
+
utm_source?: string;
|
|
975
|
+
|
|
976
|
+
/**
|
|
977
|
+
* UTM term to filter analytics by.
|
|
978
|
+
*/
|
|
979
|
+
utm_term?: string;
|
|
1033
980
|
}
|
|
1034
981
|
|
|
1035
982
|
export declare namespace Events {
|
package/src/resources/index.ts
CHANGED
|
@@ -13,8 +13,8 @@ export {
|
|
|
13
13
|
type DomainListResponse,
|
|
14
14
|
type DomainDeleteResponse,
|
|
15
15
|
type DomainCreateParams,
|
|
16
|
-
type DomainUpdateParams,
|
|
17
16
|
type DomainListParams,
|
|
17
|
+
type DomainUpdateParams,
|
|
18
18
|
} from './domains';
|
|
19
19
|
export { Events, type EventListResponse, type EventListParams } from './events';
|
|
20
20
|
export {
|
|
@@ -22,13 +22,10 @@ export {
|
|
|
22
22
|
type Link,
|
|
23
23
|
type LinkListResponse,
|
|
24
24
|
type LinkDeleteResponse,
|
|
25
|
-
type LinkCountResponse,
|
|
26
25
|
type LinkCreateParams,
|
|
27
|
-
type LinkUpdateParams,
|
|
28
26
|
type LinkListParams,
|
|
29
|
-
type LinkCountParams,
|
|
30
27
|
type LinkRetrieveInfoParams,
|
|
31
|
-
type
|
|
28
|
+
type LinkUpdateParams,
|
|
32
29
|
} from './links/links';
|
|
33
30
|
export { Projects, type Project, type ProjectListResponse } from './projects';
|
|
34
31
|
export {
|
|
@@ -36,13 +33,10 @@ export {
|
|
|
36
33
|
type QrCode,
|
|
37
34
|
type QrcodeListResponse,
|
|
38
35
|
type QrcodeDeleteResponse,
|
|
39
|
-
type QrcodeCountResponse,
|
|
40
36
|
type QrcodeCreateParams,
|
|
37
|
+
type QrcodeListParams,
|
|
41
38
|
type QrcodeRetrieveParams,
|
|
42
39
|
type QrcodeUpdateParams,
|
|
43
|
-
type QrcodeListParams,
|
|
44
|
-
type QrcodeCountParams,
|
|
45
|
-
type QrcodeUpsertParams,
|
|
46
40
|
} from './qrcodes/qrcodes';
|
|
47
41
|
export {
|
|
48
42
|
Tags,
|
|
@@ -50,8 +44,8 @@ export {
|
|
|
50
44
|
type TagListResponse,
|
|
51
45
|
type TagDeleteResponse,
|
|
52
46
|
type TagCreateParams,
|
|
53
|
-
type TagUpdateParams,
|
|
54
47
|
type TagListParams,
|
|
48
|
+
type TagUpdateParams,
|
|
55
49
|
} from './tags';
|
|
56
50
|
export {
|
|
57
51
|
Track,
|
|
@@ -21,21 +21,6 @@ export class Bulk extends APIResource {
|
|
|
21
21
|
const { body } = params ?? {};
|
|
22
22
|
return this._client.post('/links/bulk', { body: body, ...options });
|
|
23
23
|
}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* Bulk delete up to 100 links for the authenticated workspace.
|
|
27
|
-
*
|
|
28
|
-
* @example
|
|
29
|
-
* ```ts
|
|
30
|
-
* const bulk = await client.links.bulk.delete({
|
|
31
|
-
* linkIds: ['clux0rgak00011...', 'clux0rgak00022...'],
|
|
32
|
-
* });
|
|
33
|
-
* ```
|
|
34
|
-
*/
|
|
35
|
-
delete(params: BulkDeleteParams, options?: RequestOptions): APIPromise<BulkDeleteResponse> {
|
|
36
|
-
const { linkIds } = params;
|
|
37
|
-
return this._client.delete('/links/bulk', { query: { linkIds }, ...options });
|
|
38
|
-
}
|
|
39
24
|
}
|
|
40
25
|
|
|
41
26
|
export type BulkCreateResponse = Array<LinksAPI.Link | BulkCreateResponse.LinkErrorSchema>;
|
|
@@ -56,7 +41,8 @@ export namespace BulkCreateResponse {
|
|
|
56
41
|
| 'invite_pending'
|
|
57
42
|
| 'exceeded_limit'
|
|
58
43
|
| 'conflict'
|
|
59
|
-
| 'unprocessable_entity'
|
|
44
|
+
| 'unprocessable_entity'
|
|
45
|
+
| 'service_unavailable';
|
|
60
46
|
|
|
61
47
|
/**
|
|
62
48
|
* The error message.
|
|
@@ -70,13 +56,6 @@ export namespace BulkCreateResponse {
|
|
|
70
56
|
}
|
|
71
57
|
}
|
|
72
58
|
|
|
73
|
-
export interface BulkDeleteResponse {
|
|
74
|
-
/**
|
|
75
|
-
* The number of links deleted.
|
|
76
|
-
*/
|
|
77
|
-
deletedCount: number;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
59
|
export interface BulkCreateParams {
|
|
81
60
|
body?: Array<BulkCreateParams.Body>;
|
|
82
61
|
}
|
|
@@ -219,6 +198,11 @@ export namespace BulkCreateParams {
|
|
|
219
198
|
*/
|
|
220
199
|
rewrite?: boolean;
|
|
221
200
|
|
|
201
|
+
/**
|
|
202
|
+
* Smart rules for conditional destination routing by request attribute.
|
|
203
|
+
*/
|
|
204
|
+
rules?: Array<Body.Rule> | null;
|
|
205
|
+
|
|
222
206
|
/**
|
|
223
207
|
* @deprecated The unique ID of the tag assigned to the short link. This field is
|
|
224
208
|
* deprecated – use `tagIds` instead.
|
|
@@ -246,6 +230,11 @@ export namespace BulkCreateParams {
|
|
|
246
230
|
*/
|
|
247
231
|
trackConversion?: boolean;
|
|
248
232
|
|
|
233
|
+
/**
|
|
234
|
+
* Whether this link should be used as a reusable template.
|
|
235
|
+
*/
|
|
236
|
+
useAsTemplate?: boolean;
|
|
237
|
+
|
|
249
238
|
/**
|
|
250
239
|
* The video of the short link.
|
|
251
240
|
*/
|
|
@@ -764,22 +753,26 @@ export namespace BulkCreateParams {
|
|
|
764
753
|
|
|
765
754
|
ZW?: string;
|
|
766
755
|
}
|
|
767
|
-
}
|
|
768
|
-
}
|
|
769
756
|
|
|
770
|
-
export interface
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
|
|
775
|
-
|
|
757
|
+
export interface Rule {
|
|
758
|
+
attribute:
|
|
759
|
+
| 'device'
|
|
760
|
+
| 'country'
|
|
761
|
+
| 'utm_source'
|
|
762
|
+
| 'utm_medium'
|
|
763
|
+
| 'utm_campaign'
|
|
764
|
+
| 'referrer'
|
|
765
|
+
| 'language';
|
|
766
|
+
|
|
767
|
+
operator: 'equals' | 'not_equals';
|
|
768
|
+
|
|
769
|
+
url: string;
|
|
770
|
+
|
|
771
|
+
value: string;
|
|
772
|
+
}
|
|
773
|
+
}
|
|
776
774
|
}
|
|
777
775
|
|
|
778
776
|
export declare namespace Bulk {
|
|
779
|
-
export {
|
|
780
|
-
type BulkCreateResponse as BulkCreateResponse,
|
|
781
|
-
type BulkDeleteResponse as BulkDeleteResponse,
|
|
782
|
-
type BulkCreateParams as BulkCreateParams,
|
|
783
|
-
type BulkDeleteParams as BulkDeleteParams,
|
|
784
|
-
};
|
|
777
|
+
export { type BulkCreateResponse as BulkCreateResponse, type BulkCreateParams as BulkCreateParams };
|
|
785
778
|
}
|
|
@@ -1,22 +1,13 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
-
export {
|
|
4
|
-
Bulk,
|
|
5
|
-
type BulkCreateResponse,
|
|
6
|
-
type BulkDeleteResponse,
|
|
7
|
-
type BulkCreateParams,
|
|
8
|
-
type BulkDeleteParams,
|
|
9
|
-
} from './bulk';
|
|
3
|
+
export { Bulk, type BulkCreateResponse, type BulkCreateParams } from './bulk';
|
|
10
4
|
export {
|
|
11
5
|
Links,
|
|
12
6
|
type Link,
|
|
13
7
|
type LinkListResponse,
|
|
14
8
|
type LinkDeleteResponse,
|
|
15
|
-
type LinkCountResponse,
|
|
16
9
|
type LinkCreateParams,
|
|
17
|
-
type LinkUpdateParams,
|
|
18
10
|
type LinkListParams,
|
|
19
|
-
type LinkCountParams,
|
|
20
11
|
type LinkRetrieveInfoParams,
|
|
21
|
-
type
|
|
12
|
+
type LinkUpdateParams,
|
|
22
13
|
} from './links';
|