Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/cowprotocol/services
/ functions
Functions
10,749 in github.com/cowprotocol/services
⨍
Functions
10,749
◇
Types & classes
3,488
↓ 16 callers
Method
prices
The lamport value of one atom of each token, scaled by 10^9 like [`ChainTypes::NATIVE_PRICE_DENOMINATOR`]. A token no estimator prices, or whose mint
crates/autopilot-svm/src/infra/prices.rs:244
↓ 16 callers
Function
pubkey
(byte: u8)
crates/solana-driver/src/infra/blockchain/accounts.rs:175
↓ 16 callers
Function
pubkey
(byte: u8)
crates/solana-driver/src/domain/auction.rs:412
↓ 16 callers
Method
serve
Serve the API on the given listener until `shutdown` resolves, then drain in-flight requests before returning.
crates/solana-orderbook/src/infra/api/mod.rs:100
↓ 16 callers
Function
u256_to_big_decimal
(u256: &U256)
crates/number/src/conversions.rs:78
↓ 16 callers
Method
uid
(&self, domain: &DomainSeparator, owner: Address)
crates/model/src/order.rs:249
↓ 16 callers
Method
with_state
(self, state: NewState)
crates/winner-selection/src/solution.rs:59
↓ 15 callers
Method
addLiquidity
(data: &[u8])
contracts/generated/contracts-generated/swaprrouter/src/lib.rs:1221
↓ 15 callers
Method
address
Extracts the pool address configured in the ID.
crates/driver/src/domain/liquidity/balancer/v2/mod.rs:20
↓ 15 callers
Function
append
( ex: &mut PgTransaction<'_>, events: &[(EventIndex, Event)], )
crates/database/src/events.rs:73
↓ 15 callers
Method
as_str
(&self)
crates/pool-indexer/src/config.rs:56
↓ 15 callers
Function
auction
(orders: Vec<Order>)
crates/solana-driver/src/domain/auction.rs:437
↓ 15 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/balancerv2weightedpool/src/lib.rs:4201
↓ 15 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/balancerv2stablepool/src/lib.rs:4551
↓ 15 callers
Method
contracts
Onchain smart contract bindings.
crates/driver/src/infra/blockchain/mod.rs:182
↓ 15 callers
Method
current_block
Returns a type that monitors the block chain to inform about the current block.
crates/driver/src/infra/blockchain/mod.rs:194
↓ 15 callers
Method
get
(&self, address: ð::TokenAddress)
crates/driver/src/domain/competition/auction.rs:179
↓ 15 callers
Method
insert
(&self, token: Address, result: CacheEntry)
crates/price-estimation/src/native_price_cache.rs:264
↓ 15 callers
Method
load
Load the signer the config names.
crates/cow-solana-signer/src/lib.rs:30
↓ 15 callers
Function
mock_api
()
crates/solana-orderbook/tests/api.rs:29
↓ 15 callers
Function
multiple_accounts_json
A `getMultipleAccounts` mock response, one entry per requested key in request order: an account JSON or `null` for an account that does not exist.
crates/solana-testlib/src/lib.rs:137
↓ 15 callers
Method
on_auction_overhead_start
( &'a self, component: &'b str, phase: &'c str, )
crates/observe/src/metrics.rs:193
↓ 15 callers
Function
resolve_for_test
(settlement: Settlement, payer: Pubkey)
crates/solana-driver/src/domain/settlement.rs:1203
↓ 15 callers
Function
solve_request
The autopilot's own literal `/solve` request JSON. The deadline is computed relative to now so the request is always solvable, regardless of when the
crates/solana-driver/tests/api.rs:276
↓ 15 callers
Function
web3
Create a Web3 instance with an optional label for observability.
crates/ethrpc/src/lib.rs:74
↓ 14 callers
Method
abi_encode
(&self)
contracts/generated/contracts-generated/izeroex/src/lib.rs:84
↓ 14 callers
Method
as_uint256
(self)
crates/liquidity-sources/src/balancer_v2/swap/fixed_point.rs:106
↓ 14 callers
Method
block
The hash and height of the confirmed block at `slot`.
crates/cow-solana-rpc/src/lib.rs:195
↓ 14 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/balancerv2basepool/src/lib.rs:3777
↓ 14 callers
Method
contains
(&self, address: &Address)
crates/shared/src/token_list.rs:100
↓ 14 callers
Function
create_test_order_placement
Builds an `EthOrderPlacement` with the given contract address embedded in the UID. # UID Structure (56 bytes total) The CoW Protocol Order UID has t
crates/refunder/src/refund_service.rs:359
↓ 14 callers
Function
encode
(registry: &prometheus::Registry)
crates/observe/src/metrics.rs:77
↓ 14 callers
Method
estimate_native_price
( &self, token: Address, timeout: Duration, )
crates/price-estimation/src/native_price_cache.rs:428
↓ 14 callers
Function
insert
Tries to associate the contract app data with the full app data. If this contract app data already existed then the existing full app data is returne
crates/database/src/app_data.rs:7
↓ 14 callers
Method
insert
( &mut self, block: u64, keys: impl IntoIterator<Item = K>, values: impl IntoI
crates/liquidity-sources/src/recent_block_cache.rs:457
↓ 14 callers
Function
install
Install a panic hook that first calls the previous panic hook and then exits the process. This prevents the situation where a background task/thread
crates/observe/src/panic_hook.rs:11
↓ 14 callers
Method
into_response
(self)
crates/orderbook/src/api.rs:462
↓ 14 callers
Function
mint_account
A plain mint in the base layout both token programs share, owned by `program`.
crates/solana-orderbook/tests/api.rs:1773
↓ 14 callers
Method
path
(&self, suffix: &str)
crates/liquidity-sources/src/uniswap_v3/pool_indexer.rs:56
↓ 14 callers
Function
pubkey
(byte: u8)
crates/solana-driver/src/infra/solver/dto/auction.rs:265
↓ 14 callers
Function
quote_request
A `/quote` request body for the given side.
crates/solana-driver/tests/api.rs:932
↓ 14 callers
Function
setup
Set up a mock external HTTP API.
crates/solvers/src/tests/mock/http.rs:127
↓ 14 callers
Function
snapshot
(entries: impl IntoIterator<Item = (Pubkey, Account)>)
crates/solana-driver/src/infra/blockchain/accounts.rs:179
↓ 14 callers
Method
to_f64
The nearest double, for hosts that compute fees in `f64`.
crates/fee-engine/src/fee_factor.rs:24
↓ 13 callers
Method
as_str
(&self)
crates/orderbook/src/orderbook.rs:62
↓ 13 callers
Function
batching
A solver batching up to `max_batch_size` orders, without back-off.
crates/solana-solvers/src/domain/solver/mod.rs:477
↓ 13 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/cowprotocoltoken/src/lib.rs:3967
↓ 13 callers
Method
chain
Returns the chain for the RPC connection.
crates/autopilot/src/infra/blockchain/mod.rs:48
↓ 13 callers
Method
client
(&self)
crates/e2e/src/setup/services.rs:893
↓ 13 callers
Method
evm_set_automine
(&self, automine: bool)
crates/ethrpc/src/alloy/evm_ext.rs:41
↓ 13 callers
Method
get
()
crates/autopilot/src/infra/persistence/mod.rs:1269
↓ 13 callers
Function
hash_full_app_data
Hash full app data to get the bytes expected to be set as the contract level app data.
crates/app-data/src/app_data_hash.rs:103
↓ 13 callers
Method
hash_struct
Returns the value of hashStruct() over the order data as defined by EIP-712. https://eips.ethereum.org/EIPS/eip-712#definition-of-hashstruct
crates/model/src/order.rs:222
↓ 13 callers
Function
into_stream
(receiver: CurrentBlockWatcher)
crates/ethrpc/src/block_stream.rs:278
↓ 13 callers
Method
kind
Check the kind field in the error response.
crates/driver/src/tests/setup/mod.rs:1497
↓ 13 callers
Function
mint_account_json
An initialized 6-decimal SPL Token mint, in the JSON shape a `getMultipleAccounts` mock answers with.
crates/solana-testlib/src/lib.rs:111
↓ 13 callers
Method
pool
The database handle the order, trades, and auction endpoints read from.
crates/solana-orderbook/src/infra/api/mod.rs:261
↓ 13 callers
Function
spawn_recording_solver_engine
A mock solver engine that also records the last `/solve` request body it received.
crates/solana-driver/tests/api.rs:186
↓ 13 callers
Method
store
(&self)
crates/event-indexing/src/event_handler.rs:253
↓ 13 callers
Method
swap
Computes a swap (including calldata, estimated input and output amounts and the required allowance) for the specified order. These computed swaps can
crates/solvers/src/infra/dex/mod.rs:24
↓ 13 callers
Method
token_account_state
Classify the state of the token account at `address` for a caller that creates missing token accounts idempotently. An account of either token progra
crates/solana-driver/src/infra/blockchain/accounts.rs:80
↓ 13 callers
Method
uid
( &self, contracts: &Contracts, ethflow_contract: &CoWSwapEthFlow::Instance, )
crates/e2e/tests/e2e/ethflow.rs:1016
↓ 13 callers
Method
with_buy_token
(mut self, buy_token: Address)
crates/model/src/order.rs:87
↓ 13 callers
Method
with_ethflow_addresses
(&mut self, addresses: Vec<Address>)
crates/refunder/src/traits.rs:105
↓ 13 callers
Method
with_sell_token
(mut self, sell_token: Address)
crates/model/src/order.rs:82
↓ 12 callers
Function
accounts_response
A `getMultipleAccounts` response listing `accounts` in request order, `None` for a missing account.
crates/solana-orderbook/tests/api.rs:1782
↓ 12 callers
Method
apply
Applies the solver fee to every trade of `solution`. If one trade fails a step, the whole solution is rejected and left untouched.
crates/solana-driver/src/domain/solver_fee.rs:102
↓ 12 callers
Function
apply_protocol_fees
Takes `policies` from the fill `fill` describes, in list order, each from the legs the one before left: a sell order delivers less buy token, a buy or
crates/protocol-fees/src/lib.rs:261
↓ 12 callers
Function
collect_log_changes
( factory: Address, logs: &[Log], base_states: &BasePoolStates, dec_cache: &DecimalsCache,
crates/pool-indexer/src/indexer/uniswap_v3.rs:1072
↓ 12 callers
Function
generate_owners_and_order_ids
Generates 1 unique user and the provided number of unique orders for that user.
crates/database/src/trades.rs:322
↓ 12 callers
Method
get
()
crates/pool-indexer/src/metrics.rs:54
↓ 12 callers
Method
get_solver_competition
( &self, hash: B256, )
crates/e2e/src/setup/services.rs:477
↓ 12 callers
Method
id
(&self)
crates/driver/src/infra/api/routes/solve/dto/solve_request.rs:127
↓ 12 callers
Function
initialize
Initializes tracing setup that is shared between the binaries. `env_filter` has similar syntax to env_logger. It is documented at https://docs.rs/trac
crates/observe/src/tracing/init.rs:34
↓ 12 callers
Method
is_winner
(self)
crates/winner-selection/src/state.rs:39
↓ 12 callers
Method
layer
(&self, inner: S)
crates/ethrpc/src/alloy/buffering.rs:67
↓ 12 callers
Method
multiple_accounts
Fetch accounts by key. Accounts that do not exist are absent from the map. Duplicate keys are fetched once, and batches above the server's per-request
crates/cow-solana-rpc/src/lib.rs:136
↓ 12 callers
Function
order
(sell: Address, buy: Address)
crates/fee-engine/src/evaluator.rs:225
↓ 12 callers
Function
program_id
The settlement program the tests run against: not the id the interface crate was compiled for, so a crate constant leaking into a check fails.
crates/solana-orderbook/tests/api.rs:1864
↓ 12 callers
Method
reset
Resets `previous_auction` and `last_checkpoint` to their default values.
crates/autopilot/src/run_loop.rs:120
↓ 12 callers
Function
run_forked_test_with_block_number
(f: F, fork_url: String, block_number: u64)
crates/e2e/src/setup/mod.rs:145
↓ 12 callers
Method
settlement
(&self)
crates/driver/src/infra/blockchain/contracts.rs:122
↓ 12 callers
Function
signature
(n: u8)
crates/solana-indexer/src/indexer/decoder/tests.rs:319
↓ 12 callers
Function
single_full_order_with_quote
( ex: &mut PgConnection, uid: &OrderUid, )
crates/database/src/orders.rs:731
↓ 12 callers
Function
spawn_server
Spawn the API server on an ephemeral port and return its bound address.
crates/solana-orderbook/tests/api.rs:56
↓ 12 callers
Function
spawn_sponsored_server_with
A sponsored-placement server whose mock RPC answers from `mocks`.
crates/solana-orderbook/tests/api.rs:1748
↓ 12 callers
Function
sponsored_mocks
The mock RPC answers to the blockhash and height probes, and `accounts` to the order account lookup, a `getMultipleAccounts` response.
crates/solana-orderbook/tests/api.rs:1733
↓ 12 callers
Method
state
(&self)
crates/winner-selection/src/solution.rs:68
↓ 12 callers
Function
token
(u: u64)
crates/price-estimation/src/native_price_cache.rs:595
↓ 12 callers
Function
token_2022_mint
An initialized Token-2022 mint with 6 decimals and the `extensions`, whose values `init` sets.
crates/solana-testlib/src/lib.rs:49
↓ 12 callers
Method
transfer
(data: &[u8])
contracts/generated/contracts-generated/erc20/src/lib.rs:1963
↓ 12 callers
Method
web3
(&self)
crates/driver/src/tests/setup/mod.rs:1312
↓ 11 callers
Function
add_order_and_trade
( ex: &mut PgTransaction<'_>, owner: Address, order_uid: OrderUid, event_index
crates/database/src/trades.rs:375
↓ 11 callers
Function
after_launch
()
crates/fee-engine/src/evaluator.rs:253
↓ 11 callers
Method
build
(config: &Config)
crates/driver/src/infra/persistence/mod.rs:46
↓ 11 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/mockerc4626wrapper/src/lib.rs:2659
↓ 11 callers
Method
call_builder
Creates a new call builder using this contract instance's provider and address. Note that the call can be any function call, not just those defined i
contracts/generated/contracts-generated/balancerv2vault/src/lib.rs:1642
↓ 11 callers
Function
classic_mint
An initialized mint of the classic SPL token program with `decimals`.
crates/solana-testlib/src/lib.rs:31
↓ 11 callers
Method
count
(&self, owner: Address)
crates/orderbook/src/database/orders.rs:513
↓ 11 callers
Function
domain_order
(side: Side)
crates/solana-driver/src/infra/solver/dto/auction.rs:330
← previous
next →
201–300 of 10,749, ranked by callers