Skip to content

Conversation

@squadgazzz
Copy link
Contributor

@squadgazzz squadgazzz commented Jan 12, 2026

Description

Once we started forwarding native price estimates from the Orderbook to Autopilot, CoinGecko API usage went up. This happened because the estimator was disabled in the Orderbook and moved to Autopilot, which now handles all requests and also relies on CoinGecko.

This PR refactors the native price estimator by pulling the cache layer into a shared component, so it’s reused across all native price estimator instances. An optional native price estimation config is introduced that is used specifically for the estimation requests received through the API. In case of the config's absence, the main set of estimators is used. That way we configure a different price estimator to serve the Autopilot API.

The native price initialization is also moved right into the constructor. Not sure why it was a separate step initially.

How to test

Existing tests.

@squadgazzz squadgazzz marked this pull request as ready for review January 12, 2026 17:41
@squadgazzz squadgazzz requested a review from a team as a code owner January 12, 2026 17:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants