@invonetwork/web-sdk 3.27.0 → 3.28.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/server.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { I as InvoError, H as Http, a2 as AuthHeader, g as CallOptions, a3 as PlatformPurchaseInput, a4 as PlatformPurchaseResult, a5 as PlatformOrderStatusResult, a6 as PlatformPurchaseHistoryQuery, a7 as PlatformPurchaseHistoryResult, a8 as PlatformRefundInput, a9 as PlatformRefundResult, aa as CreateSubscriptionInput, ab as SubscriptionResult, ac as GetSubscriptionOptions, ad as GetSubscriptionResult, ae as ListSubscriptionsOptions, af as SubscriptionListResult, ag as CancelSubscriptionOptions, ah as CancelResult, ai as ChangeAmountResult, aj as SetPaymentMethodInput, ak as SetPaymentMethodResult, al as RefundSubscriptionInput, am as RefundResult, an as SteamSubscriptionInitInput, ao as SteamInitResult, ap as SteamFinalizeSubscriptionResult, aq as CardSetupSessionInput, ar as CardSetupSessionResult, as as CardSetupInput, at as CardSetupResult, au as CardSetupConfirmInput, av as CardSetupConfirmResult, aw as PlayerCardsResult, ax as SandboxClockResult, ay as SandboxFailureOutcome, az as SandboxForceFailureOptions, aA as SandboxForceAuthChallengeOptions, aB as ServerConfig, aC as MintPlayerTokenInput, aD as PlayerToken, aE as RegisterPlayerInput, aF as RegisterPlayerResult, aG as UpdatePlayerPhoneInput, aH as UpdatePlayerPhoneResult, aI as RequestPhoneChangeInput, aJ as RequestPhoneChangeResult, aK as PhoneChangeRequest, aL as InitiateSendInput, aM as InitiateResult, aN as InitiateTransferInput, aO as CreateCheckoutInput, aP as CreateCheckoutResult, aQ as PurchaseInput, aR as PurchaseResult, aS as CurrencyPurchaseQuoteInput, aT as CurrencyPurchaseQuote, aU as ConfirmPaymentResult, aV as OrderDetailsResult, aW as SteamPacksQuery, aX as SteamPacksResult, aY as SteamInitPurchaseInput, aZ as SteamInitPurchaseResult, a_ as SteamFinalizeInput, a$ as SteamFinalizeResult, b0 as PurchaseItemInput, b1 as PurchaseItemResult, b2 as ItemHistoryQuery, b3 as ItemHistoryResult, b4 as ItemOrderQuery, b5 as PlayerActivityQuery, b6 as PlayerActivityResult, b7 as PlayerActivityEntry, b8 as PlayerBalanceQuery, b9 as PlayerBalanceResult, o as LoyaltyCardsResult, ba as ReportServerGameEventInput, s as ReportGameEventResult, bb as InboundPendingQuery, bc as InboundPendingResult, bd as LinkedIdentitiesQuery, be as LinkedIdentitiesResult, bf as SmsVerifyResult, bg as ClaimTransferInput, bh as ClaimResult, bi as ClaimCurrencyInput, bj as TransactionStatusResult, bk as GuardianApprovalStatusResult, bl as ServerDestinationsQuery, n as DestinationsResult, bm as PhoneShareContact, bn as PhoneShareInitiateResult, bo as PhoneShareApproveInput, bp as PhoneShareApproveResult, bq as PhoneShareStatusResult, br as BeginDeviceApprovalInput, bs as DeviceApprovalGrant, bt as PollDeviceApprovalInput, bu as DeviceApprovalPollResult, bv as ConfirmDeviceEnrollmentInput, bw as ConfirmDeviceEnrollmentResult, bx as ApproveWithDeviceCodeInput, by as DeviceApprovalSettleResult, bz as CompleteDeviceApprovalInput, bA as CompleteDeviceApprovalResult } from './types-_lIm74kd.cjs';
2
2
  export { bB as CardSetupStatus, bC as CheckoutWarning, y as ClaimDelivery, bD as CurrencyBalance, bE as CurrencyPurchaseQuoteBreakdown, z as DestinationGame, bF as DeviceApprovalChannel, bG as DeviceApprovalEnrollment, bH as DeviceApprovalFlow, bI as DeviceApprovalPollStatus, bJ as DeviceEnrollmentDecision, bK as DeviceEnrollmentRespond, bL as ExpiryReason, bM as FeeTakenFrom, bN as FirstCharge, bO as FirstChargeStatus, bP as FundingSource, G as GameEventType, bQ as InboundPendingItem, F as InvoErrorInfo, J as InvoHooks, K as InvoRequestInfo, N as InvoResponseInfo, bR as LinkedIdentityEmail, O as LoyaltyCard, Q as LoyaltyCardReward, S as LoyaltyCardStep, T as LoyaltyRewardState, U as LoyaltyStepProgress, V as LoyaltyStepState, bS as MinPurchaseWarning, bT as PhoneChangeConfirmation, bU as PhoneChangeRequestStatus, bV as PlatformPurchaseStatus, bW as PlayerActivityType, a0 as Rail, bX as RefundInitiation, bY as RefundPendingApproval, bZ as RefundProcessingFeeBasis, b_ as RefundReceipt, b$ as RefundRevenueShareAttribution, c0 as RefundWarning, r as ReportGameEventInput, c1 as SandboxClockState, c2 as SavedCard, c3 as SteamPack, c4 as SteamUserSession, c5 as Subscription, c6 as SubscriptionBaseInput, c7 as SubscriptionConsent, c8 as SubscriptionConsentInput, c9 as SubscriptionFundingRail, ca as SubscriptionInterval, cb as SubscriptionRevenueShare, cc as SubscriptionRevenueShareInput, cd as SubscriptionStatus, ce as UnacknowledgedPurchaseOutcome, a1 as VerificationMethod, cf as isRefundPendingApproval } from './types-_lIm74kd.cjs';
3
- export { S as SDK_VERSION } from './version-BXFwI0-s.cjs';
3
+ export { S as SDK_VERSION } from './version-iWmcxjYu.cjs';
4
4
 
5
5
  interface VerifyWebhookOptions {
6
6
  /** Max age of the signed timestamp, in seconds. Default 300 (5 min). */
@@ -1109,6 +1109,38 @@ declare class PayoutsServer {
1109
1109
  cancelPayout(payoutIdValue: number, opts?: CallOptions): Promise<Payout>;
1110
1110
  }
1111
1111
 
1112
+ /**
1113
+ * Pick the INVO environment from the game secret alone (3.28.0).
1114
+ *
1115
+ * Going live is swapping the key: a sandbox key (including the public demo key baked into
1116
+ * INVO's game templates) talks to the sandbox, a live key to production, and nothing else in
1117
+ * your code changes.
1118
+ *
1119
+ * - The public demo key starts with `ivsdk_demo_`: always the sandbox, no network call.
1120
+ * - Any other key: INVO is asked once (`GET /api/sdk/key-environment`), production first,
1121
+ * then the sandbox. The answer is cached per key for the life of the process.
1122
+ */
1123
+ declare const PRODUCTION_BASE_URL = "https://invo.network";
1124
+ declare const SANDBOX_BASE_URL = "https://sandbox.invo.network/sandbox";
1125
+ declare const DEMO_KEY_PREFIX = "ivsdk_demo_";
1126
+ type InvoEnvironment = "production" | "sandbox";
1127
+ /** Neither environment recognised the key, or INVO could not be reached. */
1128
+ declare class EnvironmentUnknownError extends Error {
1129
+ constructor(message: string);
1130
+ }
1131
+ declare function isDemoKey(gameSecret: string | undefined | null): boolean;
1132
+ /**
1133
+ * `"production"` or `"sandbox"` for this key. Rejects with {@link EnvironmentUnknownError}
1134
+ * when neither environment knows the key (a failed lookup is not cached, so it is retried).
1135
+ */
1136
+ declare function resolveEnvironment(gameSecret: string, opts?: {
1137
+ fetch?: typeof fetch;
1138
+ }): Promise<InvoEnvironment>;
1139
+ /** The API base URL for this key (see {@link resolveEnvironment}). */
1140
+ declare function baseUrlForKey(gameSecret: string, opts?: {
1141
+ fetch?: typeof fetch;
1142
+ }): Promise<string>;
1143
+
1112
1144
  /**
1113
1145
  * @invonetwork/web-sdk/server — NODE entry.
1114
1146
  *
@@ -2124,4 +2156,4 @@ declare class InvoServer {
2124
2156
  private toInitiateResult;
2125
2157
  }
2126
2158
 
2127
- export { ApproveWithDeviceCodeInput, BeginDeviceApprovalInput, CallOptions, CancelResult, CancelSubscriptionOptions, CardSetupConfirmInput, CardSetupConfirmResult, CardSetupInput, CardSetupResult, CardSetupSessionInput, CardSetupSessionResult, CardsServer, ChangeAmountResult, ClaimCurrencyInput, ClaimResult, ClaimTransferInput, CompleteDeviceApprovalInput, CompleteDeviceApprovalResult, ConfirmDeviceEnrollmentInput, ConfirmDeviceEnrollmentResult, ConfirmPaymentResult, CreateCheckoutInput, CreateCheckoutResult, CreateSubscriptionInput, CurrencyPurchaseQuote, CurrencyPurchaseQuoteInput, DestinationsResult, DeviceApprovalGrant, DeviceApprovalPollResult, DeviceApprovalSettleResult, GetSubscriptionOptions, GetSubscriptionResult, GuardianApprovalStatusResult, type IdentityPasskeyResetData, InboundPendingQuery, InboundPendingResult, InitiateResult, InitiateSendInput, InitiateTransferInput, InvoError, InvoServer, type InvoWebhookEvent, ItemHistoryQuery, ItemHistoryResult, ItemOrderQuery, type ItemPurchasedData, LinkedIdentitiesQuery, LinkedIdentitiesResult, type ListPayeesQuery, type ListPayeesResult, type ListPayoutsQuery, type ListPayoutsResult, ListSubscriptionsOptions, LoyaltyCardsResult, MintPlayerTokenInput, OrderDetailsResult, type PayableBlocker, type Payee, type PayeeInvite, type PayeeStatus, type PayeeStatusChangedData, type Payout, type PayoutStatus, type PayoutStatusChangedData, PayoutsServer, PhoneChangeRequest, PhoneShareApproveInput, PhoneShareApproveResult, PhoneShareContact, PhoneShareInitiateResult, PhoneShareStatusResult, type PlatformCommercePurchasedData, type PlatformCommerceRefundedData, PlatformCommerceServer, PlatformOrderStatusResult, PlatformPurchaseHistoryQuery, PlatformPurchaseHistoryResult, PlatformPurchaseInput, PlatformPurchaseResult, PlatformRefundInput, PlatformRefundResult, PlayerActivityEntry, PlayerActivityQuery, PlayerActivityResult, PlayerBalanceQuery, PlayerBalanceResult, PlayerCardsResult, type PlayerPhoneChangedData, PlayerToken, PollDeviceApprovalInput, type PurchaseCompletedData, type PurchaseEventData, PurchaseInput, PurchaseItemInput, PurchaseItemResult, PurchaseResult, RefundResult, RefundSubscriptionInput, type RegisterPayeeInput, type RegisterPayeeResult, RegisterPlayerInput, RegisterPlayerResult, ReportGameEventResult, ReportServerGameEventInput, type RequestPayoutInput, type RequestPayoutResult, RequestPhoneChangeInput, RequestPhoneChangeResult, type ReturnReasonCode, SandboxClockResult, SandboxFailureOutcome, SandboxForceAuthChallengeOptions, SandboxForceFailureOptions, SandboxServer, SandboxSubscriptionsServer, ServerConfig, ServerDestinationsQuery, SetPaymentMethodInput, SetPaymentMethodResult, SmsVerifyResult, SteamFinalizeInput, SteamFinalizeResult, SteamFinalizeSubscriptionResult, SteamInitPurchaseInput, SteamInitPurchaseResult, SteamInitResult, SteamPacksQuery, SteamPacksResult, SteamSubscriptionInitInput, type SubscriptionAuthenticationRequiredData, type SubscriptionCanceledData, type SubscriptionEventCommon, type SubscriptionExpiredData, SubscriptionListResult, type SubscriptionPastDueData, type SubscriptionPaymentFailedData, type SubscriptionRefundApprovedData, type SubscriptionRefundDetail, type SubscriptionRefundRejectedData, type SubscriptionRefundRequestData, type SubscriptionRefundedData, type SubscriptionRenewalFunding, type SubscriptionRenewalSplit, type SubscriptionRenewedData, SubscriptionResult, type SubscriptionRevenueShareAttribution, type SubscriptionTrialEventFields, SubscriptionsServer, TransactionStatusResult, type TransferEventData, UpdatePlayerPhoneInput, UpdatePlayerPhoneResult, type VerifyWebhookOptions, type WebhookHandlerOptions, createWebhookHandler, verifyWebhook, verifyWebhookAsync };
2159
+ export { ApproveWithDeviceCodeInput, BeginDeviceApprovalInput, CallOptions, CancelResult, CancelSubscriptionOptions, CardSetupConfirmInput, CardSetupConfirmResult, CardSetupInput, CardSetupResult, CardSetupSessionInput, CardSetupSessionResult, CardsServer, ChangeAmountResult, ClaimCurrencyInput, ClaimResult, ClaimTransferInput, CompleteDeviceApprovalInput, CompleteDeviceApprovalResult, ConfirmDeviceEnrollmentInput, ConfirmDeviceEnrollmentResult, ConfirmPaymentResult, CreateCheckoutInput, CreateCheckoutResult, CreateSubscriptionInput, CurrencyPurchaseQuote, CurrencyPurchaseQuoteInput, DEMO_KEY_PREFIX, DestinationsResult, DeviceApprovalGrant, DeviceApprovalPollResult, DeviceApprovalSettleResult, EnvironmentUnknownError, GetSubscriptionOptions, GetSubscriptionResult, GuardianApprovalStatusResult, type IdentityPasskeyResetData, InboundPendingQuery, InboundPendingResult, InitiateResult, InitiateSendInput, InitiateTransferInput, type InvoEnvironment, InvoError, InvoServer, type InvoWebhookEvent, ItemHistoryQuery, ItemHistoryResult, ItemOrderQuery, type ItemPurchasedData, LinkedIdentitiesQuery, LinkedIdentitiesResult, type ListPayeesQuery, type ListPayeesResult, type ListPayoutsQuery, type ListPayoutsResult, ListSubscriptionsOptions, LoyaltyCardsResult, MintPlayerTokenInput, OrderDetailsResult, PRODUCTION_BASE_URL, type PayableBlocker, type Payee, type PayeeInvite, type PayeeStatus, type PayeeStatusChangedData, type Payout, type PayoutStatus, type PayoutStatusChangedData, PayoutsServer, PhoneChangeRequest, PhoneShareApproveInput, PhoneShareApproveResult, PhoneShareContact, PhoneShareInitiateResult, PhoneShareStatusResult, type PlatformCommercePurchasedData, type PlatformCommerceRefundedData, PlatformCommerceServer, PlatformOrderStatusResult, PlatformPurchaseHistoryQuery, PlatformPurchaseHistoryResult, PlatformPurchaseInput, PlatformPurchaseResult, PlatformRefundInput, PlatformRefundResult, PlayerActivityEntry, PlayerActivityQuery, PlayerActivityResult, PlayerBalanceQuery, PlayerBalanceResult, PlayerCardsResult, type PlayerPhoneChangedData, PlayerToken, PollDeviceApprovalInput, type PurchaseCompletedData, type PurchaseEventData, PurchaseInput, PurchaseItemInput, PurchaseItemResult, PurchaseResult, RefundResult, RefundSubscriptionInput, type RegisterPayeeInput, type RegisterPayeeResult, RegisterPlayerInput, RegisterPlayerResult, ReportGameEventResult, ReportServerGameEventInput, type RequestPayoutInput, type RequestPayoutResult, RequestPhoneChangeInput, RequestPhoneChangeResult, type ReturnReasonCode, SANDBOX_BASE_URL, SandboxClockResult, SandboxFailureOutcome, SandboxForceAuthChallengeOptions, SandboxForceFailureOptions, SandboxServer, SandboxSubscriptionsServer, ServerConfig, ServerDestinationsQuery, SetPaymentMethodInput, SetPaymentMethodResult, SmsVerifyResult, SteamFinalizeInput, SteamFinalizeResult, SteamFinalizeSubscriptionResult, SteamInitPurchaseInput, SteamInitPurchaseResult, SteamInitResult, SteamPacksQuery, SteamPacksResult, SteamSubscriptionInitInput, type SubscriptionAuthenticationRequiredData, type SubscriptionCanceledData, type SubscriptionEventCommon, type SubscriptionExpiredData, SubscriptionListResult, type SubscriptionPastDueData, type SubscriptionPaymentFailedData, type SubscriptionRefundApprovedData, type SubscriptionRefundDetail, type SubscriptionRefundRejectedData, type SubscriptionRefundRequestData, type SubscriptionRefundedData, type SubscriptionRenewalFunding, type SubscriptionRenewalSplit, type SubscriptionRenewedData, SubscriptionResult, type SubscriptionRevenueShareAttribution, type SubscriptionTrialEventFields, SubscriptionsServer, TransactionStatusResult, type TransferEventData, UpdatePlayerPhoneInput, UpdatePlayerPhoneResult, type VerifyWebhookOptions, type WebhookHandlerOptions, baseUrlForKey, createWebhookHandler, isDemoKey, resolveEnvironment, verifyWebhook, verifyWebhookAsync };
package/dist/server.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import { I as InvoError, H as Http, a2 as AuthHeader, g as CallOptions, a3 as PlatformPurchaseInput, a4 as PlatformPurchaseResult, a5 as PlatformOrderStatusResult, a6 as PlatformPurchaseHistoryQuery, a7 as PlatformPurchaseHistoryResult, a8 as PlatformRefundInput, a9 as PlatformRefundResult, aa as CreateSubscriptionInput, ab as SubscriptionResult, ac as GetSubscriptionOptions, ad as GetSubscriptionResult, ae as ListSubscriptionsOptions, af as SubscriptionListResult, ag as CancelSubscriptionOptions, ah as CancelResult, ai as ChangeAmountResult, aj as SetPaymentMethodInput, ak as SetPaymentMethodResult, al as RefundSubscriptionInput, am as RefundResult, an as SteamSubscriptionInitInput, ao as SteamInitResult, ap as SteamFinalizeSubscriptionResult, aq as CardSetupSessionInput, ar as CardSetupSessionResult, as as CardSetupInput, at as CardSetupResult, au as CardSetupConfirmInput, av as CardSetupConfirmResult, aw as PlayerCardsResult, ax as SandboxClockResult, ay as SandboxFailureOutcome, az as SandboxForceFailureOptions, aA as SandboxForceAuthChallengeOptions, aB as ServerConfig, aC as MintPlayerTokenInput, aD as PlayerToken, aE as RegisterPlayerInput, aF as RegisterPlayerResult, aG as UpdatePlayerPhoneInput, aH as UpdatePlayerPhoneResult, aI as RequestPhoneChangeInput, aJ as RequestPhoneChangeResult, aK as PhoneChangeRequest, aL as InitiateSendInput, aM as InitiateResult, aN as InitiateTransferInput, aO as CreateCheckoutInput, aP as CreateCheckoutResult, aQ as PurchaseInput, aR as PurchaseResult, aS as CurrencyPurchaseQuoteInput, aT as CurrencyPurchaseQuote, aU as ConfirmPaymentResult, aV as OrderDetailsResult, aW as SteamPacksQuery, aX as SteamPacksResult, aY as SteamInitPurchaseInput, aZ as SteamInitPurchaseResult, a_ as SteamFinalizeInput, a$ as SteamFinalizeResult, b0 as PurchaseItemInput, b1 as PurchaseItemResult, b2 as ItemHistoryQuery, b3 as ItemHistoryResult, b4 as ItemOrderQuery, b5 as PlayerActivityQuery, b6 as PlayerActivityResult, b7 as PlayerActivityEntry, b8 as PlayerBalanceQuery, b9 as PlayerBalanceResult, o as LoyaltyCardsResult, ba as ReportServerGameEventInput, s as ReportGameEventResult, bb as InboundPendingQuery, bc as InboundPendingResult, bd as LinkedIdentitiesQuery, be as LinkedIdentitiesResult, bf as SmsVerifyResult, bg as ClaimTransferInput, bh as ClaimResult, bi as ClaimCurrencyInput, bj as TransactionStatusResult, bk as GuardianApprovalStatusResult, bl as ServerDestinationsQuery, n as DestinationsResult, bm as PhoneShareContact, bn as PhoneShareInitiateResult, bo as PhoneShareApproveInput, bp as PhoneShareApproveResult, bq as PhoneShareStatusResult, br as BeginDeviceApprovalInput, bs as DeviceApprovalGrant, bt as PollDeviceApprovalInput, bu as DeviceApprovalPollResult, bv as ConfirmDeviceEnrollmentInput, bw as ConfirmDeviceEnrollmentResult, bx as ApproveWithDeviceCodeInput, by as DeviceApprovalSettleResult, bz as CompleteDeviceApprovalInput, bA as CompleteDeviceApprovalResult } from './types-_lIm74kd.js';
2
2
  export { bB as CardSetupStatus, bC as CheckoutWarning, y as ClaimDelivery, bD as CurrencyBalance, bE as CurrencyPurchaseQuoteBreakdown, z as DestinationGame, bF as DeviceApprovalChannel, bG as DeviceApprovalEnrollment, bH as DeviceApprovalFlow, bI as DeviceApprovalPollStatus, bJ as DeviceEnrollmentDecision, bK as DeviceEnrollmentRespond, bL as ExpiryReason, bM as FeeTakenFrom, bN as FirstCharge, bO as FirstChargeStatus, bP as FundingSource, G as GameEventType, bQ as InboundPendingItem, F as InvoErrorInfo, J as InvoHooks, K as InvoRequestInfo, N as InvoResponseInfo, bR as LinkedIdentityEmail, O as LoyaltyCard, Q as LoyaltyCardReward, S as LoyaltyCardStep, T as LoyaltyRewardState, U as LoyaltyStepProgress, V as LoyaltyStepState, bS as MinPurchaseWarning, bT as PhoneChangeConfirmation, bU as PhoneChangeRequestStatus, bV as PlatformPurchaseStatus, bW as PlayerActivityType, a0 as Rail, bX as RefundInitiation, bY as RefundPendingApproval, bZ as RefundProcessingFeeBasis, b_ as RefundReceipt, b$ as RefundRevenueShareAttribution, c0 as RefundWarning, r as ReportGameEventInput, c1 as SandboxClockState, c2 as SavedCard, c3 as SteamPack, c4 as SteamUserSession, c5 as Subscription, c6 as SubscriptionBaseInput, c7 as SubscriptionConsent, c8 as SubscriptionConsentInput, c9 as SubscriptionFundingRail, ca as SubscriptionInterval, cb as SubscriptionRevenueShare, cc as SubscriptionRevenueShareInput, cd as SubscriptionStatus, ce as UnacknowledgedPurchaseOutcome, a1 as VerificationMethod, cf as isRefundPendingApproval } from './types-_lIm74kd.js';
3
- export { S as SDK_VERSION } from './version-BXFwI0-s.js';
3
+ export { S as SDK_VERSION } from './version-iWmcxjYu.js';
4
4
 
5
5
  interface VerifyWebhookOptions {
6
6
  /** Max age of the signed timestamp, in seconds. Default 300 (5 min). */
@@ -1109,6 +1109,38 @@ declare class PayoutsServer {
1109
1109
  cancelPayout(payoutIdValue: number, opts?: CallOptions): Promise<Payout>;
1110
1110
  }
1111
1111
 
1112
+ /**
1113
+ * Pick the INVO environment from the game secret alone (3.28.0).
1114
+ *
1115
+ * Going live is swapping the key: a sandbox key (including the public demo key baked into
1116
+ * INVO's game templates) talks to the sandbox, a live key to production, and nothing else in
1117
+ * your code changes.
1118
+ *
1119
+ * - The public demo key starts with `ivsdk_demo_`: always the sandbox, no network call.
1120
+ * - Any other key: INVO is asked once (`GET /api/sdk/key-environment`), production first,
1121
+ * then the sandbox. The answer is cached per key for the life of the process.
1122
+ */
1123
+ declare const PRODUCTION_BASE_URL = "https://invo.network";
1124
+ declare const SANDBOX_BASE_URL = "https://sandbox.invo.network/sandbox";
1125
+ declare const DEMO_KEY_PREFIX = "ivsdk_demo_";
1126
+ type InvoEnvironment = "production" | "sandbox";
1127
+ /** Neither environment recognised the key, or INVO could not be reached. */
1128
+ declare class EnvironmentUnknownError extends Error {
1129
+ constructor(message: string);
1130
+ }
1131
+ declare function isDemoKey(gameSecret: string | undefined | null): boolean;
1132
+ /**
1133
+ * `"production"` or `"sandbox"` for this key. Rejects with {@link EnvironmentUnknownError}
1134
+ * when neither environment knows the key (a failed lookup is not cached, so it is retried).
1135
+ */
1136
+ declare function resolveEnvironment(gameSecret: string, opts?: {
1137
+ fetch?: typeof fetch;
1138
+ }): Promise<InvoEnvironment>;
1139
+ /** The API base URL for this key (see {@link resolveEnvironment}). */
1140
+ declare function baseUrlForKey(gameSecret: string, opts?: {
1141
+ fetch?: typeof fetch;
1142
+ }): Promise<string>;
1143
+
1112
1144
  /**
1113
1145
  * @invonetwork/web-sdk/server — NODE entry.
1114
1146
  *
@@ -2124,4 +2156,4 @@ declare class InvoServer {
2124
2156
  private toInitiateResult;
2125
2157
  }
2126
2158
 
2127
- export { ApproveWithDeviceCodeInput, BeginDeviceApprovalInput, CallOptions, CancelResult, CancelSubscriptionOptions, CardSetupConfirmInput, CardSetupConfirmResult, CardSetupInput, CardSetupResult, CardSetupSessionInput, CardSetupSessionResult, CardsServer, ChangeAmountResult, ClaimCurrencyInput, ClaimResult, ClaimTransferInput, CompleteDeviceApprovalInput, CompleteDeviceApprovalResult, ConfirmDeviceEnrollmentInput, ConfirmDeviceEnrollmentResult, ConfirmPaymentResult, CreateCheckoutInput, CreateCheckoutResult, CreateSubscriptionInput, CurrencyPurchaseQuote, CurrencyPurchaseQuoteInput, DestinationsResult, DeviceApprovalGrant, DeviceApprovalPollResult, DeviceApprovalSettleResult, GetSubscriptionOptions, GetSubscriptionResult, GuardianApprovalStatusResult, type IdentityPasskeyResetData, InboundPendingQuery, InboundPendingResult, InitiateResult, InitiateSendInput, InitiateTransferInput, InvoError, InvoServer, type InvoWebhookEvent, ItemHistoryQuery, ItemHistoryResult, ItemOrderQuery, type ItemPurchasedData, LinkedIdentitiesQuery, LinkedIdentitiesResult, type ListPayeesQuery, type ListPayeesResult, type ListPayoutsQuery, type ListPayoutsResult, ListSubscriptionsOptions, LoyaltyCardsResult, MintPlayerTokenInput, OrderDetailsResult, type PayableBlocker, type Payee, type PayeeInvite, type PayeeStatus, type PayeeStatusChangedData, type Payout, type PayoutStatus, type PayoutStatusChangedData, PayoutsServer, PhoneChangeRequest, PhoneShareApproveInput, PhoneShareApproveResult, PhoneShareContact, PhoneShareInitiateResult, PhoneShareStatusResult, type PlatformCommercePurchasedData, type PlatformCommerceRefundedData, PlatformCommerceServer, PlatformOrderStatusResult, PlatformPurchaseHistoryQuery, PlatformPurchaseHistoryResult, PlatformPurchaseInput, PlatformPurchaseResult, PlatformRefundInput, PlatformRefundResult, PlayerActivityEntry, PlayerActivityQuery, PlayerActivityResult, PlayerBalanceQuery, PlayerBalanceResult, PlayerCardsResult, type PlayerPhoneChangedData, PlayerToken, PollDeviceApprovalInput, type PurchaseCompletedData, type PurchaseEventData, PurchaseInput, PurchaseItemInput, PurchaseItemResult, PurchaseResult, RefundResult, RefundSubscriptionInput, type RegisterPayeeInput, type RegisterPayeeResult, RegisterPlayerInput, RegisterPlayerResult, ReportGameEventResult, ReportServerGameEventInput, type RequestPayoutInput, type RequestPayoutResult, RequestPhoneChangeInput, RequestPhoneChangeResult, type ReturnReasonCode, SandboxClockResult, SandboxFailureOutcome, SandboxForceAuthChallengeOptions, SandboxForceFailureOptions, SandboxServer, SandboxSubscriptionsServer, ServerConfig, ServerDestinationsQuery, SetPaymentMethodInput, SetPaymentMethodResult, SmsVerifyResult, SteamFinalizeInput, SteamFinalizeResult, SteamFinalizeSubscriptionResult, SteamInitPurchaseInput, SteamInitPurchaseResult, SteamInitResult, SteamPacksQuery, SteamPacksResult, SteamSubscriptionInitInput, type SubscriptionAuthenticationRequiredData, type SubscriptionCanceledData, type SubscriptionEventCommon, type SubscriptionExpiredData, SubscriptionListResult, type SubscriptionPastDueData, type SubscriptionPaymentFailedData, type SubscriptionRefundApprovedData, type SubscriptionRefundDetail, type SubscriptionRefundRejectedData, type SubscriptionRefundRequestData, type SubscriptionRefundedData, type SubscriptionRenewalFunding, type SubscriptionRenewalSplit, type SubscriptionRenewedData, SubscriptionResult, type SubscriptionRevenueShareAttribution, type SubscriptionTrialEventFields, SubscriptionsServer, TransactionStatusResult, type TransferEventData, UpdatePlayerPhoneInput, UpdatePlayerPhoneResult, type VerifyWebhookOptions, type WebhookHandlerOptions, createWebhookHandler, verifyWebhook, verifyWebhookAsync };
2159
+ export { ApproveWithDeviceCodeInput, BeginDeviceApprovalInput, CallOptions, CancelResult, CancelSubscriptionOptions, CardSetupConfirmInput, CardSetupConfirmResult, CardSetupInput, CardSetupResult, CardSetupSessionInput, CardSetupSessionResult, CardsServer, ChangeAmountResult, ClaimCurrencyInput, ClaimResult, ClaimTransferInput, CompleteDeviceApprovalInput, CompleteDeviceApprovalResult, ConfirmDeviceEnrollmentInput, ConfirmDeviceEnrollmentResult, ConfirmPaymentResult, CreateCheckoutInput, CreateCheckoutResult, CreateSubscriptionInput, CurrencyPurchaseQuote, CurrencyPurchaseQuoteInput, DEMO_KEY_PREFIX, DestinationsResult, DeviceApprovalGrant, DeviceApprovalPollResult, DeviceApprovalSettleResult, EnvironmentUnknownError, GetSubscriptionOptions, GetSubscriptionResult, GuardianApprovalStatusResult, type IdentityPasskeyResetData, InboundPendingQuery, InboundPendingResult, InitiateResult, InitiateSendInput, InitiateTransferInput, type InvoEnvironment, InvoError, InvoServer, type InvoWebhookEvent, ItemHistoryQuery, ItemHistoryResult, ItemOrderQuery, type ItemPurchasedData, LinkedIdentitiesQuery, LinkedIdentitiesResult, type ListPayeesQuery, type ListPayeesResult, type ListPayoutsQuery, type ListPayoutsResult, ListSubscriptionsOptions, LoyaltyCardsResult, MintPlayerTokenInput, OrderDetailsResult, PRODUCTION_BASE_URL, type PayableBlocker, type Payee, type PayeeInvite, type PayeeStatus, type PayeeStatusChangedData, type Payout, type PayoutStatus, type PayoutStatusChangedData, PayoutsServer, PhoneChangeRequest, PhoneShareApproveInput, PhoneShareApproveResult, PhoneShareContact, PhoneShareInitiateResult, PhoneShareStatusResult, type PlatformCommercePurchasedData, type PlatformCommerceRefundedData, PlatformCommerceServer, PlatformOrderStatusResult, PlatformPurchaseHistoryQuery, PlatformPurchaseHistoryResult, PlatformPurchaseInput, PlatformPurchaseResult, PlatformRefundInput, PlatformRefundResult, PlayerActivityEntry, PlayerActivityQuery, PlayerActivityResult, PlayerBalanceQuery, PlayerBalanceResult, PlayerCardsResult, type PlayerPhoneChangedData, PlayerToken, PollDeviceApprovalInput, type PurchaseCompletedData, type PurchaseEventData, PurchaseInput, PurchaseItemInput, PurchaseItemResult, PurchaseResult, RefundResult, RefundSubscriptionInput, type RegisterPayeeInput, type RegisterPayeeResult, RegisterPlayerInput, RegisterPlayerResult, ReportGameEventResult, ReportServerGameEventInput, type RequestPayoutInput, type RequestPayoutResult, RequestPhoneChangeInput, RequestPhoneChangeResult, type ReturnReasonCode, SANDBOX_BASE_URL, SandboxClockResult, SandboxFailureOutcome, SandboxForceAuthChallengeOptions, SandboxForceFailureOptions, SandboxServer, SandboxSubscriptionsServer, ServerConfig, ServerDestinationsQuery, SetPaymentMethodInput, SetPaymentMethodResult, SmsVerifyResult, SteamFinalizeInput, SteamFinalizeResult, SteamFinalizeSubscriptionResult, SteamInitPurchaseInput, SteamInitPurchaseResult, SteamInitResult, SteamPacksQuery, SteamPacksResult, SteamSubscriptionInitInput, type SubscriptionAuthenticationRequiredData, type SubscriptionCanceledData, type SubscriptionEventCommon, type SubscriptionExpiredData, SubscriptionListResult, type SubscriptionPastDueData, type SubscriptionPaymentFailedData, type SubscriptionRefundApprovedData, type SubscriptionRefundDetail, type SubscriptionRefundRejectedData, type SubscriptionRefundRequestData, type SubscriptionRefundedData, type SubscriptionRenewalFunding, type SubscriptionRenewalSplit, type SubscriptionRenewedData, SubscriptionResult, type SubscriptionRevenueShareAttribution, type SubscriptionTrialEventFields, SubscriptionsServer, TransactionStatusResult, type TransferEventData, UpdatePlayerPhoneInput, UpdatePlayerPhoneResult, type VerifyWebhookOptions, type WebhookHandlerOptions, baseUrlForKey, createWebhookHandler, isDemoKey, resolveEnvironment, verifyWebhook, verifyWebhookAsync };
package/dist/server.js CHANGED
@@ -1,6 +1,6 @@
1
- export { CardsServer, InvoServer, PayoutsServer, PlatformCommerceServer, SandboxServer, SandboxSubscriptionsServer, SubscriptionsServer, createWebhookHandler, isRefundPendingApproval, verifyWebhook, verifyWebhookAsync } from './chunk-2DYTV74W.js';
1
+ export { CardsServer, DEMO_KEY_PREFIX, EnvironmentUnknownError, InvoServer, PRODUCTION_BASE_URL, PayoutsServer, PlatformCommerceServer, SANDBOX_BASE_URL, SandboxServer, SandboxSubscriptionsServer, SubscriptionsServer, baseUrlForKey, createWebhookHandler, isDemoKey, isRefundPendingApproval, resolveEnvironment, verifyWebhook, verifyWebhookAsync } from './chunk-4YKTKXC5.js';
2
2
  import './chunk-6CN236QH.js';
3
- export { SDK_VERSION } from './chunk-3YDO7GSH.js';
3
+ export { SDK_VERSION } from './chunk-3DRWLDDF.js';
4
4
  export { InvoError } from './chunk-VP3OK4J4.js';
5
5
  //# sourceMappingURL=server.js.map
6
6
  //# sourceMappingURL=server.js.map
@@ -3,6 +3,6 @@
3
3
  * `package.json` so it cannot drift silently (it did: the UA read 3.0.0 through 3.7.0).
4
4
  * Bump it with the changeset flow.
5
5
  */
6
- declare const SDK_VERSION = "3.27.0";
6
+ declare const SDK_VERSION = "3.28.0";
7
7
 
8
8
  export { SDK_VERSION as S };
@@ -3,6 +3,6 @@
3
3
  * `package.json` so it cannot drift silently (it did: the UA read 3.0.0 through 3.7.0).
4
4
  * Bump it with the changeset flow.
5
5
  */
6
- declare const SDK_VERSION = "3.27.0";
6
+ declare const SDK_VERSION = "3.28.0";
7
7
 
8
8
  export { SDK_VERSION as S };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@invonetwork/web-sdk",
3
- "version": "3.27.0",
3
+ "version": "3.28.0",
4
4
  "description": "INVO Web SDK — currency purchase, passkey (WebAuthn) verification, loyalty, and a drop-in game economy layer (wallet, shop, hosted checkout) for partner web platforms and browser games.",
5
5
  "license": "SEE LICENSE IN LICENSE",
6
6
  "private": false,
@@ -1,6 +0,0 @@
1
- // src/version.ts
2
- var SDK_VERSION = "3.27.0";
3
-
4
- export { SDK_VERSION };
5
- //# sourceMappingURL=chunk-3YDO7GSH.js.map
6
- //# sourceMappingURL=chunk-3YDO7GSH.js.map