Skip to content

Create or update cold-calling consent
Customers

Request

Creates or updates the cold-calling consent (consentement anti-démarchage) for a customer. Requires SITE_CUSTOMER:WRITE permission and RS:CUSTOMER_UPDATE right.

Behavior:

  • One consent record per customer (upsert).
  • If the customer previously had their consent revoked, calling this endpoint reactivates it (clears the revocation date).
  • Proof files (proofs) are uploaded to the customer's cloud storage under Documents confidentiels/Consentement subfolder.

Content-Type: Use multipart/form-data when uploading proof files, or application/json when no files are attached.

Security
bearerAuth
Path
customerIdintegerrequired

Unique identifier of the customer.

Example:789
Bodyrequired
reasonstring, <= 64 charactersrequired

Reason/motive for the consent (e.g. "Accord verbal", "Formulaire signé").

Example:"Accord verbal lors de la visite"
accept_outside_hoursboolean

Whether the customer accepts being contacted outside business hours.

Example:true
proofsArray of strings or null, (binary)

Proof files (scanned documents, signed forms, etc.). Files are uploaded to the customer's cloud storage under Documents confidentiels/Consentement subfolder. Only used with multipart/form-data content type.

consent_datestring or null, (date-time)

Date when consent was given. ISO 8601 format. Defaults to current date/time when omitted.

Example:"2026-06-15T10:00:00+02:00"
curl -i -X POST \
  https://api-doc.immo-facile.com/_mock/openapi/customers/789/consent \
  -H 'Authorization: Bearer <YOUR_opaque_HERE>' \
  -H 'Content-Type: multipart/form-data' \
  -F 'reason=Accord verbal lors de la visite' \
  -F accept_outside_hours=true \
  -F 'proofs=["string"]' \
  -F 'consent_date=2026-06-15T10:00:00+02:00'

Responses

Consent created or updated successfully

Response
No content