4NK Dev
|
0fbd4333ed
|
feat: complete implementation of 4NK Certificator
✨ New features:
- RelayMonitor: WebSocket connection to sdk_relay with message handling
- PaymentWatcher: Bitcoin RPC monitoring for payments on watched addresses
- AnchorEngine: Complete anchoring logic with Bitcoin tx creation/broadcast
- Prometheus metrics: /metrics endpoint with gauges and counters
- Verification API: POST /api/v1/anchors/verify to verify on-chain anchors
- Payments API: GET /api/v1/payments/{address} for payment history
🔧 Implementation details:
- Real-time message monitoring from relay (Handshake, Commit, NewTx, Cipher)
- Block scanning for payments to watched addresses
- Mempool monitoring for pending payments
- Automatic anchor creation based on block intervals
- Payment condition verification (priceMoSats * MB >= total_paid)
- OP_RETURN transaction creation with 'NKA1' protocol identifier
- Complete database operations for processes, metrics, anchors, payments
📊 Monitoring:
- 4nk_certificator_processes_total
- 4nk_certificator_anchors_created_total
- 4nk_certificator_anchors_confirmed_total
- 4nk_certificator_data_volume_bytes
Version: 0.1.0 - Full MVP
|
2025-10-01 09:39:22 +00:00 |
|