@imtbl/sdk 1.5.0 → 1.5.2

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.d.ts CHANGED
@@ -30092,7 +30092,7 @@ type SellResultInsufficientFunds = {
30092
30092
  /** The insufficient result of smart checkout */
30093
30093
  smartCheckoutResult: SmartCheckoutInsufficient;
30094
30094
  };
30095
- type CancelResult = CancelResultSuccess | CancelResultFailed | CancelResultFulfillmentsUnsettled;
30095
+ type CancelResult = CancelResultSuccess | CancelResultFailed | CancelResultFulfillmentsUnsettled | CancelResultGasless;
30096
30096
  /**
30097
30097
  * Represents the result of {@link Checkout.cancel}
30098
30098
  * @property {CheckoutStatus.SUCCESS} status
@@ -30121,18 +30121,58 @@ type CancelResultFailed = {
30121
30121
  * @property {SendTransactionResult[]} transactions
30122
30122
  */
30123
30123
  type CancelResultFulfillmentsUnsettled = {
30124
- /** The status to indicate success */
30124
+ /** The status to indicate the fulfillments have not yet settled on chain. */
30125
30125
  status: CheckoutStatus.FULFILLMENTS_UNSETTLED;
30126
30126
  /** Array of transaction results */
30127
30127
  transactions: TransactionResponse[];
30128
30128
  };
30129
+ /**
30130
+ * Represents the result of {@link Checkout.cancel} when using gasless cancel
30131
+ * @property {SuccessfulGaslessCancellation[]} successfulCancellations
30132
+ * @property {FailedGaslessCancellation[]} failedCancellations
30133
+ * @property {PendingGaslessCancellation[]} pendingCancellations
30134
+ */
30135
+ type CancelResultGasless = {
30136
+ successfulCancellations: SuccessfulGaslessCancellation[];
30137
+ failedCancellations: FailedGaslessCancellation[];
30138
+ pendingCancellations: PendingGaslessCancellation[];
30139
+ };
30140
+ /**
30141
+ * Represents a successful gasless cancellation
30142
+ * @property {string} orderId
30143
+ */
30144
+ type SuccessfulGaslessCancellation = {
30145
+ /** The order id of the successful cancellation */
30146
+ orderId: string;
30147
+ };
30148
+ /**
30149
+ * Represents a failed gasless cancellation
30150
+ * @property {string} orderId
30151
+ * @property {string} reason
30152
+ */
30153
+ type FailedGaslessCancellation = {
30154
+ /** The order id of the failed cancellation */
30155
+ orderId: string;
30156
+ /** The reason for failure */
30157
+ reason: string;
30158
+ };
30159
+ /**
30160
+ * Represents a pending gasless cancellation
30161
+ * @property {string} orderId
30162
+ */
30163
+ type PendingGaslessCancellation = {
30164
+ /** The order id of the pending cancellation */
30165
+ orderId: string;
30166
+ };
30129
30167
  /**
30130
30168
  * Represents the overrides available for {@link Checkout.cancel}
30131
30169
  * @property {boolean} waitFulfillmentSettlements
30132
30170
  */
30133
30171
  type CancelOverrides = {
30134
- /** If the buy should wait for the fulfillment transactions to settle */
30172
+ /** If the cancel should wait for the fulfillment transactions to settle */
30135
30173
  waitFulfillmentSettlements?: boolean;
30174
+ /** If the cancel should use the gasless option */
30175
+ useGaslessCancel?: boolean;
30136
30176
  };
30137
30177
  /**
30138
30178
  * An enum representing the checkout status types
@@ -30151,7 +30191,7 @@ declare enum CheckoutStatus {
30151
30191
  /**
30152
30192
  * The type representing the order to buy
30153
30193
  * @property {string} orderId
30154
- * @property {Array<OrderFee>} takerFees
30194
+ * @property {OrderFee[]} takerFees
30155
30195
  */
30156
30196
  type BuyOrder = {
30157
30197
  /** the id of the order to buy */
@@ -32496,6 +32536,7 @@ type checkout_d_CancelParams = CancelParams;
32496
32536
  type checkout_d_CancelResult = CancelResult;
32497
32537
  type checkout_d_CancelResultFailed = CancelResultFailed;
32498
32538
  type checkout_d_CancelResultFulfillmentsUnsettled = CancelResultFulfillmentsUnsettled;
32539
+ type checkout_d_CancelResultGasless = CancelResultGasless;
32499
32540
  type checkout_d_CancelResultSuccess = CancelResultSuccess;
32500
32541
  type checkout_d_ChainId = ChainId;
32501
32542
  declare const checkout_d_ChainId: typeof ChainId;
@@ -32537,6 +32578,7 @@ type checkout_d_ERC721ItemRequirement = ERC721ItemRequirement;
32537
32578
  type checkout_d_ErrorType = ErrorType;
32538
32579
  type checkout_d_ExchangeType = ExchangeType;
32539
32580
  declare const checkout_d_ExchangeType: typeof ExchangeType;
32581
+ type checkout_d_FailedGaslessCancellation = FailedGaslessCancellation;
32540
32582
  type checkout_d_Fee = Fee;
32541
32583
  type checkout_d_FeePercentage = FeePercentage;
32542
32584
  type checkout_d_FeeToken = FeeToken;
@@ -32599,6 +32641,7 @@ type checkout_d_OrchestrationEventData = OrchestrationEventData;
32599
32641
  type checkout_d_OrchestrationEventType = OrchestrationEventType;
32600
32642
  declare const checkout_d_OrchestrationEventType: typeof OrchestrationEventType;
32601
32643
  type checkout_d_OrderFee = OrderFee;
32644
+ type checkout_d_PendingGaslessCancellation = PendingGaslessCancellation;
32602
32645
  type checkout_d_ProviderEvent<KEventName extends keyof ProviderEventMapping> = ProviderEvent<KEventName>;
32603
32646
  type checkout_d_ProviderEventType = ProviderEventType;
32604
32647
  declare const checkout_d_ProviderEventType: typeof ProviderEventType;
@@ -32639,6 +32682,7 @@ type checkout_d_SmartCheckoutParams = SmartCheckoutParams;
32639
32682
  type checkout_d_SmartCheckoutResult = SmartCheckoutResult;
32640
32683
  type checkout_d_SmartCheckoutRouter = SmartCheckoutRouter;
32641
32684
  type checkout_d_SmartCheckoutSufficient = SmartCheckoutSufficient;
32685
+ type checkout_d_SuccessfulGaslessCancellation = SuccessfulGaslessCancellation;
32642
32686
  type checkout_d_SwapEventType = SwapEventType;
32643
32687
  declare const checkout_d_SwapEventType: typeof SwapEventType;
32644
32688
  type checkout_d_SwapFailed = SwapFailed;
@@ -32711,6 +32755,7 @@ declare namespace checkout_d {
32711
32755
  checkout_d_CancelResult as CancelResult,
32712
32756
  checkout_d_CancelResultFailed as CancelResultFailed,
32713
32757
  checkout_d_CancelResultFulfillmentsUnsettled as CancelResultFulfillmentsUnsettled,
32758
+ checkout_d_CancelResultGasless as CancelResultGasless,
32714
32759
  checkout_d_CancelResultSuccess as CancelResultSuccess,
32715
32760
  checkout_d_ChainId as ChainId,
32716
32761
  checkout_d_ChainName as ChainName,
@@ -32742,6 +32787,7 @@ declare namespace checkout_d {
32742
32787
  checkout_d_ERC721ItemRequirement as ERC721ItemRequirement,
32743
32788
  checkout_d_ErrorType as ErrorType,
32744
32789
  checkout_d_ExchangeType as ExchangeType,
32790
+ checkout_d_FailedGaslessCancellation as FailedGaslessCancellation,
32745
32791
  checkout_d_Fee as Fee,
32746
32792
  checkout_d_FeePercentage as FeePercentage,
32747
32793
  checkout_d_FeeToken as FeeToken,
@@ -32795,6 +32841,7 @@ declare namespace checkout_d {
32795
32841
  checkout_d_OrchestrationEventData as OrchestrationEventData,
32796
32842
  checkout_d_OrchestrationEventType as OrchestrationEventType,
32797
32843
  checkout_d_OrderFee as OrderFee,
32844
+ checkout_d_PendingGaslessCancellation as PendingGaslessCancellation,
32798
32845
  checkout_d_ProviderEvent as ProviderEvent,
32799
32846
  checkout_d_ProviderEventType as ProviderEventType,
32800
32847
  checkout_d_ProviderUpdated as ProviderUpdated,
@@ -32831,6 +32878,7 @@ declare namespace checkout_d {
32831
32878
  checkout_d_SmartCheckoutResult as SmartCheckoutResult,
32832
32879
  checkout_d_SmartCheckoutRouter as SmartCheckoutRouter,
32833
32880
  checkout_d_SmartCheckoutSufficient as SmartCheckoutSufficient,
32881
+ checkout_d_SuccessfulGaslessCancellation as SuccessfulGaslessCancellation,
32834
32882
  checkout_d_SwapEventType as SwapEventType,
32835
32883
  checkout_d_SwapFailed as SwapFailed,
32836
32884
  checkout_d_SwapFundingStep as SwapFundingStep,