Pass instructions to processors
Read the stop and erase instructions in withdrawal and erasure webhooks, pass them to your Data Processors and report back what each one did.
When a person withdraws or is erased, the webhook lists an instruction for each partner you registered as a Data Processor. Your server passes each one on and reports back what the processor did.
Before you start#
- Partners registered as Data Processors. See Register your processors.
- A webhook endpoint for
consent.withdrawn,consent.updated,consent.expired,subject.erasedandsubject.erased_inactive. - The
consentIdstored against your user when you record consent. A task holds no identifier, and after an erasure its fingerprint may be gone. - A secret key with Read processor tasks and Record what processors reported. Keep it apart from the key that erases people, because they share the 60-a-minute budget for calls on a person.
Pass on each instruction#
- Read
data.processorsin the event. Each entry has ataskId, the partnerkeyandname, theaction, thepurposesand adueOn. - Find your user by
data.consentId, or bydata.subject.fingerprint. - Call the processor: stop processing for the purposes on a
STOP, erase on anERASE. - Keep the
taskIdwith the request you made to the processor.
{
"taskId": "2b9e4f61-0c3d-4a7e-8f15-6d2c9b0a7e34",
"key": "nilgiri-mailers",
"name": "Nilgiri Mailers",
"action": "STOP",
"purposes": ["marketing"],
"dueOn": "2026-10-05T09:30:12.004Z",
"retainLogsUntil": null
}An ERASE may carry retainLogsUntil: the processor may keep its processing logs until then. A list is often empty: a change that shuts out no processor, or a person known only by a cookie or session id, writes no task.
Many processors accept an erase request at once and finish it later. Report the task when the processor confirms the work is done, not when it accepts the request.
Report back#
curl -X POST https://console.dpconsent.com/consent/sdk/v1/processor-tasks/acknowledge \
-H "Authorization: Bearer $PIEDAP_PROCESSOR_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: nm-req-20431" \
-d '{
"acknowledgements": [{
"taskId": "2b9e4f61-0c3d-4a7e-8f15-6d2c9b0a7e34",
"outcome": "STOPPED",
"completedOn": "2026-10-04",
"reference": "NM-REQ-20431"
}]
}'const response = await fetch(
'https://console.dpconsent.com/consent/sdk/v1/processor-tasks/acknowledge',
{
method: 'POST',
headers: {
Authorization: `Bearer ${process.env.PIEDAP_PROCESSOR_KEY}`,
'Content-Type': 'application/json',
'Idempotency-Key': 'nm-req-20431',
},
body: JSON.stringify({
acknowledgements: [
{ taskId, outcome: 'STOPPED', reference: 'NM-REQ-20431' },
],
}),
},
);
const { results } = await response.json();Each result is RECORDED, UNCHANGED for a repeat, or REFUSED with a code. Up to 200 reports go in one call. A final outcome cannot be changed later.
Poll for open tasks#
If a webhook was missed, list what is still open:
curl "https://console.dpconsent.com/consent/sdk/v1/processor-tasks?status=OPEN&limit=500" \
-H "Authorization: Bearer $PIEDAP_PROCESSOR_KEY"An open task stays listed until it is reported, so polling cannot miss one. Follow nextCursor for the next page.
Keep it private#
- Do not point a processor at your webhook endpoint. The payload names the person and their other partners.
- Send each processor only its own instruction and the identifier it already holds.
- Write no names in
note,referenceor the evidence file name. Text that looks like an email address or a phone number is refused withTEXT_LOOKS_PERSONAL. - The product records what you report. It does not check that the processor acted.
Related#
- Processor tasks, every field and code
- Follow up processor tasks, in the console
- Receive webhooks