Skip to main content

Python client for the SoSoValue API returning pandas DataFrames

Project description

sosovalue-pandas

Python client for the SoSoValue API that returns data as pandas DataFrames.

Installation

uv add sosovalue-pandas
# or
pip install sosovalue-pandas

Quick start

from sosovalue_pandas import SoSoValueClient

with SoSoValueClient(api_key="your-api-key") as client:
    # ETF inflows for a single type (~300 daily points)
    df = client.get_etf_historical_inflow_chart("us-btc-spot")

    # All supported ETF types in one DataFrame
    df_all = client.get_all_etf_inflows()

    # All listed cryptocurrencies
    df_currencies = client.get_all_listed_currencies()

API reference

SoSoValueClient(api_key, base_url, timeout)

Method Description
get_etf_historical_inflow_chart(etf) ~300 daily points for one ETF type
get_all_etf_inflows() All ETF types concatenated
get_all_listed_currencies() All listed cryptocurrencies

ETF types

from sosovalue_pandas import ETF_TYPES
# ["us-btc-spot", "us-eth-spot", "us-sol-spot", "us-doge-spot",
#  "us-ltc-spot", "us-link-spot", "us-avax-spot"]

ETF inflow columns

Column Type Description
date datetime64 Trading date
totalNetInflow float Daily net inflow (USD)
totalValueTraded float Total value traded (USD)
totalNetAssets float Total net assets (USD)
cumNetInflow float Cumulative net inflow (USD)
etf str ETF type identifier

Currencies columns

Column Type Description
currencyId int Unique identifier
fullName str Full name (e.g. "Bitcoin")
currencyName str Ticker symbol (e.g. "BTC")

Error handling

from sosovalue_pandas import SoSoValueClient, SoSoValueError

with SoSoValueClient(api_key="...") as client:
    try:
        df = client.get_etf_historical_inflow_chart("us-btc-spot")
    except SoSoValueError as e:
        print(f"API error: {e}")

API key

Get your API key from SoSoValue OpenAPI.

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sosovalue_pandas-0.1.1.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sosovalue_pandas-0.1.1-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file sosovalue_pandas-0.1.1.tar.gz.

File metadata

  • Download URL: sosovalue_pandas-0.1.1.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.0 {"installer":{"name":"uv","version":"0.10.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sosovalue_pandas-0.1.1.tar.gz
Algorithm Hash digest
SHA256 039a3584069a05b77e0bfee9d461402fe987c9fbffbde10003c486bc626ed543
MD5 baa82d888aea297bb28f220e79c00d76
BLAKE2b-256 064c4ad13ae8b80b8b89ba63342f7d2c084499bee7ef809910414a69147145bb

See more details on using hashes here.

File details

Details for the file sosovalue_pandas-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: sosovalue_pandas-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 4.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.0 {"installer":{"name":"uv","version":"0.10.0","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":null,"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for sosovalue_pandas-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e74cedd6604c980cf40143b0bb5aed45485d9832531031d46da796f8a608f2a8
MD5 fe05de9f588d88ecf7912041749a9dce
BLAKE2b-256 837be0f8bd85b50d6c4d4807c7666389eea257bd04000feaeffc3f1b46dde02f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page