@numen-crypto/contract 0.20.0 → 0.21.1

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/index.cjs CHANGED
@@ -367,6 +367,7 @@ var NotificationTypeSchema = zod.z.enum([
367
367
  "COMMISSION_ACCRUED",
368
368
  "WITHDRAWAL_SENT",
369
369
  "BONUS_CLAIMED",
370
+ "PREDICTION_SETTLED",
370
371
  "SYSTEM"
371
372
  ]);
372
373
  var NotificationSchema = zod.z.object({
@@ -1273,7 +1274,7 @@ exports.TicketAttachmentUploadCommand = void 0;
1273
1274
  });
1274
1275
  })(exports.TicketAttachmentUploadCommand || (exports.TicketAttachmentUploadCommand = {}));
1275
1276
  var PredictionSideSchema = zod.z.enum(["YES", "NO"]);
1276
- var PredictionStatusSchema = zod.z.enum(["OPEN", "LOCKED", "RESOLVING", "RESOLVED", "VOID"]);
1277
+ var PredictionStatusSchema = zod.z.enum(["QUEUED", "OPEN", "LOCKED", "RESOLVING", "RESOLVED", "VOID"]);
1277
1278
  var PredictionSchema = zod.z.object({
1278
1279
  id: zod.z.string().uuid(),
1279
1280
  slug: zod.z.string(),
@@ -1284,8 +1285,10 @@ var PredictionSchema = zod.z.object({
1284
1285
  status: PredictionStatusSchema,
1285
1286
  outcome: PredictionSideSchema.nullable(),
1286
1287
  asset: AssetSymbolSchema,
1287
- betsCloseAt: zod.z.string(),
1288
- resolvesAt: zod.z.string(),
1288
+ /** Null while the prediction still waits in the queue — dates are stamped on air. */
1289
+ betsCloseAt: zod.z.string().nullable(),
1290
+ resolvesAt: zod.z.string().nullable(),
1291
+ openedAt: zod.z.string().nullable(),
1289
1292
  poolYes: MoneyStringSchema,
1290
1293
  poolNo: MoneyStringSchema,
1291
1294
  poolTotal: MoneyStringSchema,
@@ -1310,6 +1313,12 @@ var PredictionPositionSchema = zod.z.object({
1310
1313
  var PredictionDetailSchema = PredictionSchema.extend({
1311
1314
  position: PredictionPositionSchema.nullable()
1312
1315
  });
1316
+ var PredictionSlotSchema = zod.z.object({
1317
+ live: PredictionDetailSchema.nullable(),
1318
+ last: PredictionDetailSchema.nullable(),
1319
+ nextOpensAt: zod.z.string().nullable(),
1320
+ queued: zod.z.number().int().nonnegative()
1321
+ });
1313
1322
  exports.ListPredictionsCommand = void 0;
1314
1323
  ((ListPredictionsCommand2) => {
1315
1324
  ListPredictionsCommand2.endpointDetails = endpoint(
@@ -1322,6 +1331,15 @@ exports.ListPredictionsCommand = void 0;
1322
1331
  });
1323
1332
  ListPredictionsCommand2.ResponseSchema = zod.z.object({ items: zod.z.array(PredictionDetailSchema) });
1324
1333
  })(exports.ListPredictionsCommand || (exports.ListPredictionsCommand = {}));
1334
+ exports.GetPredictionSlotCommand = void 0;
1335
+ ((GetPredictionSlotCommand2) => {
1336
+ GetPredictionSlotCommand2.endpointDetails = endpoint(
1337
+ "GET",
1338
+ "/predictions/slot",
1339
+ "What the dashboard shows now: the live prediction, or the last result and the countdown"
1340
+ );
1341
+ GetPredictionSlotCommand2.ResponseSchema = PredictionSlotSchema;
1342
+ })(exports.GetPredictionSlotCommand || (exports.GetPredictionSlotCommand = {}));
1325
1343
  exports.GetPredictionCommand = void 0;
1326
1344
  ((GetPredictionCommand2) => {
1327
1345
  GetPredictionCommand2.endpointDetails = endpoint("GET", "/predictions/:slug", "One prediction with the caller position");
@@ -1441,6 +1459,7 @@ var REST_API = {
1441
1459
  },
1442
1460
  PREDICTIONS: {
1443
1461
  LIST: "/predictions",
1462
+ SLOT: "/predictions/slot",
1444
1463
  GET: "/predictions/:slug",
1445
1464
  BET: "/predictions/:slug/bet"
1446
1465
  },
@@ -1518,6 +1537,7 @@ exports.PredictionDetailSchema = PredictionDetailSchema;
1518
1537
  exports.PredictionPositionSchema = PredictionPositionSchema;
1519
1538
  exports.PredictionSchema = PredictionSchema;
1520
1539
  exports.PredictionSideSchema = PredictionSideSchema;
1540
+ exports.PredictionSlotSchema = PredictionSlotSchema;
1521
1541
  exports.PredictionStatusSchema = PredictionStatusSchema;
1522
1542
  exports.PublicTradeSchema = PublicTradeSchema;
1523
1543
  exports.REST_API = REST_API;