Metadata-Version: 2.4
Name: embipay
Version: 1.0.0
Summary: Python SDK for EmbiPay Admin and Agent APIs
Home-page: https://github.com/EmbiPay/EmbiPay-SDK-Python
Author: EmbiPay
License: ISC
Keywords: embipay sdk payments loans wallets
Classifier: Development Status :: 4 - Beta
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: ISC License (ISCL)
Classifier: Programming Language :: Python :: 3
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: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.8
Description-Content-Type: text/markdown
Dynamic: author
Dynamic: classifier
Dynamic: description
Dynamic: description-content-type
Dynamic: home-page
Dynamic: keywords
Dynamic: license
Dynamic: requires-python
Dynamic: summary

# EmbiPay Python SDK

Client library for EmbiPay Admin and Agent APIs.

## Installation

```bash
pip install embipay
```

Or install from source for development:

```bash
git clone https://github.com/EmbiPay/EmbiPay-SDK-Python.git
cd EmbiPay-SDK-Python
pip install -e .
```

## Usage

### Admin API

```python
from embipay import EmbiPayAdmin

admin = EmbiPayAdmin(
    "https://embi-pay-dashboard.vercel.app",
    "your_admin_api_token"
)

# Create wallet
result = admin.create_wallet(owner_user_id="uuid-from-supabase-auth", balance=100)
wallet = result["wallet"]

# Create pool
result = admin.create_shared_pool("resource-123", 50)
pool = result["pool"]

# Contribute to pool
admin.contribute_to_pool(pool["pool_id"], wallet["agent_id"], 10, usage_limit=5)

# Approve loan
admin.approve_loan(5)

# Record repayment
admin.record_repayment(5, 100, "Paid in full")
```

### Agent API

```python
from embipay import EmbiPayAgent

agent = EmbiPayAgent(
    "https://embi-pay-dashboard.vercel.app",
    "your_agent_key"
)

tasks = agent.fetch_tasks()
agent.complete_task(tasks["tasks"][0]["id"], "completed", "Done")
```
