Beta. consent-kit is at 0.x: expect breaking changes between releases, and treat everything it generates as a draft. Report a problem or share feedback.
Guides
- Add a vendor with a preset
Adopt a provider preset so that a third-party tool's processor entry and artefacts are written for you, then adjust it to your setup and keep it up to date.
- Add consent-kit to an existing app
This guide is for a web app that already runs, and may already have a cookie banner.
- Contribute a preset
Write a provider preset for the consent-kit catalogue: source every fact, write the fixture, version it correctly and open the pull request.
- Deploy the receipt endpoint to Cloudflare
Run @consent-kit/server as a Cloudflare Worker that receives consent receipts and appends them to a D1 database.
- Embed an iframe behind consent
This guide puts a third-party iframe, such as a video player, on a page so that nothing loads from the vendor until the visitor agrees.
- Loosen the CSP correctly
Add an exception to the generated Content-Security-Policy when the site needs one, in a way that is validated, visible in every report and signed off by a person.
- Migrate raw storage calls to the facade
This guide takes a codebase that calls localStorage, sessionStorage and document.cookie directly and moves it to the generated storage facade, one lint report at a time.
- Opt out of receipts, and what that costs
Declare that a site keeps no consent receipts, and understand what you give up before you do.
- Receive data subject requests
Add a request form to the site, receive requests in a Cloudflare Worker on D1, and email each one to the controller's mailbox.
- Record a lawyer's review
Get the generated sentences in front of a lawyer, and record their review so that the documents stop being stamped as unreviewed drafts.
- Release a policy change
Take a change to privacy.registry.yaml from edit to release: read the diff, bump the versions it asks for, sign off what needs a person, regenerate, and record the release.
- Run the audit in CI
This guide sets up a CI job that builds your site, serves it with its real response headers, runs consent-kit audit against it and fails when a check fails.
- Write a registry entry by hand
Declare a purpose, a processor and each kind of artefact in privacy.registry.yaml yourself, and fix the validation errors you are most likely to meet.