Skip to main content

trading sdk for alphasec orderbook dex

Project description

Alphasec Python SDK

A trading SDK for the Alphasec orderbook DEX.

PyPI version License: MIT

🔗 Links

🚀 Quick Start

Install

pip install alphasec-py

Installed as alphasec-py, imported as alphasec.

Configure (required for examples)

cd examples
cp config.json.example config/config.json
# Then edit config.json and fill your values

Minimal config.json

{
  "network": "kairos",
  "api_url": "https://api.alphasec.trade",
  "l1_address": "0x...your_L1_address",
  "l1_wallet": "0x...your_L1_private_key",
  "l2_wallet": "0x...your_L2_private_key",
  "session_enabled": false
}

Run an example

python examples/market_data/basic_tickers.py

🌐 Network Information

Kairos Testnet

  • API URL: https://api-testnet.alphasec.trade
  • Websocket URL: wss://api-testnet.alphasec.trade/ws
  • Network: kairos
  • L1 Chain ID: 1001 (Kaia Kairos)
  • L2 Chain ID: 41001 (AlphaSec L2)

Mainnet

  • API URL: https://api.alphasec.trade
  • Websocket URL: wss://api.alphasec.trade/ws
  • Network: mainnet
  • L1 Chain ID: 8217 (Kaia Mainnet)
  • L2 Chain ID: 48217 (AlphaSec L2)

🔐 Security

⚠️ Important Security Notes:

  • Never commit private keys to version control
  • Use environment variables or secure key management
  • Always test on kairos testnet before mainnet
  • Verify transaction details before signing
  • Blockchain transactions are irreversible

⚠️ Disclaimer

This SDK is provided as-is. Trading cryptocurrencies involves substantial risk and may result in significant losses. Always do your own research and never invest more than you can afford to lose. The developers are not responsible for any trading losses incurred while using this SDK.

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

alphasec_py-0.1.3.tar.gz (39.9 kB view details)

Uploaded Source

Built Distribution

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

alphasec_py-0.1.3-py3-none-any.whl (53.1 kB view details)

Uploaded Python 3

File details

Details for the file alphasec_py-0.1.3.tar.gz.

File metadata

  • Download URL: alphasec_py-0.1.3.tar.gz
  • Upload date:
  • Size: 39.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for alphasec_py-0.1.3.tar.gz
Algorithm Hash digest
SHA256 09aa586fbf40710839812778b797d13010afe93bef5da3fe0b1235d1013ae2e0
MD5 36050ba86cfc5c250c77d2f60183ed65
BLAKE2b-256 1402335ab8cc0988028dc74ba6ba77b40c119eb716998c2cb3b37b43997297f4

See more details on using hashes here.

File details

Details for the file alphasec_py-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: alphasec_py-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 53.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.13

File hashes

Hashes for alphasec_py-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 5a27908a9edbb4d551bb9bc7813f2130aa90b30affbbd8de72ca375a5154d789
MD5 c6ec400d615877c03d264a6e0f621704
BLAKE2b-256 3b9d0849629633d88ea364f5a8490b93a09b2bb71d8057d67b50f0a76fde88e4

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