refactor: Update client to use RPC interface

BREAKING CHANGES:
- All API calls now go to POST /rpc endpoint
- Request format: { method, message, signature, params }
- Response format: { success, result } or { success: false, error }
- Simplified API methods to match RPC methods
- Removed checkUsername, added isUsernameAvailable
- Renamed postOfferAnswer to answerOffer
- Removed discoverService/discoverServices (use getService)

Changes:
- Completely refactored api.ts for RPC interface
- Updated rondevu.ts wrapper methods
- Updated rondevu-signaler.ts to use new API
- Fixed exports in index.ts
This commit is contained in:
2025-12-12 20:10:03 +01:00
parent b5f36d8f77
commit a499062e52
4 changed files with 262 additions and 365 deletions

View File

@@ -16,9 +16,9 @@ export type {
export type {
Keypair,
OfferRequest,
Offer,
ServiceRequest,
Service,
ServiceOffer,
IceCandidate,
} from './api.js'