Authorize with either source-private-key possession (proof x25519: against the current check challenge, echoing challengeWindow) or an owning Bearer sk_live_... / Nostr NIP-98 account. Cookie sessions and PSK proofs are not accepted. NIP-98 requires an exact absolute u URL including query, matching method, a timestamp within 60 seconds, and the SHA256 of the exact request body in a payload tag. Invalid supplied account credentials never fall back to a proof. Never transmit either WireGuard private key. The new public key must be fresh and strong. Atomically reserves one shared monthly $1.00 slot before LNBits creation; exact unpaid retries reuse an invoice with more than 30 seconds remaining. Bound proofs cannot change target/key before their ten-minute challenge expires. Invoice lifetime is at most one hour and capped before UTC month rollover. Rate limits: 10 requests/min per IP (rolling), five failed proofs/hour per source public key across IPs. Request bodies are limited to 8192 bytes.
curl --location 'https://tunnelsats.com/api/public/v1/subscription/migrate' \
--header 'Content-Type: application/json' \
--data '{
"sourceWgPublicKey": "hSDwCYkwp1R0i33ctD73Wg2/Og0mOBr066SpjqqbTmo=",
"targetServerId": "eu-ch",
"newWgPublicKey": "3p7bfXt9wbTTW2HC7OQ1Nz+DQ8hbeGdNrfx+FG+IK08=",
"proof": "x25519:C1qwwR+zCDFSMb3vTSuEVCwmIaLV6r4egeVreJRAv3s=",
"challengeWindow": 123
}'{
"invoice": "lnbc1example-not-payable",
"paymentHash": "aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"migrationId": "41300000-0000-4000-8000-000000000001",
"amountSats": 1000,
"amountUsd": "1.00",
"expiresAt": "2026-11-02T12:15:00.000Z",
"resetsThisMonth": 1,
"maxResetsPerMonth": 2
}