@numen-crypto/contract 0.19.0 → 0.21.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/dist/index.cjs +25 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +117 -61
- package/dist/index.d.ts +117 -61
- package/dist/index.js +25 -3
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
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,11 +1285,16 @@ var PredictionSchema = zod.z.object({
|
|
|
1284
1285
|
status: PredictionStatusSchema,
|
|
1285
1286
|
outcome: PredictionSideSchema.nullable(),
|
|
1286
1287
|
asset: AssetSymbolSchema,
|
|
1287
|
-
|
|
1288
|
-
|
|
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,
|
|
1295
|
+
/** Staked by real bettors, house seed excluded — this is what actually funds a payout. */
|
|
1296
|
+
stakedYes: MoneyStringSchema,
|
|
1297
|
+
stakedNo: MoneyStringSchema,
|
|
1292
1298
|
/** Share of the total pool sitting on YES, in basis points. */
|
|
1293
1299
|
yesShareBp: zod.z.number().int().min(0).max(1e4),
|
|
1294
1300
|
participants: zod.z.number().int().nonnegative(),
|
|
@@ -1307,6 +1313,12 @@ var PredictionPositionSchema = zod.z.object({
|
|
|
1307
1313
|
var PredictionDetailSchema = PredictionSchema.extend({
|
|
1308
1314
|
position: PredictionPositionSchema.nullable()
|
|
1309
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
|
+
});
|
|
1310
1322
|
exports.ListPredictionsCommand = void 0;
|
|
1311
1323
|
((ListPredictionsCommand2) => {
|
|
1312
1324
|
ListPredictionsCommand2.endpointDetails = endpoint(
|
|
@@ -1319,6 +1331,15 @@ exports.ListPredictionsCommand = void 0;
|
|
|
1319
1331
|
});
|
|
1320
1332
|
ListPredictionsCommand2.ResponseSchema = zod.z.object({ items: zod.z.array(PredictionDetailSchema) });
|
|
1321
1333
|
})(exports.ListPredictionsCommand || (exports.ListPredictionsCommand = {}));
|
|
1334
|
+
var GetPredictionSlotCommand;
|
|
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
|
+
})(GetPredictionSlotCommand || (GetPredictionSlotCommand = {}));
|
|
1322
1343
|
exports.GetPredictionCommand = void 0;
|
|
1323
1344
|
((GetPredictionCommand2) => {
|
|
1324
1345
|
GetPredictionCommand2.endpointDetails = endpoint("GET", "/predictions/:slug", "One prediction with the caller position");
|
|
@@ -1438,6 +1459,7 @@ var REST_API = {
|
|
|
1438
1459
|
},
|
|
1439
1460
|
PREDICTIONS: {
|
|
1440
1461
|
LIST: "/predictions",
|
|
1462
|
+
SLOT: "/predictions/slot",
|
|
1441
1463
|
GET: "/predictions/:slug",
|
|
1442
1464
|
BET: "/predictions/:slug/bet"
|
|
1443
1465
|
},
|