Skip to main content

Prerequisites

  • Python 3.7 or higher
  • pip package manager
  • Aries API credentials (client ID and client secret)

Installation

Install the Aries Python SDK using pip:
pip install aries-exchange-sdk

Initialize the Client

from aries_exchange import AriesClient

# Initialize the client with your credentials
client = AriesClient(
    client_id="your_client_id",
    client_secret="your_client_secret"
)

Basic Operations

Get Account Information

# Retrieve user account details
accounts = client.accounts.get_user_accounts()
print(accounts)

Place a Market Order

# Place a simple market order
order = client.orders.place_order(
    symbol="AAPL",
    quantity=10,
    side="buy",
    order_type="market"
)
print(f"Order placed: {order}")

Search for Securities

# Search for a security
results = client.market_data.search("AAPL")
print(results)

Next Steps

Now that you have the basics working, explore the SDK’s capabilities:

Additional Resources