@chainflip/rpc 2.1.4 → 2.1.5
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/Client.cjs +33 -13
- package/dist/Client.d.cts +3 -0
- package/dist/Client.d.mts +3 -0
- package/dist/Client.mjs +33 -13
- package/dist/common.cjs +2 -1
- package/dist/common.d.cts +342 -0
- package/dist/common.d.mts +342 -0
- package/dist/common.mjs +3 -2
- package/dist/index.d.cts +2 -2
- package/dist/index.d.mts +2 -2
- package/dist/parsers.cjs +61 -0
- package/dist/parsers.d.cts +342 -1
- package/dist/parsers.d.mts +342 -1
- package/dist/parsers.mjs +61 -1
- package/dist/types.d.cts +3 -1
- package/dist/types.d.mts +3 -1
- package/package.json +3 -3
package/dist/common.d.mts
CHANGED
|
@@ -117,6 +117,7 @@ type RpcRequest = WithHash<{
|
|
|
117
117
|
cf_loan_accounts: [accountId?: string];
|
|
118
118
|
cf_lending_pool_supply_balances: [asset?: UncheckedAssetAndChain];
|
|
119
119
|
cf_get_vault_addresses: [];
|
|
120
|
+
cf_ingress_egress_events: [chain: Chain];
|
|
120
121
|
}> & {
|
|
121
122
|
chain_getBlockHash: [blockHeight?: number];
|
|
122
123
|
broker_request_swap_deposit_address: [sourceAsset: UncheckedAssetAndChain, destinationAsset: UncheckedAssetAndChain, destinationAddress: string, brokerCommission: number, ccmMetadata: Nullish<CcmParams>, boostFee: Nullish<number>, affiliateFees: Nullish<{
|
|
@@ -30759,6 +30760,347 @@ declare const rpcResult: {
|
|
|
30759
30760
|
Btc: number[];
|
|
30760
30761
|
}][];
|
|
30761
30762
|
}>;
|
|
30763
|
+
readonly cf_ingress_egress_events: z.ZodObject<{
|
|
30764
|
+
deposits: z.ZodArray<z.ZodObject<{
|
|
30765
|
+
deposit_chain_block_height: z.ZodNumber;
|
|
30766
|
+
deposit_address: z.ZodString;
|
|
30767
|
+
amount: z.ZodString;
|
|
30768
|
+
asset: z.ZodObject<{
|
|
30769
|
+
chain: z.ZodString;
|
|
30770
|
+
asset: z.ZodString;
|
|
30771
|
+
}, "strip", z.ZodTypeAny, {
|
|
30772
|
+
chain: string;
|
|
30773
|
+
asset: string;
|
|
30774
|
+
}, {
|
|
30775
|
+
chain: string;
|
|
30776
|
+
asset: string;
|
|
30777
|
+
}>;
|
|
30778
|
+
deposit_details: z.ZodNullable<z.ZodUnion<[z.ZodObject<{
|
|
30779
|
+
tx_hashes: z.ZodArray<z.ZodString, "many">;
|
|
30780
|
+
}, "strip", z.ZodTypeAny, {
|
|
30781
|
+
tx_hashes: string[];
|
|
30782
|
+
}, {
|
|
30783
|
+
tx_hashes: string[];
|
|
30784
|
+
}>, z.ZodObject<{
|
|
30785
|
+
tx_id: z.ZodString;
|
|
30786
|
+
vout: z.ZodNumber;
|
|
30787
|
+
}, "strip", z.ZodTypeAny, {
|
|
30788
|
+
tx_id: string;
|
|
30789
|
+
vout: number;
|
|
30790
|
+
}, {
|
|
30791
|
+
tx_id: string;
|
|
30792
|
+
vout: number;
|
|
30793
|
+
}>]>>;
|
|
30794
|
+
}, "strip", z.ZodTypeAny, {
|
|
30795
|
+
deposit_address: string;
|
|
30796
|
+
asset: {
|
|
30797
|
+
chain: string;
|
|
30798
|
+
asset: string;
|
|
30799
|
+
};
|
|
30800
|
+
amount: string;
|
|
30801
|
+
deposit_chain_block_height: number;
|
|
30802
|
+
deposit_details: {
|
|
30803
|
+
tx_hashes: string[];
|
|
30804
|
+
} | {
|
|
30805
|
+
tx_id: string;
|
|
30806
|
+
vout: number;
|
|
30807
|
+
} | null;
|
|
30808
|
+
}, {
|
|
30809
|
+
deposit_address: string;
|
|
30810
|
+
asset: {
|
|
30811
|
+
chain: string;
|
|
30812
|
+
asset: string;
|
|
30813
|
+
};
|
|
30814
|
+
amount: string;
|
|
30815
|
+
deposit_chain_block_height: number;
|
|
30816
|
+
deposit_details: {
|
|
30817
|
+
tx_hashes: string[];
|
|
30818
|
+
} | {
|
|
30819
|
+
tx_id: string;
|
|
30820
|
+
vout: number;
|
|
30821
|
+
} | null;
|
|
30822
|
+
}>, "many">;
|
|
30823
|
+
broadcasts: z.ZodArray<z.ZodObject<{
|
|
30824
|
+
broadcast_id: z.ZodNumber;
|
|
30825
|
+
broadcast_chain_block_height: z.ZodNumber;
|
|
30826
|
+
tx_out_id: z.ZodUnknown;
|
|
30827
|
+
tx_ref: z.ZodUnknown;
|
|
30828
|
+
}, "strip", z.ZodTypeAny, {
|
|
30829
|
+
broadcast_id: number;
|
|
30830
|
+
broadcast_chain_block_height: number;
|
|
30831
|
+
tx_out_id?: unknown;
|
|
30832
|
+
tx_ref?: unknown;
|
|
30833
|
+
}, {
|
|
30834
|
+
broadcast_id: number;
|
|
30835
|
+
broadcast_chain_block_height: number;
|
|
30836
|
+
tx_out_id?: unknown;
|
|
30837
|
+
tx_ref?: unknown;
|
|
30838
|
+
}>, "many">;
|
|
30839
|
+
vault_deposits: z.ZodArray<z.ZodObject<{
|
|
30840
|
+
tx_id: z.ZodString;
|
|
30841
|
+
deposit_chain_block_height: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
30842
|
+
input_asset: z.ZodObject<{
|
|
30843
|
+
chain: z.ZodString;
|
|
30844
|
+
asset: z.ZodString;
|
|
30845
|
+
}, "strip", z.ZodTypeAny, {
|
|
30846
|
+
chain: string;
|
|
30847
|
+
asset: string;
|
|
30848
|
+
}, {
|
|
30849
|
+
chain: string;
|
|
30850
|
+
asset: string;
|
|
30851
|
+
}>;
|
|
30852
|
+
output_asset: z.ZodObject<{
|
|
30853
|
+
chain: z.ZodString;
|
|
30854
|
+
asset: z.ZodString;
|
|
30855
|
+
}, "strip", z.ZodTypeAny, {
|
|
30856
|
+
chain: string;
|
|
30857
|
+
asset: string;
|
|
30858
|
+
}, {
|
|
30859
|
+
chain: string;
|
|
30860
|
+
asset: string;
|
|
30861
|
+
}>;
|
|
30862
|
+
amount: z.ZodString;
|
|
30863
|
+
destination_address: z.ZodString;
|
|
30864
|
+
ccm_deposit_metadata: z.ZodOptional<z.ZodNullable<z.ZodUnknown>>;
|
|
30865
|
+
deposit_details: z.ZodOptional<z.ZodNullable<z.ZodUnknown>>;
|
|
30866
|
+
broker_fee: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
30867
|
+
account: z.ZodString;
|
|
30868
|
+
bps: z.ZodNumber;
|
|
30869
|
+
}, "strip", z.ZodTypeAny, {
|
|
30870
|
+
account: string;
|
|
30871
|
+
bps: number;
|
|
30872
|
+
}, {
|
|
30873
|
+
account: string;
|
|
30874
|
+
bps: number;
|
|
30875
|
+
}>>>;
|
|
30876
|
+
affiliate_fees: z.ZodArray<z.ZodObject<{
|
|
30877
|
+
account: z.ZodString;
|
|
30878
|
+
bps: z.ZodNumber;
|
|
30879
|
+
}, "strip", z.ZodTypeAny, {
|
|
30880
|
+
account: string;
|
|
30881
|
+
bps: number;
|
|
30882
|
+
}, {
|
|
30883
|
+
account: string;
|
|
30884
|
+
bps: number;
|
|
30885
|
+
}>, "many">;
|
|
30886
|
+
refund_params: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
30887
|
+
retry_duration: z.ZodNumber;
|
|
30888
|
+
refund_address: z.ZodString;
|
|
30889
|
+
min_price: z.ZodString;
|
|
30890
|
+
refund_ccm_metadata: z.ZodOptional<z.ZodNullable<z.ZodUnknown>>;
|
|
30891
|
+
max_oracle_price_slippage: z.ZodOptional<z.ZodNullable<z.ZodUnknown>>;
|
|
30892
|
+
}, "strip", z.ZodTypeAny, {
|
|
30893
|
+
refund_address: string;
|
|
30894
|
+
retry_duration: number;
|
|
30895
|
+
min_price: string;
|
|
30896
|
+
refund_ccm_metadata?: unknown;
|
|
30897
|
+
max_oracle_price_slippage?: unknown;
|
|
30898
|
+
}, {
|
|
30899
|
+
refund_address: string;
|
|
30900
|
+
retry_duration: number;
|
|
30901
|
+
min_price: string;
|
|
30902
|
+
refund_ccm_metadata?: unknown;
|
|
30903
|
+
max_oracle_price_slippage?: unknown;
|
|
30904
|
+
}>>>;
|
|
30905
|
+
dca_params: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
30906
|
+
number_of_chunks: z.ZodNumber;
|
|
30907
|
+
chunk_interval: z.ZodNumber;
|
|
30908
|
+
}, "strip", z.ZodTypeAny, {
|
|
30909
|
+
number_of_chunks: number;
|
|
30910
|
+
chunk_interval: number;
|
|
30911
|
+
}, {
|
|
30912
|
+
number_of_chunks: number;
|
|
30913
|
+
chunk_interval: number;
|
|
30914
|
+
}>>>;
|
|
30915
|
+
max_boost_fee: z.ZodOptional<z.ZodNumber>;
|
|
30916
|
+
}, "strip", z.ZodTypeAny, {
|
|
30917
|
+
amount: string;
|
|
30918
|
+
tx_id: string;
|
|
30919
|
+
input_asset: {
|
|
30920
|
+
chain: string;
|
|
30921
|
+
asset: string;
|
|
30922
|
+
};
|
|
30923
|
+
output_asset: {
|
|
30924
|
+
chain: string;
|
|
30925
|
+
asset: string;
|
|
30926
|
+
};
|
|
30927
|
+
destination_address: string;
|
|
30928
|
+
affiliate_fees: {
|
|
30929
|
+
account: string;
|
|
30930
|
+
bps: number;
|
|
30931
|
+
}[];
|
|
30932
|
+
deposit_chain_block_height?: number | null | undefined;
|
|
30933
|
+
deposit_details?: unknown;
|
|
30934
|
+
ccm_deposit_metadata?: unknown;
|
|
30935
|
+
broker_fee?: {
|
|
30936
|
+
account: string;
|
|
30937
|
+
bps: number;
|
|
30938
|
+
} | null | undefined;
|
|
30939
|
+
refund_params?: {
|
|
30940
|
+
refund_address: string;
|
|
30941
|
+
retry_duration: number;
|
|
30942
|
+
min_price: string;
|
|
30943
|
+
refund_ccm_metadata?: unknown;
|
|
30944
|
+
max_oracle_price_slippage?: unknown;
|
|
30945
|
+
} | null | undefined;
|
|
30946
|
+
dca_params?: {
|
|
30947
|
+
number_of_chunks: number;
|
|
30948
|
+
chunk_interval: number;
|
|
30949
|
+
} | null | undefined;
|
|
30950
|
+
max_boost_fee?: number | undefined;
|
|
30951
|
+
}, {
|
|
30952
|
+
amount: string;
|
|
30953
|
+
tx_id: string;
|
|
30954
|
+
input_asset: {
|
|
30955
|
+
chain: string;
|
|
30956
|
+
asset: string;
|
|
30957
|
+
};
|
|
30958
|
+
output_asset: {
|
|
30959
|
+
chain: string;
|
|
30960
|
+
asset: string;
|
|
30961
|
+
};
|
|
30962
|
+
destination_address: string;
|
|
30963
|
+
affiliate_fees: {
|
|
30964
|
+
account: string;
|
|
30965
|
+
bps: number;
|
|
30966
|
+
}[];
|
|
30967
|
+
deposit_chain_block_height?: number | null | undefined;
|
|
30968
|
+
deposit_details?: unknown;
|
|
30969
|
+
ccm_deposit_metadata?: unknown;
|
|
30970
|
+
broker_fee?: {
|
|
30971
|
+
account: string;
|
|
30972
|
+
bps: number;
|
|
30973
|
+
} | null | undefined;
|
|
30974
|
+
refund_params?: {
|
|
30975
|
+
refund_address: string;
|
|
30976
|
+
retry_duration: number;
|
|
30977
|
+
min_price: string;
|
|
30978
|
+
refund_ccm_metadata?: unknown;
|
|
30979
|
+
max_oracle_price_slippage?: unknown;
|
|
30980
|
+
} | null | undefined;
|
|
30981
|
+
dca_params?: {
|
|
30982
|
+
number_of_chunks: number;
|
|
30983
|
+
chunk_interval: number;
|
|
30984
|
+
} | null | undefined;
|
|
30985
|
+
max_boost_fee?: number | undefined;
|
|
30986
|
+
}>, "many">;
|
|
30987
|
+
}, "strip", z.ZodTypeAny, {
|
|
30988
|
+
deposits: {
|
|
30989
|
+
deposit_address: string;
|
|
30990
|
+
asset: {
|
|
30991
|
+
chain: string;
|
|
30992
|
+
asset: string;
|
|
30993
|
+
};
|
|
30994
|
+
amount: string;
|
|
30995
|
+
deposit_chain_block_height: number;
|
|
30996
|
+
deposit_details: {
|
|
30997
|
+
tx_hashes: string[];
|
|
30998
|
+
} | {
|
|
30999
|
+
tx_id: string;
|
|
31000
|
+
vout: number;
|
|
31001
|
+
} | null;
|
|
31002
|
+
}[];
|
|
31003
|
+
broadcasts: {
|
|
31004
|
+
broadcast_id: number;
|
|
31005
|
+
broadcast_chain_block_height: number;
|
|
31006
|
+
tx_out_id?: unknown;
|
|
31007
|
+
tx_ref?: unknown;
|
|
31008
|
+
}[];
|
|
31009
|
+
vault_deposits: {
|
|
31010
|
+
amount: string;
|
|
31011
|
+
tx_id: string;
|
|
31012
|
+
input_asset: {
|
|
31013
|
+
chain: string;
|
|
31014
|
+
asset: string;
|
|
31015
|
+
};
|
|
31016
|
+
output_asset: {
|
|
31017
|
+
chain: string;
|
|
31018
|
+
asset: string;
|
|
31019
|
+
};
|
|
31020
|
+
destination_address: string;
|
|
31021
|
+
affiliate_fees: {
|
|
31022
|
+
account: string;
|
|
31023
|
+
bps: number;
|
|
31024
|
+
}[];
|
|
31025
|
+
deposit_chain_block_height?: number | null | undefined;
|
|
31026
|
+
deposit_details?: unknown;
|
|
31027
|
+
ccm_deposit_metadata?: unknown;
|
|
31028
|
+
broker_fee?: {
|
|
31029
|
+
account: string;
|
|
31030
|
+
bps: number;
|
|
31031
|
+
} | null | undefined;
|
|
31032
|
+
refund_params?: {
|
|
31033
|
+
refund_address: string;
|
|
31034
|
+
retry_duration: number;
|
|
31035
|
+
min_price: string;
|
|
31036
|
+
refund_ccm_metadata?: unknown;
|
|
31037
|
+
max_oracle_price_slippage?: unknown;
|
|
31038
|
+
} | null | undefined;
|
|
31039
|
+
dca_params?: {
|
|
31040
|
+
number_of_chunks: number;
|
|
31041
|
+
chunk_interval: number;
|
|
31042
|
+
} | null | undefined;
|
|
31043
|
+
max_boost_fee?: number | undefined;
|
|
31044
|
+
}[];
|
|
31045
|
+
}, {
|
|
31046
|
+
deposits: {
|
|
31047
|
+
deposit_address: string;
|
|
31048
|
+
asset: {
|
|
31049
|
+
chain: string;
|
|
31050
|
+
asset: string;
|
|
31051
|
+
};
|
|
31052
|
+
amount: string;
|
|
31053
|
+
deposit_chain_block_height: number;
|
|
31054
|
+
deposit_details: {
|
|
31055
|
+
tx_hashes: string[];
|
|
31056
|
+
} | {
|
|
31057
|
+
tx_id: string;
|
|
31058
|
+
vout: number;
|
|
31059
|
+
} | null;
|
|
31060
|
+
}[];
|
|
31061
|
+
broadcasts: {
|
|
31062
|
+
broadcast_id: number;
|
|
31063
|
+
broadcast_chain_block_height: number;
|
|
31064
|
+
tx_out_id?: unknown;
|
|
31065
|
+
tx_ref?: unknown;
|
|
31066
|
+
}[];
|
|
31067
|
+
vault_deposits: {
|
|
31068
|
+
amount: string;
|
|
31069
|
+
tx_id: string;
|
|
31070
|
+
input_asset: {
|
|
31071
|
+
chain: string;
|
|
31072
|
+
asset: string;
|
|
31073
|
+
};
|
|
31074
|
+
output_asset: {
|
|
31075
|
+
chain: string;
|
|
31076
|
+
asset: string;
|
|
31077
|
+
};
|
|
31078
|
+
destination_address: string;
|
|
31079
|
+
affiliate_fees: {
|
|
31080
|
+
account: string;
|
|
31081
|
+
bps: number;
|
|
31082
|
+
}[];
|
|
31083
|
+
deposit_chain_block_height?: number | null | undefined;
|
|
31084
|
+
deposit_details?: unknown;
|
|
31085
|
+
ccm_deposit_metadata?: unknown;
|
|
31086
|
+
broker_fee?: {
|
|
31087
|
+
account: string;
|
|
31088
|
+
bps: number;
|
|
31089
|
+
} | null | undefined;
|
|
31090
|
+
refund_params?: {
|
|
31091
|
+
refund_address: string;
|
|
31092
|
+
retry_duration: number;
|
|
31093
|
+
min_price: string;
|
|
31094
|
+
refund_ccm_metadata?: unknown;
|
|
31095
|
+
max_oracle_price_slippage?: unknown;
|
|
31096
|
+
} | null | undefined;
|
|
31097
|
+
dca_params?: {
|
|
31098
|
+
number_of_chunks: number;
|
|
31099
|
+
chunk_interval: number;
|
|
31100
|
+
} | null | undefined;
|
|
31101
|
+
max_boost_fee?: number | undefined;
|
|
31102
|
+
}[];
|
|
31103
|
+
}>;
|
|
30762
31104
|
};
|
|
30763
31105
|
type RpcMethod = keyof RpcRequest;
|
|
30764
31106
|
type RpcResponse<T extends RpcMethod> = z.input<(typeof rpcResult)[T]>;
|
package/dist/common.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { brokerRequestAccountCreationDepositAddress, brokerRequestSwapDepositAddress, cfAccountInfo, cfAccounts, cfAuctionState, cfAvailablePools, cfBoostPoolDetails, cfBoostPoolPendingFees, cfBoostPoolsDepth, cfEnvironment, cfFailedCallEvm, cfFlipSuppy, cfFundingEnvironment, cfGetTradingStrategies, cfGetTradingStrategyLimits, cfIngressEgressEnvironment, cfLendingConfig, cfLendingPoolSupplyBalances, cfLendingPools, cfLoanAccounts, cfMonitoringSimulateAuction, cfOraclePrices, cfPoolDepth, cfPoolOrderbook, cfPoolOrders, cfPoolPriceV2, cfPoolsEnvironment, cfSafeModeStatuses, cfSupportedAssets, cfSwapRate, cfSwapRateV2, cfSwapRateV3, cfSwappingEnvironment, cfVaultAddresses, chainGetBlockHash, ethereumAddress, hexString, lpTotalBalances, numberOrHex, requestSwapParameterEncoding, rpcResponse, stateGetMetadata, stateGetRuntimeVersion } from "./parsers.mjs";
|
|
1
|
+
import { brokerRequestAccountCreationDepositAddress, brokerRequestSwapDepositAddress, cfAccountInfo, cfAccounts, cfAuctionState, cfAvailablePools, cfBoostPoolDetails, cfBoostPoolPendingFees, cfBoostPoolsDepth, cfEnvironment, cfFailedCallEvm, cfFlipSuppy, cfFundingEnvironment, cfGetTradingStrategies, cfGetTradingStrategyLimits, cfIngressEgressEnvironment, cfIngressEgressEvents, cfLendingConfig, cfLendingPoolSupplyBalances, cfLendingPools, cfLoanAccounts, cfMonitoringSimulateAuction, cfOraclePrices, cfPoolDepth, cfPoolOrderbook, cfPoolOrders, cfPoolPriceV2, cfPoolsEnvironment, cfSafeModeStatuses, cfSupportedAssets, cfSwapRate, cfSwapRateV2, cfSwapRateV3, cfSwappingEnvironment, cfVaultAddresses, chainGetBlockHash, ethereumAddress, hexString, lpTotalBalances, numberOrHex, requestSwapParameterEncoding, rpcResponse, stateGetMetadata, stateGetRuntimeVersion } from "./parsers.mjs";
|
|
2
2
|
import { z } from "zod";
|
|
3
3
|
|
|
4
4
|
//#region src/common.ts
|
|
@@ -49,7 +49,8 @@ const rpcResult = {
|
|
|
49
49
|
cf_lending_config: cfLendingConfig,
|
|
50
50
|
cf_loan_accounts: cfLoanAccounts,
|
|
51
51
|
cf_lending_pool_supply_balances: cfLendingPoolSupplyBalances,
|
|
52
|
-
cf_get_vault_addresses: cfVaultAddresses
|
|
52
|
+
cf_get_vault_addresses: cfVaultAddresses,
|
|
53
|
+
cf_ingress_egress_events: cfIngressEgressEvents
|
|
53
54
|
};
|
|
54
55
|
|
|
55
56
|
//#endregion
|
package/dist/index.d.cts
CHANGED
|
@@ -3,5 +3,5 @@ import { RpcMethod, RpcRequest, RpcResult } from "./common.cjs";
|
|
|
3
3
|
import HttpClient from "./HttpClient.cjs";
|
|
4
4
|
import WsClient from "./WsClient.cjs";
|
|
5
5
|
import { constants_d_exports } from "./constants.cjs";
|
|
6
|
-
import { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, LpTotalBalances, LpTotalBalancesResponse } from "./types.cjs";
|
|
7
|
-
export { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, HttpClient, LpTotalBalances, LpTotalBalancesResponse, RpcLimitOrder, RpcMethod, RpcRequest as RpcParams, RpcRangeOrder, RpcResult, WsClient, constants_d_exports as constants };
|
|
6
|
+
import { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfIngressEgressEvents, CfIngressEgressEventsResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, LpTotalBalances, LpTotalBalancesResponse } from "./types.cjs";
|
|
7
|
+
export { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfIngressEgressEvents, CfIngressEgressEventsResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, HttpClient, LpTotalBalances, LpTotalBalancesResponse, RpcLimitOrder, RpcMethod, RpcRequest as RpcParams, RpcRangeOrder, RpcResult, WsClient, constants_d_exports as constants };
|
package/dist/index.d.mts
CHANGED
|
@@ -3,5 +3,5 @@ import { RpcMethod, RpcRequest, RpcResult } from "./common.mjs";
|
|
|
3
3
|
import HttpClient from "./HttpClient.mjs";
|
|
4
4
|
import WsClient from "./WsClient.mjs";
|
|
5
5
|
import { constants_d_exports } from "./constants.mjs";
|
|
6
|
-
import { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, LpTotalBalances, LpTotalBalancesResponse } from "./types.mjs";
|
|
7
|
-
export { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, HttpClient, LpTotalBalances, LpTotalBalancesResponse, RpcLimitOrder, RpcMethod, RpcRequest as RpcParams, RpcRangeOrder, RpcResult, WsClient, constants_d_exports as constants };
|
|
6
|
+
import { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfIngressEgressEvents, CfIngressEgressEventsResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, LpTotalBalances, LpTotalBalancesResponse } from "./types.mjs";
|
|
7
|
+
export { CfAccountInfo, CfAccountInfoResponse, CfAccounts, CfAccountsResponse, CfAuctionState, CfAuctionStateResponse, CfAvailablePools, CfAvailablePoolsResponse, CfBoostPoolDetails, CfBoostPoolDetailsResponse, CfBoostPoolPendingFees, CfBoostPoolPendingFeesResponse, CfBoostPoolsDepth, CfBoostPoolsDepthResponse, CfBrokerAccount, CfEncodeCfParameters, CfEncodeCfParametersResponse, CfEnvironment, CfEnvironmentResponse, CfFailedCallArbitrum, CfFailedCallArbitrumResponse, CfFailedCallEthereum, CfFailedCallEthereumResponse, CfFlipSupply, CfFlipSupplyResponse, CfFundingEnvironment, CfFundingEnvironmentResponse, CfGetTradingStrategies, CfGetTradingStrategiesResponse, CfGetTradingStrategyLimits, CfGetTradingStrategyLimitsResponse, CfIngressEgressEnvironment, CfIngressEgressEnvironmentResponse, CfIngressEgressEvents, CfIngressEgressEventsResponse, CfLendingConfig, CfLendingConfigResponse, CfLendingPoolSupplyBalances, CfLendingPoolSupplyBalancesResponse, CfLendingPools, CfLendingPoolsResponse, CfLiquidityProviderAccount, CfLoanAccounts, CfLoanAccountsResponse, CfMonitoringSimulateAuction, CfMonitoringSimulateAuctionResponse, CfOperatorAccount, CfOraclePrices, CfOraclePricesResponse, CfPoolDepth, CfPoolDepthResponse, CfPoolOrderbook, CfPoolOrderbookResponse, CfPoolOrders, CfPoolOrdersResponse, CfPoolPriceV2, CfPoolPriceV2Response, CfPoolsEnvironment, CfPoolsEnvironmentResponse, CfRequestSwapParameterEncoding, CfRequestSwapParameterEncodingResponse, CfSafeModeStatuses, CfSafeModeStatusesResponse, CfSupportedAssets, CfSupportedAssetsResponse, CfSwapRate, CfSwapRateResponse, CfSwapRateV2, CfSwapRateV2Response, CfSwapRateV3, CfSwapRateV3Response, CfSwappingEnvironment, CfSwappingEnvironmentResponse, CfUnregisteredAccount, CfValidatorAccount, CfVaultAddresses, CfVaultAddressesResponse, HttpClient, LpTotalBalances, LpTotalBalancesResponse, RpcLimitOrder, RpcMethod, RpcRequest as RpcParams, RpcRangeOrder, RpcResult, WsClient, constants_d_exports as constants };
|
package/dist/parsers.cjs
CHANGED
|
@@ -742,6 +742,66 @@ const cfLendingPoolSupplyBalances = zod.z.array(zod.z.intersection(rpcAssetSchem
|
|
|
742
742
|
lp_id: accountId,
|
|
743
743
|
total_amount: numberOrHex
|
|
744
744
|
})) })));
|
|
745
|
+
const ingressEgressDeposit = zod.z.object({
|
|
746
|
+
deposit_chain_block_height: zod.z.number(),
|
|
747
|
+
deposit_address: zod.z.string(),
|
|
748
|
+
amount: zod.z.string(),
|
|
749
|
+
asset: zod.z.object({
|
|
750
|
+
chain: zod.z.string(),
|
|
751
|
+
asset: zod.z.string()
|
|
752
|
+
}),
|
|
753
|
+
deposit_details: zod.z.union([zod.z.object({ tx_hashes: zod.z.array(zod.z.string()) }), zod.z.object({
|
|
754
|
+
tx_id: zod.z.string(),
|
|
755
|
+
vout: zod.z.number()
|
|
756
|
+
})]).nullable()
|
|
757
|
+
});
|
|
758
|
+
const ingressEgressBroadcast = zod.z.object({
|
|
759
|
+
broadcast_id: zod.z.number(),
|
|
760
|
+
broadcast_chain_block_height: zod.z.number(),
|
|
761
|
+
tx_out_id: zod.z.unknown(),
|
|
762
|
+
tx_ref: zod.z.unknown()
|
|
763
|
+
});
|
|
764
|
+
const ingressEgressVaultDeposit = zod.z.object({
|
|
765
|
+
tx_id: zod.z.string(),
|
|
766
|
+
deposit_chain_block_height: zod.z.number().nullable().optional(),
|
|
767
|
+
input_asset: zod.z.object({
|
|
768
|
+
chain: zod.z.string(),
|
|
769
|
+
asset: zod.z.string()
|
|
770
|
+
}),
|
|
771
|
+
output_asset: zod.z.object({
|
|
772
|
+
chain: zod.z.string(),
|
|
773
|
+
asset: zod.z.string()
|
|
774
|
+
}),
|
|
775
|
+
amount: zod.z.string(),
|
|
776
|
+
destination_address: zod.z.string(),
|
|
777
|
+
ccm_deposit_metadata: zod.z.unknown().nullable().optional(),
|
|
778
|
+
deposit_details: zod.z.unknown().nullable().optional(),
|
|
779
|
+
broker_fee: zod.z.object({
|
|
780
|
+
account: zod.z.string(),
|
|
781
|
+
bps: zod.z.number()
|
|
782
|
+
}).nullable().optional(),
|
|
783
|
+
affiliate_fees: zod.z.array(zod.z.object({
|
|
784
|
+
account: zod.z.string(),
|
|
785
|
+
bps: zod.z.number()
|
|
786
|
+
})),
|
|
787
|
+
refund_params: zod.z.object({
|
|
788
|
+
retry_duration: zod.z.number(),
|
|
789
|
+
refund_address: zod.z.string(),
|
|
790
|
+
min_price: zod.z.string(),
|
|
791
|
+
refund_ccm_metadata: zod.z.unknown().nullable().optional(),
|
|
792
|
+
max_oracle_price_slippage: zod.z.unknown().nullable().optional()
|
|
793
|
+
}).nullable().optional(),
|
|
794
|
+
dca_params: zod.z.object({
|
|
795
|
+
number_of_chunks: zod.z.number(),
|
|
796
|
+
chunk_interval: zod.z.number()
|
|
797
|
+
}).nullable().optional(),
|
|
798
|
+
max_boost_fee: zod.z.number().optional()
|
|
799
|
+
});
|
|
800
|
+
const cfIngressEgressEvents = zod.z.object({
|
|
801
|
+
deposits: zod.z.array(ingressEgressDeposit),
|
|
802
|
+
broadcasts: zod.z.array(ingressEgressBroadcast),
|
|
803
|
+
vault_deposits: zod.z.array(ingressEgressVaultDeposit)
|
|
804
|
+
});
|
|
745
805
|
const cfVaultAddresses = zod.z.object({
|
|
746
806
|
ethereum: zod.z.object({ Eth: zod.z.array(zod.z.number()).length(20).transform(_chainflip_utils_bytes.bytesToHex) }),
|
|
747
807
|
arbitrum: zod.z.object({ Arb: zod.z.array(zod.z.number()).length(20).transform(_chainflip_utils_bytes.bytesToHex) }),
|
|
@@ -774,6 +834,7 @@ exports.cfFundingEnvironment = cfFundingEnvironment;
|
|
|
774
834
|
exports.cfGetTradingStrategies = cfGetTradingStrategies;
|
|
775
835
|
exports.cfGetTradingStrategyLimits = cfGetTradingStrategyLimits;
|
|
776
836
|
exports.cfIngressEgressEnvironment = cfIngressEgressEnvironment;
|
|
837
|
+
exports.cfIngressEgressEvents = cfIngressEgressEvents;
|
|
777
838
|
exports.cfLendingConfig = cfLendingConfig;
|
|
778
839
|
exports.cfLendingPoolSupplyBalances = cfLendingPoolSupplyBalances;
|
|
779
840
|
exports.cfLendingPools = cfLendingPools;
|