Receta para agentes
Enviar una notificación del art. 8 (Ley 2213)
Notificar a una parte de un auto admisorio u otra providencia por correo, con constancia de entrega.
Esta es la receta que el servidor MCP entrega a los asistentes de IA, tal cual. Está en inglés porque los modelos la siguen mejor así; el asistente le responde en su idioma.
Un asistente la lee con docs({uri:"docs://recipes/send-an-article-8-notification"})
docs://recipes/send-an-article-8-notification — prepare an art. 8 (Ley 2213) personal notification and request its send
Use when the lawyer wants to notify a party (usually the demandado) of a providencia —
typically the auto admisorio — by email with a constancia de entrega.
You PREPARE; a signed-in lawyer SWEARS the recipients and CONFIRMS the send in the panel.
You can never send on your own: sendNotification over MCP only requests the send.
Already have a draft id? Jump to step 6.
1. whoami({})
→ orgId, scopes every other call below takes this orgId
scopes lack "notifications:write"? Stop: the token cannot prepare notifications.
skip if you already hold orgId
2. caseList({orgId:"<orgId>", limit:200})
→ case.id look for the 23-digit radicado the lawyer gave you
Found it? Skip step 3. Not there? Step 3.
3. createCase({radicado:"<23 DIGITS>", juzgado:"<court name>", juzgadoEmail:"<court buzón>",
ciudad:"<city>", especialidad:"<e.g. Civil>", claseProceso:"<e.g. Verbal>",
cliente:"<the firm's client>"})
→ case.id
X_CASE_RADICADO_TAKEN? The case exists — go back to step 2, never create a second one.
Missing a field? Ask the lawyer. Do not invent a juzgado or its email.
4. For each PDF to attach (auto admisorio, demanda, anexos — at most 20 MB in total):
requestUpload({kind:"otro", filename:"<file.pdf>", contentType:"application/pdf", size:<bytes>})
→ key, url, contentType
PUT the file's bytes to url with header Content-Type: <contentType>
(url may be a path: prefix it with the server origin, e.g. https://www.notificado.co).
confirmUpload({key:"<key>", kind:"otro", filename:"<file.pdf>", contentType:"application/pdf"})
→ document.id, sha256
confirmUpload refused? The bytes are not a PDF/PNG/JPEG, exceed 20 MB, or the PUT never
landed — read the error's fix line, tell the lawyer, do not retry the same bytes blindly.
skip if the lawyer already uploaded the documents and gave you their ids
5. createNotification({orgId:"<orgId>", caseId:"<case.id>", template:"art8-personal",
providencia:"auto admisorio de la demanda", providenciaFecha:"YYYY-MM-DD"})
→ notification.id status "draft"; nothing is sent, no credit is used
Optional fields: terminoDias (1-365 días hábiles), mensaje (up to 5000 characters).
6. For each document.id from step 4:
attachDocument({orgId:"<orgId>", notificationId:"<notification.id>", documentId:"<document.id>",
kind:"auto_admisorio|demanda|anexo|subsanacion|providencia|otro"})
→ attachment.sha256
X_ATTACHMENT_DUPLICATE? Already attached — continue.
7. Ask the lawyer to open https://www.notificado.co/notificaciones/<notification.id> and add each
recipient there. Adding a recipient is the lawyer's sworn statement (juramento, art. 8) about
where the address came from — you cannot do it for them, and there is no tool for it.
Wait until they say it is done. This is the last point where nothing is committed.
8. creditsBalance({orgId:"<orgId>"})
→ balance one credit per recipient
balance smaller than the number of recipients? Stop: see docs://recipes/top-up-credits.
9. sendNotification({orgId:"<orgId>", notificationId:"<notification.id>", confirm:true})
→ status "awaiting_confirmation", confirmUrl, expiresAt
Give the lawyer confirmUrl. They confirm in the panel; only then is the message frozen,
timestamped and emailed. The request expires after 24 hours.
X_NOTIFICATION_NO_RECIPIENTS? Step 7 was not finished — ask again.
X_KYC_REQUIRED? The lawyer's identity check is not approved yet — they finish it in the panel.
Already called it for this draft? Do not call again — hand the lawyer the first link.
Done when you have handed the lawyer confirmUrl. To follow up after they confirm, use
docs://recipes/check-a-notification-status.
Tips
- The radicado is the 23-digit court number (Código Único de Radicación). Dashes and spaces are
fine; the brand is Notificado, never "radicado".
- Never call sendNotification "to test" — each request is shown to the lawyer as a send to confirm.
- Never retry step 9 after awaiting_confirmation: the lawyer confirms once, in the panel.
- Dates are plain calendar days (YYYY-MM-DD). Times you read back are UTC; show them in
America/Bogota.