Decoding tools
Use our DCS decoder to quickly and easily decode your Didomi Consent Strings and view their contents in a human-readable format.
SDK API - Web
The Didomi Web SDK provides a JavaScript API to decode the Didomi Consent String (DCS). This API can be used in two ways depending on your needs:
Simple decoding
This method allows you to decode a DCS string into a readable JSON object containing the user’s consent preferences, timestamps, and vendor/purpose consents.
Use this if you’re only interested in accessing and inspecting user consent choices (e.g. for debugging or integration validation).
Query example
Response example
Granular decoding
This advanced method provides insight into the internal structure of the DCS, including the encoding strategy used for each field and its offset in the binary string. This is useful for debugging, validation, or developing your own decoder.
Query example
Response example
Coming soon - Open source DCS library
We’re currently working on open-sourcing the DCS library, which will allow you to encode and decode the Didomi Consent String with greater flexibility. This will be particularly useful if you’re building advanced tools, integrations, or custom debugging utilities.
Last updated