Skip to main content

near-account-py

Python package for account management on the NEAR Protocol.

Python 3.9+ | pip install near-account-py


Installation

pip install near-account-py


Quick Start

from near_account_py import NearAccountPyClient

client = NearAccountPyClient() # defaults to mainnet RPC

Check if an account exists

exists = client.account_exists("alice.near")

Get account details

account = client.get_account("alice.near")

Get balance

balance = client.get_balance("alice.near")


Usage

client = NearAccountPyClient( rpc_url="https://rpc.mainnet.near.org", # optional timeout=30 # optional )

Available Methods

Method Description
get_account(account_id) Fetch account state
account_exists(account_id) Check if account exists
get_balance(account_id) Get account balance
get_access_keys(account_id) List access keys
send_transaction(signed_tx) Submit a signed transaction (sync)
send_transaction_async(signed_tx) Submit a signed transaction (async)
get_block(block_id) Fetch block by ID or "latest"
get_network_info() Retrieve network info
get_gas_price(block_id) Get gas price for a block

Networks

Testnet

client = NearAccountPyClient(rpc_url="https://rpc.testnet.near.org")


License

MIT

Download files

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

Source Distribution

near_account_py-1.0.0.tar.gz (3.1 kB view details)

Uploaded Source

Built Distribution

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

near_account_py-1.0.0-py3-none-any.whl (3.5 kB view details)

Uploaded Python 3

File details

Details for the file near_account_py-1.0.0.tar.gz.

File metadata

  • Download URL: near_account_py-1.0.0.tar.gz
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.13.12

File hashes

Hashes for near_account_py-1.0.0.tar.gz
Algorithm Hash digest
SHA256 d7b1cf4b09f9f1dd0fcc189f144bf77d883796d3c85496285a977ff2b2ab13e8
MD5 e2cb506684fd67088c2d4ab453867292
BLAKE2b-256 2680883089d4f30a6643864d2139ae23fcd74ff84aac37edda67a6bb5ce09011

See more details on using hashes here.

File details

Details for the file near_account_py-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for near_account_py-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 d50350c6edf708b1627bc986496860b7b4c1de440b1a36b336bf9ff8240dd8a2
MD5 11e8945e873485274f0a3516c94feb4b
BLAKE2b-256 6ac852f209e43ee6a7210c9ba007ba08634a7d9e42696e242869a8b080272ca4

See more details on using hashes here.

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 files

Supported by

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