Write personal lines
Saves the personal lines your assistant wrote, for up to 5,000 people per call (fewer is fine). A finished file with more goes through POST .../leads/custom-fields/import. Set up the campaign's personal-line variables first (PUT .../personalization). Send leads as a list of {lead_id or email, values: {custom_x: "..."}}; a person you checked and found nothing for can keep the fallback with keep_fallback: true. Each line is one plain line within the variable's max_length (20 to 300 characters, 150 by default), and basis is up to 200 characters.
A line a person already has is never replaced by accident. Without overwrite it stays, and the answer lists it in kept_existing with the saved and the sent text. To correct lines, send them again with overwrite: true. To clear a line, send the variable as null (or an empty text) with overwrite: true; the person gets the fallback again and, with no line left, is back in the list of people still to write. Every replaced or cleared line is kept as a record, old and new, and the answer lists them in changes. Sending the same line again changes nothing (unchanged). Up to 300 calls an hour per workspace.
| Cost | What it does | Key scopes |
|---|---|---|
| Free | Writes | argorant:manage_lists |
Authorization
BearerAuth Your API key from app.argorant.com/profile, sent as Authorization: Bearer <key>. A connector sign-in token (ag_mcp_...) works the same way.
In: header
Path Parameters
The campaign id from create or list.
uuidHeader Parameters
Any unique text up to 128 characters. A retry with the same key and the same body within 24 hours returns the first answer (with the header Idempotent-Replayed: true) instead of doing the work twice. The same key with another body answers 409 idempotency_conflict.
length <= 128Your own id for this request, 8 to 64 letters, digits, dot, dash or underscore. Returned as X-Request-Id; one is made for you when you send none.
^[A-Za-z0-9._-]{8,64}$Request Body
application/json
TypeScript Definitions
Use the request body type in TypeScript.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X PATCH "https://app.argorant.com/api/v1/campaigns/7f3a2c1e-9b4d-4e8a-a1c2-5d6e7f8a9b0c/leads/custom-fields" \ -H "Idempotency-Key: 6f1c2e7a-run-42" \ -H "Content-Type: application/json" \ -d '{ "leads": [ { "email": "jane.doe@example-acme.com", "values": { "custom_opener": "Congrats on the new Munich office." } } ] }'{ "saved": 1, "kept_fallback": 0, "values_saved": 1, "unchanged": 0, "changed": 0, "cleared": 0, "kept_existing_count": 1, "kept_existing": [ { "lead_id": "0c9d8e7f-6a5b-4c3d-8e2f-1a0b9c8d7e6f", "name": "custom_opener", "saved": "Congrats on the Munich office.", "sent": "Congrats on the new Munich office." } ], "changes": [], "overwrite": false, "rejected_count": 0, "rejected": [], "not_found_count": 0, "not_found": [], "progress": { "total": 1188, "written": 413, "fallback": 775 }, "summary": "Saved lines for 1 contact. 1 contact already has a saved line that was kept (see kept_existing). To replace or clear saved lines, send them again with overwrite: true."}