Prerequisites
- The API deployment must have an email provider configured.
- Enable
email_notification_config.enabledin the target environment. - Configure a billing or help reply-to email in business settings. A manual send without a reply-to address fails.
Send an invoice
CallPOST /v1/invoices/{id}/email. The invoice must be finalized.
tois optional. If omitted, Flexprice uses the customer’s email address. If neither provides a recipient, the manual request fails with a validation error.ccis optional.toandccaccept recipient email addresses.idempotency_keyis optional. Retrying with the same key for the same invoice returns the existing email log. Reusing that key for another invoice is rejected.
delivery_status: queued. This means the email is queued for dispatch, not delivered. An idempotent retry returns the existing log with its current delivery status, not a new queued log.
Track delivery
- Call
GET /v1/invoices/{id}/emailsto list email logs for an invoice. - Call
POST /v1/emails/searchwith a JSON body to search email logs across invoices. Send{}for an unfiltered search or{"delivery_statuses":["bounced"]}to find bounced emails.
queued: waiting for dispatchsent: accepted by the email providerdelivery_delayed: delivery was delayeddelivered: delivered to the recipient’s mail serverbounced,failed, orsuppressed: delivery failed or was suppressedcomplained: the recipient filed a complaint about the message, including after deliveryskipped: an automatic email was intentionally not sent
email_events.enabled in deployment configuration, an email provider, and email_notification_config.auto_send.enabled with invoice included in auto_send.entities for the environment. For an automatic send, a missing customer email or a zero-total invoice is recorded as skipped. If no reply-to address is configured, the automatic send is not recorded.
