Goal: When a contact form is submitted, enrich the lead data before adding to CRM.Workflow:
Copy
1. Receive form data (name, email, company)2. Research company online (industry, size, funding)3. Check LinkedIn for person's role4. Calculate lead score (1-100)5. Add to CRM with enriched data6. Return lead score and priority
For each parameter you want to return, specify:Name: The field name in the response (e.g., lead_score, generated_image, report_pdf)Description: Natural language explanation of what this field contains and where Maia should get the value from. This helps Maia understand which workflow outputs map to this response field.Type: The type of data (text, file, etc.)
Response parameter definitions work identically to body parameters in Custom Actions. See that section for detailed parameter configuration guidance.
Body Parameters:- Name: lead_id Description: The CRM record ID assigned to this lead- Name: score Description: Calculated lead score from 1-100 based on company research- Name: priority Description: Priority level (hot/warm/cold) based on the score- Name: next_action Description: Recommended follow-up action for the sales team
Body Parameters:- Name: report_pdf Description: The generated PDF report file created by the workflow Type: File (base64)- Name: summary Description: Brief text summary of the report contents
If not found: Create support ticket via custom action, send notification
Return response to chat widget
Request from caller:
Copy
{ "visitor_id": "vis_123", "message": "What's your refund policy?", "page_url": "/pricing"}
Response to caller:
Copy
{ "response": "We offer a 30-day money-back guarantee on all plans. If you're not satisfied, contact support@company.com for a full refund.", "confidence": 0.92, "escalate": false, "source": "Help Center: Refund Policy"}
Result: Instant, accurate responses powered by AI, with human fallback.
If legitimate, publish to website via custom action
If mentions bug/issue, create support ticket via custom action
Return analysis
Request from caller:
Copy
{ "product_id": "prod_456", "rating": 4, "review": "Great product! Works as advertised. Customer support was responsive when I had a question about setup. Only issue: shipping took longer than expected.", "reviewer_email": "customer@example.com"}