#!/usr/bin/env python3
"""
Quick import test for route402 package
"""
import sys
from pathlib import Path

# Add package to path
sys.path.insert(0, str(Path(__file__).parent))

try:
    # Test imports
    from route402 import Route402Client, Payment, PaymentStatus, Chain
    from route402.exceptions import Route402Error, APIError, PaymentError, ValidationError

    print("✅ All imports successful!")
    print(f"   - Route402Client: {Route402Client}")
    print(f"   - Payment: {Payment}")
    print(f"   - PaymentStatus: {PaymentStatus}")
    print(f"   - Chain: {Chain}")
    print(f"   - Exceptions: {Route402Error.__name__}, {APIError.__name__}")

    # Test client initialization
    client = Route402Client(api_key="test_key")
    print(f"\n✅ Client initialized successfully!")
    print(f"   - API URL: {client.api_url}")
    print(f"   - API Key: {client.api_key[:10]}...")

    # Test enums
    print(f"\n✅ Enums work correctly!")
    print(f"   - PaymentStatus.CONFIRMED: {PaymentStatus.CONFIRMED.value}")
    print(f"   - Chain.BASE: {Chain.BASE.value}")

    print("\n🎉 Package is working correctly!")
    sys.exit(0)

except ImportError as e:
    print(f"❌ Import error: {e}")
    sys.exit(1)
except Exception as e:
    print(f"❌ Error: {e}")
    sys.exit(1)
