Vendor Configuration

The vendor property is optional and provides a way to add custom vendor scripts and customized components used within a Canopy IIIF project.

Google

The vendor property can be used to add Google Analytics or Google Tag Manager to your Canopy project. The googleAnalytics and googleTagManager properties are optional and can be added to the vendor object in the config/canopy.json file.

Google Tag Manager

config/canopy.json
{
  "collection": "https://iiif.io/api/cookbook/recipe/0032-collection/collection.json",
  "vendor": {
    "googleTagManager": {
      "gtmId": "GTM-XXXXXXXX"
    }
  }
}

Google Analytics

config/canopy.json
{
  "collection": "https://iiif.io/api/cookbook/recipe/0032-collection/collection.json",
  "vendor": {
    "googleAnalytics": {
      "gaId": "G-XXXXXXXXXX"
    }
  }
}