Shrijanagain commited on
Commit
879b5df
·
verified ·
1 Parent(s): ad6f538

Upload 3 files

Browse files
Files changed (3) hide show
  1. Wallet.py +24 -0
  2. __init__.py +18 -0
  3. utils.py +28 -0
Wallet.py ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ # Yeh bina entity secret ke - old API use karta hai
2
+
3
+ import requests
4
+ import uuid
5
+
6
+ API_KEY = "TEST_API_KEY:b1beeb711246a7b7206dcaf9c16d92fe:fb82a6566d5d81123f3cad2094f8cff1"
7
+
8
+ # Try old endpoint
9
+ headers = {
10
+ "Authorization": f"Bearer {API_KEY}"
11
+ }
12
+
13
+ # Direct wallet create (without wallet set)
14
+ resp = requests.post(
15
+ "https://api-sandbox.circle.com/v1/wallets", # Old endpoint
16
+ headers=headers,
17
+ json={
18
+ "idempotencyKey": str(uuid.uuid4()),
19
+ "blockchain": "MATIC-AMOY"
20
+ }
21
+ )
22
+
23
+ print(f"Old API Status: {resp.status_code}")
24
+ print(resp.text[:500])
__init__.py ADDED
@@ -0,0 +1,18 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ __init__.py - SKT OMNI-ARC V49 Package
3
+ Central initialization for all modules.
4
+ """
5
+
6
+ __version__ = "49.0.0"
7
+ __author__ = "Shrijan Kumar Tiwari | SKT AI Labs"
8
+
9
+ # Import main modules for easy access
10
+ from .arc_relayer import arc_relayer
11
+ from .security import security
12
+
13
+ # Version banner
14
+ print(f"🚀 SKT OMNI-ARC v{__version__} initialized")
15
+ print(" Modules loaded: security, arc_relayer")
16
+
17
+ # Expose key objects
18
+ __all__ = ['arc_relayer', 'security', 'generate_session_id']
utils.py ADDED
@@ -0,0 +1,28 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ """
2
+ utils.py - SKT OMNI-ARC V49 Utilities
3
+ Common helper functions for formatting, timing, and logging.
4
+ """
5
+
6
+ import time
7
+ from datetime import datetime
8
+
9
+ def format_usdc(amount: float) -> str:
10
+ """Format amount as USDC with 4 decimals"""
11
+ return f"{amount:.4f} USDC"
12
+
13
+ def get_elapsed_time(start_time: float) -> str:
14
+ """Calculate and format elapsed time"""
15
+ elapsed = round((time.time() - start_time) * 1000)
16
+ return f"{elapsed}ms"
17
+
18
+ def log_step(step_name: str, details: str = ""):
19
+ """Beautiful console logging"""
20
+ timestamp = datetime.now().strftime("%H:%M:%S")
21
+ print(f"[{timestamp}] 🔹 {step_name} {details}")
22
+
23
+ def generate_tx_reference():
24
+ """Unique transaction reference"""
25
+ import uuid
26
+ return f"TX-{uuid.uuid4().hex[:12].upper()}"
27
+
28
+ # Future: Add rate limiting, input validation helpers here