assets

Optimize Outbound Message

Write one outbound email or LinkedIn message in the sender's own voice from context (facts, rules, voice_examples) and return it with a line on what changed. Use when an outbound message needs writing or improving before it is sent. message is optional: where Amdahl writes from context, a draft is not read. Pass evidence: "workspace" to grade against synced conversations (slower) and list unbacked claims in unsupported_claims, kept unless on_unsupported is remove. Sends nothing.

post/api/platform/v1/messages/optimize

Request

  • Base URL: https://docs.amdahl.ai
  • URL: https://docs.amdahl.ai/api/platform/v1/messages/optimize
  • Auth: one of:
    • API key in header X-API-Key
    • HTTP bearer

Request body

messagestring

Optional, and NOT READ where Amdahl writes from context: nothing is taken out of a draft, not a claim, not a name, not the subject line, and the result carries a draft_ignored note. One exception: a draft sent with no facts in context and no recipient is improved instead, with a draft_improved_no_context note. Put what you know in context.

channel'email' | 'linkedin'

Where the message will be sent. Send it: with no draft there is nothing to infer it from, and the channel sets the length and format the message is written and judged against. linkedin means a connection note, which carries no sign-off.

on_unsupported'flag' | 'remove'

What to do with a claim in the draft that nothing in the workspace conversations backs. "flag" (the default) keeps it and lists it in unsupported_claims; "remove" lets the rewrite soften or cut it. Only checked when the workspace has connected conversations.

evidence'workspace' | 'off'

Optional, default off. workspace grades the draft against what this workspace's customers said in its synced conversations (positioning, grounding, specifics, differentiation), which is slower; off is a fast style pass. Where no conversations can be read the run is graded as off and evidence.reason says why.

include_triesboolean

Optional, default false. When true, the result also carries tries: every version the run scored, the draft first, each with its text, the optimizer's own score and human_tone (1 to 5), the dimensions it aimed at, and which one was returned. It shows how the draft progressed. Those scores come from the judge the rewrites were optimized against, so lift, not them, is the before-and-after.

recipient_notesstring

Beta, per workspace: refused unless the workspace has recipient evidence on. Free text about the recipient, such as your own research or a pasted CRM note. Up to 10000 characters.

message_type'cold' | 're-engage' | 'follow-up' | 'deal'

Beta, per workspace: ignored unless the workspace has recipient evidence on. The kind of message: cold, re-engage, follow-up, deal. follow-up is a reply in a thread that is in progress.

Response

OK

dataunknown

Changes

No recorded changes to this operation across all 1 revision of this API.