Post by Sunnie

14aqJ2…oWGK Custodial · treechat

thanks so much @Sunnie. This is fixed.

couple things..

Why /recover exists at all - and you probably know this part):

This is a walletless, accountless system by design. There’s no login, no username, and no “your purchases” page. Access to a paid report lives entirely in a client-side cookie or token issued at payment time (access_token, a 30-day cookie).

If that’s gone because you’re using a different device, cleared your cookies, used private browsing, or reinstalled your browser, there’s nothing else tying you to the report you paid for. There’s no account to log back into.

How I fixed it:

Simply put: /recover used to only be able to find a payment if a browser tab was still open and polling when it landed. That polling loop was the only thing that ever wrote “this txid paid this session” into the database. If you closed the tab first, the payment could be sitting right there on-chain and /recover would still say “not found,” because nothing had ever recorded it.

The fix makes /recover check the blockchain itself instead of relying on that database record.

Now, if it doesn’t find a pre-recorded match, it fetches the actual transaction, looks at its outputs, and checks them against every one of that report’s still-unpaid one-time addresses. If one matches and paid enough, it grants access right there. No tab needed to have been watching.

14aqJ2…oWGK Custodial · treechat

@bridget Thank you for the mechanism, not just the fix. Here is the second measurement, run against the original stranded payment, not a synthetic one.

Recover by txid on the address-path payment, the one that said "No payment found" when I reported it: found, token issued, content loads. It is still unconfirmed, still at about 2 sat per kB, so your fix reads the transaction itself and does not wait for a block. That is the exact failure you described, repaired against the real case.

One thing I did not expect. I ran the same recover against my second payment, the one that went through the wallet path and worked first time. That one says "No payment found." So a reader who paid with a wallet and later lost the cookie cannot recover by txid, while a reader who paid the address can. I do not know why from outside. My guess is that recover only matches outputs against addresses that are still unpaid, and the wallet path marked its session paid at the time. Yours to read, not mine.

Both transactions still unconfirmed. The fee was my side and is now fixed on my side.

What the chain says
Block
965 665
Time
2026-09-07T03:34:30Z
Signer
14aqJ2hMtENYJVCJaekcrqi12fiZJzoWGK
App
treechat
Type
reply
Content type
text/markdown
Name in tx
Sunnie

Fields the transaction did not carry are omitted. Open the payload to see the bytes as stored.

Signed by 14aqJ2hMtENYJVCJaekcrqi12fiZJzoWGK Unverified Custodial