Quick start
In about five minutes you will create a property, add one script tag to your website, record a consent and find its receipt in your consent log.
You need an OptProof workspace and a page you can edit, such as a staging copy of your site or a local HTML file.
When you sign up at app.optproof.in, you create a workspace and choose the plan you will use. You can do everything on this page straight away with test keys, before you pay. Live keys, and with them live consent capture, become available once your plan is active (see Going live below).
1. Create a property#
A property is one place where you collect consent: a website, an app or a physical location. Each property has its own ledger and its own keys.
- Sign in at app.optproof.in and open Properties.
- Choose New property, pick Website, and give it a name such as "Clinic website".
- Under Allowed origins, add the origin of the page you will test on, for example
https://staging.example.inorhttp://localhost:8080. The widget only works on these origins. - If you chose an industry template during onboarding, your purposes and a draft notice are already there. Publish the notice under Notices before you continue: the widget shows the latest published version.
Note
pk_test_…, sk_test_…) from the start, and live keys (pk_live_…, sk_live_…) once your plan is active. Publishable keys are safe to put in a web page. Secret keys are shown once and belong on your server only.2. Add the script tag#
Open the property, go to Install, and copy the snippet. It looks like this:
<script src="https://cdn.optproof.in/w.js" data-pk="pk_test_..." async></script>Paste it into the <head> of your page, or just before </body>. The script loads asynchronously, stays under 15 KB gzipped and runs inside its own Shadow DOM, so it cannot break your styles or throw errors into your page.
Use the pk_test_ key while you try things out. Test keys write to a separate sandbox chain, so nothing appears in your live log.
3. Load the page and make a choice#
Open the page in a browser. You should see the consent banner with Accept all, Reject all and Customise. They have the same size and weight on purpose: refusing must be as easy as agreeing.
Choose Customise, switch on one optional purpose and save. The widget shows a receipt code such as OP-7K2M-9QXD and offers Save receipt, which downloads the signed receipt as a JSON file.
You can also read the receipt from the browser console:
optproof.receipt();// { code: 'OP-7K2M-9QXD', jws: 'eyJhbGciOiJFZERTQSIs...' }4. Find the consent in the log#
Back in the console, open Consent log and switch the mode selector to Test. The newest event is at the top. Search by the receipt code to open it. The event detail shows:
- the action (
grantfor the purposes you accepted, and a separatedenyevent for the ones you refused), - the purposes, notice version, language and channel (
web), - the event's position (
seq) in the property's hash chain and its hash, - the signed receipt and a link to check it on
verify.optproof.in.
That is the whole loop: a decision on your page became an append-only ledger event with a receipt that anyone can verify.
Test and live keys#
| Test keys | Live keys | |
|---|---|---|
| Prefix | pk_test_, sk_test_ | pk_live_, sk_live_ |
| Ledger | A separate sandbox chain per property | The live chain per property |
| Consent log | Shown under the Test mode | Shown by default |
| Webhooks | Delivered with "test": true | Delivered with "test": false |
| Usage and billing | Not counted | Counted toward your plan |
| Available | As soon as you sign up | Once your plan is active |
Going live#
- Open Billing in the console and activate the plan you chose (annual, per website or app, plus GST). For an offline invoice or bank transfer, write to us and we activate the workspace once it is paid.
- Open the property, go to Keys, and create a live publishable key (and a live secret key if your server calls the API).
- Swap
pk_test_forpk_live_in the snippet. Nothing else changes.
If a renewal is late, recording does not stop: consents, withdrawals, rights requests, receipts and verification keep working. The console shows a billing warning until the plan is renewed.
Next steps#
- Customise the widgetLayouts, inline form consent, script blocking and Google Consent Mode.
- Record consent from your backendFor sign-up flows you build yourself, and to check consent before a send.
- Get notified of changesSigned events for every grant, withdrawal and erasure request.
- Collect consent offlineQR posters, a reception kiosk, WhatsApp and imports.