Skip to main content

Ordernet

A small, typed Python client and command-line tool for the OrderNet Spark API. It currently supports Spark authentication, account discovery, and total balance lookup for the nesua, meitav, and psagot broker hosts.

This is an unofficial client. Do not use it as the sole source for financial decisions, and never commit Spark credentials or bearer tokens.

Installation

python -m pip install ordernet

Python API

from ordernet_api import Broker, OrdernetClient

client = OrdernetClient(Broker.MEITAV)
client.authenticate("username", "password")

for account in client.get_accounts():
    print(account.number, client.get_account_balance(account))

Balances are returned as decimal.Decimal values to avoid floating-point rounding surprises.

Command line

Let the command prompt securely for the password:

ordernet --username 1234 --broker meitav

Or supply it through the environment and optionally restrict the lookup:

export ORDERNET_PASSWORD='your-password'
ordernet -u 1234 -b meitav -a ACC_000-111111

Passing --password is supported for compatibility, but can expose the secret in shell history and process listings.

Development

uv sync --dev
./scripts/check.sh
./scripts/build.sh

The project uses Ruff for linting and formatting, ty for type checking, and the standard-library test runner. Development dependencies are locked in uv.lock.

Install Lefthook once, then enable the repository's pre-commit checks:

lefthook install

The hook runs linting, formatting checks, type checking, and tests before each commit.

Releasing

GitHub Actions runs the quality suite and tests Python 3.10 through 3.13 on every pull request and push to main. Version tags build and publish through PyPI Trusted Publishing:

uv version --bump patch
git add pyproject.toml uv.lock
git commit -m "Release v0.1.1"
git tag v0.1.1
git push origin main v0.1.1

Before the first release, configure a pending PyPI Trusted Publisher for GitHub owner ereli, repository Ordernet, workflow release.yml, and environment pypi. No PyPI API token is stored in GitHub.

Credits

Courtesy shout-out to Assaf Morami for publishing OrdernetAPI, which helped inspire this project.

License

GPL-3.0-only. See LICENSE.

Download files

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

Source Distribution

ordernet-0.1.2.tar.gz (18.6 kB view details)

Uploaded Source

Built Distribution

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

ordernet-0.1.2-py3-none-any.whl (19.1 kB view details)

Uploaded Python 3

File details

Details for the file ordernet-0.1.2.tar.gz.

File metadata

  • Download URL: ordernet-0.1.2.tar.gz
  • Upload date:
  • Size: 18.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ordernet-0.1.2.tar.gz
Algorithm Hash digest
SHA256 b1dfda9a7a74054a5b97f7e9bc5678c2bd4ba121ed3ee8de1b6d1d3951f3ee4a
MD5 fc1f28d62f2d2ce38fc6d55b55db39b8
BLAKE2b-256 a1788ec2b3c4808a0ee9866c41ed2a818a23204e9ed4b7187b5095b27976e001

See more details on using hashes here.

Provenance

The following attestation bundles were made for ordernet-0.1.2.tar.gz:

Publisher: release.yml on ereli/Ordernet

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file ordernet-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: ordernet-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 19.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ordernet-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 7d670f650a6496d4ea0535e754c07c69e4e114f290e80b0ca56aa345e546bc76
MD5 5c9ea3a521f79b890abbba924bc9dcc8
BLAKE2b-256 e63557149183df821963dc2abe434417b328b7eb5df804e5a6419676a521b9e1

See more details on using hashes here.

Provenance

The following attestation bundles were made for ordernet-0.1.2-py3-none-any.whl:

Publisher: release.yml on ereli/Ordernet

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

This release

0.1.2 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page