/** * Read the Phototology registry id a photo carries in its XMP. * * `enrich_photo` writes an IPTC Extension `Iptc4xmpExt:RegistryId` entry * whose `RegItemId` is the sha256 of the photo's original bytes and whose * `RegOrgId` is `phototology.com`. Once the file's bytes change (the enrich * itself changes them), that id is still the registry key, so `lookup_photo` * tries it before hashing the file. * * This is a byte scan, not an XMP parser: it looks only at complete packets * within the first 2 MB, where JPEG, PNG, WebP and HEIC keep their XMP, and * ignores anything inside XML comments. * * @module lib/registry-id */ /** Bytes scanned for the XMP packet. */ export declare const REGISTRY_SCAN_BYTES: number; /** `RegOrgId` of the entries Phototology writes. */ export declare const PHOTOTOLOGY_REGISTRY_ORG = "phototology.com"; /** * Find the Phototology registry id embedded in an image's XMP. * * @param bytes - The image file's bytes * @returns The lower-case sha256 hex id, or `null` when the first 2 MB hold * no XMP packet with a `phototology.com` registry entry whose item * id is 64 hex characters * * @example * ```ts * const id = readEmbeddedRegistryId(fs.readFileSync('enriched.jpg')); * if (id) await client.lookup({ sha256: id }); * ``` */ export declare function readEmbeddedRegistryId(bytes: Buffer): string | null; //# sourceMappingURL=registry-id.d.ts.map