@numen-crypto/contract 0.8.0 → 0.9.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 +22 -3
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +37 -1
- package/dist/index.d.ts +37 -1
- package/dist/index.js +22 -4
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -19,6 +19,9 @@ declare const ERROR_CODE: {
|
|
|
19
19
|
readonly EMAIL_NOT_VERIFIED: "EMAIL_NOT_VERIFIED";
|
|
20
20
|
readonly EMAIL_ALREADY_VERIFIED: "EMAIL_ALREADY_VERIFIED";
|
|
21
21
|
readonly TOKEN_INVALID: "TOKEN_INVALID";
|
|
22
|
+
readonly TOTP_INVALID: "TOTP_INVALID";
|
|
23
|
+
readonly CAPTCHA_REQUIRED: "CAPTCHA_REQUIRED";
|
|
24
|
+
readonly CAPTCHA_INVALID: "CAPTCHA_INVALID";
|
|
22
25
|
readonly INSUFFICIENT_BALANCE: "INSUFFICIENT_BALANCE";
|
|
23
26
|
readonly PURCHASE_LIMIT_EXCEEDED: "PURCHASE_LIMIT_EXCEEDED";
|
|
24
27
|
readonly PURCHASE_CAP_EXCEEDED: "PURCHASE_CAP_EXCEEDED";
|
|
@@ -1312,14 +1315,17 @@ declare namespace RegisterCommand {
|
|
|
1312
1315
|
email: z.ZodString;
|
|
1313
1316
|
password: z.ZodString;
|
|
1314
1317
|
referralCode: z.ZodOptional<z.ZodString>;
|
|
1318
|
+
captchaToken: z.ZodOptional<z.ZodString>;
|
|
1315
1319
|
}, "strip", z.ZodTypeAny, {
|
|
1316
1320
|
email: string;
|
|
1317
1321
|
password: string;
|
|
1318
1322
|
referralCode?: string | undefined;
|
|
1323
|
+
captchaToken?: string | undefined;
|
|
1319
1324
|
}, {
|
|
1320
1325
|
email: string;
|
|
1321
1326
|
password: string;
|
|
1322
1327
|
referralCode?: string | undefined;
|
|
1328
|
+
captchaToken?: string | undefined;
|
|
1323
1329
|
}>;
|
|
1324
1330
|
type Request = z.infer<typeof RequestSchema>;
|
|
1325
1331
|
const ResponseSchema: z.ZodObject<{
|
|
@@ -1338,13 +1344,16 @@ declare namespace LoginCommand {
|
|
|
1338
1344
|
email: z.ZodString;
|
|
1339
1345
|
password: z.ZodString;
|
|
1340
1346
|
totp: z.ZodOptional<z.ZodString>;
|
|
1347
|
+
captchaToken: z.ZodOptional<z.ZodString>;
|
|
1341
1348
|
}, "strip", z.ZodTypeAny, {
|
|
1342
1349
|
email: string;
|
|
1343
1350
|
password: string;
|
|
1351
|
+
captchaToken?: string | undefined;
|
|
1344
1352
|
totp?: string | undefined;
|
|
1345
1353
|
}, {
|
|
1346
1354
|
email: string;
|
|
1347
1355
|
password: string;
|
|
1356
|
+
captchaToken?: string | undefined;
|
|
1348
1357
|
totp?: string | undefined;
|
|
1349
1358
|
}>;
|
|
1350
1359
|
type Request = z.infer<typeof RequestSchema>;
|
|
@@ -1596,6 +1605,32 @@ declare namespace ResetPasswordCommand {
|
|
|
1596
1605
|
type Response = z.infer<typeof ResponseSchema>;
|
|
1597
1606
|
}
|
|
1598
1607
|
|
|
1608
|
+
declare const ThreatLevelSchema: z.ZodEnum<["calm", "elevated", "high", "attack"]>;
|
|
1609
|
+
type ThreatLevel = z.infer<typeof ThreatLevelSchema>;
|
|
1610
|
+
declare namespace CaptchaPolicyCommand {
|
|
1611
|
+
const endpointDetails: EndpointDetails;
|
|
1612
|
+
const ResponseSchema: z.ZodObject<{
|
|
1613
|
+
provider: z.ZodEnum<["turnstile", "none"]>;
|
|
1614
|
+
siteKey: z.ZodNullable<z.ZodString>;
|
|
1615
|
+
register: z.ZodBoolean;
|
|
1616
|
+
login: z.ZodBoolean;
|
|
1617
|
+
level: z.ZodEnum<["calm", "elevated", "high", "attack"]>;
|
|
1618
|
+
}, "strip", z.ZodTypeAny, {
|
|
1619
|
+
level: "calm" | "elevated" | "high" | "attack";
|
|
1620
|
+
provider: "turnstile" | "none";
|
|
1621
|
+
siteKey: string | null;
|
|
1622
|
+
register: boolean;
|
|
1623
|
+
login: boolean;
|
|
1624
|
+
}, {
|
|
1625
|
+
level: "calm" | "elevated" | "high" | "attack";
|
|
1626
|
+
provider: "turnstile" | "none";
|
|
1627
|
+
siteKey: string | null;
|
|
1628
|
+
register: boolean;
|
|
1629
|
+
login: boolean;
|
|
1630
|
+
}>;
|
|
1631
|
+
type Response = z.infer<typeof ResponseSchema>;
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1599
1634
|
declare namespace GetWalletCommand {
|
|
1600
1635
|
const endpointDetails: EndpointDetails;
|
|
1601
1636
|
const ResponseSchema: zod.ZodObject<{
|
|
@@ -4293,6 +4328,7 @@ declare const REST_API: {
|
|
|
4293
4328
|
readonly RESEND_VERIFICATION: "/auth/verify-email/resend";
|
|
4294
4329
|
readonly FORGOT_PASSWORD: "/auth/password/forgot";
|
|
4295
4330
|
readonly RESET_PASSWORD: "/auth/password/reset";
|
|
4331
|
+
readonly CAPTCHA_POLICY: "/auth/captcha-policy";
|
|
4296
4332
|
};
|
|
4297
4333
|
readonly WALLET: {
|
|
4298
4334
|
readonly OVERVIEW: "/wallet";
|
|
@@ -4373,4 +4409,4 @@ declare const REST_API: {
|
|
|
4373
4409
|
declare const API_PREFIX = "/api";
|
|
4374
4410
|
declare const API_VERSION = "v1";
|
|
4375
4411
|
|
|
4376
|
-
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, type AssetBalance, AssetBalanceSchema, type AssetSymbol, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, type ChartPeriod, ChartPeriodSchema, type ChartPoint, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, type DailyBonusClaimResult, DailyBonusClaimResultSchema, type DailyBonusDay, DailyBonusDaySchema, type DailyBonusStatus, DailyBonusStatusSchema, type DepositAddress, DepositAddressCommand, DepositAddressSchema, type DepositEntry, DepositEntrySchema, type DepositStatus, DepositStatusSchema, type DepositableAsset, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, type EarningsOverview, EarningsOverviewSchema, type EndpointDetails, type ErrorCode, type ErrorResponse, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, type HttpMethod, type IncomeOverview, IncomeOverviewSchema, type IncomePeriod, IncomePeriodSchema, type Leaderboard, type LeaderboardEntry, LeaderboardEntrySchema, type LeaderboardPeriod, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, type LinkProvider, LinkProviderSchema, LinkTelegramCommand, type LinkedAccount, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, type MonthlyPricePoint, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, type Notification, NotificationSchema, type NotificationType, NotificationTypeSchema, type Order, type OrderBook, type OrderBookLevel, OrderBookLevelSchema, OrderBookSchema, OrderSchema, type OrderSide, OrderSideSchema, type OrderStatus, OrderStatusSchema, type OrderType, OrderTypeSchema, type Package, PackageSchema, type PackageStatus, PackageStatusSchema, type PackagesOverview, PackagesOverviewSchema, PaginatedSchema, type PaginationQuery, PaginationQuerySchema, type PartnerAccrual, PartnerAccrualSchema, type PartnerLevel, PartnerLevelSchema, type PartnersOverview, PartnersOverviewSchema, type Period, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, type PublicTrade, PublicTradeSchema, REST_API, type RankDef, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, type SessionInfo, SessionInfoSchema, SetupTotpCommand, type Slide, type SlideButtonStyle, SlideButtonStyleSchema, type SlideKind, SlideKindSchema, type SlideLinkTarget, SlideLinkTargetSchema, SlideSchema, type SlidesResponse, SlidesResponseSchema, SwapCommand, type SwapSide, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, type TicketAttachment, type TicketAttachmentInput, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, type TicketAuthorType, TicketAuthorTypeSchema, TicketBodySchema, type TicketCategory, TicketCategorySchema, type TicketDetail, TicketDetailSchema, type TicketMessage, TicketMessageSchema, type TicketStatus, TicketStatusSchema, type TicketSummary, TicketSummarySchema, type TokenPrice, TokenPriceSchema, type TradeLimits, TradeLimitsSchema, type TradeResult, TradeResultSchema, type Transaction, TransactionSchema, type TransactionStatus, TransactionStatusSchema, type TransactionType, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, type UserProfile, UserProfileSchema, type UserRank, UserRankSchema, type UserSettings, UserSettingsSchema, type UserStatus, UserStatusSchema, UuidSchema, VerifyEmailCommand, type WalletOverview, WalletOverviewSchema, type Withdrawal, WithdrawalSchema, type WithdrawalStatus, WithdrawalStatusSchema, assetDecimals, endpoint };
|
|
4412
|
+
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, type AssetBalance, AssetBalanceSchema, type AssetSymbol, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, CaptchaPolicyCommand, type ChartPeriod, ChartPeriodSchema, type ChartPoint, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, type DailyBonusClaimResult, DailyBonusClaimResultSchema, type DailyBonusDay, DailyBonusDaySchema, type DailyBonusStatus, DailyBonusStatusSchema, type DepositAddress, DepositAddressCommand, DepositAddressSchema, type DepositEntry, DepositEntrySchema, type DepositStatus, DepositStatusSchema, type DepositableAsset, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, type EarningsOverview, EarningsOverviewSchema, type EndpointDetails, type ErrorCode, type ErrorResponse, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, type HttpMethod, type IncomeOverview, IncomeOverviewSchema, type IncomePeriod, IncomePeriodSchema, type Leaderboard, type LeaderboardEntry, LeaderboardEntrySchema, type LeaderboardPeriod, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, type LinkProvider, LinkProviderSchema, LinkTelegramCommand, type LinkedAccount, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, type MonthlyPricePoint, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, type Notification, NotificationSchema, type NotificationType, NotificationTypeSchema, type Order, type OrderBook, type OrderBookLevel, OrderBookLevelSchema, OrderBookSchema, OrderSchema, type OrderSide, OrderSideSchema, type OrderStatus, OrderStatusSchema, type OrderType, OrderTypeSchema, type Package, PackageSchema, type PackageStatus, PackageStatusSchema, type PackagesOverview, PackagesOverviewSchema, PaginatedSchema, type PaginationQuery, PaginationQuerySchema, type PartnerAccrual, PartnerAccrualSchema, type PartnerLevel, PartnerLevelSchema, type PartnersOverview, PartnersOverviewSchema, type Period, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, type PublicTrade, PublicTradeSchema, REST_API, type RankDef, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, type SessionInfo, SessionInfoSchema, SetupTotpCommand, type Slide, type SlideButtonStyle, SlideButtonStyleSchema, type SlideKind, SlideKindSchema, type SlideLinkTarget, SlideLinkTargetSchema, SlideSchema, type SlidesResponse, SlidesResponseSchema, SwapCommand, type SwapSide, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, type ThreatLevel, ThreatLevelSchema, type TicketAttachment, type TicketAttachmentInput, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, type TicketAuthorType, TicketAuthorTypeSchema, TicketBodySchema, type TicketCategory, TicketCategorySchema, type TicketDetail, TicketDetailSchema, type TicketMessage, TicketMessageSchema, type TicketStatus, TicketStatusSchema, type TicketSummary, TicketSummarySchema, type TokenPrice, TokenPriceSchema, type TradeLimits, TradeLimitsSchema, type TradeResult, TradeResultSchema, type Transaction, TransactionSchema, type TransactionStatus, TransactionStatusSchema, type TransactionType, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, type UserProfile, UserProfileSchema, type UserRank, UserRankSchema, type UserSettings, UserSettingsSchema, type UserStatus, UserStatusSchema, UuidSchema, VerifyEmailCommand, type WalletOverview, WalletOverviewSchema, type Withdrawal, WithdrawalSchema, type WithdrawalStatus, WithdrawalStatusSchema, assetDecimals, endpoint };
|
package/dist/index.d.ts
CHANGED
|
@@ -19,6 +19,9 @@ declare const ERROR_CODE: {
|
|
|
19
19
|
readonly EMAIL_NOT_VERIFIED: "EMAIL_NOT_VERIFIED";
|
|
20
20
|
readonly EMAIL_ALREADY_VERIFIED: "EMAIL_ALREADY_VERIFIED";
|
|
21
21
|
readonly TOKEN_INVALID: "TOKEN_INVALID";
|
|
22
|
+
readonly TOTP_INVALID: "TOTP_INVALID";
|
|
23
|
+
readonly CAPTCHA_REQUIRED: "CAPTCHA_REQUIRED";
|
|
24
|
+
readonly CAPTCHA_INVALID: "CAPTCHA_INVALID";
|
|
22
25
|
readonly INSUFFICIENT_BALANCE: "INSUFFICIENT_BALANCE";
|
|
23
26
|
readonly PURCHASE_LIMIT_EXCEEDED: "PURCHASE_LIMIT_EXCEEDED";
|
|
24
27
|
readonly PURCHASE_CAP_EXCEEDED: "PURCHASE_CAP_EXCEEDED";
|
|
@@ -1312,14 +1315,17 @@ declare namespace RegisterCommand {
|
|
|
1312
1315
|
email: z.ZodString;
|
|
1313
1316
|
password: z.ZodString;
|
|
1314
1317
|
referralCode: z.ZodOptional<z.ZodString>;
|
|
1318
|
+
captchaToken: z.ZodOptional<z.ZodString>;
|
|
1315
1319
|
}, "strip", z.ZodTypeAny, {
|
|
1316
1320
|
email: string;
|
|
1317
1321
|
password: string;
|
|
1318
1322
|
referralCode?: string | undefined;
|
|
1323
|
+
captchaToken?: string | undefined;
|
|
1319
1324
|
}, {
|
|
1320
1325
|
email: string;
|
|
1321
1326
|
password: string;
|
|
1322
1327
|
referralCode?: string | undefined;
|
|
1328
|
+
captchaToken?: string | undefined;
|
|
1323
1329
|
}>;
|
|
1324
1330
|
type Request = z.infer<typeof RequestSchema>;
|
|
1325
1331
|
const ResponseSchema: z.ZodObject<{
|
|
@@ -1338,13 +1344,16 @@ declare namespace LoginCommand {
|
|
|
1338
1344
|
email: z.ZodString;
|
|
1339
1345
|
password: z.ZodString;
|
|
1340
1346
|
totp: z.ZodOptional<z.ZodString>;
|
|
1347
|
+
captchaToken: z.ZodOptional<z.ZodString>;
|
|
1341
1348
|
}, "strip", z.ZodTypeAny, {
|
|
1342
1349
|
email: string;
|
|
1343
1350
|
password: string;
|
|
1351
|
+
captchaToken?: string | undefined;
|
|
1344
1352
|
totp?: string | undefined;
|
|
1345
1353
|
}, {
|
|
1346
1354
|
email: string;
|
|
1347
1355
|
password: string;
|
|
1356
|
+
captchaToken?: string | undefined;
|
|
1348
1357
|
totp?: string | undefined;
|
|
1349
1358
|
}>;
|
|
1350
1359
|
type Request = z.infer<typeof RequestSchema>;
|
|
@@ -1596,6 +1605,32 @@ declare namespace ResetPasswordCommand {
|
|
|
1596
1605
|
type Response = z.infer<typeof ResponseSchema>;
|
|
1597
1606
|
}
|
|
1598
1607
|
|
|
1608
|
+
declare const ThreatLevelSchema: z.ZodEnum<["calm", "elevated", "high", "attack"]>;
|
|
1609
|
+
type ThreatLevel = z.infer<typeof ThreatLevelSchema>;
|
|
1610
|
+
declare namespace CaptchaPolicyCommand {
|
|
1611
|
+
const endpointDetails: EndpointDetails;
|
|
1612
|
+
const ResponseSchema: z.ZodObject<{
|
|
1613
|
+
provider: z.ZodEnum<["turnstile", "none"]>;
|
|
1614
|
+
siteKey: z.ZodNullable<z.ZodString>;
|
|
1615
|
+
register: z.ZodBoolean;
|
|
1616
|
+
login: z.ZodBoolean;
|
|
1617
|
+
level: z.ZodEnum<["calm", "elevated", "high", "attack"]>;
|
|
1618
|
+
}, "strip", z.ZodTypeAny, {
|
|
1619
|
+
level: "calm" | "elevated" | "high" | "attack";
|
|
1620
|
+
provider: "turnstile" | "none";
|
|
1621
|
+
siteKey: string | null;
|
|
1622
|
+
register: boolean;
|
|
1623
|
+
login: boolean;
|
|
1624
|
+
}, {
|
|
1625
|
+
level: "calm" | "elevated" | "high" | "attack";
|
|
1626
|
+
provider: "turnstile" | "none";
|
|
1627
|
+
siteKey: string | null;
|
|
1628
|
+
register: boolean;
|
|
1629
|
+
login: boolean;
|
|
1630
|
+
}>;
|
|
1631
|
+
type Response = z.infer<typeof ResponseSchema>;
|
|
1632
|
+
}
|
|
1633
|
+
|
|
1599
1634
|
declare namespace GetWalletCommand {
|
|
1600
1635
|
const endpointDetails: EndpointDetails;
|
|
1601
1636
|
const ResponseSchema: zod.ZodObject<{
|
|
@@ -4293,6 +4328,7 @@ declare const REST_API: {
|
|
|
4293
4328
|
readonly RESEND_VERIFICATION: "/auth/verify-email/resend";
|
|
4294
4329
|
readonly FORGOT_PASSWORD: "/auth/password/forgot";
|
|
4295
4330
|
readonly RESET_PASSWORD: "/auth/password/reset";
|
|
4331
|
+
readonly CAPTCHA_POLICY: "/auth/captcha-policy";
|
|
4296
4332
|
};
|
|
4297
4333
|
readonly WALLET: {
|
|
4298
4334
|
readonly OVERVIEW: "/wallet";
|
|
@@ -4373,4 +4409,4 @@ declare const REST_API: {
|
|
|
4373
4409
|
declare const API_PREFIX = "/api";
|
|
4374
4410
|
declare const API_VERSION = "v1";
|
|
4375
4411
|
|
|
4376
|
-
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, type AssetBalance, AssetBalanceSchema, type AssetSymbol, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, type ChartPeriod, ChartPeriodSchema, type ChartPoint, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, type DailyBonusClaimResult, DailyBonusClaimResultSchema, type DailyBonusDay, DailyBonusDaySchema, type DailyBonusStatus, DailyBonusStatusSchema, type DepositAddress, DepositAddressCommand, DepositAddressSchema, type DepositEntry, DepositEntrySchema, type DepositStatus, DepositStatusSchema, type DepositableAsset, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, type EarningsOverview, EarningsOverviewSchema, type EndpointDetails, type ErrorCode, type ErrorResponse, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, type HttpMethod, type IncomeOverview, IncomeOverviewSchema, type IncomePeriod, IncomePeriodSchema, type Leaderboard, type LeaderboardEntry, LeaderboardEntrySchema, type LeaderboardPeriod, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, type LinkProvider, LinkProviderSchema, LinkTelegramCommand, type LinkedAccount, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, type MonthlyPricePoint, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, type Notification, NotificationSchema, type NotificationType, NotificationTypeSchema, type Order, type OrderBook, type OrderBookLevel, OrderBookLevelSchema, OrderBookSchema, OrderSchema, type OrderSide, OrderSideSchema, type OrderStatus, OrderStatusSchema, type OrderType, OrderTypeSchema, type Package, PackageSchema, type PackageStatus, PackageStatusSchema, type PackagesOverview, PackagesOverviewSchema, PaginatedSchema, type PaginationQuery, PaginationQuerySchema, type PartnerAccrual, PartnerAccrualSchema, type PartnerLevel, PartnerLevelSchema, type PartnersOverview, PartnersOverviewSchema, type Period, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, type PublicTrade, PublicTradeSchema, REST_API, type RankDef, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, type SessionInfo, SessionInfoSchema, SetupTotpCommand, type Slide, type SlideButtonStyle, SlideButtonStyleSchema, type SlideKind, SlideKindSchema, type SlideLinkTarget, SlideLinkTargetSchema, SlideSchema, type SlidesResponse, SlidesResponseSchema, SwapCommand, type SwapSide, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, type TicketAttachment, type TicketAttachmentInput, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, type TicketAuthorType, TicketAuthorTypeSchema, TicketBodySchema, type TicketCategory, TicketCategorySchema, type TicketDetail, TicketDetailSchema, type TicketMessage, TicketMessageSchema, type TicketStatus, TicketStatusSchema, type TicketSummary, TicketSummarySchema, type TokenPrice, TokenPriceSchema, type TradeLimits, TradeLimitsSchema, type TradeResult, TradeResultSchema, type Transaction, TransactionSchema, type TransactionStatus, TransactionStatusSchema, type TransactionType, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, type UserProfile, UserProfileSchema, type UserRank, UserRankSchema, type UserSettings, UserSettingsSchema, type UserStatus, UserStatusSchema, UuidSchema, VerifyEmailCommand, type WalletOverview, WalletOverviewSchema, type Withdrawal, WithdrawalSchema, type WithdrawalStatus, WithdrawalStatusSchema, assetDecimals, endpoint };
|
|
4412
|
+
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, type AssetBalance, AssetBalanceSchema, type AssetSymbol, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, CaptchaPolicyCommand, type ChartPeriod, ChartPeriodSchema, type ChartPoint, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, type DailyBonusClaimResult, DailyBonusClaimResultSchema, type DailyBonusDay, DailyBonusDaySchema, type DailyBonusStatus, DailyBonusStatusSchema, type DepositAddress, DepositAddressCommand, DepositAddressSchema, type DepositEntry, DepositEntrySchema, type DepositStatus, DepositStatusSchema, type DepositableAsset, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, type EarningsOverview, EarningsOverviewSchema, type EndpointDetails, type ErrorCode, type ErrorResponse, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, type HttpMethod, type IncomeOverview, IncomeOverviewSchema, type IncomePeriod, IncomePeriodSchema, type Leaderboard, type LeaderboardEntry, LeaderboardEntrySchema, type LeaderboardPeriod, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, type LinkProvider, LinkProviderSchema, LinkTelegramCommand, type LinkedAccount, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, type MonthlyPricePoint, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, type Notification, NotificationSchema, type NotificationType, NotificationTypeSchema, type Order, type OrderBook, type OrderBookLevel, OrderBookLevelSchema, OrderBookSchema, OrderSchema, type OrderSide, OrderSideSchema, type OrderStatus, OrderStatusSchema, type OrderType, OrderTypeSchema, type Package, PackageSchema, type PackageStatus, PackageStatusSchema, type PackagesOverview, PackagesOverviewSchema, PaginatedSchema, type PaginationQuery, PaginationQuerySchema, type PartnerAccrual, PartnerAccrualSchema, type PartnerLevel, PartnerLevelSchema, type PartnersOverview, PartnersOverviewSchema, type Period, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, type PublicTrade, PublicTradeSchema, REST_API, type RankDef, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, type SessionInfo, SessionInfoSchema, SetupTotpCommand, type Slide, type SlideButtonStyle, SlideButtonStyleSchema, type SlideKind, SlideKindSchema, type SlideLinkTarget, SlideLinkTargetSchema, SlideSchema, type SlidesResponse, SlidesResponseSchema, SwapCommand, type SwapSide, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, type ThreatLevel, ThreatLevelSchema, type TicketAttachment, type TicketAttachmentInput, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, type TicketAuthorType, TicketAuthorTypeSchema, TicketBodySchema, type TicketCategory, TicketCategorySchema, type TicketDetail, TicketDetailSchema, type TicketMessage, TicketMessageSchema, type TicketStatus, TicketStatusSchema, type TicketSummary, TicketSummarySchema, type TokenPrice, TokenPriceSchema, type TradeLimits, TradeLimitsSchema, type TradeResult, TradeResultSchema, type Transaction, TransactionSchema, type TransactionStatus, TransactionStatusSchema, type TransactionType, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, type UserProfile, UserProfileSchema, type UserRank, UserRankSchema, type UserSettings, UserSettingsSchema, type UserStatus, UserStatusSchema, UuidSchema, VerifyEmailCommand, type WalletOverview, WalletOverviewSchema, type Withdrawal, WithdrawalSchema, type WithdrawalStatus, WithdrawalStatusSchema, assetDecimals, endpoint };
|
package/dist/index.js
CHANGED
|
@@ -19,6 +19,9 @@ var ERROR_CODE = {
|
|
|
19
19
|
EMAIL_NOT_VERIFIED: "EMAIL_NOT_VERIFIED",
|
|
20
20
|
EMAIL_ALREADY_VERIFIED: "EMAIL_ALREADY_VERIFIED",
|
|
21
21
|
TOKEN_INVALID: "TOKEN_INVALID",
|
|
22
|
+
TOTP_INVALID: "TOTP_INVALID",
|
|
23
|
+
CAPTCHA_REQUIRED: "CAPTCHA_REQUIRED",
|
|
24
|
+
CAPTCHA_INVALID: "CAPTCHA_INVALID",
|
|
22
25
|
INSUFFICIENT_BALANCE: "INSUFFICIENT_BALANCE",
|
|
23
26
|
PURCHASE_LIMIT_EXCEEDED: "PURCHASE_LIMIT_EXCEEDED",
|
|
24
27
|
PURCHASE_CAP_EXCEEDED: "PURCHASE_CAP_EXCEEDED",
|
|
@@ -379,7 +382,8 @@ var RegisterCommand;
|
|
|
379
382
|
RegisterCommand2.RequestSchema = z.object({
|
|
380
383
|
email: z.string().email().max(254),
|
|
381
384
|
password: z.string().min(8).max(128),
|
|
382
|
-
referralCode: z.string().min(4).max(64).optional()
|
|
385
|
+
referralCode: z.string().min(4).max(64).optional(),
|
|
386
|
+
captchaToken: z.string().max(4096).optional()
|
|
383
387
|
});
|
|
384
388
|
RegisterCommand2.ResponseSchema = z.object({
|
|
385
389
|
userId: z.string().uuid()
|
|
@@ -391,7 +395,8 @@ var LoginCommand;
|
|
|
391
395
|
LoginCommand2.RequestSchema = z.object({
|
|
392
396
|
email: z.string().email().max(254),
|
|
393
397
|
password: z.string().min(1).max(128),
|
|
394
|
-
totp: z.string().regex(/^\d{6}$/).optional()
|
|
398
|
+
totp: z.string().regex(/^\d{6}$/).optional(),
|
|
399
|
+
captchaToken: z.string().max(4096).optional()
|
|
395
400
|
});
|
|
396
401
|
LoginCommand2.ResponseSchema = z.object({
|
|
397
402
|
user: UserProfileSchema
|
|
@@ -466,6 +471,18 @@ var ResetPasswordCommand;
|
|
|
466
471
|
});
|
|
467
472
|
ResetPasswordCommand2.ResponseSchema = z.object({ reset: z.boolean() });
|
|
468
473
|
})(ResetPasswordCommand || (ResetPasswordCommand = {}));
|
|
474
|
+
var ThreatLevelSchema = z.enum(["calm", "elevated", "high", "attack"]);
|
|
475
|
+
var CaptchaPolicyCommand;
|
|
476
|
+
((CaptchaPolicyCommand2) => {
|
|
477
|
+
CaptchaPolicyCommand2.endpointDetails = endpoint("GET", "/auth/captcha-policy", "Whether the auth forms must show a captcha");
|
|
478
|
+
CaptchaPolicyCommand2.ResponseSchema = z.object({
|
|
479
|
+
provider: z.enum(["turnstile", "none"]),
|
|
480
|
+
siteKey: z.string().nullable(),
|
|
481
|
+
register: z.boolean(),
|
|
482
|
+
login: z.boolean(),
|
|
483
|
+
level: ThreatLevelSchema
|
|
484
|
+
});
|
|
485
|
+
})(CaptchaPolicyCommand || (CaptchaPolicyCommand = {}));
|
|
469
486
|
|
|
470
487
|
// src/commands/wallet/get-wallet.command.ts
|
|
471
488
|
var GetWalletCommand;
|
|
@@ -977,7 +994,8 @@ var REST_API = {
|
|
|
977
994
|
VERIFY_EMAIL: "/auth/verify-email",
|
|
978
995
|
RESEND_VERIFICATION: "/auth/verify-email/resend",
|
|
979
996
|
FORGOT_PASSWORD: "/auth/password/forgot",
|
|
980
|
-
RESET_PASSWORD: "/auth/password/reset"
|
|
997
|
+
RESET_PASSWORD: "/auth/password/reset",
|
|
998
|
+
CAPTCHA_POLICY: "/auth/captcha-policy"
|
|
981
999
|
},
|
|
982
1000
|
WALLET: {
|
|
983
1001
|
OVERVIEW: "/wallet",
|
|
@@ -1058,6 +1076,6 @@ var REST_API = {
|
|
|
1058
1076
|
var API_PREFIX = "/api";
|
|
1059
1077
|
var API_VERSION = "v1";
|
|
1060
1078
|
|
|
1061
|
-
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, AssetBalanceSchema, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, ChartPeriodSchema, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, DailyBonusClaimResultSchema, DailyBonusDaySchema, DailyBonusStatusSchema, DepositAddressCommand, DepositAddressSchema, DepositEntrySchema, DepositStatusSchema, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, EarningsOverviewSchema, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, IncomeOverviewSchema, IncomePeriodSchema, LeaderboardEntrySchema, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, LinkProviderSchema, LinkTelegramCommand, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, NotificationSchema, NotificationTypeSchema, OrderBookLevelSchema, OrderBookSchema, OrderSchema, OrderSideSchema, OrderStatusSchema, OrderTypeSchema, PackageSchema, PackageStatusSchema, PackagesOverviewSchema, PaginatedSchema, PaginationQuerySchema, PartnerAccrualSchema, PartnerLevelSchema, PartnersOverviewSchema, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, PublicTradeSchema, REST_API, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, SessionInfoSchema, SetupTotpCommand, SlideButtonStyleSchema, SlideKindSchema, SlideLinkTargetSchema, SlideSchema, SlidesResponseSchema, SwapCommand, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, TicketAuthorTypeSchema, TicketBodySchema, TicketCategorySchema, TicketDetailSchema, TicketMessageSchema, TicketStatusSchema, TicketSummarySchema, TokenPriceSchema, TradeLimitsSchema, TradeResultSchema, TransactionSchema, TransactionStatusSchema, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, UserProfileSchema, UserRankSchema, UserSettingsSchema, UserStatusSchema, UuidSchema, VerifyEmailCommand, WalletOverviewSchema, WithdrawalSchema, WithdrawalStatusSchema, assetDecimals, endpoint };
|
|
1079
|
+
export { API_PREFIX, API_VERSION, ASSET_DECIMALS, ASSET_SYMBOLS, AVATAR_CONTENT_TYPES, AssetBalanceSchema, AssetSymbolSchema, AvatarContentTypeSchema, AvatarUploadUrlCommand, BuyPackageCommand, CancelOrderCommand, CancelWithdrawalCommand, CaptchaPolicyCommand, ChartPeriodSchema, ChartPointSchema, ClaimDailyBonusCommand, ConfirmEmailChangeCommand, ConfirmTotpCommand, ConfirmWithdrawalCommand, CreateTicketCommand, DEPOSITABLE_ASSETS, DailyBonusClaimResultSchema, DailyBonusDaySchema, DailyBonusStatusSchema, DepositAddressCommand, DepositAddressSchema, DepositEntrySchema, DepositStatusSchema, DepositableAssetSchema, DisableTotpCommand, ERROR_CODE, EarningsOverviewSchema, ErrorResponseSchema, FUNDING_ASSET, ForgotPasswordCommand, GetDailyBonusCommand, GetEarningsCommand, GetIncomeCommand, GetLeaderboardCommand, GetOrderBookCommand, GetPackagesCommand, GetPartnersCommand, GetRanksCommand, GetSettingsCommand, GetSlidesCommand, GetTicketCommand, GetTokenChartCommand, GetTokenPriceCommand, GetTransactionsCommand, GetWalletCommand, IncomeOverviewSchema, IncomePeriodSchema, LeaderboardEntrySchema, LeaderboardPeriodSchema, LeaderboardSchema, LinkGoogleCommand, LinkProviderSchema, LinkTelegramCommand, LinkedAccountSchema, ListDepositsCommand, ListLinkedAccountsCommand, ListMyOrdersCommand, ListNotificationsCommand, ListTicketsCommand, ListTradesCommand, ListWithdrawalsCommand, LoginCommand, LogoutCommand, MONEY_REGEX, MarkNotificationsReadCommand, MeCommand, MoneyStringSchema, MonthlyPricePointSchema, NMN_PRICE_DECIMALS, NotificationSchema, NotificationTypeSchema, OrderBookLevelSchema, OrderBookSchema, OrderSchema, OrderSideSchema, OrderStatusSchema, OrderTypeSchema, PackageSchema, PackageStatusSchema, PackagesOverviewSchema, PaginatedSchema, PaginationQuerySchema, PartnerAccrualSchema, PartnerLevelSchema, PartnersOverviewSchema, PeriodSchema, PlaceOrderCommand, PositiveMoneyStringSchema, PublicTradeSchema, REST_API, RankDefSchema, RegisterCommand, ReplyTicketCommand, RequestEmailChangeCommand, RequestWithdrawalCommand, ResendVerificationCommand, ResetPasswordCommand, SessionInfoSchema, SetupTotpCommand, SlideButtonStyleSchema, SlideKindSchema, SlideLinkTargetSchema, SlideSchema, SlidesResponseSchema, SwapCommand, SwapSideSchema, TICKET_CATEGORIES, TOKEN_ASSET, ThreatLevelSchema, TicketAttachmentInputSchema, TicketAttachmentSchema, TicketAttachmentUploadCommand, TicketAuthorTypeSchema, TicketBodySchema, TicketCategorySchema, TicketDetailSchema, TicketMessageSchema, TicketStatusSchema, TicketSummarySchema, TokenPriceSchema, TradeLimitsSchema, TradeResultSchema, TransactionSchema, TransactionStatusSchema, TransactionTypeSchema, UnlinkAccountCommand, UpdateProfileCommand, UpdateSettingsCommand, UpgradePackageCommand, UserProfileSchema, UserRankSchema, UserSettingsSchema, UserStatusSchema, UuidSchema, VerifyEmailCommand, WalletOverviewSchema, WithdrawalSchema, WithdrawalStatusSchema, assetDecimals, endpoint };
|
|
1062
1080
|
//# sourceMappingURL=index.js.map
|
|
1063
1081
|
//# sourceMappingURL=index.js.map
|