@orbit-software/sdk 1.75.0 → 1.80.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/esm/assets/icons/IconBalanceCoins.d.ts +3 -0
- package/dist/esm/{app/ui/components/IconBalanceCoin.d.ts → assets/icons/IconBalanceGems.d.ts} +1 -1
- package/dist/esm/assets/icons/IconUsdt.d.ts +3 -0
- package/dist/esm/components/BuyAdsFreeButton.d.ts +1 -0
- package/dist/esm/{features/profile/components → components}/OverlayProfile.d.ts +2 -2
- package/dist/esm/components/layout/BottomSentinel.d.ts +2 -0
- package/dist/esm/components/modals/BoxOpeningModal/AnimatedFullscreen.d.ts +14 -0
- package/dist/esm/components/modals/BoxOpeningModal/BoxOpeningModal.d.ts +2 -0
- package/dist/esm/{launcherSrc/features/profile/components → components/modals/BoxOpeningModal}/PrizeCarousel.d.ts +4 -3
- package/dist/esm/components/modals/BoxOpeningModal/RewardBoxRareBadge.d.ts +5 -0
- package/dist/esm/{launcherSrc/features/profile/components → components/modals/BoxOpeningModal}/RewardTypeBadge.d.ts +2 -2
- package/dist/esm/{launcherSrc/features/profile/components → components/modals/BoxOpeningModal}/RewardTypeImage.d.ts +3 -3
- package/dist/esm/{launcherSrc/features/profile → components/modals/BoxOpeningModal}/utils/findPrizeIndex.d.ts +1 -1
- package/dist/esm/components/modals/BoxOpeningModal/utils/generateExcitingPrizes.d.ts +9 -0
- package/dist/esm/components/modals/BoxOpeningModal/utils/sortPrizesDistributed.d.ts +2 -0
- package/dist/esm/components/modals/LevelInfoModal.d.ts +2 -0
- package/dist/esm/components/modals/ProfileInventoryModal.d.ts +2 -0
- package/dist/esm/components/modals/PurchaseAdsFreeModal.d.ts +2 -0
- package/dist/esm/components/modals/TopUpModal/TopUpModal.d.ts +2 -0
- package/dist/esm/components/{AnimatedBalance.d.ts → ui/AnimatedBalance.d.ts} +2 -1
- package/dist/esm/components/ui/BalanceHeader.d.ts +4 -0
- package/dist/esm/components/ui/Drawer.d.ts +9 -0
- package/dist/esm/components/ui/EventsStack.d.ts +6 -0
- package/dist/esm/components/ui/FormattedXP.d.ts +4 -0
- package/dist/esm/components/ui/Icon.d.ts +27 -0
- package/dist/esm/{launcherSrc/app/ui/components → components/ui}/XpProgress.d.ts +2 -4
- package/dist/esm/{launcherSrc/app/contexts → components/ui/snackbar}/SnackbarContext.d.ts +4 -2
- package/dist/esm/confirm/confirm.d.ts +2 -0
- package/dist/esm/constants/animations.d.ts +2 -0
- package/dist/esm/hooks/useAnimateNumber.d.ts +1 -0
- package/dist/esm/hooks/useLottie.d.ts +12 -0
- package/dist/esm/hooks/useThrottle.d.ts +1 -0
- package/dist/esm/i18n/generate-types.d.ts +1 -0
- package/dist/esm/i18n/generated-translation-type.d.ts +112 -0
- package/dist/esm/i18n/languages.d.ts +7 -0
- package/dist/esm/i18n/locales/en.json.d.ts +137 -0
- package/dist/esm/i18n/locales/es.json.d.ts +136 -0
- package/dist/esm/i18n/locales/hi.json.d.ts +137 -0
- package/dist/esm/i18n/locales/pt.json.d.ts +136 -0
- package/dist/esm/i18n/locales/ru.json.d.ts +137 -0
- package/dist/esm/i18n/types.d.ts +9 -0
- package/dist/esm/i18n/useTranslation.d.ts +6 -0
- package/dist/esm/lib/BannerManager.d.ts +36 -0
- package/dist/esm/lib/WebSocketManager.d.ts +3 -3
- package/dist/esm/lib/activity-detector.d.ts +1 -1
- package/dist/esm/lib/tma-network.d.ts +1 -1
- package/dist/esm/providers/BoxOpeningProvider.d.ts +21 -0
- package/dist/esm/providers/ConfettiProvider.d.ts +3 -0
- package/dist/esm/providers/I18nBackendLanguageProvider.d.ts +3 -0
- package/dist/esm/queries/box/useBoxRewards.d.ts +13 -0
- package/dist/esm/queries/box/useRevealReward.d.ts +10 -0
- package/dist/esm/queries/user/useCancelNoAds.d.ts +2 -0
- package/dist/esm/queries/user/useCreateInvoiceBuyNoAds.d.ts +3 -0
- package/dist/esm/queries/user/usePrices.d.ts +3 -0
- package/dist/esm/queries/user/useProfile.d.ts +4 -0
- package/dist/esm/queryClient.d.ts +2 -0
- package/dist/esm/sdk.d.ts +56 -31
- package/dist/esm/sdk.mjs +44640 -43919
- package/dist/esm/sdk.umd.js +134 -198
- package/dist/esm/stores/confettiStore.d.ts +8 -0
- package/dist/esm/stores/inventroryModalStore.d.ts +6 -0
- package/dist/esm/stores/topUpModalStore.d.ts +6 -0
- package/dist/esm/types/api.d.ts +39 -0
- package/dist/esm/utils/cn.d.ts +2 -0
- package/dist/esm/utils/formatter.d.ts +5 -0
- package/dist/esm/utils/price.d.ts +2 -0
- package/dist/esm/utils/shuffleArray.d.ts +1 -0
- package/dist/esm/utils/telegramLanguageCodeToFlagEmoji.d.ts +11 -0
- package/dist/stats-confirm.html +1 -1
- package/dist/stats-esm.html +1 -1
- package/dist/stats-umd-react.html +1 -1
- package/dist/stats-umd.html +1 -1
- package/dist/umd/sdk.umd.js +134 -198
- package/dist/umd_react/sdk_react.umd.js +191 -255
- package/package.json +28 -30
- package/dist/confirm/index.html +0 -24
- package/dist/esm/app/helpers.d.ts +0 -2
- package/dist/esm/app/ui/assets/IconBack.d.ts +0 -1
- package/dist/esm/app/ui/components/AvatarProgress.d.ts +0 -13
- package/dist/esm/app/ui/components/ClosableModal.d.ts +0 -12
- package/dist/esm/app/ui/components/IconBalanceDiamond.d.ts +0 -3
- package/dist/esm/app/ui/components/InputSwitch.d.ts +0 -9
- package/dist/esm/app/ui/components/Inventory/Inventory.d.ts +0 -2
- package/dist/esm/app/ui/components/Inventory/context.d.ts +0 -10
- package/dist/esm/app/ui/components/XsButton.d.ts +0 -6
- package/dist/esm/app/ui/hooks/useAnimateNumber.d.ts +0 -1
- package/dist/esm/app/utils.d.ts +0 -2
- package/dist/esm/components/AppContent/AppContent.d.ts +0 -10
- package/dist/esm/components/AppContent/BottomSentinel.d.ts +0 -2
- package/dist/esm/components/BuyShopItem.d.ts +0 -1
- package/dist/esm/components/ModalCardContent.d.ts +0 -5
- package/dist/esm/features/profile/assets/IconAd.d.ts +0 -1
- package/dist/esm/features/profile/assets/IconAddCircle.d.ts +0 -1
- package/dist/esm/features/profile/assets/IconChevronRight.d.ts +0 -2
- package/dist/esm/features/profile/assets/IconDrag.d.ts +0 -2
- package/dist/esm/features/profile/assets/IconEdit.d.ts +0 -2
- package/dist/esm/features/profile/assets/IconGame.d.ts +0 -2
- package/dist/esm/features/profile/assets/IconNoSign.d.ts +0 -1
- package/dist/esm/features/profile/assets/IconProfile.d.ts +0 -1
- package/dist/esm/features/profile/assets/profileBgGradients.d.ts +0 -6
- package/dist/esm/features/profile/components/BalanceConfetti.d.ts +0 -6
- package/dist/esm/features/profile/components/BuyMenu.d.ts +0 -8
- package/dist/esm/features/profile/components/CircleParticles.d.ts +0 -10
- package/dist/esm/features/profile/components/FormattedXP.d.ts +0 -8
- package/dist/esm/features/profile/components/LevelInfoModal.d.ts +0 -9
- package/dist/esm/features/profile/components/ModalContainer.d.ts +0 -6
- package/dist/esm/features/profile/components/PurchaseConfirm.d.ts +0 -9
- package/dist/esm/features/profile/components/TaskCard.d.ts +0 -21
- package/dist/esm/features/profile/components/XpProgress.d.ts +0 -14
- package/dist/esm/features/profile/components/adsFree/BuyAdsFreeButton.d.ts +0 -3
- package/dist/esm/features/profile/components/adsFree/PurchaseAdsFree.d.ts +0 -11
- package/dist/esm/features/profile/hooks/useAnimatedProfile.d.ts +0 -5
- package/dist/esm/features/profile/utils/getFormattedDate.d.ts +0 -1
- package/dist/esm/features/wages/components/ModalContainer.d.ts +0 -6
- package/dist/esm/features/wages/components/WageCollapsedOverlay.d.ts +0 -6
- package/dist/esm/features/wages/components/WageExpandedOverlay.d.ts +0 -7
- package/dist/esm/features/wages/components/WageMenu.d.ts +0 -4
- package/dist/esm/features/wages/index.d.ts +0 -3
- package/dist/esm/features/wages/utils/formatTime.d.ts +0 -1
- package/dist/esm/features/wages/utils/formatTimeWageItem.d.ts +0 -1
- package/dist/esm/features/wages/utils/getSecondsPassed.d.ts +0 -1
- package/dist/esm/i18n/locales/translations/en.json.d.ts +0 -300
- package/dist/esm/i18n/locales/translations/hi.json.d.ts +0 -300
- package/dist/esm/i18n/locales/translations/ru.json.d.ts +0 -300
- package/dist/esm/launcherSrc/App.d.ts +0 -2
- package/dist/esm/launcherSrc/api/types.d.ts +0 -211
- package/dist/esm/launcherSrc/api/userApi.d.ts +0 -24
- package/dist/esm/launcherSrc/app/components/DebugConsole.d.ts +0 -2
- package/dist/esm/launcherSrc/app/helpers.d.ts +0 -3
- package/dist/esm/launcherSrc/app/hooks/forceRerender.d.ts +0 -1
- package/dist/esm/launcherSrc/app/hooks/useMainButtonControl.d.ts +0 -7
- package/dist/esm/launcherSrc/app/hooks/useMiniApp.d.ts +0 -3
- package/dist/esm/launcherSrc/app/hooks.d.ts +0 -10
- package/dist/esm/launcherSrc/app/store.d.ts +0 -17
- package/dist/esm/launcherSrc/app/ui/assets/IconBack.d.ts +0 -1
- package/dist/esm/launcherSrc/app/ui/assets/IconCheck.d.ts +0 -2
- package/dist/esm/launcherSrc/app/ui/assets/IconCheckThin.d.ts +0 -2
- package/dist/esm/launcherSrc/app/ui/assets/IconCross.d.ts +0 -2
- package/dist/esm/launcherSrc/app/ui/assets/IconSearch.d.ts +0 -2
- package/dist/esm/launcherSrc/app/ui/components/AvatarProgress.d.ts +0 -13
- package/dist/esm/launcherSrc/app/ui/components/ClosableModal.d.ts +0 -10
- package/dist/esm/launcherSrc/app/ui/components/FormattedXP.d.ts +0 -8
- package/dist/esm/launcherSrc/app/ui/components/IconBalance.d.ts +0 -3
- package/dist/esm/launcherSrc/app/ui/components/InputSwitch.d.ts +0 -9
- package/dist/esm/launcherSrc/app/ui/components/Twemoji.d.ts +0 -8
- package/dist/esm/launcherSrc/app/ui/components/UICell.d.ts +0 -16
- package/dist/esm/launcherSrc/app/ui/components/UIDateInput.d.ts +0 -21
- package/dist/esm/launcherSrc/app/ui/components/UIDivider.d.ts +0 -4
- package/dist/esm/launcherSrc/app/ui/components/UIEmoji.d.ts +0 -8
- package/dist/esm/launcherSrc/app/ui/components/UIHero.d.ts +0 -10
- package/dist/esm/launcherSrc/app/ui/components/UISection.d.ts +0 -9
- package/dist/esm/launcherSrc/app/ui/components/UITextarea.d.ts +0 -7
- package/dist/esm/launcherSrc/app/ui/hooks/useAnimateNumber.d.ts +0 -1
- package/dist/esm/launcherSrc/app/utils.d.ts +0 -13
- package/dist/esm/launcherSrc/assets/Icon28Edit.d.ts +0 -2
- package/dist/esm/launcherSrc/assets/Icon28Game.d.ts +0 -1
- package/dist/esm/launcherSrc/assets/Icon28Link.d.ts +0 -1
- package/dist/esm/launcherSrc/features/games/assets/IconFilter.d.ts +0 -1
- package/dist/esm/launcherSrc/features/games/assets/IconPlayers.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconQuestion.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconQuestionCircle.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconStar.d.ts +0 -4
- package/dist/esm/launcherSrc/features/games/assets/IconThumbsDownFilled.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconThumbsDownOutlined.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconThumbsUpFilled.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/assets/IconThumbsUpOutlined.d.ts +0 -2
- package/dist/esm/launcherSrc/features/games/components/GameItem.d.ts +0 -10
- package/dist/esm/launcherSrc/features/games/components/ResetStorageButton.d.ts +0 -3
- package/dist/esm/launcherSrc/features/games/components/ReviewModal.d.ts +0 -10
- package/dist/esm/launcherSrc/features/games/hooks/useGamesData.d.ts +0 -13
- package/dist/esm/launcherSrc/features/games/redux/gamesSlice.d.ts +0 -34
- package/dist/esm/launcherSrc/features/games/service/gamesService.d.ts +0 -3
- package/dist/esm/launcherSrc/features/leaderboard/components/Rating.d.ts +0 -1
- package/dist/esm/launcherSrc/features/leaderboard/components/RatingCard/RatingCard.d.ts +0 -10
- package/dist/esm/launcherSrc/features/leaderboard/components/RatingInfo/RatingInfo.d.ts +0 -1
- package/dist/esm/launcherSrc/features/leaderboard/components/RatingLevel/IconWreaths.d.ts +0 -3
- package/dist/esm/launcherSrc/features/leaderboard/components/RatingLevel/RatingLevel.d.ts +0 -6
- package/dist/esm/launcherSrc/features/leaderboard/components/RatingLevel/lock.d.ts +0 -3
- package/dist/esm/launcherSrc/features/leaderboard/hooks/useLeaderboardData.d.ts +0 -10
- package/dist/esm/launcherSrc/features/leaderboard/index.d.ts +0 -1
- package/dist/esm/launcherSrc/features/leaderboard/redux/leaderboardSlice.d.ts +0 -18
- package/dist/esm/launcherSrc/features/leaderboard/services/leaderboardService.d.ts +0 -2
- package/dist/esm/launcherSrc/features/navigation/assets/IconGame.d.ts +0 -1
- package/dist/esm/launcherSrc/features/navigation/assets/IconProfile.d.ts +0 -1
- package/dist/esm/launcherSrc/features/navigation/assets/IconSmile.d.ts +0 -2
- package/dist/esm/launcherSrc/features/navigation/components/FloatingProfile.d.ts +0 -2
- package/dist/esm/launcherSrc/features/navigation/components/IconWithCounter.d.ts +0 -7
- package/dist/esm/launcherSrc/features/navigation/redux/navigationSlice.d.ts +0 -15
- package/dist/esm/launcherSrc/features/navigation/redux/tabsSlice.d.ts +0 -12
- package/dist/esm/launcherSrc/features/profile/assets/IconAd.d.ts +0 -1
- package/dist/esm/launcherSrc/features/profile/assets/IconAddCircle.d.ts +0 -1
- package/dist/esm/launcherSrc/features/profile/assets/IconChevronRight.d.ts +0 -2
- package/dist/esm/launcherSrc/features/profile/assets/IconColorPicker.d.ts +0 -1
- package/dist/esm/launcherSrc/features/profile/assets/IconCurrencyStar.d.ts +0 -3
- package/dist/esm/launcherSrc/features/profile/assets/IconGlobe.d.ts +0 -2
- package/dist/esm/launcherSrc/features/profile/assets/IconLock.d.ts +0 -2
- package/dist/esm/launcherSrc/features/profile/assets/IconNoSign.d.ts +0 -1
- package/dist/esm/launcherSrc/features/profile/assets/IconSignature.d.ts +0 -5
- package/dist/esm/launcherSrc/features/profile/assets/profileBgGradients.d.ts +0 -50
- package/dist/esm/launcherSrc/features/profile/components/AdsFree/BuyAdsFreeButton.d.ts +0 -0
- package/dist/esm/launcherSrc/features/profile/components/AdsFree/PurchaseAdsFree.d.ts +0 -9
- package/dist/esm/launcherSrc/features/profile/components/Balance/ProfileBalance.d.ts +0 -6
- package/dist/esm/launcherSrc/features/profile/components/Balance/TopUpModal/BuyMenu.d.ts +0 -8
- package/dist/esm/launcherSrc/features/profile/components/Balance/TopUpModal/Ribbon.d.ts +0 -6
- package/dist/esm/launcherSrc/features/profile/components/BoxOpeningModal.d.ts +0 -3
- package/dist/esm/launcherSrc/features/profile/components/LevelInfoModal.d.ts +0 -9
- package/dist/esm/launcherSrc/features/profile/components/ProfileInventory.d.ts +0 -1
- package/dist/esm/launcherSrc/features/profile/components/ProfileLeaderboard.d.ts +0 -6
- package/dist/esm/launcherSrc/features/profile/components/ProfileReviews.d.ts +0 -6
- package/dist/esm/launcherSrc/features/profile/components/RewardBoxRareBadge.d.ts +0 -4
- package/dist/esm/launcherSrc/features/profile/components/particles/BalanceConfetti.d.ts +0 -6
- package/dist/esm/launcherSrc/features/profile/components/particles/CircleParticles.d.ts +0 -10
- package/dist/esm/launcherSrc/features/profile/components/particles/StarParticles.d.ts +0 -10
- package/dist/esm/launcherSrc/features/profile/contexts/BoxOpeningContext.d.ts +0 -12
- package/dist/esm/launcherSrc/features/profile/data/countries.d.ts +0 -10
- package/dist/esm/launcherSrc/features/profile/hooks/useProfileData.d.ts +0 -24
- package/dist/esm/launcherSrc/features/profile/redux/profileSlice.d.ts +0 -130
- package/dist/esm/launcherSrc/features/profile/services/buyMenuService.d.ts +0 -3
- package/dist/esm/launcherSrc/features/profile/services/profileService.d.ts +0 -12
- package/dist/esm/launcherSrc/i18n/index.d.ts +0 -2
- package/dist/esm/launcherSrc/index.d.ts +0 -0
- package/dist/esm/launcherSrc/setupTests.d.ts +0 -0
- package/dist/esm/launcherSrc/utils/openTelegramLinkFixed.d.ts +0 -1
- package/dist/esm/lib/init-sentry.d.ts +0 -5
- package/dist/esm/stores/buyShopModalStore.d.ts +0 -8
- package/dist/esm/stores/profileStore.d.ts +0 -17
- package/dist/esm/stores/wageStore.d.ts +0 -12
- package/dist/esm/{app/ui/assets → assets/icons}/IconClosePlain.d.ts +0 -0
- package/dist/esm/{features/profile/assets → assets/icons}/IconCurrencyStar.d.ts +0 -0
- package/dist/esm/{features/profile/assets → assets/icons}/IconTelegramStar.d.ts +0 -0
- package/dist/esm/{features/profile/assets → assets/lottie}/moneyTongue.json.d.ts +0 -0
- package/dist/esm/{features/profile/assets → assets/lottie}/newspaper.json.d.ts +0 -0
- package/dist/esm/{launcherSrc/features/profile/components/Balance → components/modals}/TopUpModal/BuyOption.d.ts +0 -0
- package/dist/esm/{features/profile/components → components/modals/TopUpModal}/Ribbon.d.ts +0 -0
- package/dist/esm/{launcherSrc/app/ui/components → components/ui/XsButton}/XsButton.d.ts +1 -1
- /package/dist/esm/{launcherSrc/features/profile/components → components/ui}/particles/ConfettiParticles.d.ts +0 -0
- /package/dist/esm/{features/profile/components → components/ui/particles}/StarParticles.d.ts +0 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import { ServiceBoxContentResponse } from '../../types/api';
|
|
2
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare function useBoxRewards(props?: Omit<UseMutationOptions<ServiceBoxContentResponse, Error, {
|
|
4
|
+
boxId: number;
|
|
5
|
+
}>, 'mutationFn'>): import('@tanstack/react-query').UseMutationResult<{
|
|
6
|
+
rewards: {
|
|
7
|
+
reward_value: number;
|
|
8
|
+
reward_type: string;
|
|
9
|
+
}[];
|
|
10
|
+
recent_rewards: import('../../types/api').ServiceRecentReward[];
|
|
11
|
+
}, Error, {
|
|
12
|
+
boxId: number;
|
|
13
|
+
}, unknown>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { ServiceBoxOpenResponse } from '../../types/api';
|
|
2
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare function useRevealReward(props?: Omit<UseMutationOptions<ServiceBoxOpenResponse, Error, {
|
|
4
|
+
boxId: number;
|
|
5
|
+
}>, 'mutationFn'>): import('@tanstack/react-query').UseMutationResult<{
|
|
6
|
+
reward_value: number;
|
|
7
|
+
reward_type: string;
|
|
8
|
+
}, Error, {
|
|
9
|
+
boxId: number;
|
|
10
|
+
}, unknown>;
|
|
@@ -0,0 +1,3 @@
|
|
|
1
|
+
import { ServiceInvoiceCreatedResponse } from '../../types/api';
|
|
2
|
+
import { UseMutationOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare function useCreateInvoiceBuyNoAds(props?: Omit<UseMutationOptions<ServiceInvoiceCreatedResponse, Error>, 'mutationFn'>): import('@tanstack/react-query').UseMutationResult<ServiceInvoiceCreatedResponse, Error, void, unknown>;
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import { CryptoSteamSDKProfile } from '../../sdk';
|
|
2
|
+
import { UseQueryOptions } from '@tanstack/react-query';
|
|
3
|
+
export declare const PROFILE_TAG = "profile";
|
|
4
|
+
export declare function useProfile(props?: Omit<UseQueryOptions<CryptoSteamSDKProfile>, 'queryKey' | 'queryFn'>): import('@tanstack/react-query').UseSuspenseQueryResult<CryptoSteamSDKProfile, Error>;
|
package/dist/esm/sdk.d.ts
CHANGED
|
@@ -1,8 +1,9 @@
|
|
|
1
|
+
import { InventoryItem, ServiceInvoiceCreatedResponse } from './types/api';
|
|
1
2
|
export declare const BASE_URL = "https://app.portalapp.games/sdk";
|
|
2
3
|
interface LaunchResponse {
|
|
3
4
|
tma_ads_key: string;
|
|
4
5
|
ads?: {
|
|
5
|
-
type:
|
|
6
|
+
type: 'tma' | 'monetag' | 'adsgram';
|
|
6
7
|
tmaAdsKey?: string;
|
|
7
8
|
monetag?: string;
|
|
8
9
|
adsgram?: string;
|
|
@@ -20,37 +21,55 @@ export declare class APIRequestError extends Error {
|
|
|
20
21
|
responseText: string | undefined;
|
|
21
22
|
});
|
|
22
23
|
}
|
|
23
|
-
export declare function makeRequest<T>(path: string, method:
|
|
24
|
+
export declare function makeRequest<T>(path: string, method: 'POST' | 'GET' | 'PUT' | 'DELETE', body?: any): Promise<T>;
|
|
24
25
|
export interface CryptoSteamSDKConfig {
|
|
25
|
-
supported_screen_formats: (
|
|
26
|
+
supported_screen_formats: ('landscape' | 'portrait' | 'fullscreen')[];
|
|
26
27
|
supported_devices: string[];
|
|
27
28
|
title: string;
|
|
28
29
|
app_url: string;
|
|
29
30
|
}
|
|
30
|
-
export type Audience =
|
|
31
|
+
export type Audience = 'start_page_default' | 'start_page_few_ads' | 'start_page_no_ads' | 'start_page_games' | 'banner_test';
|
|
31
32
|
export interface CryptoSteamSDKProfile {
|
|
32
33
|
id: number;
|
|
33
|
-
|
|
34
|
-
experience: number;
|
|
35
|
-
level_up_exp: number;
|
|
36
|
-
level: number;
|
|
34
|
+
avatar_ug: string;
|
|
37
35
|
user_name: string;
|
|
38
36
|
first_name: string;
|
|
39
37
|
last_name: string;
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
language: string;
|
|
39
|
+
email: string;
|
|
40
|
+
email_confirmed: boolean;
|
|
41
|
+
phone_number: string;
|
|
42
|
+
location: string;
|
|
43
|
+
background_color: string;
|
|
44
|
+
override_ads: boolean;
|
|
45
|
+
ton_address: string;
|
|
42
46
|
audiences: Audience[];
|
|
47
|
+
is_premium: boolean;
|
|
48
|
+
allows_write_to_pm: boolean;
|
|
49
|
+
ads_disabled_until?: string;
|
|
50
|
+
created: string;
|
|
51
|
+
updated: string;
|
|
52
|
+
avatar: string;
|
|
53
|
+
birth_date: string;
|
|
43
54
|
balance_gems: number;
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
55
|
+
balance_coins: number;
|
|
56
|
+
experience: number;
|
|
57
|
+
balance_usdt: number;
|
|
58
|
+
minimum_usdt_withdraw: number;
|
|
59
|
+
level: number;
|
|
60
|
+
level_up_exp: number;
|
|
47
61
|
invited: number;
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
62
|
+
invited_full: number;
|
|
63
|
+
games_count: number;
|
|
64
|
+
ads_free: boolean;
|
|
65
|
+
is_admin: boolean;
|
|
66
|
+
inventory: InventoryItem[];
|
|
67
|
+
game_id?: number | string;
|
|
68
|
+
onboarding: boolean;
|
|
69
|
+
review_stats: {
|
|
70
|
+
total: number;
|
|
71
|
+
with_comments: number;
|
|
72
|
+
};
|
|
54
73
|
}
|
|
55
74
|
export interface CryptoSteamSDKShopItem {
|
|
56
75
|
id: number;
|
|
@@ -106,13 +125,10 @@ export interface CryptoSteamSDKWage {
|
|
|
106
125
|
export interface OverlayConfig {
|
|
107
126
|
onOverlayOpen?: () => void;
|
|
108
127
|
onOverlayClose?: () => void;
|
|
109
|
-
variant?:
|
|
110
|
-
initialPosition?:
|
|
128
|
+
variant?: 'light' | 'dark' | 'translucent';
|
|
129
|
+
initialPosition?: 'topLeft' | 'topRight' | 'bottomLeft' | 'bottomRight';
|
|
111
130
|
botId?: string;
|
|
112
131
|
}
|
|
113
|
-
interface InvoiceResponse {
|
|
114
|
-
invoice_link: string;
|
|
115
|
-
}
|
|
116
132
|
export interface CryptoSteamSDKTask {
|
|
117
133
|
id: number;
|
|
118
134
|
title: string;
|
|
@@ -125,7 +141,7 @@ export interface CryptoSteamSDKTask {
|
|
|
125
141
|
is_done: boolean;
|
|
126
142
|
}
|
|
127
143
|
interface PurchaseConfirmResponse {
|
|
128
|
-
status:
|
|
144
|
+
status: 'success' | 'error';
|
|
129
145
|
}
|
|
130
146
|
interface TelegramCloudStorage {
|
|
131
147
|
getValue: (key: string) => Promise<string>;
|
|
@@ -139,7 +155,7 @@ interface TMANetworkInterstitialResponse {
|
|
|
139
155
|
interface ShowPromiseResult {
|
|
140
156
|
done: boolean;
|
|
141
157
|
description: string;
|
|
142
|
-
state:
|
|
158
|
+
state: 'load' | 'render' | 'playing' | 'destroy';
|
|
143
159
|
error: boolean;
|
|
144
160
|
}
|
|
145
161
|
interface AdsgramController {
|
|
@@ -153,7 +169,7 @@ interface BalanceResponse {
|
|
|
153
169
|
balance_gems: number;
|
|
154
170
|
balance_coins: number;
|
|
155
171
|
}
|
|
156
|
-
export type AdType =
|
|
172
|
+
export type AdType = 'REWARD' | 'INTERSTITIAL';
|
|
157
173
|
export interface RequestAdOptions {
|
|
158
174
|
onStart?: () => void;
|
|
159
175
|
}
|
|
@@ -163,7 +179,7 @@ interface RequestWageValueParams {
|
|
|
163
179
|
}
|
|
164
180
|
export interface StartupConfig {
|
|
165
181
|
isFullscreen: boolean;
|
|
166
|
-
overlayPosition:
|
|
182
|
+
overlayPosition: 'topLeft' | 'topRight' | 'bottomLeft' | 'bottomRight';
|
|
167
183
|
}
|
|
168
184
|
export declare function startGameTimeTrack(): void;
|
|
169
185
|
export interface CryptoSteamSDK {
|
|
@@ -192,8 +208,7 @@ export interface CryptoSteamSDK {
|
|
|
192
208
|
width: number;
|
|
193
209
|
height: number;
|
|
194
210
|
}) => Promise<PurchaseConfirmResponse>;
|
|
195
|
-
createInvoice: (title: string, description: string, to_user_id: number, amount: number) => Promise<
|
|
196
|
-
getTasks: () => Promise<CryptoSteamSDKTask[]>;
|
|
211
|
+
createInvoice: (title: string, description: string, to_user_id: number, amount: number) => Promise<ServiceInvoiceCreatedResponse>;
|
|
197
212
|
claimTask: (taskId: number) => Promise<void>;
|
|
198
213
|
getValue: (key: string) => Promise<string>;
|
|
199
214
|
setValue: (key: string, value: string) => Promise<void>;
|
|
@@ -216,6 +231,7 @@ export interface CryptoSteamSDK {
|
|
|
216
231
|
gameReady: () => void;
|
|
217
232
|
getAdsgramController: () => AdsgramController | null;
|
|
218
233
|
getLaunchResponse: () => LaunchResponse | null;
|
|
234
|
+
isLaunchedFromPortal: () => boolean;
|
|
219
235
|
setBottomBanner: () => void;
|
|
220
236
|
clearBottomBanner: () => void;
|
|
221
237
|
}
|
|
@@ -237,7 +253,7 @@ declare global {
|
|
|
237
253
|
declare global {
|
|
238
254
|
namespace NodeJS {
|
|
239
255
|
interface ProcessEnv {
|
|
240
|
-
NODE_ENV:
|
|
256
|
+
NODE_ENV: 'development' | 'production';
|
|
241
257
|
version: string;
|
|
242
258
|
}
|
|
243
259
|
}
|
|
@@ -247,3 +263,12 @@ export default CryptoSteamSDK;
|
|
|
247
263
|
export { CryptoSteamSDK as PortalSDK };
|
|
248
264
|
export declare const TelegramWebApp: import('@twa-dev/types').WebApp;
|
|
249
265
|
export type { ShowPromiseResult };
|
|
266
|
+
export interface PortalEmuSDK {
|
|
267
|
+
isAdRunning: () => boolean;
|
|
268
|
+
getValueSync: (key: string) => string;
|
|
269
|
+
setValueSync: (key: string, value: string) => void;
|
|
270
|
+
removeValueSync: (key: string) => Promise<void>;
|
|
271
|
+
reloadAd: () => void;
|
|
272
|
+
getStartParam: () => string;
|
|
273
|
+
requestAd: () => Promise<void>;
|
|
274
|
+
}
|