Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cowprotocol/services
/ functions
Functions
10,747 in github.com/cowprotocol/services
⨍
Functions
10,747
◇
Types & classes
3,488
↓ 2 callers
Function
delete_invalidations
( ex: &mut PgTransaction<'_>, block_number: i64, )
crates/database/src/onchain_invalidations.rs:45
↓ 2 callers
Function
delete_order_events_before
Deletes the order events recorded before `timestamp`, except `invalid` ones: [`unrecorded_dead_creations`] reads them to record each dead creation onc
crates/autopilot-svm/src/infra/db.rs:790
↓ 2 callers
Method
deploy_multicall3
(&self)
crates/ethrpc/src/alloy/mod.rs:193
↓ 2 callers
Function
deployment_block
(chain_id: &u64)
contracts/generated/contracts-generated/weth9/src/lib.rs:3098
↓ 2 callers
Function
deserialize_url_with_trailing_slash
Deserialize a URL and make sure its path ends with a slash.
crates/serde-ext/src/url.rs:7
↓ 2 callers
Method
dispatch
(&self, payload: &str)
crates/autopilot/src/infra/order_notify/mod.rs:79
↓ 2 callers
Function
domain_auction
(orders: Vec<domain::Order>)
crates/solana-driver/src/infra/solver/dto/auction.rs:545
↓ 2 callers
Method
downscale_down
Similar to downscale up above, but rounded down, this is just checked div. https://github.com/balancer-labs/balancer-v2-monorepo/blob/c18ff2686c61a8cb
crates/liquidity-sources/src/balancer_v2/swap/mod.rs:67
↓ 2 callers
Method
downscale_up
Returns the token amount corresponding to the internal Balancer representation for the same amount. Based on contract code here: https://github.com/ba
crates/liquidity-sources/src/balancer_v2/swap/mod.rs:61
↓ 2 callers
Method
driver
Remaining time until the deadline for driver to return solution to autopilot is reached.
crates/driver/src/domain/time.rs:41
↓ 2 callers
Function
driver_name
A driver's metric label: the last segment of its URL path, which names the solver behind it, or the host for a URL without a path.
crates/solana-orderbook/src/infra/quoter.rs:262
↓ 2 callers
Function
drop_pools_missing_decimals
Drops pools missing either token's `decimals`. Treating missing as `0` would mis-scale prices, so we fail closed and wait for the indexer's decimals b
crates/liquidity-sources/src/uniswap_v3/pool_indexer.rs:156
↓ 2 callers
Method
encode
(&self)
crates/solver/src/interactions/uniswap_v3.rs:20
↓ 2 callers
Function
encode_registry
(registry: &Registry)
crates/observe/src/client_metrics.rs:40
↓ 2 callers
Function
encode_wrapper_settlement
Encodes a settlement transaction that uses wrapper contracts. Takes the base settlement calldata and wraps it in a wrappedSettleCall with encoded wra
crates/simulator/src/encoding.rs:284
↓ 2 callers
Function
encoded_size
The transaction's wire size, `None` when it does not serialize.
crates/solana-driver/src/domain/competition.rs:1159
↓ 2 callers
Function
engine
()
crates/autopilot/src/fee_engine.rs:381
↓ 2 callers
Function
engine_with
The engine `new` loads: `definition` with the list `wrapped_native`, validated on the sample orders.
crates/orderbook/src/fee_engine.rs:377
↓ 2 callers
Function
ensure_quote_accuracy
Returns an error if settling the quote would require using too much of the settlement contract buffers.
crates/price-estimation/src/trade_verifier.rs:829
↓ 2 callers
Method
enumerated
Every solution with its persisted uid: the position in `ranked` followed by `filtered_out`, so winners come first. Everything persisted references thi
crates/autopilot-svm/src/domain/cycle.rs:58
↓ 2 callers
Method
erc20
Returns a [`token::Erc20`] for the specified address.
crates/driver/src/infra/blockchain/mod.rs:230
↓ 2 callers
Method
estimate
(&self)
crates/gas-price-estimation/src/configurable_alloy.rs:126
↓ 2 callers
Method
estimate_native_price
( &self, token: Address, total_timeout: Duration, )
crates/price-estimation/src/competition/native.rs:22
↓ 2 callers
Method
estimate_native_price
( &self, token: Address, timeout: Duration, )
crates/price-estimation/src/native/mod.rs:107
↓ 2 callers
Method
estimate_result
Determines the result of a price estimate, returning either "success" or the error reason
crates/price-estimation/src/instrumented.rs:44
↓ 2 callers
Function
estimate_rows_in_table
Estimates the row count the way the query planner does: tuples per page from the last `VACUUM` or `ANALYZE`, times the table's current page count. See
crates/autopilot/src/database/mod.rs:127
↓ 2 callers
Function
ether_to_decimal
Converts an `eth::Ether` amount into a `BigDecimal` representation.
crates/solvers/src/util/conv.rs:28
↓ 2 callers
Method
ether_value
Computes an amount equivalent in value to the specified [`eth::Ether`] at the given price.
crates/solvers/src/domain/auction.rs:67
↓ 2 callers
Function
ethrpc
(url: &Url, ethrpc_args: &shared::web3::Arguments)
crates/autopilot/src/run.rs:91
↓ 2 callers
Function
evaluate
(source: &str)
crates/fee-engine/src/fee.rs:315
↓ 2 callers
Method
evaluate
( &self, order: &Order, app_data: &ValidatedAppData, app_code: Option<String>,
crates/orderbook/src/fee_engine.rs:48
↓ 2 callers
Function
event_log
(block_number: u64, block_timestamp: Option<u64>)
crates/autopilot/src/database/onchain_order_events/mod.rs:1492
↓ 2 callers
Method
execTransaction
(data: &[u8])
contracts/generated/contracts-generated/gnosissafe/src/lib.rs:3463
↓ 2 callers
Function
executed_amounts
The total executed amounts for one order, summed across the trades that fill it.
crates/solana-driver/src/domain/settlement.rs:749
↓ 2 callers
Function
executed_protocol_fees
( ex: &mut PgConnection, keys_filter: &[Execution], )
crates/database/src/order_execution.rs:80
↓ 2 callers
Method
executed_protocol_fees
( &self, ex: &mut PgConnection, keys_filter: &[Execution], )
crates/orderbook/src/database/fee_policies.rs:19
↓ 2 callers
Method
execution
Compute the execution of an order given the available liquidity
crates/driver/src/tests/setup/blockchain.rs:707
↓ 2 callers
Method
expire
Makes the probe fail until the next auction.
crates/autopilot-svm/src/run.rs:247
↓ 2 callers
Method
expire
Lower a dead creation's stored deadline below the chain height, which drops the order from the next cut, and record the order as invalid, since the cu
crates/autopilot-svm/src/infra/sponsor.rs:275
↓ 2 callers
Function
extract_critical_revert
Analyzes the simulation and only surfaces a revert if it was critical (as opposed to being caused by limitations of the simulation approach).
crates/shared/src/order_creation_simulation.rs:206
↓ 2 callers
Method
extract_custom_and_general_order_data
( &self, order_placement_events: Vec<(ContractEvent, Log)>, )
crates/autopilot/src/database/onchain_order_events/mod.rs:228
↓ 2 callers
Function
extract_interactions
( order: &FullOrderDb, execution: ExecutionTime, )
crates/shared/src/db_order_conversions.rs:205
↓ 2 callers
Function
extract_order_data_from_onchain_order_placement_event
( order_placement: &ContractOrderPlacement, domain_separator: DomainSeparator, )
crates/autopilot/src/database/onchain_order_events/mod.rs:677
↓ 2 callers
Function
extract_sload_slots
( trace: GethTrace, initial_storage_context: Address, )
crates/balance-overrides/src/detector.rs:34
↓ 2 callers
Function
factor
(v: f64)
crates/autopilot/src/fast_path.rs:717
↓ 2 callers
Function
factor
(value: f64)
crates/autopilot/src/fee_engine.rs:358
↓ 2 callers
Method
factor
(&self)
crates/driver/src/domain/liquidity/balancer/v2/stable.rs:126
↓ 2 callers
Function
factor_on_grid
`number` in the unit `grid_units` sizes ([`PERCENT`], [`BPS`]) as a fee factor: `0.3` with `BPS` is 30 steps of 1e-6, i.e. 0.00003. A value that is no
crates/fee-engine/src/fee.rs:83
↓ 2 callers
Method
factory
(data: &[u8])
contracts/generated/contracts-generated/iswaprpair/src/lib.rs:4886
↓ 2 callers
Function
fast_path_executed_amounts_match_quote
The on-chain fill of a fast-path order lands on the compounded quote-plus-fees bid to the wei, exercising the full fee stack for both order kinds: a
crates/e2e/tests/e2e/fast_path_settle.rs:498
↓ 2 callers
Method
fast_path_outcome
( &self, order: &Order, quote: &Quote, app_data: &ValidatedAppData, )
crates/orderbook/src/fee_engine.rs:162
↓ 2 callers
Function
fast_path_settle
A fast-path order signed against a quoting solver that charges a solver fee, at exactly the quote and with no slippage of the user's own. The fee is w
crates/e2e/tests/e2e/fast_path_settle.rs:181
↓ 2 callers
Method
fee
The fee the policy takes.
crates/protocol-fees/src/lib.rs:178
↓ 2 callers
Method
fee
Total fee (protocol fee + network fee). Equal to a surplus difference before and after applying the fees.
crates/autopilot/src/domain/settlement/trade/math.rs:126
↓ 2 callers
Function
fee_from_volume
( fulfillment: &Fulfillment, prices: ClearingPrices, factor: f64,
crates/driver/src/domain/competition/solution/fee.rs:492
↓ 2 callers
Method
fee_handler
Who prices the execution costs into this solver's fills.
crates/solana-driver/src/infra/solver/mod.rs:63
↓ 2 callers
Function
fee_mint
A Token-2022 mint charging `older` until `newer` takes over at its epoch.
crates/solana-token/src/lib.rs:341
↓ 2 callers
Method
fees
Protocol fees are defined by fee policies attached to the order. Every policy is unwound, so each fee is measured at the legs its policy was applied
crates/driver/src/domain/competition/solution/scoring.rs:156
↓ 2 callers
Method
fetch
(&self, contract_app_data: &AppDataHash)
crates/orderbook/src/ipfs_app_data.rs:87
↓ 2 callers
Function
fetch_by_order_uid
( ex: &mut PgConnection, order_uid: &OrderUid, )
crates/database/src/fee_policies.rs:107
↓ 2 callers
Method
fetch_common_pool_info
( &self, pool_address: Address, block_created: u64, )
crates/liquidity-sources/src/balancer_v2/pools/common.rs:84
↓ 2 callers
Function
fetch_decimals
(provider: &AlloyProvider, token: Address)
crates/pool-indexer/src/indexer/uniswap_v3.rs:456
↓ 2 callers
Function
fetch_in_flight_orders
Fetches all orders for which we must assume that there are still onchain transactions being mined or submitted. Those are all orders (JIT or regular)
crates/database/src/solver_competition_v2.rs:472
↓ 2 callers
Method
fetch_inner_many
(&self, keys: HashSet<K>, block: Block)
crates/liquidity-sources/src/recent_block_cache.rs:291
↓ 2 callers
Method
fetch_into_cache
Ask the stages in turn for the tokens still short of the required prices, and cache every verdict.
crates/autopilot-svm/src/infra/prices.rs:399
↓ 2 callers
Method
fetch_pools_page
`GET /pools?limit=N[&after=cursor]`. `None` means 503 (still bootstrapping) — the caller decides whether to retry or fail.
crates/liquidity-sources/src/uniswap_v3/pool_indexer.rs:261
↓ 2 callers
Method
fetch_token
(&self, address: Address)
crates/token-info/src/lib.rs:59
↓ 2 callers
Function
fetcher
Create the default [`BalanceFetching`] instance.
crates/account-balances/src/lib.rs:91
↓ 2 callers
Function
fill
(db: &mut PgTransaction<'_>, order_uid: OrderUid, log_index: i64)
crates/database/src/orders.rs:2454
↓ 2 callers
Method
fillOrKillLimitOrder
(data: &[u8])
contracts/generated/contracts-generated/izeroex/src/lib.rs:7339
↓ 2 callers
Function
fillable_orders
Drop orders a prior fill left with a leg scaled down to zero: no solver can fill them, so they would go out in every cut until they expire. Returns th
crates/autopilot-svm/src/infra/provider.rs:531
↓ 2 callers
Method
filter
(&self)
crates/liquidity-sources/src/balancer_v2/pool_fetching/registry.rs:44
↓ 2 callers
Method
filter_unsupported_orders_in_auction
Removes all unsupported orders from the auction.
crates/driver/src/domain/competition/risk_detector/mod.rs:71
↓ 2 callers
Method
filtered
Mark that this order should be filtered out before being sent to the solver.
crates/driver/src/tests/setup/mod.rs:206
↓ 2 callers
Function
finalize_bid
Computes the effective bid the driver would settle at: nets the quote's gas fee out first (as the user-facing quote does), then applies the volume-fee
crates/autopilot/src/fast_path.rs:677
↓ 2 callers
Method
finalized_block
(&self)
crates/pool-indexer/src/indexer/uniswap_v3.rs:224
↓ 2 callers
Function
find_app_data
The document stored under `hash`. `None` when the hash is unknown.
crates/solana-orderbook/src/infra/db.rs:312
↓ 2 callers
Function
find_banned_user_orders
Finds all orders whose owners, receivers or account that placed the order onchain are in the set of "banned" users.
crates/autopilot/src/solvable_orders.rs:513
↓ 2 callers
Function
find_competition_by_id_unfiltered
The competition of one auction, before its deadline too, for internal callers only.
crates/solana-orderbook/src/infra/db.rs:467
↓ 2 callers
Function
find_competition_by_tx_signature
The competition the transaction settled, under the visibility rule of [`find_competition_by_id`]. `None` when no settlement attributed to a solution c
crates/solana-orderbook/src/infra/db.rs:548
↓ 2 callers
Function
find_indexing_start_block
1. Check the `last_indexed_blocks` table for the `index_name`. 2. If no value found or the index is 0, use `fallback_start_block`, if provided. 3. Fal
crates/autopilot/src/database/onchain_order_events/ethflow_events.rs:253
↓ 2 callers
Function
find_latest_competition
The most recent competition whose deadline slot the indexer has passed.
crates/solana-orderbook/src/infra/db.rs:568
↓ 2 callers
Function
find_order
( orders: &'a [competition::Order], uid: &solvers_dto::solution::OrderUid, )
crates/driver/src/infra/solver/dto/solution.rs:271
↓ 2 callers
Function
find_order_solutions
The proposed solutions of the auction that settled the order's latest trade, or of the latest auction in which a solution executed the order. Worst to
crates/solana-orderbook/src/infra/db.rs:382
↓ 2 callers
Method
find_pair
(&self, order: &Order)
crates/driver/src/tests/setup/blockchain.rs:667
↓ 2 callers
Function
find_presignature_pending_orders
Finds orders with pending presignatures. EIP-1271 signature validation is skipped entirely - the driver validates signatures before settlement.
crates/autopilot/src/solvable_orders.rs:558
↓ 2 callers
Function
find_quote
Finds the most recent quote matching the given search parameters.
crates/shared/src/quote_storage.rs:95
↓ 2 callers
Function
find_unsupported_tokens
( orders: &[&Order], deny_listed_tokens: &DenyListedTokens, )
crates/autopilot/src/solvable_orders.rs:710
↓ 2 callers
Function
finder
A finder whose ids are 1, 2, 3, ... in allocation order.
crates/price-estimation/src/trade_finding/external.rs:375
↓ 2 callers
Function
fits
Narrows a leg scaled from, and bounded by, `u64` amounts.
crates/solana-driver/src/domain/auction.rs:368
↓ 2 callers
Function
fits
Narrows a leg scaled from, and bounded by, `u64` amounts.
crates/autopilot-svm/src/domain/auction.rs:143
↓ 2 callers
Method
flush
`write` sends each block downstream immediately, so a write effectively always flushes and there's nothing buffered left to do here.
crates/driver/src/infra/solver/streaming/mod.rs:139
↓ 2 callers
Method
from
(value: PrivateKeySigner)
crates/driver/src/infra/solver/mod.rs:176
↓ 2 callers
Function
full_order_into_model_order
(order: database::orders::FullOrder)
crates/shared/src/db_order_conversions.rs:43
↓ 2 callers
Function
full_orders_in_tx
( ex: &'a mut PgConnection, tx_hash: &'a TransactionHash, )
crates/database/src/orders.rs:778
↓ 2 callers
Function
full_path
(path: Option<String>, query: Option<String>)
crates/solvers/src/tests/mock/http.rs:292
↓ 2 callers
Function
full_preparations
The full whitelisted preparation prefix for a native-sell intent: create the wSOL account (the owner pays its rent, as placement requires), fund it, s
crates/solana-orderbook/tests/api.rs:1880
↓ 2 callers
Function
full_sample_order
The bare sample with every optional field present, so that a rule can reach any name the view may hold.
crates/fee-engine/src/rules.rs:392
↓ 2 callers
Function
funder_paid_accounts
The associated token accounts a creation opens with the funder as payer. Creations carry no lookup tables, so the static keys resolve every index.
crates/autopilot-svm/src/infra/sponsor.rs:326
↓ 2 callers
Function
funding
(source: Source)
crates/solana-orderbook/src/infra/verifier.rs:697
← previous
next →
1,601–1,700 of 10,747, ranked by callers