AlgierexDevelopers
All SDKs

Python SDK

Python 3.9 or newer. Standard library only; pandas optional.

Install

pip install algierex            # or "algierex[pandas]" for to_frame()

Then set ALGIEREX_API_KEY to a key from the dashboard. On PyPI.

Example

from algierex import Algierex, PaymentRequiredError, to_frame

client = Algierex()  # reads ALGIEREX_API_KEY

try:
    prices = to_frame(client.get_prices("SAI", from_="2025-01-01"))
except PaymentRequiredError as err:
    raise SystemExit(err)  # no active plan: choose one on the dashboard

print(prices["close"].tail())

curve = client.get_yield_curve(date="2026-09-30")
print(curve["asOf"], curve["fit"]["rSquared"] if curve["fit"] else "not enough trades")

Methods

MethodReturns
list_tickers()List securitiesGET /tickers
get_prices(ticker, from_=, to=)Daily prices for one securityGET /prices/{ticker} (all pages)
list_sessions(market=, from_=, to=)Market sessionsGET /sessions (all pages)
get_dzair_index(from_=, to=)Dzair indexGET /index/dzair (all pages)
get_yield_curve(date=)OAT yield curveGET /yield-curve
list_fx()Latest exchange ratesGET /fx
get_fx_history(code, source=, from_=, to=)Exchange rate historyGET /fx/{code} (all pages)
get_calendar(from_=, to=, ticker=, locale=)Company events calendarGET /calendar (all pages)
list_news(ticker=, source=, from_=, to=, locale=, include_routine=)NewsGET /news (all pages)

Paged methods return every row. Each has an iter_ twin (iter_prices, iter_news, ...) that yields rows as pages arrive.

Errors and retries

Errors raise AlgierexError subclasses: BadRequestError (400), AuthenticationError (401), PaymentRequiredError (402), NotFoundError (404) and RateLimitError (429, with retry_after).

After a 429 the client waits the Retry-After time and tries again, up to 3 times. Server errors, timeouts and network failures are not retried. Field meanings for every response are in the docs.