Metadata-Version: 2.1
Name: tastytrade-api
Version: 0.1.0
Summary: A Python client for the Tastytrade API
Home-page: https://github.com/peter-oroszvari/tastytrade-api
Author: Peter Oroszvari
Author-email: peter@oroszvari.hu
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.6
Classifier: Programming Language :: Python :: 3.7
Classifier: Programming Language :: Python :: 3.8
Classifier: Programming Language :: Python :: 3.9
Classifier: Programming Language :: Python :: 3.10
Requires-Python: >=3.6
Description-Content-Type: text/markdown
License-File: LICENSE

# Tastytrade API

A Python client for the Tastytrade API, providing convenient access to Tastytrade's REST API for trading, account management, and more.

## Installation

Install the package using pip:

```bash
pip install tastytrade-api
```

## USAGE

Here's an example of how to use the Tastytrade API client:
```python
from tastytrade_api.authentication import TastytradeAuth

username = "your_username"
password = "your_password"

# Initialize the authentication object
auth = TastytradeAuth(username, password)

# Log in to the API
auth_data = auth.login()

if auth_data:
    print("Successfully logged in!")
else:
    print("Failed to log in.")

# Validate the session
is_valid = auth.validate_session()

if is_valid:
    print("Session is valid.")
else:
    print("Session is invalid or expired.")

# Destroy the session (log out)
if auth.destroy_session():
    print("Successfully logged out.")
else:
    print("Failed to log out.")
```

## Development

To run tests, first install the required development packages:

```bash
pip install -r requirements-dev.txt
```

Then, execute the tests using unittest:

```bash
python -m unittest discover
```

## License

This project is licensed under the MIT License. See the LICENSE file for details.



