Edit Email With Prompt
Changed onPrompt Migma to edit one generated email as a canvas follow-up turn (same orchestrator path as design chat). Omit async or set it to false to wait for the edited Email response; this existing synchronous write is not idempotent and the SDK does not automatically retry it. Set async to true to durably enqueue the edit with no AI work on the request path and receive an EmailEditOperation. Async edits require email:write and email:read; credits are checked when the worker starts. Poll the edit-specific status endpoint and do not use conversation generation status, because a previous conversation turn may already be completed. Total work varies with section and image complexity, provider behavior, and retries; no fixed maximum latency is established.
Request
- Base URLhttps://api.migma.ai
- URLhttps://api.migma.ai/v1/emails/{emailId}/edit
- AuthAPI key in header Authorization
Path parameters
Email ID returned in generation status result.emails[].emailId.
Headers
Optional key of at most 100 characters for async edits only. For the same authenticated API key and email, reusing the key with the same prompt and label returns the same job; a conflicting body returns 409 IDEMPOTENCY_CONFLICT. The receipt remains available for at least 24 hours after terminal completion under normal cleanup. Reuse the same key after an uncertain async start.
Request body
Response
Synchronous edit completed. Returned when async is omitted or false.
Changes
- breaking
the
request property's minLength was increased from0to1 - breaking
the
request property's minLength was increased from0to1 - warning
the
request property's maxLength was set to120 - warning
the
request property's maxLength was set to20000 - info
added the new optional
headerrequest parameterIdempotency-Key - info
added the new optional request property
- info
added the non-success response with the status
- info
added the non-success response with the status
- info
added the success response with the status
- breaking