Add QuickNode add-on helpers, exports, tests, and cluster feature wiring#20
Add QuickNode add-on helpers, exports, tests, and cluster feature wiring#20RachitSrivastava12 wants to merge 5 commits into
Conversation
- getQuickNodePriorityFeesFactory: fetches live fee estimates from QuickNode's qn_estimatePriorityFees API with 5 levels (low/medium/ recommended/high/extreme) plus network congestion score - getAssetsByOwnerFactory: queries NFTs, cNFTs and tokens via QuickNode's Metaplex DAS API - getAssetFactory: fetches full details for a single digital asset Both add-ons are FREE on QuickNode endpoints. Enable at: https://dashboard.quicknode.com
mikemaccana
left a comment
There was a problem hiding this comment.
Great work Rachit! I really appreciate how comprehensive this is. I have a few changes suggested but once they're done we should be able to get this in soon!
| isNameKnownToSolanaExplorer: false, | ||
| // TODO: add support for QuickNode priority fee API | ||
| // QuickNode exposes a separate qn_estimatePriorityFees helper API, but | ||
| // the core smart-transaction path still uses standard recent fee fallback. |
There was a problem hiding this comment.
Thanks for adding support here! We actually think it's awesome - anyone with a Quicknode RPC should use it by default! Please add:
supportsQNEstimatePriorityFees: true
And update the PR so Quicknode users use it!
| const { | ||
| webSocketURL: derivedWsUrl, | ||
| features, | ||
| } = getClusterDetailsFromClusterConfig(clusterName, clusterDetails); |
There was a problem hiding this comment.
This looks like a formatting change - please use the existing formatting settings, otherwise the PR has a bunch of noise in it.
|
|
||
| let supportsGetPriorityFeeEstimate = false; | ||
| let needsPriorityFees = false; | ||
| let enableClientSideRetries = false; |
There was a problem hiding this comment.
Why are you moving these?
| @@ -0,0 +1,1966 @@ | |||
| /** | |||
| * QuickNode-specific helpers for Kite | |||
There was a problem hiding this comment.
lowercase 'n' (yes we changed it) - just 'Quicknode' now!
Please fix this everywhere!
| * Get a free endpoint at: https://dashboard.quicknode.com | ||
| * | ||
| * Add-ons used: | ||
| * - Solana Priority Fee API (FREE) → getQuickNodePriorityFeesFactory |
There was a problem hiding this comment.
The FREE/PAID will change over time - best to keep it in one place - remove it from here and just let the dashboard determine what's free and paid.
| outAmount: string; | ||
| minOutAmount: string; | ||
| price_impact?: string; | ||
| priceImpact?: string; |
There was a problem hiding this comment.
This API is stupid. You should explicitly call it out for having price_impact and priceImpact, tell me if one or the other is deprecated, add a URL to the github issue where you have raised this as a bug.
| inAmount: quote.inAmount, | ||
| outAmount: quote.outAmount, | ||
| minOutAmount: quote.minOutAmount, | ||
| priceImpact: quote.price_impact ?? quote.priceImpact ?? "0", |
There was a problem hiding this comment.
This is good. Postel's law.
Just add a comment saying // This API sucks, see comment above or similar.
| name: quote.inToken.name, | ||
| symbol: quote.inToken.symbol, | ||
| decimals: quote.inToken.decimals, | ||
| }, |
There was a problem hiding this comment.
Could you not do inToken = quote.inToken and outToken = quote = quote.outToken?
| groupKey: "collection", | ||
| groupValue: options.collectionMint, | ||
| limit: options.limit ?? 100, | ||
| page: options.page ?? 1, |
There was a problem hiding this comment.
Don't line up code like this. Just use prettier. Have your editor format on save.
| return isQuickNodeRpcUrl(normalized) ? "https://public.jupiterapi.com" : normalized; | ||
| }; | ||
|
|
||
| const resolveOpenOceanBase = (endpointUrl: string) => { |
There was a problem hiding this comment.
OK this file is getting too large - I want you to chaneg the PR so:
lib/quicknode/addons/openocean.ts
lib/quicknode/addons/openocean.test.ts
Claude will do this for you easily!
|
Hey @mikemaccana i’ve updated the PR and applied the changes:
|
Summary
This PR adds QuickNode add-on support to Kite as an additive extension, without changing the existing core helper APIs.
The main work is:
createKitePluginactually respects cluster config instead of hardcoding the transaction feature flagsWhat was added
QuickNode helper support was added in:
src/lib/quicknode.tsExports were added in:
src/index.tsTests were added/updated in:
src/tests/quicknode.test.tsCluster/config cleanup was done in:
src/lib/clusters.tssrc/lib/connect.tsQuickNode functionality covered
Free add-ons:
Paid add-on helper surface:
Yellowstone was intentionally not included.
Important fixes made
1. Real endpoint/path corrections
Several helper paths and payload assumptions were updated to match real QuickNode behavior:
/quoteand/swaproutes/pump-fun/swaproute/addon/807/v4/solana/...amountDecimals2. MEV send path correction
The Merkle/Blink helpers were changed to use the real exposed
sendTransactionpath instead of unsupported custom RPC method assumptions.3. Cluster feature wiring
createKitePluginwas previously hardcoding transaction feature flags tofalse.This PR updates that wiring so known cluster config features are actually respected.
4. Export surface cleanup
Unsupported Pump.fun market-data helper exports were removed from the public package surface so the PR does not claim undocumented functionality.
Validation performed
Build verification
npm run buildpassesLive verification performed
Live checks were performed against a real QuickNode endpoint for the free add-ons / free-access paths:
What was not fully live-tested
Paid add-ons were not fully live-tested end-to-end because no paid-enabled endpoint was available in this validation pass.
Also not fully proven end-to-end:
Notes
This PR is additive and is intended to extend Kite’s QuickNode support without changing unrelated existing functionality.