@chainflip/sdk 1.2.0-rc.0 → 1.2.0-rc.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/{broker-MHEH3K4E.mjs → broker-Z7ASKYS2.mjs} +2 -2
- package/dist/{chunk-Q7HQVR3T.mjs → chunk-DV4HDL4K.mjs} +585 -5
- package/dist/chunk-M2FID654.mjs +27 -0
- package/dist/{chunk-PDTD3K27.mjs → chunk-OV3KFLWM.mjs} +2 -1
- package/dist/funding.js +585 -23
- package/dist/funding.mjs +2 -2
- package/dist/swap.d.mts +37 -15
- package/dist/swap.d.ts +37 -15
- package/dist/swap.js +14 -12
- package/dist/swap.mjs +17 -17
- package/package.json +1 -1
- package/dist/chunk-6H62DRRW.mjs +0 -606
package/dist/swap.d.mts
CHANGED
|
@@ -438,20 +438,8 @@ interface DepositAddressResponse extends DepositAddressRequest {
|
|
|
438
438
|
interface SwapStatusRequest {
|
|
439
439
|
id: string;
|
|
440
440
|
}
|
|
441
|
-
interface
|
|
442
|
-
srcAsset: Asset;
|
|
443
|
-
srcChain: Chain;
|
|
444
|
-
destAsset: Asset | undefined;
|
|
445
|
-
destChain: Chain | undefined;
|
|
441
|
+
interface SwapStatusResponseCommonFields {
|
|
446
442
|
destAddress: string;
|
|
447
|
-
depositAddress: string | undefined;
|
|
448
|
-
depositChannelCreatedAt: number | undefined;
|
|
449
|
-
depositChannelBrokerCommissionBps: number | undefined;
|
|
450
|
-
expectedDepositAmount: string | undefined;
|
|
451
|
-
depositChannelExpiryBlock: string | undefined;
|
|
452
|
-
estimatedDepositChannelExpiryTime: number | undefined;
|
|
453
|
-
isDepositChannelExpired: boolean | undefined;
|
|
454
|
-
depositChannelOpenedThroughBackend: boolean | undefined;
|
|
455
443
|
ccmDepositReceivedBlockIndex: string | undefined;
|
|
456
444
|
ccmMetadata: {
|
|
457
445
|
gasBudget: string;
|
|
@@ -459,7 +447,38 @@ interface CommonStatusFields {
|
|
|
459
447
|
} | undefined;
|
|
460
448
|
feesPaid: SwapFee[];
|
|
461
449
|
}
|
|
462
|
-
|
|
450
|
+
interface DepositAddressFields extends SwapStatusResponseCommonFields {
|
|
451
|
+
depositAddress: string;
|
|
452
|
+
depositChannelCreatedAt: number;
|
|
453
|
+
depositChannelBrokerCommissionBps: number;
|
|
454
|
+
expectedDepositAmount: string | undefined;
|
|
455
|
+
depositChannelExpiryBlock: string;
|
|
456
|
+
estimatedDepositChannelExpiryTime: number;
|
|
457
|
+
isDepositChannelExpired: boolean;
|
|
458
|
+
depositChannelOpenedThroughBackend: boolean;
|
|
459
|
+
}
|
|
460
|
+
type CopyFields<T, U> = {
|
|
461
|
+
[K in Exclude<keyof T, keyof U>]: undefined;
|
|
462
|
+
} & U;
|
|
463
|
+
type VaultSwapFields = CopyFields<DepositAddressFields, SwapStatusResponseCommonFields>;
|
|
464
|
+
type FailedVaultSwapStatusResponse = CopyFields<DepositAddressFields, {
|
|
465
|
+
depositAmount: string;
|
|
466
|
+
depositTransactionHash: string;
|
|
467
|
+
destAddress: string;
|
|
468
|
+
error: {
|
|
469
|
+
message: string;
|
|
470
|
+
name: string;
|
|
471
|
+
};
|
|
472
|
+
failedAt: number;
|
|
473
|
+
failedBlockIndex: string;
|
|
474
|
+
failure: string;
|
|
475
|
+
feesPaid: [];
|
|
476
|
+
srcAsset: Asset;
|
|
477
|
+
srcChain: Chain;
|
|
478
|
+
state: 'FAILED';
|
|
479
|
+
depositAddress: undefined;
|
|
480
|
+
}>;
|
|
481
|
+
type SwapState = {
|
|
463
482
|
state: 'AWAITING_DEPOSIT';
|
|
464
483
|
depositAmount: string | undefined;
|
|
465
484
|
depositTransactionHash: string | undefined;
|
|
@@ -565,7 +584,10 @@ type SwapStatusResponse = CommonStatusFields & ({
|
|
|
565
584
|
ignoredEgressAmount: string;
|
|
566
585
|
egressIgnoredAt: number;
|
|
567
586
|
egressIgnoredBlockIndex: string;
|
|
568
|
-
}
|
|
587
|
+
};
|
|
588
|
+
type DepositAddressStatusResponse = DepositAddressFields & SwapState;
|
|
589
|
+
type VaultSwapStatusResponse = VaultSwapFields & SwapState;
|
|
590
|
+
type SwapStatusResponse = DepositAddressStatusResponse | VaultSwapStatusResponse | FailedVaultSwapStatusResponse;
|
|
569
591
|
|
|
570
592
|
type RequestOptions = {
|
|
571
593
|
signal?: AbortSignal;
|
package/dist/swap.d.ts
CHANGED
|
@@ -438,20 +438,8 @@ interface DepositAddressResponse extends DepositAddressRequest {
|
|
|
438
438
|
interface SwapStatusRequest {
|
|
439
439
|
id: string;
|
|
440
440
|
}
|
|
441
|
-
interface
|
|
442
|
-
srcAsset: Asset;
|
|
443
|
-
srcChain: Chain;
|
|
444
|
-
destAsset: Asset | undefined;
|
|
445
|
-
destChain: Chain | undefined;
|
|
441
|
+
interface SwapStatusResponseCommonFields {
|
|
446
442
|
destAddress: string;
|
|
447
|
-
depositAddress: string | undefined;
|
|
448
|
-
depositChannelCreatedAt: number | undefined;
|
|
449
|
-
depositChannelBrokerCommissionBps: number | undefined;
|
|
450
|
-
expectedDepositAmount: string | undefined;
|
|
451
|
-
depositChannelExpiryBlock: string | undefined;
|
|
452
|
-
estimatedDepositChannelExpiryTime: number | undefined;
|
|
453
|
-
isDepositChannelExpired: boolean | undefined;
|
|
454
|
-
depositChannelOpenedThroughBackend: boolean | undefined;
|
|
455
443
|
ccmDepositReceivedBlockIndex: string | undefined;
|
|
456
444
|
ccmMetadata: {
|
|
457
445
|
gasBudget: string;
|
|
@@ -459,7 +447,38 @@ interface CommonStatusFields {
|
|
|
459
447
|
} | undefined;
|
|
460
448
|
feesPaid: SwapFee[];
|
|
461
449
|
}
|
|
462
|
-
|
|
450
|
+
interface DepositAddressFields extends SwapStatusResponseCommonFields {
|
|
451
|
+
depositAddress: string;
|
|
452
|
+
depositChannelCreatedAt: number;
|
|
453
|
+
depositChannelBrokerCommissionBps: number;
|
|
454
|
+
expectedDepositAmount: string | undefined;
|
|
455
|
+
depositChannelExpiryBlock: string;
|
|
456
|
+
estimatedDepositChannelExpiryTime: number;
|
|
457
|
+
isDepositChannelExpired: boolean;
|
|
458
|
+
depositChannelOpenedThroughBackend: boolean;
|
|
459
|
+
}
|
|
460
|
+
type CopyFields<T, U> = {
|
|
461
|
+
[K in Exclude<keyof T, keyof U>]: undefined;
|
|
462
|
+
} & U;
|
|
463
|
+
type VaultSwapFields = CopyFields<DepositAddressFields, SwapStatusResponseCommonFields>;
|
|
464
|
+
type FailedVaultSwapStatusResponse = CopyFields<DepositAddressFields, {
|
|
465
|
+
depositAmount: string;
|
|
466
|
+
depositTransactionHash: string;
|
|
467
|
+
destAddress: string;
|
|
468
|
+
error: {
|
|
469
|
+
message: string;
|
|
470
|
+
name: string;
|
|
471
|
+
};
|
|
472
|
+
failedAt: number;
|
|
473
|
+
failedBlockIndex: string;
|
|
474
|
+
failure: string;
|
|
475
|
+
feesPaid: [];
|
|
476
|
+
srcAsset: Asset;
|
|
477
|
+
srcChain: Chain;
|
|
478
|
+
state: 'FAILED';
|
|
479
|
+
depositAddress: undefined;
|
|
480
|
+
}>;
|
|
481
|
+
type SwapState = {
|
|
463
482
|
state: 'AWAITING_DEPOSIT';
|
|
464
483
|
depositAmount: string | undefined;
|
|
465
484
|
depositTransactionHash: string | undefined;
|
|
@@ -565,7 +584,10 @@ type SwapStatusResponse = CommonStatusFields & ({
|
|
|
565
584
|
ignoredEgressAmount: string;
|
|
566
585
|
egressIgnoredAt: number;
|
|
567
586
|
egressIgnoredBlockIndex: string;
|
|
568
|
-
}
|
|
587
|
+
};
|
|
588
|
+
type DepositAddressStatusResponse = DepositAddressFields & SwapState;
|
|
589
|
+
type VaultSwapStatusResponse = VaultSwapFields & SwapState;
|
|
590
|
+
type SwapStatusResponse = DepositAddressStatusResponse | VaultSwapStatusResponse | FailedVaultSwapStatusResponse;
|
|
569
591
|
|
|
570
592
|
type RequestOptions = {
|
|
571
593
|
signal?: AbortSignal;
|
package/dist/swap.js
CHANGED
|
@@ -4755,7 +4755,7 @@ var init_broker = __esm({
|
|
|
4755
4755
|
}
|
|
4756
4756
|
});
|
|
4757
4757
|
|
|
4758
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
4758
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/observable-ade1bad8.mjs
|
|
4759
4759
|
function identity(x) {
|
|
4760
4760
|
return x;
|
|
4761
4761
|
}
|
|
@@ -4834,7 +4834,7 @@ function observable(subscribe) {
|
|
|
4834
4834
|
}
|
|
4835
4835
|
__name(observable, "observable");
|
|
4836
4836
|
|
|
4837
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
4837
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/observable/index.mjs
|
|
4838
4838
|
function share(_opts) {
|
|
4839
4839
|
return (originalObserver) => {
|
|
4840
4840
|
let refCount = 0;
|
|
@@ -4939,7 +4939,7 @@ function observableToPromise(observable2) {
|
|
|
4939
4939
|
}
|
|
4940
4940
|
__name(observableToPromise, "observableToPromise");
|
|
4941
4941
|
|
|
4942
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
4942
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/splitLink-4c75f7be.mjs
|
|
4943
4943
|
function createChain(opts) {
|
|
4944
4944
|
return observable((observer) => {
|
|
4945
4945
|
function execute(index = 0, op = opts.op) {
|
|
@@ -4963,7 +4963,7 @@ function createChain(opts) {
|
|
|
4963
4963
|
}
|
|
4964
4964
|
__name(createChain, "createChain");
|
|
4965
4965
|
|
|
4966
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
4966
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/codes-c924c3db.mjs
|
|
4967
4967
|
function invert(obj) {
|
|
4968
4968
|
const newObj = /* @__PURE__ */ Object.create(null);
|
|
4969
4969
|
for (const key in obj) {
|
|
@@ -5001,7 +5001,7 @@ var TRPC_ERROR_CODES_BY_KEY = {
|
|
|
5001
5001
|
};
|
|
5002
5002
|
invert(TRPC_ERROR_CODES_BY_KEY);
|
|
5003
5003
|
|
|
5004
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
5004
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/index-f91d720c.mjs
|
|
5005
5005
|
invert(TRPC_ERROR_CODES_BY_KEY);
|
|
5006
5006
|
var noop = /* @__PURE__ */ __name(() => {
|
|
5007
5007
|
}, "noop");
|
|
@@ -5039,7 +5039,7 @@ var createFlatProxy = /* @__PURE__ */ __name((callback) => {
|
|
|
5039
5039
|
});
|
|
5040
5040
|
}, "createFlatProxy");
|
|
5041
5041
|
|
|
5042
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
5042
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/getCauseFromUnknown-2d66414a.mjs
|
|
5043
5043
|
function isObject(value) {
|
|
5044
5044
|
return !!value && !Array.isArray(value) && typeof value === "object";
|
|
5045
5045
|
}
|
|
@@ -5070,7 +5070,7 @@ function getCauseFromUnknown(cause) {
|
|
|
5070
5070
|
}
|
|
5071
5071
|
__name(getCauseFromUnknown, "getCauseFromUnknown");
|
|
5072
5072
|
|
|
5073
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5073
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/transformResult-ace864b8.mjs
|
|
5074
5074
|
function isObject2(value) {
|
|
5075
5075
|
return !!value && !Array.isArray(value) && typeof value === "object";
|
|
5076
5076
|
}
|
|
@@ -5123,7 +5123,7 @@ function transformResult(response, runtime) {
|
|
|
5123
5123
|
}
|
|
5124
5124
|
__name(transformResult, "transformResult");
|
|
5125
5125
|
|
|
5126
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5126
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/TRPCClientError-38f9a32a.mjs
|
|
5127
5127
|
function isTRPCClientError(cause) {
|
|
5128
5128
|
return cause instanceof TRPCClientError || /**
|
|
5129
5129
|
* @deprecated
|
|
@@ -5181,7 +5181,7 @@ var _TRPCClientError = class _TRPCClientError extends Error {
|
|
|
5181
5181
|
__name(_TRPCClientError, "TRPCClientError");
|
|
5182
5182
|
var TRPCClientError = _TRPCClientError;
|
|
5183
5183
|
|
|
5184
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5184
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/httpUtils-b9d0cb48.mjs
|
|
5185
5185
|
var isFunction = /* @__PURE__ */ __name((fn) => typeof fn === "function", "isFunction");
|
|
5186
5186
|
function getFetch(customFetchImpl) {
|
|
5187
5187
|
if (customFetchImpl) {
|
|
@@ -5325,7 +5325,7 @@ function httpRequest(opts) {
|
|
|
5325
5325
|
}
|
|
5326
5326
|
__name(httpRequest, "httpRequest");
|
|
5327
5327
|
|
|
5328
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5328
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/httpBatchLink-d0f9eac9.mjs
|
|
5329
5329
|
var throwFatalError = /* @__PURE__ */ __name(() => {
|
|
5330
5330
|
throw new Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new");
|
|
5331
5331
|
}, "throwFatalError");
|
|
@@ -5555,7 +5555,7 @@ var batchRequester = /* @__PURE__ */ __name((requesterOpts) => {
|
|
|
5555
5555
|
}, "batchRequester");
|
|
5556
5556
|
var httpBatchLink = createHTTPBatchLink(batchRequester);
|
|
5557
5557
|
|
|
5558
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5558
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/links/httpLink.mjs
|
|
5559
5559
|
function httpLinkFactory(factoryOpts) {
|
|
5560
5560
|
return (opts) => {
|
|
5561
5561
|
const resolvedOpts = resolveHTTPLinkOptions(opts);
|
|
@@ -5607,7 +5607,7 @@ function httpLinkFactory(factoryOpts) {
|
|
|
5607
5607
|
}
|
|
5608
5608
|
__name(httpLinkFactory, "httpLinkFactory");
|
|
5609
5609
|
|
|
5610
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
5610
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/index.mjs
|
|
5611
5611
|
var _TRPCUntypedClient = class _TRPCUntypedClient {
|
|
5612
5612
|
$request({ type, input, path, context = {} }) {
|
|
5613
5613
|
const chain$ = createChain({
|
|
@@ -6962,6 +6962,7 @@ init_guards();
|
|
|
6962
6962
|
// ../shared/src/rpc/index.ts
|
|
6963
6963
|
init_lib();
|
|
6964
6964
|
init_enums();
|
|
6965
|
+
init_parsers();
|
|
6965
6966
|
var numberOrHex = z.union([
|
|
6966
6967
|
z.string(),
|
|
6967
6968
|
z.number()
|
|
@@ -7113,6 +7114,7 @@ var swapRate = z.object({
|
|
|
7113
7114
|
output: numberOrHex
|
|
7114
7115
|
});
|
|
7115
7116
|
createRequest("cf_swap_rate", swapRate);
|
|
7117
|
+
createRequest("state_getMetadata", hexString);
|
|
7116
7118
|
|
|
7117
7119
|
// ../shared/src/rpc/utils.ts
|
|
7118
7120
|
init_enums();
|
package/dist/swap.mjs
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { getTokenContractAddress, getEnvironment, getVaultManagerContractAddress, approve, checkAllowance, Vault__factory, extractOverrides } from './chunk-
|
|
2
|
-
import {
|
|
3
|
-
import { __name, z, Chains, Assets, ChainflipNetworks, assetChains, assetDecimals, isTestnet, __publicField, assert, assertIsValidAssetAndChain, isTokenCall, isTokenSwap, chainContractIds, assetContractIds } from './chunk-
|
|
4
|
-
export { Assets, ChainflipNetworks, Chains, assetChains, assetContractIds, assetDecimals, chainAssets, chainContractIds } from './chunk-
|
|
1
|
+
import { getTokenContractAddress, getEnvironment, getVaultManagerContractAddress, approve, checkAllowance, Vault__factory, extractOverrides } from './chunk-OV3KFLWM.mjs';
|
|
2
|
+
import { ccmMetadataSchema } from './chunk-M2FID654.mjs';
|
|
3
|
+
import { __name, z, numericString, Chains, Assets, ethereumAddress, dotAddress, ChainflipNetworks, assetChains, assetDecimals, isTestnet, __publicField, assert, assertIsValidAssetAndChain, isTokenCall, isTokenSwap, chainContractIds, assetContractIds, btcAddress } from './chunk-DV4HDL4K.mjs';
|
|
4
|
+
export { Assets, ChainflipNetworks, Chains, assetChains, assetContractIds, assetDecimals, chainAssets, chainContractIds } from './chunk-DV4HDL4K.mjs';
|
|
5
5
|
import { decodeAddress } from '@polkadot/util-crypto';
|
|
6
6
|
import axios from 'axios';
|
|
7
7
|
|
|
8
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
8
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/observable-ade1bad8.mjs
|
|
9
9
|
function identity(x) {
|
|
10
10
|
return x;
|
|
11
11
|
}
|
|
@@ -84,7 +84,7 @@ function observable(subscribe) {
|
|
|
84
84
|
}
|
|
85
85
|
__name(observable, "observable");
|
|
86
86
|
|
|
87
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
87
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/observable/index.mjs
|
|
88
88
|
function share(_opts) {
|
|
89
89
|
return (originalObserver) => {
|
|
90
90
|
let refCount = 0;
|
|
@@ -189,7 +189,7 @@ function observableToPromise(observable2) {
|
|
|
189
189
|
}
|
|
190
190
|
__name(observableToPromise, "observableToPromise");
|
|
191
191
|
|
|
192
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
192
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/splitLink-4c75f7be.mjs
|
|
193
193
|
function createChain(opts) {
|
|
194
194
|
return observable((observer) => {
|
|
195
195
|
function execute(index = 0, op = opts.op) {
|
|
@@ -213,7 +213,7 @@ function createChain(opts) {
|
|
|
213
213
|
}
|
|
214
214
|
__name(createChain, "createChain");
|
|
215
215
|
|
|
216
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
216
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/codes-c924c3db.mjs
|
|
217
217
|
function invert(obj) {
|
|
218
218
|
const newObj = /* @__PURE__ */ Object.create(null);
|
|
219
219
|
for (const key in obj) {
|
|
@@ -251,7 +251,7 @@ var TRPC_ERROR_CODES_BY_KEY = {
|
|
|
251
251
|
};
|
|
252
252
|
invert(TRPC_ERROR_CODES_BY_KEY);
|
|
253
253
|
|
|
254
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
254
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/index-f91d720c.mjs
|
|
255
255
|
invert(TRPC_ERROR_CODES_BY_KEY);
|
|
256
256
|
var noop = /* @__PURE__ */ __name(() => {
|
|
257
257
|
}, "noop");
|
|
@@ -289,7 +289,7 @@ var createFlatProxy = /* @__PURE__ */ __name((callback) => {
|
|
|
289
289
|
});
|
|
290
290
|
}, "createFlatProxy");
|
|
291
291
|
|
|
292
|
-
// ../../node_modules/.pnpm/@trpc+server@10.45.
|
|
292
|
+
// ../../node_modules/.pnpm/@trpc+server@10.45.1/node_modules/@trpc/server/dist/getCauseFromUnknown-2d66414a.mjs
|
|
293
293
|
function isObject(value) {
|
|
294
294
|
return !!value && !Array.isArray(value) && typeof value === "object";
|
|
295
295
|
}
|
|
@@ -320,7 +320,7 @@ function getCauseFromUnknown(cause) {
|
|
|
320
320
|
}
|
|
321
321
|
__name(getCauseFromUnknown, "getCauseFromUnknown");
|
|
322
322
|
|
|
323
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
323
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/transformResult-ace864b8.mjs
|
|
324
324
|
function isObject2(value) {
|
|
325
325
|
return !!value && !Array.isArray(value) && typeof value === "object";
|
|
326
326
|
}
|
|
@@ -373,7 +373,7 @@ function transformResult(response, runtime) {
|
|
|
373
373
|
}
|
|
374
374
|
__name(transformResult, "transformResult");
|
|
375
375
|
|
|
376
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
376
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/TRPCClientError-38f9a32a.mjs
|
|
377
377
|
function isTRPCClientError(cause) {
|
|
378
378
|
return cause instanceof TRPCClientError || /**
|
|
379
379
|
* @deprecated
|
|
@@ -431,7 +431,7 @@ var _TRPCClientError = class _TRPCClientError extends Error {
|
|
|
431
431
|
__name(_TRPCClientError, "TRPCClientError");
|
|
432
432
|
var TRPCClientError = _TRPCClientError;
|
|
433
433
|
|
|
434
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
434
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/httpUtils-b9d0cb48.mjs
|
|
435
435
|
var isFunction = /* @__PURE__ */ __name((fn) => typeof fn === "function", "isFunction");
|
|
436
436
|
function getFetch(customFetchImpl) {
|
|
437
437
|
if (customFetchImpl) {
|
|
@@ -575,7 +575,7 @@ function httpRequest(opts) {
|
|
|
575
575
|
}
|
|
576
576
|
__name(httpRequest, "httpRequest");
|
|
577
577
|
|
|
578
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
578
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/httpBatchLink-d0f9eac9.mjs
|
|
579
579
|
var throwFatalError = /* @__PURE__ */ __name(() => {
|
|
580
580
|
throw new Error("Something went wrong. Please submit an issue at https://github.com/trpc/trpc/issues/new");
|
|
581
581
|
}, "throwFatalError");
|
|
@@ -805,7 +805,7 @@ var batchRequester = /* @__PURE__ */ __name((requesterOpts) => {
|
|
|
805
805
|
}, "batchRequester");
|
|
806
806
|
var httpBatchLink = createHTTPBatchLink(batchRequester);
|
|
807
807
|
|
|
808
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
808
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/links/httpLink.mjs
|
|
809
809
|
function httpLinkFactory(factoryOpts) {
|
|
810
810
|
return (opts) => {
|
|
811
811
|
const resolvedOpts = resolveHTTPLinkOptions(opts);
|
|
@@ -857,7 +857,7 @@ function httpLinkFactory(factoryOpts) {
|
|
|
857
857
|
}
|
|
858
858
|
__name(httpLinkFactory, "httpLinkFactory");
|
|
859
859
|
|
|
860
|
-
// ../../node_modules/.pnpm/@trpc+client@10.45.
|
|
860
|
+
// ../../node_modules/.pnpm/@trpc+client@10.45.1_@trpc+server@10.45.1/node_modules/@trpc/client/dist/index.mjs
|
|
861
861
|
var _TRPCUntypedClient = class _TRPCUntypedClient {
|
|
862
862
|
$request({ type, input, path, context = {} }) {
|
|
863
863
|
const chain$ = createChain({
|
|
@@ -2567,7 +2567,7 @@ var _SwapSDK = class _SwapSDK {
|
|
|
2567
2567
|
}, BigInt(amount));
|
|
2568
2568
|
let response;
|
|
2569
2569
|
if (this.brokerConfig !== void 0) {
|
|
2570
|
-
const { requestSwapDepositAddress } = await import('./broker-
|
|
2570
|
+
const { requestSwapDepositAddress } = await import('./broker-Z7ASKYS2.mjs');
|
|
2571
2571
|
const result = await requestSwapDepositAddress(depositAddressRequest, this.brokerConfig, this.network);
|
|
2572
2572
|
response = {
|
|
2573
2573
|
id: `${result.issuedBlock}-${depositAddressRequest.srcChain}-${result.channelId}`,
|