Skip to main content
Add Osano cookie consent to your docs with a custom JavaScript file in your repository.

Setup

Create an osano.js file in your docs repository with the following content:
var script = document.createElement("script");
script.src = "OSANO_SCRIPT_URL";
document.head.appendChild(script);
Replace OSANO_SCRIPT_URL with your Osano script URL. Your script URL is the src value in the code snippet that Osano generates. Your script URL always starts with https://cmp.osano.com/ and ends with /osano.js.

Troubleshooting

If your documentation pages aren’t loading properly when using Osano’s Strict compliance mode, you’ll need to whitelist Mintlify’s domain to allow images and other assets to load.
1

Navigate to Managed Rules

In your Osano dashboard, go to ScriptsManaged Rules.
2

Add Mintlify domain

Add .mintlify.app/ as a managed rule.
Osano managed rule
This ensures that all Mintlify-served assets (including images, stylesheets, and other documentation resources) are treated as essential and will load even when Osano blocks uncategorized third-party content.