@cowprotocol/cow-sdk 6.0.0-RC.9 → 6.0.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/README.md +3 -1
- package/dist/README.md +3 -1
- package/dist/bridging/BridgingSdk/BridgingSdk.d.ts +87 -63
- package/dist/bridging/BridgingSdk/findBridgeProviderFromHook.d.ts +2 -0
- package/dist/bridging/BridgingSdk/getBridgeSignedHook.d.ts +8 -0
- package/dist/bridging/BridgingSdk/getCrossChainOrder.d.ts +16 -0
- package/dist/bridging/BridgingSdk/getQuoteWithBridge.d.ts +3 -0
- package/dist/bridging/BridgingSdk/getQuoteWithoutBridge.d.ts +7 -7
- package/dist/bridging/BridgingSdk/mock/bridgeRequestMocks.d.ts +20 -0
- package/dist/bridging/BridgingSdk/types.d.ts +43 -0
- package/dist/bridging/const.d.ts +4 -2
- package/dist/bridging/errors.d.ts +22 -0
- package/dist/bridging/index.d.ts +8 -5
- package/dist/bridging/providers/across/AcrossApi.d.ts +30 -195
- package/dist/bridging/providers/across/AcrossBridgeProvider.d.ts +44 -41
- package/dist/bridging/providers/across/abi.d.ts +154 -154
- package/dist/bridging/providers/across/const/contracts.d.ts +3 -3
- package/dist/bridging/providers/across/const/interfaces.d.ts +3 -0
- package/dist/bridging/providers/across/const/misc.d.ts +2 -0
- package/dist/bridging/providers/across/const/tokens.d.ts +11 -11
- package/dist/bridging/providers/across/createAcrossDepositCall.d.ts +9 -9
- package/dist/bridging/providers/across/getDepositParams.d.ts +4 -0
- package/dist/bridging/providers/across/types.d.ts +242 -0
- package/dist/bridging/providers/across/util.d.ts +43 -39
- package/dist/bridging/providers/bungee/BungeeApi.d.ts +67 -0
- package/dist/bridging/providers/bungee/BungeeBridgeProvider.d.ts +44 -0
- package/dist/bridging/providers/bungee/abi.d.ts +203 -0
- package/dist/bridging/providers/bungee/const/contracts.d.ts +4 -0
- package/dist/bridging/providers/bungee/const/misc.d.ts +8 -0
- package/dist/bridging/providers/bungee/createBungeeDepositCall.d.ts +7 -0
- package/dist/bridging/providers/bungee/getBridgingStatusFromEvents.d.ts +3 -0
- package/dist/bridging/providers/bungee/types.d.ts +267 -0
- package/dist/bridging/providers/bungee/util.d.ts +62 -0
- package/dist/bridging/providers/mock/MockBridgeProvider.d.ts +26 -20
- package/dist/bridging/providers/utils/getGasLimitEstimationForHook.d.ts +4 -0
- package/dist/bridging/types.d.ts +323 -251
- package/dist/bridging/utils.d.ts +9 -6
- package/dist/chains/const/index.d.ts +25 -25
- package/dist/chains/const/path.d.ts +1 -1
- package/dist/chains/details/arbitrum.d.ts +7 -7
- package/dist/chains/details/avalanche.d.ts +2 -0
- package/dist/chains/details/base.d.ts +7 -7
- package/dist/chains/details/gnosis.d.ts +7 -7
- package/dist/chains/details/index.d.ts +8 -0
- package/dist/chains/details/mainnet.d.ts +7 -7
- package/dist/chains/details/optimism.d.ts +2 -2
- package/dist/chains/details/polygon.d.ts +2 -2
- package/dist/chains/details/sepolia.d.ts +7 -7
- package/dist/chains/index.d.ts +4 -3
- package/dist/chains/types.d.ts +127 -122
- package/dist/chains/utils.d.ts +18 -18
- package/dist/common/consts/config.d.ts +9 -9
- package/dist/common/consts/contracts.d.ts +43 -34
- package/dist/common/consts/ipfs.d.ts +2 -2
- package/dist/common/consts/order.d.ts +1 -0
- package/dist/common/consts/path.d.ts +1 -1
- package/dist/common/consts/tokens.d.ts +9 -9
- package/dist/common/generated/CoWShed.d.ts +219 -219
- package/dist/common/generated/CoWShedFactory.d.ts +191 -191
- package/dist/common/generated/ComposableCoW.d.ts +340 -340
- package/dist/common/generated/EthFlow.d.ts +117 -117
- package/dist/common/generated/ExtensibleFallbackHandler.d.ts +282 -282
- package/dist/common/generated/GPv2Settlement.d.ts +107 -107
- package/dist/common/generated/TWAP.d.ts +141 -141
- package/dist/common/generated/common.d.ts +21 -21
- package/dist/common/generated/factories/CoWShedFactory__factory.d.ts +250 -250
- package/dist/common/generated/factories/CoWShed__factory.d.ts +254 -254
- package/dist/common/generated/factories/ComposableCoW__factory.d.ts +475 -475
- package/dist/common/generated/factories/EthFlow__factory.d.ts +124 -124
- package/dist/common/generated/factories/ExtensibleFallbackHandler__factory.d.ts +389 -389
- package/dist/common/generated/factories/GPv2Settlement__factory.d.ts +81 -81
- package/dist/common/generated/factories/TWAP__factory.d.ts +260 -260
- package/dist/common/generated/factories/index.d.ts +7 -7
- package/dist/common/generated/index.d.ts +15 -15
- package/dist/common/index.d.ts +12 -10
- package/dist/common/types/config.d.ts +70 -70
- package/dist/common/types/cow-error.d.ts +4 -4
- package/dist/common/types/ethereum.d.ts +5 -5
- package/dist/common/types/tokens.d.ts +12 -12
- package/dist/common/types/wallets.d.ts +5 -5
- package/dist/common/utils/common.d.ts +1 -0
- package/dist/common/utils/config.d.ts +4 -4
- package/dist/common/utils/log.d.ts +2 -0
- package/dist/common/utils/math.d.ts +19 -0
- package/dist/common/utils/order.d.ts +4 -0
- package/dist/common/utils/serialize.d.ts +1 -1
- package/dist/common/utils/wallet.d.ts +3 -3
- package/dist/composable/ConditionalOrder.d.ts +206 -206
- package/dist/composable/ConditionalOrderFactory.d.ts +19 -19
- package/dist/composable/Multiplexer.d.ts +174 -174
- package/dist/composable/contracts.d.ts +6 -6
- package/dist/composable/generated/ComposableCoW.d.ts +340 -340
- package/dist/composable/generated/ExtensibleFallbackHandler.d.ts +282 -282
- package/dist/composable/generated/TWAP.d.ts +141 -141
- package/dist/composable/generated/common.d.ts +21 -21
- package/dist/composable/generated/factories/ComposableCoW__factory.d.ts +475 -475
- package/dist/composable/generated/factories/ExtensibleFallbackHandler__factory.d.ts +389 -389
- package/dist/composable/generated/factories/TWAP__factory.d.ts +260 -260
- package/dist/composable/generated/factories/index.d.ts +3 -3
- package/dist/composable/generated/index.d.ts +7 -7
- package/dist/composable/index.d.ts +6 -6
- package/dist/composable/orderTypes/Twap.d.ts +242 -242
- package/dist/composable/orderTypes/index.d.ts +3 -3
- package/dist/composable/orderTypes/test/TestConditionalOrder.d.ts +25 -25
- package/dist/composable/types.d.ts +133 -133
- package/dist/composable/utils.d.ts +37 -37
- package/dist/cow-shed/CowShedSdk.d.ts +74 -69
- package/dist/cow-shed/contracts/CoWShedHooks.d.ts +47 -45
- package/dist/cow-shed/contracts/utils.d.ts +4 -4
- package/dist/cow-shed/index.d.ts +3 -2
- package/dist/cow-shed/types.d.ts +17 -17
- package/dist/hooks/utils.d.ts +3 -2
- package/dist/index-847d9333.js +29 -0
- package/dist/index-847d9333.js.map +1 -0
- package/dist/index.d.ts +11 -10
- package/dist/index.js +4 -4
- package/dist/index.js.map +1 -1
- package/dist/index.modern.mjs +1 -1
- package/dist/index.module.js +4 -4
- package/dist/index.module.js.map +1 -1
- package/dist/order-book/api.d.ts +235 -235
- package/dist/order-book/generated/index.d.ts +55 -55
- package/dist/order-book/generated/models/Address.d.ts +4 -4
- package/dist/order-book/generated/models/AppData.d.ts +7 -7
- package/dist/order-book/generated/models/AppDataHash.d.ts +6 -6
- package/dist/order-book/generated/models/AppDataObject.d.ts +7 -7
- package/dist/order-book/generated/models/Auction.d.ts +30 -30
- package/dist/order-book/generated/models/AuctionOrder.d.ts +92 -92
- package/dist/order-book/generated/models/AuctionPrices.d.ts +6 -6
- package/dist/order-book/generated/models/BigUint.d.ts +4 -4
- package/dist/order-book/generated/models/BuyTokenDestination.d.ts +7 -7
- package/dist/order-book/generated/models/CallData.d.ts +4 -4
- package/dist/order-book/generated/models/CompetitionAuction.d.ts +14 -14
- package/dist/order-book/generated/models/CompetitionOrderStatus.d.ts +29 -29
- package/dist/order-book/generated/models/EcdsaSignature.d.ts +4 -4
- package/dist/order-book/generated/models/EcdsaSigningScheme.d.ts +7 -7
- package/dist/order-book/generated/models/EthflowData.d.ts +20 -20
- package/dist/order-book/generated/models/ExecutedAmounts.d.ts +5 -5
- package/dist/order-book/generated/models/ExecutedProtocolFee.d.ts +8 -8
- package/dist/order-book/generated/models/FeePolicy.d.ts +7 -7
- package/dist/order-book/generated/models/InteractionData.d.ts +11 -11
- package/dist/order-book/generated/models/NativePriceResponse.d.ts +10 -10
- package/dist/order-book/generated/models/OnchainOrderData.d.ts +24 -24
- package/dist/order-book/generated/models/Order.d.ts +3 -3
- package/dist/order-book/generated/models/OrderCancellation.d.ts +14 -14
- package/dist/order-book/generated/models/OrderCancellationError.d.ts +15 -15
- package/dist/order-book/generated/models/OrderCancellations.d.ts +18 -18
- package/dist/order-book/generated/models/OrderClass.d.ts +8 -8
- package/dist/order-book/generated/models/OrderCreation.d.ts +80 -80
- package/dist/order-book/generated/models/OrderKind.d.ts +7 -7
- package/dist/order-book/generated/models/OrderMetaData.d.ts +100 -100
- package/dist/order-book/generated/models/OrderParameters.d.ts +53 -53
- package/dist/order-book/generated/models/OrderPostError.d.ts +35 -35
- package/dist/order-book/generated/models/OrderQuoteRequest.d.ts +58 -58
- package/dist/order-book/generated/models/OrderQuoteResponse.d.ts +27 -27
- package/dist/order-book/generated/models/OrderQuoteSide.d.ts +26 -26
- package/dist/order-book/generated/models/OrderQuoteSideKindBuy.d.ts +3 -3
- package/dist/order-book/generated/models/OrderQuoteSideKindSell.d.ts +3 -3
- package/dist/order-book/generated/models/OrderQuoteValidity.d.ts +14 -14
- package/dist/order-book/generated/models/OrderStatus.d.ts +10 -10
- package/dist/order-book/generated/models/PreSignature.d.ts +4 -4
- package/dist/order-book/generated/models/PriceEstimationError.d.ts +12 -12
- package/dist/order-book/generated/models/PriceImprovement.d.ts +12 -12
- package/dist/order-book/generated/models/PriceQuality.d.ts +16 -16
- package/dist/order-book/generated/models/Quote.d.ts +19 -19
- package/dist/order-book/generated/models/SellTokenSource.d.ts +8 -8
- package/dist/order-book/generated/models/Signature.d.ts +6 -6
- package/dist/order-book/generated/models/SigningScheme.d.ts +9 -9
- package/dist/order-book/generated/models/SolverCompetitionResponse.d.ts +30 -30
- package/dist/order-book/generated/models/SolverSettlement.d.ts +47 -47
- package/dist/order-book/generated/models/Surplus.d.ts +7 -7
- package/dist/order-book/generated/models/TokenAmount.d.ts +4 -4
- package/dist/order-book/generated/models/TotalSurplus.d.ts +10 -10
- package/dist/order-book/generated/models/Trade.d.ts +57 -57
- package/dist/order-book/generated/models/TransactionHash.d.ts +4 -4
- package/dist/order-book/generated/models/UID.d.ts +8 -8
- package/dist/order-book/generated/models/Volume.d.ts +6 -6
- package/dist/order-book/index.d.ts +5 -5
- package/dist/order-book/mock.d.ts +63 -63
- package/dist/order-book/quoteAmountsAndCostsUtils.d.ts +35 -22
- package/dist/order-book/request.d.ts +49 -49
- package/dist/order-book/transformOrder.d.ts +10 -10
- package/dist/order-book/types.d.ts +74 -74
- package/dist/order-signing/index.d.ts +2 -2
- package/dist/order-signing/orderSigningUtils.d.ts +97 -97
- package/dist/order-signing/types.d.ts +55 -55
- package/dist/order-signing/utils.d.ts +49 -49
- package/dist/package.json +31 -32
- package/dist/schemas/trading/LimitOrderAdvancedSettings.ts +151 -12
- package/dist/schemas/trading/LimitTradeParameters.ts +136 -15
- package/dist/schemas/trading/QuoteResultsSerialized.ts +292 -27
- package/dist/schemas/trading/QuoterParameters.ts +10 -0
- package/dist/schemas/trading/SwapAdvancedSettings.ts +331 -12
- package/dist/schemas/trading/TradeParameters.ts +136 -15
- package/dist/src/trading/README.md +99 -7
- package/dist/subgraph/api.d.ts +77 -77
- package/dist/subgraph/graphql.d.ts +3203 -3203
- package/dist/subgraph/index.d.ts +1 -1
- package/dist/subgraph/queries.d.ts +14 -14
- package/dist/test/utils.d.ts +1 -0
- package/dist/trading/appDataUtils.d.ts +5 -4
- package/dist/trading/calculateUniqueOrderId.d.ts +5 -5
- package/dist/trading/consts.d.ts +6 -14
- package/dist/trading/getEthFlowTransaction.d.ts +12 -7
- package/dist/trading/getOrderToSign.d.ts +11 -8
- package/dist/trading/getOrderTypedData.d.ts +4 -4
- package/dist/trading/getPreSignTransaction.d.ts +4 -4
- package/dist/trading/getQuote.d.ts +26 -14
- package/dist/trading/index.d.ts +21 -19
- package/dist/trading/postCoWProtocolTrade.d.ts +4 -4
- package/dist/trading/postLimitOrder.d.ts +3 -3
- package/dist/trading/postSellNativeCurrencyOrder.d.ts +4 -7
- package/dist/trading/postSwapOrder.d.ts +5 -5
- package/dist/trading/suggestSlippageBps.d.ts +13 -0
- package/dist/trading/suggestSlippageFromFee.d.ts +19 -0
- package/dist/trading/suggestSlippageFromVolume.d.ts +10 -0
- package/dist/trading/tradingSdk.d.ts +26 -26
- package/dist/trading/types.d.ts +221 -190
- package/dist/trading/utils/getPartnerFeeBps.d.ts +2 -0
- package/dist/trading/{utils.d.ts → utils/misc.d.ts} +27 -27
- package/dist/trading/utils/slippage.d.ts +16 -0
- package/dist/utils-09dadb80.js +2 -0
- package/dist/utils-09dadb80.js.map +1 -0
- package/dist/utils-0ff3f95e.js +2 -0
- package/dist/utils-0ff3f95e.js.map +1 -0
- package/dist/utils-ddcfac77.js +2 -0
- package/dist/utils-ddcfac77.js.map +1 -0
- package/dist/utils.d.ts +3 -3
- package/dist/weiroll/index.d.ts +23 -23
- package/package.json +31 -32
- package/dist/bridging/BridgingSdk/getErc20Decimals.d.ts +0 -4
- package/dist/bridging/BridgingSdk/getQuoteWithBridging.d.ts +0 -9
- package/dist/index-317c25f1.js +0 -29
- package/dist/index-317c25f1.js.map +0 -1
- package/dist/utils-204a9cbe.js +0 -2
- package/dist/utils-204a9cbe.js.map +0 -1
- package/dist/utils-762ee9c3.js +0 -2
- package/dist/utils-762ee9c3.js.map +0 -1
- package/dist/utils-de2eb543.js +0 -2
- package/dist/utils-de2eb543.js.map +0 -1
|
@@ -20,7 +20,7 @@ export default {
|
|
|
20
20
|
},
|
|
21
21
|
"slippageBps": {
|
|
22
22
|
"type": "number",
|
|
23
|
-
"description": "Slippage
|
|
23
|
+
"description": "Slippage in basis points. If not provided, it will use AUTO slippage, which would suggest a slippage based on the quote."
|
|
24
24
|
},
|
|
25
25
|
"receiver": {
|
|
26
26
|
"anyOf": [
|
|
@@ -39,22 +39,143 @@ export default {
|
|
|
39
39
|
"description": "Unix timestamp (`uint32`) until which the order is valid."
|
|
40
40
|
},
|
|
41
41
|
"partnerFee": {
|
|
42
|
-
"
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
"
|
|
46
|
-
|
|
42
|
+
"anyOf": [
|
|
43
|
+
{
|
|
44
|
+
"type": "array",
|
|
45
|
+
"items": {
|
|
46
|
+
"anyOf": [
|
|
47
|
+
{
|
|
48
|
+
"type": "object",
|
|
49
|
+
"properties": {
|
|
50
|
+
"volumeBps": {
|
|
51
|
+
"type": "number",
|
|
52
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on volume. Capped at protocol level to 100 BPS (1%)"
|
|
53
|
+
},
|
|
54
|
+
"recipient": {
|
|
55
|
+
"type": "string",
|
|
56
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
57
|
+
}
|
|
58
|
+
},
|
|
59
|
+
"required": [
|
|
60
|
+
"volumeBps",
|
|
61
|
+
"recipient"
|
|
62
|
+
],
|
|
63
|
+
"additionalProperties": false
|
|
64
|
+
},
|
|
65
|
+
{
|
|
66
|
+
"type": "object",
|
|
67
|
+
"properties": {
|
|
68
|
+
"surplusBps": {
|
|
69
|
+
"type": "number",
|
|
70
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on surplus"
|
|
71
|
+
},
|
|
72
|
+
"maxVolumeBps": {
|
|
73
|
+
"type": "number",
|
|
74
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
75
|
+
},
|
|
76
|
+
"recipient": {
|
|
77
|
+
"type": "string",
|
|
78
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"required": [
|
|
82
|
+
"surplusBps",
|
|
83
|
+
"maxVolumeBps",
|
|
84
|
+
"recipient"
|
|
85
|
+
],
|
|
86
|
+
"additionalProperties": false
|
|
87
|
+
},
|
|
88
|
+
{
|
|
89
|
+
"type": "object",
|
|
90
|
+
"properties": {
|
|
91
|
+
"priceImprovementBps": {
|
|
92
|
+
"type": "number",
|
|
93
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on price improvement"
|
|
94
|
+
},
|
|
95
|
+
"maxVolumeBps": {
|
|
96
|
+
"type": "number",
|
|
97
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
98
|
+
},
|
|
99
|
+
"recipient": {
|
|
100
|
+
"type": "string",
|
|
101
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
102
|
+
}
|
|
103
|
+
},
|
|
104
|
+
"required": [
|
|
105
|
+
"priceImprovementBps",
|
|
106
|
+
"maxVolumeBps",
|
|
107
|
+
"recipient"
|
|
108
|
+
],
|
|
109
|
+
"additionalProperties": false
|
|
110
|
+
}
|
|
111
|
+
]
|
|
112
|
+
}
|
|
47
113
|
},
|
|
48
|
-
|
|
49
|
-
"type": "
|
|
50
|
-
"
|
|
114
|
+
{
|
|
115
|
+
"type": "object",
|
|
116
|
+
"properties": {
|
|
117
|
+
"volumeBps": {
|
|
118
|
+
"type": "number",
|
|
119
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on volume. Capped at protocol level to 100 BPS (1%)"
|
|
120
|
+
},
|
|
121
|
+
"recipient": {
|
|
122
|
+
"type": "string",
|
|
123
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
124
|
+
}
|
|
125
|
+
},
|
|
126
|
+
"required": [
|
|
127
|
+
"volumeBps",
|
|
128
|
+
"recipient"
|
|
129
|
+
],
|
|
130
|
+
"additionalProperties": false
|
|
131
|
+
},
|
|
132
|
+
{
|
|
133
|
+
"type": "object",
|
|
134
|
+
"properties": {
|
|
135
|
+
"surplusBps": {
|
|
136
|
+
"type": "number",
|
|
137
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on surplus"
|
|
138
|
+
},
|
|
139
|
+
"maxVolumeBps": {
|
|
140
|
+
"type": "number",
|
|
141
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
142
|
+
},
|
|
143
|
+
"recipient": {
|
|
144
|
+
"type": "string",
|
|
145
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
"required": [
|
|
149
|
+
"surplusBps",
|
|
150
|
+
"maxVolumeBps",
|
|
151
|
+
"recipient"
|
|
152
|
+
],
|
|
153
|
+
"additionalProperties": false
|
|
154
|
+
},
|
|
155
|
+
{
|
|
156
|
+
"type": "object",
|
|
157
|
+
"properties": {
|
|
158
|
+
"priceImprovementBps": {
|
|
159
|
+
"type": "number",
|
|
160
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on price improvement"
|
|
161
|
+
},
|
|
162
|
+
"maxVolumeBps": {
|
|
163
|
+
"type": "number",
|
|
164
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
165
|
+
},
|
|
166
|
+
"recipient": {
|
|
167
|
+
"type": "string",
|
|
168
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
169
|
+
}
|
|
170
|
+
},
|
|
171
|
+
"required": [
|
|
172
|
+
"priceImprovementBps",
|
|
173
|
+
"maxVolumeBps",
|
|
174
|
+
"recipient"
|
|
175
|
+
],
|
|
176
|
+
"additionalProperties": false
|
|
51
177
|
}
|
|
52
|
-
|
|
53
|
-
"required": [
|
|
54
|
-
"bps",
|
|
55
|
-
"recipient"
|
|
56
|
-
],
|
|
57
|
-
"additionalProperties": false
|
|
178
|
+
]
|
|
58
179
|
},
|
|
59
180
|
"kind": {
|
|
60
181
|
"type": "string",
|
|
@@ -96,6 +217,10 @@ export default {
|
|
|
96
217
|
],
|
|
97
218
|
"description": "Information about the trade, including the kind of order, the owner, the sell and buy tokens, and the amount."
|
|
98
219
|
},
|
|
220
|
+
"suggestedSlippageBps": {
|
|
221
|
+
"type": "number",
|
|
222
|
+
"description": "The suggested slippage based on the quote."
|
|
223
|
+
},
|
|
99
224
|
"orderToSign": {
|
|
100
225
|
"type": "object",
|
|
101
226
|
"additionalProperties": false,
|
|
@@ -500,33 +625,172 @@ export default {
|
|
|
500
625
|
"additionalProperties": false
|
|
501
626
|
},
|
|
502
627
|
"partnerFee": {
|
|
628
|
+
"anyOf": [
|
|
629
|
+
{
|
|
630
|
+
"type": "array",
|
|
631
|
+
"items": {
|
|
632
|
+
"anyOf": [
|
|
633
|
+
{
|
|
634
|
+
"type": "object",
|
|
635
|
+
"properties": {
|
|
636
|
+
"volumeBps": {
|
|
637
|
+
"type": "number",
|
|
638
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on volume. Capped at protocol level to 100 BPS (1%)"
|
|
639
|
+
},
|
|
640
|
+
"recipient": {
|
|
641
|
+
"type": "string",
|
|
642
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
643
|
+
}
|
|
644
|
+
},
|
|
645
|
+
"required": [
|
|
646
|
+
"volumeBps",
|
|
647
|
+
"recipient"
|
|
648
|
+
],
|
|
649
|
+
"additionalProperties": false
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
"type": "object",
|
|
653
|
+
"properties": {
|
|
654
|
+
"surplusBps": {
|
|
655
|
+
"type": "number",
|
|
656
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on surplus"
|
|
657
|
+
},
|
|
658
|
+
"maxVolumeBps": {
|
|
659
|
+
"type": "number",
|
|
660
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
661
|
+
},
|
|
662
|
+
"recipient": {
|
|
663
|
+
"type": "string",
|
|
664
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
665
|
+
}
|
|
666
|
+
},
|
|
667
|
+
"required": [
|
|
668
|
+
"surplusBps",
|
|
669
|
+
"maxVolumeBps",
|
|
670
|
+
"recipient"
|
|
671
|
+
],
|
|
672
|
+
"additionalProperties": false
|
|
673
|
+
},
|
|
674
|
+
{
|
|
675
|
+
"type": "object",
|
|
676
|
+
"properties": {
|
|
677
|
+
"priceImprovementBps": {
|
|
678
|
+
"type": "number",
|
|
679
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on price improvement"
|
|
680
|
+
},
|
|
681
|
+
"maxVolumeBps": {
|
|
682
|
+
"type": "number",
|
|
683
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
684
|
+
},
|
|
685
|
+
"recipient": {
|
|
686
|
+
"type": "string",
|
|
687
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
688
|
+
}
|
|
689
|
+
},
|
|
690
|
+
"required": [
|
|
691
|
+
"priceImprovementBps",
|
|
692
|
+
"maxVolumeBps",
|
|
693
|
+
"recipient"
|
|
694
|
+
],
|
|
695
|
+
"additionalProperties": false
|
|
696
|
+
}
|
|
697
|
+
]
|
|
698
|
+
}
|
|
699
|
+
},
|
|
700
|
+
{
|
|
701
|
+
"type": "object",
|
|
702
|
+
"properties": {
|
|
703
|
+
"volumeBps": {
|
|
704
|
+
"type": "number",
|
|
705
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on volume. Capped at protocol level to 100 BPS (1%)"
|
|
706
|
+
},
|
|
707
|
+
"recipient": {
|
|
708
|
+
"type": "string",
|
|
709
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
710
|
+
}
|
|
711
|
+
},
|
|
712
|
+
"required": [
|
|
713
|
+
"volumeBps",
|
|
714
|
+
"recipient"
|
|
715
|
+
],
|
|
716
|
+
"additionalProperties": false
|
|
717
|
+
},
|
|
718
|
+
{
|
|
719
|
+
"type": "object",
|
|
720
|
+
"properties": {
|
|
721
|
+
"surplusBps": {
|
|
722
|
+
"type": "number",
|
|
723
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on surplus"
|
|
724
|
+
},
|
|
725
|
+
"maxVolumeBps": {
|
|
726
|
+
"type": "number",
|
|
727
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
728
|
+
},
|
|
729
|
+
"recipient": {
|
|
730
|
+
"type": "string",
|
|
731
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
732
|
+
}
|
|
733
|
+
},
|
|
734
|
+
"required": [
|
|
735
|
+
"surplusBps",
|
|
736
|
+
"maxVolumeBps",
|
|
737
|
+
"recipient"
|
|
738
|
+
],
|
|
739
|
+
"additionalProperties": false
|
|
740
|
+
},
|
|
741
|
+
{
|
|
742
|
+
"type": "object",
|
|
743
|
+
"properties": {
|
|
744
|
+
"priceImprovementBps": {
|
|
745
|
+
"type": "number",
|
|
746
|
+
"description": "The fee in basis points (BPS) to be paid to the partner based on price improvement"
|
|
747
|
+
},
|
|
748
|
+
"maxVolumeBps": {
|
|
749
|
+
"type": "number",
|
|
750
|
+
"description": "The maximum volume in basis points (BPS) to be paid to the partner. Capped at protocol level to 100 BPS (1%). You can chose to go lower but not higher"
|
|
751
|
+
},
|
|
752
|
+
"recipient": {
|
|
753
|
+
"type": "string",
|
|
754
|
+
"description": "The Ethereum address of the partner to receive the fee."
|
|
755
|
+
}
|
|
756
|
+
},
|
|
757
|
+
"required": [
|
|
758
|
+
"priceImprovementBps",
|
|
759
|
+
"maxVolumeBps",
|
|
760
|
+
"recipient"
|
|
761
|
+
],
|
|
762
|
+
"additionalProperties": false
|
|
763
|
+
}
|
|
764
|
+
]
|
|
765
|
+
},
|
|
766
|
+
"replacedOrder": {
|
|
503
767
|
"type": "object",
|
|
504
768
|
"properties": {
|
|
505
|
-
"
|
|
506
|
-
"type": "number",
|
|
507
|
-
"description": "The fee in basis points (BPS) to be paid to the partner. One basis point is equivalent to 0.01% (1/100th of a percent)"
|
|
508
|
-
},
|
|
509
|
-
"recipient": {
|
|
769
|
+
"uid": {
|
|
510
770
|
"type": "string",
|
|
511
|
-
"description": "The
|
|
771
|
+
"description": "The replaced order UID."
|
|
512
772
|
}
|
|
513
773
|
},
|
|
514
774
|
"required": [
|
|
515
|
-
"
|
|
516
|
-
"recipient"
|
|
775
|
+
"uid"
|
|
517
776
|
],
|
|
518
777
|
"additionalProperties": false
|
|
519
778
|
},
|
|
520
|
-
"
|
|
779
|
+
"bridging": {
|
|
521
780
|
"type": "object",
|
|
522
781
|
"properties": {
|
|
523
|
-
"
|
|
782
|
+
"destinationChainId": {
|
|
524
783
|
"type": "string",
|
|
525
|
-
"description": "
|
|
784
|
+
"description": "Id of a blockchain where funds will be received"
|
|
785
|
+
},
|
|
786
|
+
"destinationTokenAddress": {
|
|
787
|
+
"type": "string",
|
|
788
|
+
"description": "Address of a token that will be received at destination chain. The chain might be EVM or non-EVM. Some chains might even not have a token address. E.g.: Bitcoin"
|
|
526
789
|
}
|
|
527
790
|
},
|
|
528
791
|
"required": [
|
|
529
|
-
"
|
|
792
|
+
"destinationChainId",
|
|
793
|
+
"destinationTokenAddress"
|
|
530
794
|
],
|
|
531
795
|
"additionalProperties": false
|
|
532
796
|
}
|
|
@@ -850,6 +1114,7 @@ export default {
|
|
|
850
1114
|
"orderToSign",
|
|
851
1115
|
"orderTypedData",
|
|
852
1116
|
"quoteResponse",
|
|
1117
|
+
"suggestedSlippageBps",
|
|
853
1118
|
"tradeParameters"
|
|
854
1119
|
],
|
|
855
1120
|
"additionalProperties": false,
|
|
@@ -13,6 +13,8 @@ export default {
|
|
|
13
13
|
100,
|
|
14
14
|
42161,
|
|
15
15
|
8453,
|
|
16
|
+
137,
|
|
17
|
+
43114,
|
|
16
18
|
11155111
|
|
17
19
|
],
|
|
18
20
|
"description": "Supported chains and their `chainId` for the SDK.\n\nA supported chain, is a chain where CoW Protocol is deployed, so you can sell tokens from there."
|
|
@@ -20,6 +22,14 @@ export default {
|
|
|
20
22
|
"appCode": {
|
|
21
23
|
"type": "string",
|
|
22
24
|
"description": "The code identifying the CLI, UI, service generating the order."
|
|
25
|
+
},
|
|
26
|
+
"env": {
|
|
27
|
+
"type": "string",
|
|
28
|
+
"enum": [
|
|
29
|
+
"prod",
|
|
30
|
+
"staging"
|
|
31
|
+
],
|
|
32
|
+
"description": "The environment to use for the Cow API."
|
|
23
33
|
}
|
|
24
34
|
},
|
|
25
35
|
"required": [
|