Skip to main content

ArkhamClient

Struct ArkhamClient 

Source
pub struct ArkhamClient { /* private fields */ }
Expand description

HTTP client for Arkham Intel’s public data API.

Implementations§

Source§

impl ArkhamClient

Source

pub fn new() -> Result<Self, TailFinError>

Build a Chrome-145-emulated client. The TLS fingerprint is overkill for api.arkm.com (vanilla curl works), but keeps us aligned with the SPA and inoculates against future Cloudflare tightening.

Source

pub async fn signed_get( &self, path: &str, query_pairs: &[(&str, &str)], ) -> Result<Value, TailFinError>

Call any signed GET endpoint and return the response body as Value. Public so library users can hit endpoints we haven’t typed yet.

Source

pub async fn search(&self, query: &str) -> Result<SearchResults, TailFinError>

Search across entities, tokens, and pools.

Source

pub async fn address_enriched( &self, address: &str, ) -> Result<AddressEnriched, TailFinError>

Cross-chain enriched profile for an EVM-style address.

Source

pub async fn transfers( &self, q: &TransfersQuery<'_>, ) -> Result<TransfersPage, TailFinError>

Page of transfers matching the filter. Pass TransfersQuery::default for a default scan, or populate fields like base, flow, usd_gte, sort_key/sort_dir, limit, offset to filter and paginate.

Source

pub async fn balances_address( &self, address: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn counterparties_address( &self, address: &str, chains: Option<&str>, flow: Option<&str>, time_last: Option<&str>, usd_gte: Option<&str>, limit: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn flow_address( &self, address: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn history_address( &self, address: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_address( &self, address: &str, chain: &str, ) -> Result<Value, TailFinError>

Single-chain /intelligence/address/{address} (NOT the /all variant).

Source

pub async fn intelligence_address_all( &self, address: &str, ) -> Result<Value, TailFinError>

All-chain /intelligence/address/{address}/all.

Source

pub async fn intelligence_address_enriched_chain( &self, address: &str, chain: &str, ) -> Result<Value, TailFinError>

Single-chain enriched profile (vs address_enriched() which is /all).

Source

pub async fn intelligence_contract( &self, chain: &str, address: &str, ) -> Result<Value, TailFinError>

Source

pub async fn loans_address( &self, address: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn portfolio_address( &self, address: &str, time: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES time (unix milliseconds string). Returns 400 “invalid unix millisecond time” without it.

Source

pub async fn portfolio_timeseries_address( &self, address: &str, pricing_id: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES pricing_id. Returns 400 “missing pricingId” without it.

Source

pub async fn volume_address( &self, address: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn balances_entity( &self, entity: &str, chains: Option<&str>, cheap: Option<bool>, ) -> Result<Value, TailFinError>

Source

pub async fn counterparties_entity( &self, entity: &str, chains: Option<&str>, flow: Option<&str>, time_last: Option<&str>, usd_gte: Option<&str>, limit: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn flow_entity( &self, entity: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn history_entity( &self, entity: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn loans_entity( &self, entity: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn portfolio_entity( &self, entity: &str, time: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES time (unix milliseconds string). Returns 400 “invalid unix millisecond time” without it.

Source

pub async fn portfolio_timeseries_entity( &self, entity: &str, pricing_id: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES pricing_id. Returns 400 “missing pricingId” without it.

Source

pub async fn volume_entity( &self, entity: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_entity( &self, entity: &str, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_entity_summary( &self, entity: &str, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_entity_predictions( &self, entity: &str, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_entity_balance_changes( &self, order_by: &str, order_dir: &str, interval: &str, limit: u32, chains: Option<&str>, entity_types: Option<&str>, entity_ids: Option<&str>, offset: Option<u32>, ) -> Result<Value, TailFinError>

Recent balance changes across entities. Server REQUIRES four params — order_by, order_dir, interval, and limit. Without interval the server returns 400; without limit it returns 500. Valid order_by: balanceUsd | balanceUsdChange | balanceUsdPctChange | balanceUnit | balanceUnitChange | balanceUnitPctChange. Valid interval: 7d | 14d | 30d.

Source

pub async fn intelligence_entity_types(&self) -> Result<Value, TailFinError>

Source

pub async fn token_addresses(&self, id: &str) -> Result<Value, TailFinError>

Source

pub async fn token_balance_by_addr( &self, chain: &str, token_address: &str, entity_id: Option<&str>, holder_address: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn token_balance_by_id( &self, id: &str, entity_id: Option<&str>, holder_address: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn token_holders_by_addr( &self, chain: &str, token_address: &str, group_by_entity: Option<bool>, limit: Option<u32>, offset: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn token_holders_by_id( &self, id: &str, group_by_entity: Option<bool>, limit: Option<u32>, offset: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn token_market(&self, id: &str) -> Result<Value, TailFinError>

Source

pub async fn token_price_history_by_addr( &self, chain: &str, token_address: &str, daily: Option<bool>, ) -> Result<Value, TailFinError>

Source

pub async fn token_price_history_by_id( &self, id: &str, daily: Option<bool>, ) -> Result<Value, TailFinError>

Source

pub async fn token_price_change( &self, id: &str, past_time: &str, ) -> Result<Value, TailFinError>

Server REQUIRES past_time as an RFC 3339 timestamp (e.g. 2025-12-01T00:00:00Z) — NOT a Go duration. Server returns 400 “missing pastTime query param” without it, “invalid pastTime format” with anything that doesn’t parse as RFC 3339.

Source

pub async fn token_top( &self, timeframe: &str, order_by_agg: &str, order_by_percent: bool, order_by_desc: bool, from: u32, size: u32, chains: Option<&str>, ) -> Result<Value, TailFinError>

Top tokens. Server REQUIRES four params — timeframe, order_by_agg, order_by_percent, from, order_by_desc, AND size — six required params total. Server returns 400 naming whichever is missing. from is the pagination start (0 for the first page). Note order_by_agg here is distinct from the order_by param on /intelligence/entity_balance_changes.

Source

pub async fn token_top_flow_by_addr( &self, chain: &str, token_address: &str, time_last: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES time_last (Go duration: 1h, 24h, 7d, 30d). Returns 400 “invalid timeLast” without it.

Source

pub async fn token_top_flow_by_id( &self, id: &str, time_last: &str, chains: Option<&str>, ) -> Result<Value, TailFinError>

Server REQUIRES time_last. See [token_top_flow_by_addr].

Source

pub async fn token_volume_by_addr( &self, chain: &str, token_address: &str, time_last: &str, granularity: &str, ) -> Result<Value, TailFinError>

Server REQUIRES granularity as a Go duration string (1h, 1d, 30m, etc. — NOT keywords like hourly/daily). Returns 400 “missing granularity” or “invalid duration” otherwise. time_last is also de-facto required by the server.

Source

pub async fn token_volume_by_id( &self, id: &str, time_last: &str, granularity: &str, ) -> Result<Value, TailFinError>

Server REQUIRES granularity and time_last. See [token_volume_by_addr].

Source

pub async fn token_arkham_exchange_tokens(&self) -> Result<Value, TailFinError>

Source

pub async fn intelligence_token_by_addr( &self, chain: &str, address: &str, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_token_by_id( &self, id: &str, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_addresses_updates( &self, since: Option<&str>, limit: Option<u32>, page_token: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_entities_updates( &self, since: Option<&str>, limit: Option<u32>, page_token: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_tags_updates( &self, since: Option<&str>, limit: Option<u32>, page_token: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn intelligence_address_tags_updates( &self, since: Option<&str>, limit: Option<u32>, page_token: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn transfers_histogram( &self, q: &TransfersQuery<'_>, granularity: Option<&str>, ) -> Result<Value, TailFinError>

Source

pub async fn transfers_histogram_simple( &self, q: &TransfersQuery<'_>, ) -> Result<Value, TailFinError>

Source

pub async fn transfers_tx( &self, hash: &str, transfer_type: &str, chain: &str, ) -> Result<Value, TailFinError>

Server REQUIRES chain. Returns 400 “could not parse chain” without it.

Source

pub async fn tx(&self, hash: &str) -> Result<Value, TailFinError>

Source

pub async fn swaps( &self, base: Option<&[&str]>, chains: Option<&str>, flow: Option<&str>, time_last: Option<&str>, usd_gte: Option<&str>, sort_key: Option<&str>, sort_dir: Option<&str>, limit: Option<u32>, offset: Option<u32>, ) -> Result<Value, TailFinError>

base mirrors /transfers (repeated ?base=A&base=B for multi).

Source

pub async fn cluster_summary(&self, id: &str) -> Result<Value, TailFinError>

Source

pub async fn tag_params( &self, id: &str, limit: Option<u32>, offset: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn tag_summary(&self, id: &str) -> Result<Value, TailFinError>

Source

pub async fn balances_solana_subaccounts_address( &self, addresses: &str, pricing_id: &str, limit: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn balances_solana_subaccounts_entity( &self, entities: &str, pricing_id: &str, limit: Option<u32>, ) -> Result<Value, TailFinError>

Source

pub async fn chains(&self) -> Result<Value, TailFinError>

Source

pub async fn networks_status(&self) -> Result<Value, TailFinError>

Source

pub async fn networks_history(&self, chain: &str) -> Result<Value, TailFinError>

Source

pub async fn altcoin_index(&self) -> Result<Value, TailFinError>

Source

pub async fn arkm_circulating(&self) -> Result<Value, TailFinError>

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.