Metadata-Version: 2.1
Name: macpymessenger
Version: 0.1.0
Summary: A Python Interface for iMessage on MacOS
Home-page: https://github.com/ethan-wickstrom/macpymessenger
Author: Ethan Wickstrom
Author-email: e.t.wickstrom@wustl.edu
License: Apache License 2.0
Platform: Operating System :: MacOS :: MacOS X
Classifier: Environment :: Web Environment
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: Apache Software License
Classifier: Operating System :: MacOS
Classifier: Operating System :: MacOS :: MacOS X
Classifier: Programming Language :: Python
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.4
Classifier: Programming Language :: Python :: 3.5
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
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Programming Language :: Python :: Implementation :: PyPy
Classifier: Topic :: Internet :: WWW/HTTP :: Dynamic Content
Classifier: Topic :: Internet :: WWW/HTTP :: WSGI
Classifier: Topic :: Software Development :: Libraries
Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Software Development :: Libraries :: Application Frameworks
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Classifier: Topic :: Utilities
Requires-Python: >=3.8
Description-Content-Type: text/markdown
License-File: LICENSE

# 🚀💬 macpymessenger

macpymessenger is a Python library that provides a simple interface for sending iMessages on macOS. It allows you to send text messages programmatically using the Messages app on your Mac.

## Features

| Feature                   | Status |
|---------------------------|--------|
| Send text messages        | ✅     |
| Check compatibility       | ❌     |
| Send images               | ❌     |
| Send attachments          | ❌     |
| Receive messages          | ❌     |
| Group messaging           | ❌     |
| Bulk messaging            | ❌     |
| Message history retrieval | ❌     |
| Message status retrieval  | ❌     |

## 🔑 Installation

You can install macpymessenger using pip:

```bash
pip install macpymessenger
```

## 🧑🏽‍💻 Usage

Here's a simple example of how to use macpymessenger to send a text message:

```python
from i_py_messenger import IMessageClient, Configuration

config = Configuration()
client = IMessageClient(config)

phone_number = "1234567890"
message = "Hello, this is a test message sent using macpymessenger!"

success = client.send(phone_number, message)

if success:
    print("Message sent successfully!")
else:
    print("Failed to send the message.")
```

## ⚙️ Configuration

The `Configuration` class allows you to customize the paths to the AppleScript files used by macpymessenger. By default, it uses the following paths:

- `send_script_path`: `osascript/sendMessage.scpt`
- `check_compatibility_script_path`: `osascript/checkCompatibility.scpt`

You can modify these paths if needed by creating an instance of the `Configuration` class and setting the desired paths.

## 🧪 Testing

macpymessenger includes a test suite to ensure the functionality of the library. To run the tests, make sure you have the required dependencies installed and execute the following command:

```bash
python -m pytest test.py
```

The tests cover the following scenarios:
- Sending a message successfully
- Initializing the `Configuration` class
- Verifying the paths of the AppleScript files

## 📦 Project Structure

```
macpymessenger/
├── i_py_messenger/
│   ├── __init__.py
│   ├── configuration.py
│   ├── imessage_client.py
│   └── osascript/
│       └── sendMessage.scpt
├── .env.template
├── .github/
│   └── workflows/
│       └── python-publish.yml
├── LICENSE
├── README.md
├── requirements.txt
├── setup.py
└── test.py
```

## 📜 License

macpymessenger is licensed under the Apache License 2.0. See the [LICENSE](LICENSE) file for more information.

## 🤝 Contributing

Contributions to macpymessenger are welcome! If you find any issues or have suggestions for improvements, please open an issue or submit a pull request on the [GitHub repository](https://github.com/ethan-wickstrom/macpymessenger).

## 🙏 Acknowledgements

Originally forked from [Rolstenhouse/py-iMessage](https://github.com/Rolstenhouse/py-iMessage), macpymessenger was inspired by the need for a simple and intuitive way to send iMessages using Python on macOS. Special thanks to the developers of the libraries and tools used in this project.

## 📧 Contact

If you have any questions or inquiries, feel free to reach out to me:

- **Email:** e.t.wickstrom@wustl.edu
- **GitHub:** [ethan-wickstrom](https://github.com/ethan-wickstrom)

Thank you for using macpymessenger!
