Skip to content

Update WhatsApp notification toggles

PUT
/v1/auth/me/whatsapp/prefs
curl --request PUT \
--url https://api.emite.cr/v1/auth/me/whatsapp/prefs \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "notifyAccepted": true, "notifyRejected": true, "notifyError": true, "notifyPurchaseDue": true, "notifyImportCompleted": true }'

Turns on or off the notifications the person receives on the linked number; only the toggles sent change. They are per person and opt-in (a new link starts with all of them off), and cover the company the number acts for, while the person is still a member of it. Nothing is sent while the company has its WhatsApp notifications switched off (whatsappEnabled in its notification settings). 400 WHATSAPP_LINK_NOT_VERIFIED before the code is confirmed; 404 WHATSAPP_LINK_NOT_FOUND without a link. For a person’s session (JWT) only: an API key answers 403.

Media typeapplication/json
object
notifyAccepted

Notify when Hacienda accepts an invoice

boolean
notifyRejected

Notify when Hacienda rejects an invoice

boolean
notifyError

Notify when a document ends in error instead of a verdict: sending it or checking its status failed for good, or Hacienda gave no verdict within 24 hours

boolean
notifyPurchaseDue

Notify when pending purchase acceptances approach their DGT deadline

boolean
notifyImportCompleted

Notify when the documents that arrived in the company's inbound mailbox finish importing: how many were saved, out of how many files.

boolean
Examplegenerated
{
"notifyAccepted": true,
"notifyRejected": true,
"notifyError": true,
"notifyPurchaseDue": true,
"notifyImportCompleted": true
}