This quickstart guide will walk you through setting up your first Mercury sales persona and integrating it with external workflow platforms in under 30 minutes. We'll cover both UI configuration and API integration to demonstrate Mercury's flexible, streamlined approach to conversation automation.
Configure common sales scenarios and responses:
{
"offers": [
{
"title": "Free Consultation",
"description": "30-minute strategy session to identify your specific needs",
"value_proposition": "Personalized insights with no commitment"
},
{
"title": "Product Demo",
"description": "Live demonstration of our platform's core features",
"value_proposition": "See exactly how our solution fits your workflow"
}
]
}{
"objections": [
{
"objection": "It's too expensive",
"response": "I understand budget is important. Let's explore our flexible pricing options and ROI calculator to find a solution that works for you."
},
{
"objection": "We need to think about it",
"response": "Absolutely, this is an important decision. What specific aspects would you like to discuss further? I can provide additional information to help with your evaluation."
}
]
}The POST /conversations RPC API is Mercury's primary integration endpoint. It handles resource upserts (create or update) and conversation initiation in a single call.
Base URL: https://your-api-name.mercury.ratiomachina.com Endpoint: POST /conversations Headers: Content-Type: application/json x-mercury-api-key: YOUR_API_KEY
{
"persona": {
"externalId": "sales-alex-v1",
"name": "Sales Assistant Alex",
"data": {
"role": "sales",
"tone": "professional_friendly",
"business_description": "Your business description"
}
},
"contact": {
"externalId": "contact_12345",
"name": "John Smith",
"data": {
"email": "john@example.com",
"phone": "+1234567890",
"lead_source": "website_form"
}
},
"conversation": {
"externalId": "conv_website_john_smith",
"channel": "sms"
},
"message": {
"content": "Hi! I'm interested in learning more about your services.",
"sender": "contact"
}
}Configure Mercury as a webhook in your GoHighLevel workflow:
Webhook Configuration:
URL: https://your-api-name.mercury.ratiomachina.com/conversations
Method: POST
Headers: {
"Content-Type": "application/json",
"x-mercury-api-key": "your_api_key"
}Field Mapping:
{
"persona": {
"externalId": "sales-alex-v1"
},
"contact": {
"externalId": "ghl_contact_{{contact.id}}",
"name": "{{contact.first_name}} {{contact.last_name}}",
"data": {
"email": "{{contact.email}}",
"phone": "{{contact.phone}}",
"ghl_contact_id": "{{contact.id}}"
}
},
"conversation": {
"externalId": "ghl_conv_{{contact.id}}_{{workflow.id}}",
"channel": "sms"
},
"message": {
"content": "{{trigger.message}}",
"sender": "contact"
}
}Set up Mercury as a webhook action in Kartra sequences:
{
"persona": {
"externalId": "sales-alex-v1"
},
"contact": {
"externalId": "kartra_lead_[lead_id]",
"name": "[first_name] [last_name]",
"data": {
"email": "[email]",
"kartra_lead_id": "[lead_id]",
"sequence_name": "[sequence_name]"
}
},
"conversation": {
"externalId": "kartra_conv_[lead_id]_[sequence_id]",
"channel": "email"
},
"message": {
"content": "[custom_field_inquiry]",
"sender": "contact"
}
}Create a Zapier webhook action:
Zap Configuration:
Dynamic Field Mapping:
{
"persona": {
"externalId": "sales-alex-v1"
},
"contact": {
"externalId": "zapier_{{lead_id}}",
"name": "{{first_name}} {{last_name}}",
"data": {
"email": "{{email}}",
"source": "{{lead_source}}"
}
},
"conversation": {
"externalId": "zapier_conv_{{lead_id}}_{{zap_meta_human_now}}",
"channel": "sms"
},
"message": {
"content": "{{inquiry_message}}",
"sender": "contact"
}
}Mercury returns comprehensive conversation data including the AI-generated response:
{
"conversation": {
"id": "uuid-here",
"externalId": "conv_website_john_smith",
"channel": "sms"
},
"persona": {
"id": "uuid-here",
"externalId": "sales-alex-v1",
"name": "Sales Assistant Alex"
},
"contact": {
"id": "uuid-here",
"externalId": "contact_12345",
"name": "John Smith"
},
"messages": [
{
"id": "uuid-here",
"content": "Hi! I'm interested in learning more about your services.",
"sender": "contact",
"createdAt": "2024-01-15T10:30:00Z"
},
{
"id": "uuid-here",
"content": "Hello John! I'd be happy to help you learn more about our services. Based on your inquiry, I can see you're looking for solutions that could benefit your business. What specific challenges are you hoping to address?",
"sender": "persona",
"createdAt": "2024-01-15T10:30:02Z"
}
]
}Use the AI response from Mercury to automate your platform's follow-up actions:
// Get the latest persona message const aiResponse = response.messages .filter(msg => msg.sender === 'persona') .pop() .content;
Monitor key metrics in Mercury UI:
You now have a fully functional Mercury sales persona integrated with your external workflow platform. Your AI assistant is ready to handle prospect inquiries, qualify leads, and provide personalized responses 24/7.