563848e0ecc0
Send a practitioner credentialing outreach email
Sends a credentialing outreach email for a practitioner workflow via SendGrid and persists an outreach record in the DAL. Call this after a practitioner credentialing workflow is active and you need to contact one or more recipients; for facility credentialing outreach, use the facility-specific outreach endpoint instead. The request body must include at least one recipient in toEmails. For a single-workflow outreach, supply workflowId. For a multi-workflow (multi-tenant) outreach, supply workflowIds (two or more entries) and initiatingWorkflowId, which must be a member of workflowIds; attachments are not permitted on multi-workflow requests. Multi-tenant outreach must be enabled via the OUTREACH_MULTI_TENANT_ENABLED feature flag; when disabled, a multi-workflow request returns 503. This operation is not idempotent - each call dispatches a new email via SendGrid and persists a new outreach record.
Headers
Tenant ID of the initiating organization; scopes the outreach record and email dispatch to this tenant.
Request body
Example request
{
"workflowId": "workflow-123",
"workflowIds": [
"workflow-123",
"workflow-456"
],
"initiatingWorkflowId": "workflow-123",
"toEmails": [
"recipient@example.com"
],
"body": "Please complete your credentialing application.",
"ccEmails": [
"cc@example.com"
],
"bccEmails": [
"bcc@example.com"
],
"outreachReasons": [
"Missing documentation",
"Expired license"
],
"outreachReasonsWithLabels": [
{
"id": "reason-123",
"label": "Missing documentation"
}
],
"subject": "Action Required: Complete Your Credentialing"
}Response
Outreach email sent successfully. The response body shape depends on the request type: a single-workflow request (workflowId supplied) returns a bare string containing the created outreach record ID; a multi-workflow request (workflowIds with more than one entry) returns a MultiTenantOutreachResult object with an outreachId and a sends array describing the per-workflow send status.