@homespot-sdk/core 0.0.347 → 0.0.348

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.
@@ -1239,27 +1239,120 @@ export const zStageCardsResponse = z.object({
1239
1239
  data: zCursorPageTaskCardResponse,
1240
1240
  });
1241
1241
  export const zBucket = z.object({
1242
- count: z.optional(z.coerce
1242
+ count: z.coerce
1243
1243
  .bigint()
1244
1244
  .min(BigInt('-9223372036854775808'), {
1245
1245
  error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1246
1246
  })
1247
1247
  .max(BigInt('9223372036854775807'), {
1248
1248
  error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1249
- })),
1250
- value: z.optional(z.number()),
1251
- commission: z.optional(z.number()),
1249
+ }),
1250
+ value: z.number(),
1251
+ commission: z.number(),
1252
1252
  });
1253
1253
  export const zPipelineCommissionResponse = z.object({
1254
- from: z.optional(z.iso.date()),
1255
- to: z.optional(z.iso.date()),
1256
- won: z.optional(zBucket),
1257
- lost: z.optional(zBucket),
1258
- pending: z.optional(zBucket),
1259
- total: z.optional(zBucket),
1254
+ from: z.iso.date(),
1255
+ to: z.iso.date(),
1256
+ won: zBucket,
1257
+ lost: zBucket,
1258
+ pending: zBucket,
1259
+ total: zBucket,
1260
+ });
1261
+ export const zOutcomeBucket = z.object({
1262
+ count: z.coerce
1263
+ .bigint()
1264
+ .min(BigInt('-9223372036854775808'), {
1265
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1266
+ })
1267
+ .max(BigInt('9223372036854775807'), {
1268
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1269
+ }),
1270
+ share: z.number(),
1271
+ value: z.number(),
1272
+ commission: z.number(),
1273
+ spark: z.array(z.coerce
1274
+ .bigint()
1275
+ .min(BigInt('-9223372036854775808'), {
1276
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1277
+ })
1278
+ .max(BigInt('9223372036854775807'), {
1279
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1280
+ })),
1281
+ });
1282
+ export const zOutcomes = z.object({
1283
+ won: zOutcomeBucket,
1284
+ lost: zOutcomeBucket,
1285
+ pending: zOutcomeBucket,
1286
+ total: zOutcomeBucket,
1287
+ });
1288
+ export const zStageStats = z.object({
1289
+ stageId: z.uuid(),
1290
+ name: z.string(),
1291
+ color: z.string(),
1292
+ position: z
1293
+ .int()
1294
+ .min(-2147483648, {
1295
+ error: 'Invalid value: Expected int32 to be >= -2147483648',
1296
+ })
1297
+ .max(2147483647, {
1298
+ error: 'Invalid value: Expected int32 to be <= 2147483647',
1299
+ }),
1300
+ openCount: z.coerce
1301
+ .bigint()
1302
+ .min(BigInt('-9223372036854775808'), {
1303
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1304
+ })
1305
+ .max(BigInt('9223372036854775807'), {
1306
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1307
+ }),
1308
+ value: z.number(),
1309
+ commission: z.number(),
1310
+ avgAgeSeconds: z.optional(z.coerce
1311
+ .bigint()
1312
+ .min(BigInt('-9223372036854775808'), {
1313
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1314
+ })
1315
+ .max(BigInt('9223372036854775807'), {
1316
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1317
+ })),
1318
+ });
1319
+ export const zBoardStatsResponse = z.object({
1320
+ boardId: z.uuid(),
1321
+ boardName: z.string(),
1322
+ from: z.iso.date(),
1323
+ to: z.iso.date(),
1324
+ granularity: z.enum(['DAY', 'WEEK', 'MONTH']),
1325
+ buckets: z.array(z.iso.date()),
1326
+ outcomes: zOutcomes,
1327
+ stages: z.array(zStageStats),
1328
+ });
1329
+ export const zSegment = z.object({
1330
+ kind: z.enum(['LISTER_ONLY', 'SEEKER_ONLY', 'BOTH', 'NEITHER']),
1331
+ count: z.coerce
1332
+ .bigint()
1333
+ .min(BigInt('-9223372036854775808'), {
1334
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1335
+ })
1336
+ .max(BigInt('9223372036854775807'), {
1337
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1338
+ }),
1339
+ share: z.number(),
1340
+ });
1341
+ export const zContactSegmentsResponse = z.object({
1342
+ from: z.iso.date(),
1343
+ to: z.iso.date(),
1344
+ segments: z.array(zSegment),
1345
+ total: z.coerce
1346
+ .bigint()
1347
+ .min(BigInt('-9223372036854775808'), {
1348
+ error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1349
+ })
1350
+ .max(BigInt('9223372036854775807'), {
1351
+ error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1352
+ }),
1260
1353
  });
1261
1354
  export const zChannelSeries = z.object({
1262
- channel: z.optional(z.enum([
1355
+ channel: z.enum([
1263
1356
  'MY_HOME',
1264
1357
  'SS',
1265
1358
  'HOME_SPOT',
@@ -1268,38 +1361,38 @@ export const zChannelSeries = z.object({
1268
1361
  'INSTAGRAM',
1269
1362
  'WHATSAPP',
1270
1363
  'UNKNOWN',
1271
- ])),
1272
- points: z.optional(z.array(z.coerce
1364
+ ]),
1365
+ points: z.array(z.coerce
1273
1366
  .bigint()
1274
1367
  .min(BigInt('-9223372036854775808'), {
1275
1368
  error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1276
1369
  })
1277
1370
  .max(BigInt('9223372036854775807'), {
1278
1371
  error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1279
- }))),
1280
- total: z.optional(z.coerce
1372
+ })),
1373
+ total: z.coerce
1281
1374
  .bigint()
1282
1375
  .min(BigInt('-9223372036854775808'), {
1283
1376
  error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1284
1377
  })
1285
1378
  .max(BigInt('9223372036854775807'), {
1286
1379
  error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1287
- })),
1380
+ }),
1288
1381
  });
1289
1382
  export const zContactAcquisitionResponse = z.object({
1290
- from: z.optional(z.iso.date()),
1291
- to: z.optional(z.iso.date()),
1292
- granularity: z.optional(z.enum(['DAY', 'WEEK', 'MONTH'])),
1293
- buckets: z.optional(z.array(z.iso.date())),
1294
- series: z.optional(z.array(zChannelSeries)),
1295
- total: z.optional(z.coerce
1383
+ from: z.iso.date(),
1384
+ to: z.iso.date(),
1385
+ granularity: z.enum(['DAY', 'WEEK', 'MONTH']),
1386
+ buckets: z.array(z.iso.date()),
1387
+ series: z.array(zChannelSeries),
1388
+ total: z.coerce
1296
1389
  .bigint()
1297
1390
  .min(BigInt('-9223372036854775808'), {
1298
1391
  error: 'Invalid value: Expected int64 to be >= -9223372036854775808',
1299
1392
  })
1300
1393
  .max(BigInt('9223372036854775807'), {
1301
1394
  error: 'Invalid value: Expected int64 to be <= 9223372036854775807',
1302
- })),
1395
+ }),
1303
1396
  });
1304
1397
  export const zPageMetadata = z.object({
1305
1398
  size: z.optional(z.coerce
@@ -4936,6 +5029,35 @@ export const zGetStatsPipelineCommissionData = z.object({
4936
5029
  * OK
4937
5030
  */
4938
5031
  export const zGetStatsPipelineCommissionResponse = zPipelineCommissionResponse;
5032
+ export const zGetStatsPipelineBoardsByBoardIdData = z.object({
5033
+ body: z.optional(z.never()),
5034
+ path: z.object({
5035
+ boardId: z.uuid(),
5036
+ }),
5037
+ query: z.object({
5038
+ from: z.iso.date(),
5039
+ to: z.iso.date(),
5040
+ granularity: z.optional(z.enum(['DAY', 'WEEK', 'MONTH'])),
5041
+ memberId: z.optional(z.uuid()),
5042
+ }),
5043
+ });
5044
+ /**
5045
+ * OK
5046
+ */
5047
+ export const zGetStatsPipelineBoardsByBoardIdResponse = zBoardStatsResponse;
5048
+ export const zGetStatsContactsSegmentsData = z.object({
5049
+ body: z.optional(z.never()),
5050
+ path: z.optional(z.never()),
5051
+ query: z.object({
5052
+ from: z.iso.date(),
5053
+ to: z.iso.date(),
5054
+ memberId: z.optional(z.uuid()),
5055
+ }),
5056
+ });
5057
+ /**
5058
+ * OK
5059
+ */
5060
+ export const zGetStatsContactsSegmentsResponse = zContactSegmentsResponse;
4939
5061
  export const zGetStatsContactsAcquisitionData = z.object({
4940
5062
  body: z.optional(z.never()),
4941
5063
  path: z.optional(z.never()),