Skip to main content

Legacy JavaScript library: Viewing manifest data

Warning

This is documentation for the deprecated legacy JavaScript library, c2pa-js-legacy. This library is no longer maintained or supported. Instead use the new JavaScript web library.

Initializing the library

The way that you import wasmSrc and workerSrc varies depending on the build system you use. For more information, see Quick start.

Viewing manifest data

If the input provided to c2pa.read has a C2PA manifest and was processed without errors, the returned c2paReadResult contains a manifestStore.

The manifestStore object contains a few properties:

  • manifests: An object containing all manifests found in an asset, keyed by UUID.
  • activeManifest: A pointer to the latest manifest in the manifest store. Effectively the "parent" manifest, this is the likely starting point when inspecting an asset's C2PA data.
  • validationStatus: A list of any validation errors the library generated when processing an asset. See Validation for more information.

Manifest objects contain properties pertaining to an asset's provenance, along with convenient interfaces for accessing assertion data and generating a thumbnail.