@readyfor/api-client-pigeon 0.204.0 → 0.206.0-pr972.a0fd0c3
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/dist/{chunk-NRG2B6IH.mjs → chunk-2MMWMEXK.mjs} +1 -1
- package/dist/{chunk-LPRHBCYQ.mjs → chunk-4FARDKZH.mjs} +1 -1
- package/dist/{chunk-XZHFP5LC.mjs → chunk-4VTSMOLP.mjs} +1 -1
- package/dist/{chunk-K7GDUSMN.mjs → chunk-7EJYWAM4.mjs} +1 -1
- package/dist/{chunk-QVXGKDN7.mjs → chunk-ECVEPFAI.mjs} +1 -1
- package/dist/{chunk-VP2N74DP.mjs → chunk-FOCILVNV.mjs} +1 -1
- package/dist/{chunk-TCFEZAJT.mjs → chunk-FP5RUB46.mjs} +1 -1
- package/dist/{chunk-EU35TDAI.mjs → chunk-FUIJU2DC.mjs} +1 -1
- package/dist/{chunk-HXXKAZDM.mjs → chunk-HQKSU4DI.mjs} +4 -0
- package/dist/{chunk-6HAZ74NE.mjs → chunk-IPPG4HQB.mjs} +1 -1
- package/dist/chunk-KBTZNIQJ.mjs +20 -0
- package/dist/{chunk-HXNGO56J.mjs → chunk-MCXNTHWW.mjs} +1 -1
- package/dist/{chunk-SMZ4TQUF.mjs → chunk-NZ4GVNQD.mjs} +1 -1
- package/dist/{chunk-5W4KIPPC.mjs → chunk-S32VFOLV.mjs} +1 -1
- package/dist/{chunk-B6LDGLWA.mjs → chunk-V2EU732S.mjs} +1 -1
- package/dist/{chunk-A27E5C24.mjs → chunk-Z6OJIRKU.mjs} +1 -1
- package/dist/components.d.mts +8 -1
- package/dist/components.d.ts +8 -1
- package/dist/components.js +5 -0
- package/dist/components.mjs +3 -1
- package/dist/fetch/campaigns.js +3 -0
- package/dist/fetch/campaigns.mjs +2 -2
- package/dist/fetch/campaignsId.js +3 -0
- package/dist/fetch/campaignsId.mjs +2 -2
- package/dist/fetch/campaignsIdPreview.js +3 -0
- package/dist/fetch/campaignsIdPreview.mjs +2 -2
- package/dist/fetch/campaignsIdPreviewDeliveryEmail.d.mts +17 -0
- package/dist/fetch/campaignsIdPreviewDeliveryEmail.d.ts +17 -0
- package/dist/fetch/campaignsIdPreviewDeliveryEmail.js +42 -0
- package/dist/fetch/campaignsIdPreviewDeliveryEmail.mjs +8 -0
- package/dist/fetch/projectsProjectIdOrKeyword.js +3 -0
- package/dist/fetch/projectsProjectIdOrKeyword.mjs +2 -2
- package/dist/fetch/segmentsBehaviorSegments.js +3 -0
- package/dist/fetch/segmentsBehaviorSegments.mjs +2 -2
- package/dist/fetch/segmentsProfileSegments.js +3 -0
- package/dist/fetch/segmentsProfileSegments.mjs +2 -2
- package/dist/fetch/segmentsTargetUsersCount.js +3 -0
- package/dist/fetch/segmentsTargetUsersCount.mjs +2 -2
- package/dist/hooks/index.js +42 -36
- package/dist/hooks/index.mjs +21 -20
- package/dist/hooks/useCampaigns.js +14 -8
- package/dist/hooks/useCampaigns.mjs +11 -10
- package/dist/hooks/useCampaignsId.js +14 -8
- package/dist/hooks/useCampaignsId.mjs +11 -10
- package/dist/hooks/useCampaignsIdPreview.js +14 -8
- package/dist/hooks/useCampaignsIdPreview.mjs +11 -10
- package/dist/hooks/useProjectsProjectIdOrKeyword.js +15 -9
- package/dist/hooks/useProjectsProjectIdOrKeyword.mjs +11 -10
- package/dist/hooks/useSegmentsBehaviorSegments.js +15 -9
- package/dist/hooks/useSegmentsBehaviorSegments.mjs +11 -10
- package/dist/hooks/useSegmentsProfileSegments.js +15 -9
- package/dist/hooks/useSegmentsProfileSegments.mjs +11 -10
- package/dist/hooks/useSegmentsTargetUsersCount.js +15 -9
- package/dist/hooks/useSegmentsTargetUsersCount.mjs +11 -10
- package/dist/index.d.mts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +36 -14
- package/dist/index.mjs +21 -13
- package/dist/schemaType.d.mts +41 -0
- package/dist/schemaType.d.ts +41 -0
- package/package.json +11 -12
- /package/dist/{chunk-OAIF3WPC.mjs → chunk-S7JMIMW4.mjs} +0 -0
package/dist/hooks/index.js
CHANGED
|
@@ -58,7 +58,7 @@ module.exports = __toCommonJS(hooks_exports);
|
|
|
58
58
|
var import_immutable = __toESM(require("swr/immutable"));
|
|
59
59
|
var import_infinite = __toESM(require("swr/infinite"));
|
|
60
60
|
var import_swr = __toESM(require("swr"));
|
|
61
|
-
var
|
|
61
|
+
var import_api_client_base10 = require("@readyfor/api-client-base");
|
|
62
62
|
var import_react = require("@readyfor/api-client-base/react");
|
|
63
63
|
|
|
64
64
|
// src/components.ts
|
|
@@ -259,6 +259,9 @@ var GetBehaviorSegmentsResponse = import_zod.z.object({
|
|
|
259
259
|
var GetProjectsProjectIdOrKeywordResponse = import_zod.z.object({
|
|
260
260
|
project: ReadyforProject
|
|
261
261
|
});
|
|
262
|
+
var PostCampaignsCampaignIdPreviewDeliveryEmailRequestBody = import_zod.z.object({
|
|
263
|
+
emails: import_zod.z.array(import_zod.z.string())
|
|
264
|
+
});
|
|
262
265
|
var GetCampaignsCampaignIdPreviewResponse = import_zod.z.object({
|
|
263
266
|
content: import_zod.z.string()
|
|
264
267
|
});
|
|
@@ -291,26 +294,29 @@ var import_api_client_base3 = require("@readyfor/api-client-base");
|
|
|
291
294
|
var import_api_client_base4 = require("@readyfor/api-client-base");
|
|
292
295
|
var buildCampaignsIdPreviewGetFetcher = (requestInit) => (0, import_api_client_base4.createJsonFetcher)(GetCampaignsCampaignIdPreviewResponse, { ...requestInit });
|
|
293
296
|
|
|
294
|
-
// src/fetch/
|
|
297
|
+
// src/fetch/campaignsIdPreviewDeliveryEmail.ts
|
|
295
298
|
var import_api_client_base5 = require("@readyfor/api-client-base");
|
|
296
|
-
var buildProjectsProjectIdOrKeywordGetFetcher = (requestInit) => (0, import_api_client_base5.createJsonFetcher)(GetProjectsProjectIdOrKeywordResponse, { ...requestInit });
|
|
297
299
|
|
|
298
|
-
// src/fetch/
|
|
300
|
+
// src/fetch/projectsProjectIdOrKeyword.ts
|
|
299
301
|
var import_api_client_base6 = require("@readyfor/api-client-base");
|
|
300
|
-
var
|
|
302
|
+
var buildProjectsProjectIdOrKeywordGetFetcher = (requestInit) => (0, import_api_client_base6.createJsonFetcher)(GetProjectsProjectIdOrKeywordResponse, { ...requestInit });
|
|
301
303
|
|
|
302
|
-
// src/fetch/
|
|
304
|
+
// src/fetch/segmentsBehaviorSegments.ts
|
|
303
305
|
var import_api_client_base7 = require("@readyfor/api-client-base");
|
|
304
|
-
var
|
|
306
|
+
var buildSegmentsBehaviorSegmentsGetFetcher = (requestInit) => (0, import_api_client_base7.createJsonFetcher)(GetBehaviorSegmentsResponse, { ...requestInit });
|
|
305
307
|
|
|
306
|
-
// src/fetch/
|
|
308
|
+
// src/fetch/segmentsProfileSegments.ts
|
|
307
309
|
var import_api_client_base8 = require("@readyfor/api-client-base");
|
|
308
|
-
var
|
|
310
|
+
var buildSegmentsProfileSegmentsGetFetcher = (requestInit) => (0, import_api_client_base8.createJsonFetcher)(GetProfileSegmentsResponse, { ...requestInit });
|
|
311
|
+
|
|
312
|
+
// src/fetch/segmentsTargetUsersCount.ts
|
|
313
|
+
var import_api_client_base9 = require("@readyfor/api-client-base");
|
|
314
|
+
var buildSegmentsTargetUsersCountGetFetcher = (requestInit) => (0, import_api_client_base9.createJsonFetcher)(GetTargetUsersCountResponse, { ...requestInit });
|
|
309
315
|
|
|
310
316
|
// src/hooks/useCampaigns.ts
|
|
311
317
|
var campaignsGetFetcher = buildCampaignsGetFetcher();
|
|
312
318
|
var useCampaigns = (query, swrConfig = {}) => {
|
|
313
|
-
const key = (0,
|
|
319
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns", {}, query);
|
|
314
320
|
const requestInit = (0, import_react.useRequestInit)();
|
|
315
321
|
const result = (0, import_swr.default)(
|
|
316
322
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -320,7 +326,7 @@ var useCampaigns = (query, swrConfig = {}) => {
|
|
|
320
326
|
return { key, ...result };
|
|
321
327
|
};
|
|
322
328
|
var useCampaignsImmutable = (query, swrConfig = {}) => {
|
|
323
|
-
const key = (0,
|
|
329
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns", {}, query);
|
|
324
330
|
const requestInit = (0, import_react.useRequestInit)();
|
|
325
331
|
const result = (0, import_immutable.default)(
|
|
326
332
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -330,7 +336,7 @@ var useCampaignsImmutable = (query, swrConfig = {}) => {
|
|
|
330
336
|
return { key, ...result };
|
|
331
337
|
};
|
|
332
338
|
var useCampaignsInfinite = (getKey, swrConfig) => (0, import_infinite.default)(
|
|
333
|
-
getKey((query) => (0,
|
|
339
|
+
getKey((query) => (0, import_api_client_base10.__internal__requestUrl)({}, query)),
|
|
334
340
|
campaignsGetFetcher,
|
|
335
341
|
swrConfig
|
|
336
342
|
);
|
|
@@ -339,11 +345,11 @@ var useCampaignsInfinite = (getKey, swrConfig) => (0, import_infinite.default)(
|
|
|
339
345
|
var import_immutable2 = __toESM(require("swr/immutable"));
|
|
340
346
|
var import_infinite2 = __toESM(require("swr/infinite"));
|
|
341
347
|
var import_swr2 = __toESM(require("swr"));
|
|
342
|
-
var
|
|
348
|
+
var import_api_client_base11 = require("@readyfor/api-client-base");
|
|
343
349
|
var import_react2 = require("@readyfor/api-client-base/react");
|
|
344
350
|
var campaignsIdGetFetcher = buildCampaignsIdGetFetcher();
|
|
345
351
|
var useCampaignsId = (path, swrConfig = {}) => {
|
|
346
|
-
const key = (0,
|
|
352
|
+
const key = (0, import_api_client_base11.__internal__requestUrl)("/api/campaigns/{id}", path);
|
|
347
353
|
const requestInit = (0, import_react2.useRequestInit)();
|
|
348
354
|
const result = (0, import_swr2.default)(
|
|
349
355
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -353,7 +359,7 @@ var useCampaignsId = (path, swrConfig = {}) => {
|
|
|
353
359
|
return { key, ...result };
|
|
354
360
|
};
|
|
355
361
|
var useCampaignsIdImmutable = (path, swrConfig = {}) => {
|
|
356
|
-
const key = (0,
|
|
362
|
+
const key = (0, import_api_client_base11.__internal__requestUrl)("/api/campaigns/{id}", path);
|
|
357
363
|
const requestInit = (0, import_react2.useRequestInit)();
|
|
358
364
|
const result = (0, import_immutable2.default)(
|
|
359
365
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -363,7 +369,7 @@ var useCampaignsIdImmutable = (path, swrConfig = {}) => {
|
|
|
363
369
|
return { key, ...result };
|
|
364
370
|
};
|
|
365
371
|
var useCampaignsIdInfinite = (getKey, swrConfig) => (0, import_infinite2.default)(
|
|
366
|
-
getKey((path) => (0,
|
|
372
|
+
getKey((path) => (0, import_api_client_base11.__internal__requestUrl)(path)),
|
|
367
373
|
campaignsIdGetFetcher,
|
|
368
374
|
swrConfig
|
|
369
375
|
);
|
|
@@ -372,11 +378,11 @@ var useCampaignsIdInfinite = (getKey, swrConfig) => (0, import_infinite2.default
|
|
|
372
378
|
var import_immutable3 = __toESM(require("swr/immutable"));
|
|
373
379
|
var import_infinite3 = __toESM(require("swr/infinite"));
|
|
374
380
|
var import_swr3 = __toESM(require("swr"));
|
|
375
|
-
var
|
|
381
|
+
var import_api_client_base12 = require("@readyfor/api-client-base");
|
|
376
382
|
var import_react3 = require("@readyfor/api-client-base/react");
|
|
377
383
|
var campaignsIdPreviewGetFetcher = buildCampaignsIdPreviewGetFetcher();
|
|
378
384
|
var useCampaignsIdPreview = (path, swrConfig = {}) => {
|
|
379
|
-
const key = (0,
|
|
385
|
+
const key = (0, import_api_client_base12.__internal__requestUrl)("/api/campaigns/{id}/preview", path);
|
|
380
386
|
const requestInit = (0, import_react3.useRequestInit)();
|
|
381
387
|
const result = (0, import_swr3.default)(
|
|
382
388
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -386,7 +392,7 @@ var useCampaignsIdPreview = (path, swrConfig = {}) => {
|
|
|
386
392
|
return { key, ...result };
|
|
387
393
|
};
|
|
388
394
|
var useCampaignsIdPreviewImmutable = (path, swrConfig = {}) => {
|
|
389
|
-
const key = (0,
|
|
395
|
+
const key = (0, import_api_client_base12.__internal__requestUrl)("/api/campaigns/{id}/preview", path);
|
|
390
396
|
const requestInit = (0, import_react3.useRequestInit)();
|
|
391
397
|
const result = (0, import_immutable3.default)(
|
|
392
398
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -396,7 +402,7 @@ var useCampaignsIdPreviewImmutable = (path, swrConfig = {}) => {
|
|
|
396
402
|
return { key, ...result };
|
|
397
403
|
};
|
|
398
404
|
var useCampaignsIdPreviewInfinite = (getKey, swrConfig) => (0, import_infinite3.default)(
|
|
399
|
-
getKey((path) => (0,
|
|
405
|
+
getKey((path) => (0, import_api_client_base12.__internal__requestUrl)(path)),
|
|
400
406
|
campaignsIdPreviewGetFetcher,
|
|
401
407
|
swrConfig
|
|
402
408
|
);
|
|
@@ -405,11 +411,11 @@ var useCampaignsIdPreviewInfinite = (getKey, swrConfig) => (0, import_infinite3.
|
|
|
405
411
|
var import_immutable4 = __toESM(require("swr/immutable"));
|
|
406
412
|
var import_infinite4 = __toESM(require("swr/infinite"));
|
|
407
413
|
var import_swr4 = __toESM(require("swr"));
|
|
408
|
-
var
|
|
414
|
+
var import_api_client_base13 = require("@readyfor/api-client-base");
|
|
409
415
|
var import_react4 = require("@readyfor/api-client-base/react");
|
|
410
416
|
var projectsProjectIdOrKeywordGetFetcher = buildProjectsProjectIdOrKeywordGetFetcher();
|
|
411
417
|
var useProjectsProjectIdOrKeyword = (path, swrConfig = {}) => {
|
|
412
|
-
const key = (0,
|
|
418
|
+
const key = (0, import_api_client_base13.__internal__requestUrl)(
|
|
413
419
|
"/api/projects/{project_id_or_keyword}",
|
|
414
420
|
path
|
|
415
421
|
);
|
|
@@ -422,7 +428,7 @@ var useProjectsProjectIdOrKeyword = (path, swrConfig = {}) => {
|
|
|
422
428
|
return { key, ...result };
|
|
423
429
|
};
|
|
424
430
|
var useProjectsProjectIdOrKeywordImmutable = (path, swrConfig = {}) => {
|
|
425
|
-
const key = (0,
|
|
431
|
+
const key = (0, import_api_client_base13.__internal__requestUrl)(
|
|
426
432
|
"/api/projects/{project_id_or_keyword}",
|
|
427
433
|
path
|
|
428
434
|
);
|
|
@@ -436,7 +442,7 @@ var useProjectsProjectIdOrKeywordImmutable = (path, swrConfig = {}) => {
|
|
|
436
442
|
};
|
|
437
443
|
var useProjectsProjectIdOrKeywordInfinite = (getKey, swrConfig) => (0, import_infinite4.default)(
|
|
438
444
|
getKey(
|
|
439
|
-
(path) => (0,
|
|
445
|
+
(path) => (0, import_api_client_base13.__internal__requestUrl)(path)
|
|
440
446
|
),
|
|
441
447
|
projectsProjectIdOrKeywordGetFetcher,
|
|
442
448
|
swrConfig
|
|
@@ -446,11 +452,11 @@ var useProjectsProjectIdOrKeywordInfinite = (getKey, swrConfig) => (0, import_in
|
|
|
446
452
|
var import_immutable5 = __toESM(require("swr/immutable"));
|
|
447
453
|
var import_infinite5 = __toESM(require("swr/infinite"));
|
|
448
454
|
var import_swr5 = __toESM(require("swr"));
|
|
449
|
-
var
|
|
455
|
+
var import_api_client_base14 = require("@readyfor/api-client-base");
|
|
450
456
|
var import_react5 = require("@readyfor/api-client-base/react");
|
|
451
457
|
var segmentsBehaviorSegmentsGetFetcher = buildSegmentsBehaviorSegmentsGetFetcher();
|
|
452
458
|
var useSegmentsBehaviorSegments = (swrConfig = {}) => {
|
|
453
|
-
const key = (0,
|
|
459
|
+
const key = (0, import_api_client_base14.__internal__requestUrl)("/api/segments/behavior_segments");
|
|
454
460
|
const requestInit = (0, import_react5.useRequestInit)();
|
|
455
461
|
const result = (0, import_swr5.default)(
|
|
456
462
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -460,7 +466,7 @@ var useSegmentsBehaviorSegments = (swrConfig = {}) => {
|
|
|
460
466
|
return { key, ...result };
|
|
461
467
|
};
|
|
462
468
|
var useSegmentsBehaviorSegmentsImmutable = (swrConfig = {}) => {
|
|
463
|
-
const key = (0,
|
|
469
|
+
const key = (0, import_api_client_base14.__internal__requestUrl)("/api/segments/behavior_segments");
|
|
464
470
|
const requestInit = (0, import_react5.useRequestInit)();
|
|
465
471
|
const result = (0, import_immutable5.default)(
|
|
466
472
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -470,7 +476,7 @@ var useSegmentsBehaviorSegmentsImmutable = (swrConfig = {}) => {
|
|
|
470
476
|
return { key, ...result };
|
|
471
477
|
};
|
|
472
478
|
var useSegmentsBehaviorSegmentsInfinite = (getKey, swrConfig) => (0, import_infinite5.default)(
|
|
473
|
-
getKey(() => (0,
|
|
479
|
+
getKey(() => (0, import_api_client_base14.__internal__requestUrl)()),
|
|
474
480
|
segmentsBehaviorSegmentsGetFetcher,
|
|
475
481
|
swrConfig
|
|
476
482
|
);
|
|
@@ -479,11 +485,11 @@ var useSegmentsBehaviorSegmentsInfinite = (getKey, swrConfig) => (0, import_infi
|
|
|
479
485
|
var import_immutable6 = __toESM(require("swr/immutable"));
|
|
480
486
|
var import_infinite6 = __toESM(require("swr/infinite"));
|
|
481
487
|
var import_swr6 = __toESM(require("swr"));
|
|
482
|
-
var
|
|
488
|
+
var import_api_client_base15 = require("@readyfor/api-client-base");
|
|
483
489
|
var import_react6 = require("@readyfor/api-client-base/react");
|
|
484
490
|
var segmentsProfileSegmentsGetFetcher = buildSegmentsProfileSegmentsGetFetcher();
|
|
485
491
|
var useSegmentsProfileSegments = (swrConfig = {}) => {
|
|
486
|
-
const key = (0,
|
|
492
|
+
const key = (0, import_api_client_base15.__internal__requestUrl)("/api/segments/profile_segments");
|
|
487
493
|
const requestInit = (0, import_react6.useRequestInit)();
|
|
488
494
|
const result = (0, import_swr6.default)(
|
|
489
495
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -493,7 +499,7 @@ var useSegmentsProfileSegments = (swrConfig = {}) => {
|
|
|
493
499
|
return { key, ...result };
|
|
494
500
|
};
|
|
495
501
|
var useSegmentsProfileSegmentsImmutable = (swrConfig = {}) => {
|
|
496
|
-
const key = (0,
|
|
502
|
+
const key = (0, import_api_client_base15.__internal__requestUrl)("/api/segments/profile_segments");
|
|
497
503
|
const requestInit = (0, import_react6.useRequestInit)();
|
|
498
504
|
const result = (0, import_immutable6.default)(
|
|
499
505
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -503,7 +509,7 @@ var useSegmentsProfileSegmentsImmutable = (swrConfig = {}) => {
|
|
|
503
509
|
return { key, ...result };
|
|
504
510
|
};
|
|
505
511
|
var useSegmentsProfileSegmentsInfinite = (getKey, swrConfig) => (0, import_infinite6.default)(
|
|
506
|
-
getKey(() => (0,
|
|
512
|
+
getKey(() => (0, import_api_client_base15.__internal__requestUrl)()),
|
|
507
513
|
segmentsProfileSegmentsGetFetcher,
|
|
508
514
|
swrConfig
|
|
509
515
|
);
|
|
@@ -512,11 +518,11 @@ var useSegmentsProfileSegmentsInfinite = (getKey, swrConfig) => (0, import_infin
|
|
|
512
518
|
var import_immutable7 = __toESM(require("swr/immutable"));
|
|
513
519
|
var import_infinite7 = __toESM(require("swr/infinite"));
|
|
514
520
|
var import_swr7 = __toESM(require("swr"));
|
|
515
|
-
var
|
|
521
|
+
var import_api_client_base16 = require("@readyfor/api-client-base");
|
|
516
522
|
var import_react7 = require("@readyfor/api-client-base/react");
|
|
517
523
|
var segmentsTargetUsersCountGetFetcher = buildSegmentsTargetUsersCountGetFetcher();
|
|
518
524
|
var useSegmentsTargetUsersCount = (query, swrConfig = {}) => {
|
|
519
|
-
const key = (0,
|
|
525
|
+
const key = (0, import_api_client_base16.__internal__requestUrl)(
|
|
520
526
|
"/api/segments/target_users_count",
|
|
521
527
|
{},
|
|
522
528
|
query
|
|
@@ -530,7 +536,7 @@ var useSegmentsTargetUsersCount = (query, swrConfig = {}) => {
|
|
|
530
536
|
return { key, ...result };
|
|
531
537
|
};
|
|
532
538
|
var useSegmentsTargetUsersCountImmutable = (query, swrConfig = {}) => {
|
|
533
|
-
const key = (0,
|
|
539
|
+
const key = (0, import_api_client_base16.__internal__requestUrl)(
|
|
534
540
|
"/api/segments/target_users_count",
|
|
535
541
|
{},
|
|
536
542
|
query
|
|
@@ -545,7 +551,7 @@ var useSegmentsTargetUsersCountImmutable = (query, swrConfig = {}) => {
|
|
|
545
551
|
};
|
|
546
552
|
var useSegmentsTargetUsersCountInfinite = (getKey, swrConfig) => (0, import_infinite7.default)(
|
|
547
553
|
getKey(
|
|
548
|
-
(query) => (0,
|
|
554
|
+
(query) => (0, import_api_client_base16.__internal__requestUrl)({}, query)
|
|
549
555
|
),
|
|
550
556
|
segmentsTargetUsersCountGetFetcher,
|
|
551
557
|
swrConfig
|
package/dist/hooks/index.mjs
CHANGED
|
@@ -1,48 +1,49 @@
|
|
|
1
|
+
import {
|
|
2
|
+
useProjectsProjectIdOrKeyword,
|
|
3
|
+
useProjectsProjectIdOrKeywordImmutable,
|
|
4
|
+
useProjectsProjectIdOrKeywordInfinite
|
|
5
|
+
} from "../chunk-7EJYWAM4.mjs";
|
|
1
6
|
import {
|
|
2
7
|
useSegmentsBehaviorSegments,
|
|
3
8
|
useSegmentsBehaviorSegmentsImmutable,
|
|
4
9
|
useSegmentsBehaviorSegmentsInfinite
|
|
5
|
-
} from "../chunk-
|
|
10
|
+
} from "../chunk-4VTSMOLP.mjs";
|
|
6
11
|
import {
|
|
7
12
|
useSegmentsProfileSegments,
|
|
8
13
|
useSegmentsProfileSegmentsImmutable,
|
|
9
14
|
useSegmentsProfileSegmentsInfinite
|
|
10
|
-
} from "../chunk-
|
|
15
|
+
} from "../chunk-4FARDKZH.mjs";
|
|
11
16
|
import {
|
|
12
17
|
useSegmentsTargetUsersCount,
|
|
13
18
|
useSegmentsTargetUsersCountImmutable,
|
|
14
19
|
useSegmentsTargetUsersCountInfinite
|
|
15
|
-
} from "../chunk-
|
|
20
|
+
} from "../chunk-ECVEPFAI.mjs";
|
|
16
21
|
import {
|
|
17
22
|
useCampaigns,
|
|
18
23
|
useCampaignsImmutable,
|
|
19
24
|
useCampaignsInfinite
|
|
20
|
-
} from "../chunk-
|
|
25
|
+
} from "../chunk-2MMWMEXK.mjs";
|
|
21
26
|
import {
|
|
22
27
|
useCampaignsId,
|
|
23
28
|
useCampaignsIdImmutable,
|
|
24
29
|
useCampaignsIdInfinite
|
|
25
|
-
} from "../chunk-
|
|
30
|
+
} from "../chunk-S32VFOLV.mjs";
|
|
26
31
|
import {
|
|
27
32
|
useCampaignsIdPreview,
|
|
28
33
|
useCampaignsIdPreviewImmutable,
|
|
29
34
|
useCampaignsIdPreviewInfinite
|
|
30
|
-
} from "../chunk-
|
|
31
|
-
import
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
import "../chunk-
|
|
37
|
-
import "../chunk-
|
|
38
|
-
import "../chunk-SMZ4TQUF.mjs";
|
|
39
|
-
import "../chunk-EU35TDAI.mjs";
|
|
40
|
-
import "../chunk-6HAZ74NE.mjs";
|
|
41
|
-
import "../chunk-VP2N74DP.mjs";
|
|
35
|
+
} from "../chunk-FP5RUB46.mjs";
|
|
36
|
+
import "../chunk-S7JMIMW4.mjs";
|
|
37
|
+
import "../chunk-V2EU732S.mjs";
|
|
38
|
+
import "../chunk-Z6OJIRKU.mjs";
|
|
39
|
+
import "../chunk-NZ4GVNQD.mjs";
|
|
40
|
+
import "../chunk-FUIJU2DC.mjs";
|
|
41
|
+
import "../chunk-IPPG4HQB.mjs";
|
|
42
|
+
import "../chunk-FOCILVNV.mjs";
|
|
42
43
|
import "../chunk-YV4XRZY2.mjs";
|
|
43
|
-
import "../chunk-
|
|
44
|
-
import "../chunk-
|
|
45
|
-
import "../chunk-
|
|
44
|
+
import "../chunk-MCXNTHWW.mjs";
|
|
45
|
+
import "../chunk-HQKSU4DI.mjs";
|
|
46
|
+
import "../chunk-KBTZNIQJ.mjs";
|
|
46
47
|
export {
|
|
47
48
|
useCampaigns,
|
|
48
49
|
useCampaignsId,
|
|
@@ -38,7 +38,7 @@ module.exports = __toCommonJS(useCampaigns_exports);
|
|
|
38
38
|
var import_immutable = __toESM(require("swr/immutable"));
|
|
39
39
|
var import_infinite = __toESM(require("swr/infinite"));
|
|
40
40
|
var import_swr = __toESM(require("swr"));
|
|
41
|
-
var
|
|
41
|
+
var import_api_client_base10 = require("@readyfor/api-client-base");
|
|
42
42
|
var import_react = require("@readyfor/api-client-base/react");
|
|
43
43
|
|
|
44
44
|
// src/components.ts
|
|
@@ -239,6 +239,9 @@ var GetBehaviorSegmentsResponse = import_zod.z.object({
|
|
|
239
239
|
var GetProjectsProjectIdOrKeywordResponse = import_zod.z.object({
|
|
240
240
|
project: ReadyforProject
|
|
241
241
|
});
|
|
242
|
+
var PostCampaignsCampaignIdPreviewDeliveryEmailRequestBody = import_zod.z.object({
|
|
243
|
+
emails: import_zod.z.array(import_zod.z.string())
|
|
244
|
+
});
|
|
242
245
|
var GetCampaignsCampaignIdPreviewResponse = import_zod.z.object({
|
|
243
246
|
content: import_zod.z.string()
|
|
244
247
|
});
|
|
@@ -269,22 +272,25 @@ var import_api_client_base3 = require("@readyfor/api-client-base");
|
|
|
269
272
|
// src/fetch/campaignsIdPreview.ts
|
|
270
273
|
var import_api_client_base4 = require("@readyfor/api-client-base");
|
|
271
274
|
|
|
272
|
-
// src/fetch/
|
|
275
|
+
// src/fetch/campaignsIdPreviewDeliveryEmail.ts
|
|
273
276
|
var import_api_client_base5 = require("@readyfor/api-client-base");
|
|
274
277
|
|
|
275
|
-
// src/fetch/
|
|
278
|
+
// src/fetch/projectsProjectIdOrKeyword.ts
|
|
276
279
|
var import_api_client_base6 = require("@readyfor/api-client-base");
|
|
277
280
|
|
|
278
|
-
// src/fetch/
|
|
281
|
+
// src/fetch/segmentsBehaviorSegments.ts
|
|
279
282
|
var import_api_client_base7 = require("@readyfor/api-client-base");
|
|
280
283
|
|
|
281
|
-
// src/fetch/
|
|
284
|
+
// src/fetch/segmentsProfileSegments.ts
|
|
282
285
|
var import_api_client_base8 = require("@readyfor/api-client-base");
|
|
283
286
|
|
|
287
|
+
// src/fetch/segmentsTargetUsersCount.ts
|
|
288
|
+
var import_api_client_base9 = require("@readyfor/api-client-base");
|
|
289
|
+
|
|
284
290
|
// src/hooks/useCampaigns.ts
|
|
285
291
|
var campaignsGetFetcher = buildCampaignsGetFetcher();
|
|
286
292
|
var useCampaigns = (query, swrConfig = {}) => {
|
|
287
|
-
const key = (0,
|
|
293
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns", {}, query);
|
|
288
294
|
const requestInit = (0, import_react.useRequestInit)();
|
|
289
295
|
const result = (0, import_swr.default)(
|
|
290
296
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -294,7 +300,7 @@ var useCampaigns = (query, swrConfig = {}) => {
|
|
|
294
300
|
return { key, ...result };
|
|
295
301
|
};
|
|
296
302
|
var useCampaignsImmutable = (query, swrConfig = {}) => {
|
|
297
|
-
const key = (0,
|
|
303
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns", {}, query);
|
|
298
304
|
const requestInit = (0, import_react.useRequestInit)();
|
|
299
305
|
const result = (0, import_immutable.default)(
|
|
300
306
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -304,7 +310,7 @@ var useCampaignsImmutable = (query, swrConfig = {}) => {
|
|
|
304
310
|
return { key, ...result };
|
|
305
311
|
};
|
|
306
312
|
var useCampaignsInfinite = (getKey, swrConfig) => (0, import_infinite.default)(
|
|
307
|
-
getKey((query) => (0,
|
|
313
|
+
getKey((query) => (0, import_api_client_base10.__internal__requestUrl)({}, query)),
|
|
308
314
|
campaignsGetFetcher,
|
|
309
315
|
swrConfig
|
|
310
316
|
);
|
|
@@ -2,17 +2,18 @@ import {
|
|
|
2
2
|
useCampaigns,
|
|
3
3
|
useCampaignsImmutable,
|
|
4
4
|
useCampaignsInfinite
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-2MMWMEXK.mjs";
|
|
6
|
+
import "../chunk-S7JMIMW4.mjs";
|
|
7
|
+
import "../chunk-V2EU732S.mjs";
|
|
8
|
+
import "../chunk-Z6OJIRKU.mjs";
|
|
9
|
+
import "../chunk-NZ4GVNQD.mjs";
|
|
10
|
+
import "../chunk-FUIJU2DC.mjs";
|
|
11
|
+
import "../chunk-IPPG4HQB.mjs";
|
|
12
|
+
import "../chunk-FOCILVNV.mjs";
|
|
12
13
|
import "../chunk-YV4XRZY2.mjs";
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
15
|
-
import "../chunk-
|
|
14
|
+
import "../chunk-MCXNTHWW.mjs";
|
|
15
|
+
import "../chunk-HQKSU4DI.mjs";
|
|
16
|
+
import "../chunk-KBTZNIQJ.mjs";
|
|
16
17
|
export {
|
|
17
18
|
useCampaigns,
|
|
18
19
|
useCampaignsImmutable,
|
|
@@ -38,7 +38,7 @@ module.exports = __toCommonJS(useCampaignsId_exports);
|
|
|
38
38
|
var import_immutable = __toESM(require("swr/immutable"));
|
|
39
39
|
var import_infinite = __toESM(require("swr/infinite"));
|
|
40
40
|
var import_swr = __toESM(require("swr"));
|
|
41
|
-
var
|
|
41
|
+
var import_api_client_base10 = require("@readyfor/api-client-base");
|
|
42
42
|
var import_react = require("@readyfor/api-client-base/react");
|
|
43
43
|
|
|
44
44
|
// src/components.ts
|
|
@@ -239,6 +239,9 @@ var GetBehaviorSegmentsResponse = import_zod.z.object({
|
|
|
239
239
|
var GetProjectsProjectIdOrKeywordResponse = import_zod.z.object({
|
|
240
240
|
project: ReadyforProject
|
|
241
241
|
});
|
|
242
|
+
var PostCampaignsCampaignIdPreviewDeliveryEmailRequestBody = import_zod.z.object({
|
|
243
|
+
emails: import_zod.z.array(import_zod.z.string())
|
|
244
|
+
});
|
|
242
245
|
var GetCampaignsCampaignIdPreviewResponse = import_zod.z.object({
|
|
243
246
|
content: import_zod.z.string()
|
|
244
247
|
});
|
|
@@ -269,22 +272,25 @@ var import_api_client_base3 = require("@readyfor/api-client-base");
|
|
|
269
272
|
// src/fetch/campaignsIdPreview.ts
|
|
270
273
|
var import_api_client_base4 = require("@readyfor/api-client-base");
|
|
271
274
|
|
|
272
|
-
// src/fetch/
|
|
275
|
+
// src/fetch/campaignsIdPreviewDeliveryEmail.ts
|
|
273
276
|
var import_api_client_base5 = require("@readyfor/api-client-base");
|
|
274
277
|
|
|
275
|
-
// src/fetch/
|
|
278
|
+
// src/fetch/projectsProjectIdOrKeyword.ts
|
|
276
279
|
var import_api_client_base6 = require("@readyfor/api-client-base");
|
|
277
280
|
|
|
278
|
-
// src/fetch/
|
|
281
|
+
// src/fetch/segmentsBehaviorSegments.ts
|
|
279
282
|
var import_api_client_base7 = require("@readyfor/api-client-base");
|
|
280
283
|
|
|
281
|
-
// src/fetch/
|
|
284
|
+
// src/fetch/segmentsProfileSegments.ts
|
|
282
285
|
var import_api_client_base8 = require("@readyfor/api-client-base");
|
|
283
286
|
|
|
287
|
+
// src/fetch/segmentsTargetUsersCount.ts
|
|
288
|
+
var import_api_client_base9 = require("@readyfor/api-client-base");
|
|
289
|
+
|
|
284
290
|
// src/hooks/useCampaignsId.ts
|
|
285
291
|
var campaignsIdGetFetcher = buildCampaignsIdGetFetcher();
|
|
286
292
|
var useCampaignsId = (path, swrConfig = {}) => {
|
|
287
|
-
const key = (0,
|
|
293
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns/{id}", path);
|
|
288
294
|
const requestInit = (0, import_react.useRequestInit)();
|
|
289
295
|
const result = (0, import_swr.default)(
|
|
290
296
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -294,7 +300,7 @@ var useCampaignsId = (path, swrConfig = {}) => {
|
|
|
294
300
|
return { key, ...result };
|
|
295
301
|
};
|
|
296
302
|
var useCampaignsIdImmutable = (path, swrConfig = {}) => {
|
|
297
|
-
const key = (0,
|
|
303
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns/{id}", path);
|
|
298
304
|
const requestInit = (0, import_react.useRequestInit)();
|
|
299
305
|
const result = (0, import_immutable.default)(
|
|
300
306
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -304,7 +310,7 @@ var useCampaignsIdImmutable = (path, swrConfig = {}) => {
|
|
|
304
310
|
return { key, ...result };
|
|
305
311
|
};
|
|
306
312
|
var useCampaignsIdInfinite = (getKey, swrConfig) => (0, import_infinite.default)(
|
|
307
|
-
getKey((path) => (0,
|
|
313
|
+
getKey((path) => (0, import_api_client_base10.__internal__requestUrl)(path)),
|
|
308
314
|
campaignsIdGetFetcher,
|
|
309
315
|
swrConfig
|
|
310
316
|
);
|
|
@@ -2,17 +2,18 @@ import {
|
|
|
2
2
|
useCampaignsId,
|
|
3
3
|
useCampaignsIdImmutable,
|
|
4
4
|
useCampaignsIdInfinite
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-S32VFOLV.mjs";
|
|
6
|
+
import "../chunk-S7JMIMW4.mjs";
|
|
7
|
+
import "../chunk-V2EU732S.mjs";
|
|
8
|
+
import "../chunk-Z6OJIRKU.mjs";
|
|
9
|
+
import "../chunk-NZ4GVNQD.mjs";
|
|
10
|
+
import "../chunk-FUIJU2DC.mjs";
|
|
11
|
+
import "../chunk-IPPG4HQB.mjs";
|
|
12
|
+
import "../chunk-FOCILVNV.mjs";
|
|
12
13
|
import "../chunk-YV4XRZY2.mjs";
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
15
|
-
import "../chunk-
|
|
14
|
+
import "../chunk-MCXNTHWW.mjs";
|
|
15
|
+
import "../chunk-HQKSU4DI.mjs";
|
|
16
|
+
import "../chunk-KBTZNIQJ.mjs";
|
|
16
17
|
export {
|
|
17
18
|
useCampaignsId,
|
|
18
19
|
useCampaignsIdImmutable,
|
|
@@ -38,7 +38,7 @@ module.exports = __toCommonJS(useCampaignsIdPreview_exports);
|
|
|
38
38
|
var import_immutable = __toESM(require("swr/immutable"));
|
|
39
39
|
var import_infinite = __toESM(require("swr/infinite"));
|
|
40
40
|
var import_swr = __toESM(require("swr"));
|
|
41
|
-
var
|
|
41
|
+
var import_api_client_base10 = require("@readyfor/api-client-base");
|
|
42
42
|
var import_react = require("@readyfor/api-client-base/react");
|
|
43
43
|
|
|
44
44
|
// src/components.ts
|
|
@@ -239,6 +239,9 @@ var GetBehaviorSegmentsResponse = import_zod.z.object({
|
|
|
239
239
|
var GetProjectsProjectIdOrKeywordResponse = import_zod.z.object({
|
|
240
240
|
project: ReadyforProject
|
|
241
241
|
});
|
|
242
|
+
var PostCampaignsCampaignIdPreviewDeliveryEmailRequestBody = import_zod.z.object({
|
|
243
|
+
emails: import_zod.z.array(import_zod.z.string())
|
|
244
|
+
});
|
|
242
245
|
var GetCampaignsCampaignIdPreviewResponse = import_zod.z.object({
|
|
243
246
|
content: import_zod.z.string()
|
|
244
247
|
});
|
|
@@ -269,22 +272,25 @@ var import_api_client_base3 = require("@readyfor/api-client-base");
|
|
|
269
272
|
var import_api_client_base4 = require("@readyfor/api-client-base");
|
|
270
273
|
var buildCampaignsIdPreviewGetFetcher = (requestInit) => (0, import_api_client_base4.createJsonFetcher)(GetCampaignsCampaignIdPreviewResponse, { ...requestInit });
|
|
271
274
|
|
|
272
|
-
// src/fetch/
|
|
275
|
+
// src/fetch/campaignsIdPreviewDeliveryEmail.ts
|
|
273
276
|
var import_api_client_base5 = require("@readyfor/api-client-base");
|
|
274
277
|
|
|
275
|
-
// src/fetch/
|
|
278
|
+
// src/fetch/projectsProjectIdOrKeyword.ts
|
|
276
279
|
var import_api_client_base6 = require("@readyfor/api-client-base");
|
|
277
280
|
|
|
278
|
-
// src/fetch/
|
|
281
|
+
// src/fetch/segmentsBehaviorSegments.ts
|
|
279
282
|
var import_api_client_base7 = require("@readyfor/api-client-base");
|
|
280
283
|
|
|
281
|
-
// src/fetch/
|
|
284
|
+
// src/fetch/segmentsProfileSegments.ts
|
|
282
285
|
var import_api_client_base8 = require("@readyfor/api-client-base");
|
|
283
286
|
|
|
287
|
+
// src/fetch/segmentsTargetUsersCount.ts
|
|
288
|
+
var import_api_client_base9 = require("@readyfor/api-client-base");
|
|
289
|
+
|
|
284
290
|
// src/hooks/useCampaignsIdPreview.ts
|
|
285
291
|
var campaignsIdPreviewGetFetcher = buildCampaignsIdPreviewGetFetcher();
|
|
286
292
|
var useCampaignsIdPreview = (path, swrConfig = {}) => {
|
|
287
|
-
const key = (0,
|
|
293
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns/{id}/preview", path);
|
|
288
294
|
const requestInit = (0, import_react.useRequestInit)();
|
|
289
295
|
const result = (0, import_swr.default)(
|
|
290
296
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -294,7 +300,7 @@ var useCampaignsIdPreview = (path, swrConfig = {}) => {
|
|
|
294
300
|
return { key, ...result };
|
|
295
301
|
};
|
|
296
302
|
var useCampaignsIdPreviewImmutable = (path, swrConfig = {}) => {
|
|
297
|
-
const key = (0,
|
|
303
|
+
const key = (0, import_api_client_base10.__internal__requestUrl)("/api/campaigns/{id}/preview", path);
|
|
298
304
|
const requestInit = (0, import_react.useRequestInit)();
|
|
299
305
|
const result = (0, import_immutable.default)(
|
|
300
306
|
swrConfig?.shouldNotFetch ? null : key,
|
|
@@ -304,7 +310,7 @@ var useCampaignsIdPreviewImmutable = (path, swrConfig = {}) => {
|
|
|
304
310
|
return { key, ...result };
|
|
305
311
|
};
|
|
306
312
|
var useCampaignsIdPreviewInfinite = (getKey, swrConfig) => (0, import_infinite.default)(
|
|
307
|
-
getKey((path) => (0,
|
|
313
|
+
getKey((path) => (0, import_api_client_base10.__internal__requestUrl)(path)),
|
|
308
314
|
campaignsIdPreviewGetFetcher,
|
|
309
315
|
swrConfig
|
|
310
316
|
);
|
|
@@ -2,17 +2,18 @@ import {
|
|
|
2
2
|
useCampaignsIdPreview,
|
|
3
3
|
useCampaignsIdPreviewImmutable,
|
|
4
4
|
useCampaignsIdPreviewInfinite
|
|
5
|
-
} from "../chunk-
|
|
6
|
-
import "../chunk-
|
|
7
|
-
import "../chunk-
|
|
8
|
-
import "../chunk-
|
|
9
|
-
import "../chunk-
|
|
10
|
-
import "../chunk-
|
|
11
|
-
import "../chunk-
|
|
5
|
+
} from "../chunk-FP5RUB46.mjs";
|
|
6
|
+
import "../chunk-S7JMIMW4.mjs";
|
|
7
|
+
import "../chunk-V2EU732S.mjs";
|
|
8
|
+
import "../chunk-Z6OJIRKU.mjs";
|
|
9
|
+
import "../chunk-NZ4GVNQD.mjs";
|
|
10
|
+
import "../chunk-FUIJU2DC.mjs";
|
|
11
|
+
import "../chunk-IPPG4HQB.mjs";
|
|
12
|
+
import "../chunk-FOCILVNV.mjs";
|
|
12
13
|
import "../chunk-YV4XRZY2.mjs";
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-
|
|
15
|
-
import "../chunk-
|
|
14
|
+
import "../chunk-MCXNTHWW.mjs";
|
|
15
|
+
import "../chunk-HQKSU4DI.mjs";
|
|
16
|
+
import "../chunk-KBTZNIQJ.mjs";
|
|
16
17
|
export {
|
|
17
18
|
useCampaignsIdPreview,
|
|
18
19
|
useCampaignsIdPreviewImmutable,
|