Marmot-TS
    Preparing search index...

    Function encodeMediaImetaTag

    • Serializes a MediaAttachment into an encrypted-media-v1 imeta tag array (features/encrypted-media.md — Message Shape).

      Field order follows the spec: v, locator…, ciphertext_sha256, plaintext_sha256, nonce, m, filename, optional dim, optional thumbhash. The attachment MUST carry at least one locator.

      Parameters

      • attachment: MediaAttachment

        A populated attachment (locators filled in after upload)

      Returns string[]

      A Nostr tag array beginning with "imeta"