@fiatjaf @Biz @hodlbod @greenart7c3 I integrated NIP-55 into one of the native apps I'm working on using @Biz capacitorjs plugin and I had some questions about the spec
1. Why are there a mix of "pubkey" and "npub" (bech32) when its been a nostr standard to have all public keys in hex format?
2. The spec says that nip04 and nip44 encrypt and decrypt calls return a "signature" and "id". is that a typeo? I don't see how an encrypt or decrypt call would return a signature
3. What is the use for the "decrypt_zap_event"?
@Biz for the capacitorjs plugin is "app.icon" from "getInstalledSignerApps" always a base64 encoded image/png or could it ever be a URL?
@hodlbod Thanks for making a working example, I used a lot of your code for reference 😀
Also thanks for all the work you guys (and everyone I'm forgetting) put in to this to get this working, its a much better native experience than using NIP-46
The "signature" in the case of a decryption/encryption event is just the decrypted/encrypted text.
cool, but why call it signature then? is there a restriction of what fields can be passed back and forth from the signer and the app?
Probably old name when the app only did signatures.
also as promised 200k sats to @Biz for building the capacitorjs plugin 😀
nostr:nevent1qvzqqqpxqupzpw5qnyrxdmctda962pvng7ltzvjzjg09ge57dqqxfjn42ft2rcaxqqsvvllva06t4xzwqlegcchpef73mxgywv85x005guhk9pyl93pg52c6p7upn
nostr:nevent1qvzqqqqqqypzqfngzhsvjggdlgeycm96x4emzjlwf8dyyzdfg4hefp89zpkdgz99qyghwumn8ghj7mn0wd68ytnhd9hx2tcpzfmhxue69uhkummnw3e82efwvdhk6tcqyqcuql9zdhtaqql2dqamewhadqx3edmepj55cqk9y9t3lxwvddff2wva42k
1 - there's a pull request to change that but the nip repo is slow
2 - This could also be changed. I think result would be better for all kinds
3 - Private zaps use a different method of encrypting the data
Where is the PR? Is Amber updated to the new way?
It's beautiful when devs cooperate and things come together so well. I know very little about nip 55, but for reference on private zaps look at amethyst's code.
Glad you like it :-) the app icon is sourced from the Android Package Manager as a native Drawable and afaik encoding them as a base64 blob is the only way to pass them to Capacitor
Would it be possible to append the data:image/png,base64: prefix to it so its a valid URL?
I'm just worried about guessing the minetype in the app since I'm not sure if the mimetype would change