[C] Consentify

@consentify/cloud

Deprecated. Event reporting moved into @consentify/core.

This package is deprecated and does nothing. As of @consentify/cloud@2.0.0, enableCloud() is a no-op that logs a warning and returns an empty teardown function. Remove it from your dependencies.

What replaced it

Cloud functionality — event reporting, visitor hashing, deduplication and the retry buffer — moved into @consentify/core. There is no adapter to install any more; passing a siteId to createConsentify() is what turns reporting on.

import { createConsentify } from '@consentify/core';

// Cloud mode is async: it fetches the site's policy before returning.
const consentify = await createConsentify({
  siteId: 'your-site-id',
  apiKey: 'ck_your_api_key', // optional
});

Migrating

  1. npm uninstall @consentify/cloud
  2. Delete the enableCloud(...) call and its import.
  3. Replace your createConsentify({ policy }) call with createConsentify({ siteId }), and await it. In cloud mode the category list comes from the server, so you no longer declare policy.categories locally.
  4. Drop the dispose() call — cloud mode cleans itself up with the instance.

If you would rather keep declaring your policy in code and skip server reporting, stay on self-hosted mode and simply remove the enableCloud call. See @consentify/core.

Cloud mode's default endpoints - https://ingest.consentify.dev and https://cdn.consentify.dev - are not currently served. Cloud mode does not work without overriding endpoints to point at https://consentify.dev/api/sdk, as shown in the core cloud mode docs and SDK endpoints.

On this page