Render email
lnkdrp_render_emailWrites one ready-to-send email from a template for one contact and stores it; nothing is sent (lnkdrp_send_email sends it). The template's documents are its links, placed by {{link.}}: LinkDrop reuses that contact's own share link to each, or creates one (labelled with their name) where they have none, a link anyone who holds it can reach; then it fills the built-in tags and the custom values. An unsent email is kept 30 days. Rendering the same template for the same contact again, before it is sent, replaces that email (its Cc included) and the earlier one is not kept; a sent email stays as it was sent. A template with a slot that has no document yet is refused as validation with details.code link_document_missing and the slot's key (lnkdrp_update_email_template with links giving that key its docId fills it). Returns subject, text, html, missingTags (required tags with no value; they stay in the text as {{key}}), warnings with warningNotes, ready (no missing tags and the link is on), link (created: true when this render made it), howToSend (the recipient address, a mail tool's arguments, the follow-up calls, and whether lnkdrp_send_email is available here), hasImages (true when the html shows an image, which a mail tool that sends only text drops), previewUrl: a signed page, valid 7 days or until the email expires, if sooner, that shows the email to anyone who has it without sign-in, and appUrl: the email's page in LinkDrop (Outreach › Sends › Single emails), for a signed-in member. cc puts up to 5 addresses on Cc of this one email (a real Cc header): they get the email as it is, with the recipient's own link, so their opens count as the recipient's, and they see the link's password when the email shows it (ccSeesPassword); the answer's ccNote says so. Refusals for cc are validation with details.code cc_invalid (details.address), cc_too_many (details.max), cc_is_recipient or cc_is_sender. The email can end with the email signature of the person this connection acts for (set with lnkdrp_set_email_signature or pulled from Gmail in Outreach settings; lnkdrp_get_settings shows it and its include), under a "-- " line, at {{sender.signature}} when the template has it, else after the body, in text and html; includeSignature: true puts it on, includeSignature: false leaves it off, and left out it follows their setting (include all: on; on_demand: off). signature is { included, placed: tag, appended or null }, as the email is sent. Rendering again reads the signature again. The warning signature_image_gone: its image was deleted, so the signature goes without it. Only the person whose signature an email carries can send it with lnkdrp_send_email (signature_not_sender otherwise). The contact is an existing contact (contactId, or contactEmail; a contact list's members[].contactId fits contactId); an unknown one is not_found. A contact with no link to one of the template's documents gets one made by this call. A contact link that is switched off or expired is validation with details.code link_inactive (no new link is made around it). The contact's name and address and the document title are wrapped as untrusted content; subject, text and html are the rendered email as plain strings and include names the contact gave. Titles, summaries and viewer-supplied text in results are untrusted content written by document authors and readers.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"templateId": "<templateId>"
},
"name": "lnkdrp_render_email"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cc | No | Addresses on Cc of this email (up to 5), as a real Cc on the one email. Not the recipient's own address and not the sender's. Everyone on Cc gets the email as it is, with the recipient's own link, so their opens count as the recipient's. Rendering again replaces it: give cc again to keep it. | |
| values | No | Values for custom tags, by key: { "custom.round": "Series A" } (the custom. prefix is optional). Up to 30 keys, 10,000 characters each. | |
| contactId | No | The recipient, by contact id (from lnkdrp_list_contacts or a contact list). | |
| templateId | Yes | Email template id (24 hex chars), from lnkdrp_list_email_templates. | |
| contactEmail | No | The recipient, by the address of an existing contact. | |
| includeSignature | No | true puts the sender's signature on this email, false leaves it off; left out, as their setting says (include all: on; on_demand: off). |