The Axis Direct Rapid API Python client
Python library for Axis Direct trading API based on the documentation provided by the Axis Direct (RAPID API by Axis Direct). Axis Direct API.
RAPID API by Axis Direct is a powerful tool that expose many capabilities required to build a personalized Trading and Investment platform. Place orders, fetch user holdings, positions, orders, and more, with the simple HTTP API collection. This is not official library from the Axis Direct.
Documentation
Installing the client
You can install the latest release via pip
pip install --upgrade rapidapi-axisdirect
Requirements
'client_id' and 'authorization_key' are required to use this client. Read the official documentation for more information here
API usage
from rapidapi_axisdirect import AxisAPIClient
axis_client = AxisAPIClient(client_id="your_api_key-xxx-xxx-x", authorization_key="your_authorization_keyxx-xxx-x")
# Initialize the initiate_sso method with $redirectURL to get the SSO login url.
login_url = axis_client.initiate_sso('https://app.example.com/redirect-here')
# Redirect the user to the login url obtained ('login_url')
# User will be redirected to the given $redirectURL with 'ssoId' after the SSO login flow.
# Once you have the ssoId, obtain the authToken and subAccountId
data = axis_client.authenticate_sso('ssoId')
axis_client.set_session(data['metadata']['accounts'][0]['subAccountId'], data['authToken']['token'])
# Place an order
try:
order_resp = axis_client.place_order(order_ref_id="any_unique_remark",
script_id="11500112",
exchange='BSE',
transaction_type="BUY",
quantity=1,
segment='EQ,
order_type="MARKET",
product_type='DELIVERY',
validity_type='DAY')
print("Order placed- response: ", order_resp)
except Exception as e:
print("Failed. response: ", e.message)
# Fetch all orders by status
axis_client.get_order_book(order_status='open')
# Fetch the order history of a particular order.
axis_client.get_order_history("2024712987987")
# Get Security master
axis_client.get_security_master()
# Get the status of the market.
axis_client.get_market_status()
# Get holdings
axis_client.holdings(segment="EQ")
Changelog
Metadata
Release files for rapidapi-axisdirect 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| rapidapi_axisdirect-0.0.2.tar.gz | 10.0 kB | Without provenance | Details for rapidapi_axisdirect-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| rapidapi_axisdirect-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for rapidapi_axisdirect-0.0.2-py3-none-any.whl |
Total release size: 20.4 kB
Release files / rapidapi_axisdirect-0.0.2.tar.gz
| Download URL | rapidapi_axisdirect-0.0.2.tar.gz |
|---|---|
| Size | 10.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9be761f85591809acbb9c0112998480b952cb5d97ec636660f7021ad248c12fe
|
|
BLAKE2b-256 checksum How to use checksums |
108ea257b0989fcb2226dae02bcde64029e454a3c5079bd5a9c715c0e6ca6215
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.12.3
|
Release files / rapidapi_axisdirect-0.0.2-py3-none-any.whl
| Download URL | rapidapi_axisdirect-0.0.2-py3-none-any.whl |
|---|---|
| Size | 10.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
dc96d967665effad907eb132c0f17ccf01b56db88bb884993d7e7193c296688d
|
|
BLAKE2b-256 checksum How to use checksums |
fac72f48a7c1d696e8c36f1dfa6438c222d5acea28b83d4e351171b61c8b79e3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/5.1.0 CPython/3.12.3
|
Security for rapidapi-axisdirect 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.