Skip to main content
POST
/
sandbox
/
salesforce
/
{sandbox_id}
/
initialize
Initialize salesforce sandbox with data
curl --request POST \
  --url https://api.klavis.ai/sandbox/salesforce/{sandbox_id}/initialize \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "accounts": [
    {
      "name": "Acme Corporation",
      "industry": "Technology",
      "type": "Customer",
      "phone": "+1-555-0100",
      "website": "https://www.acmecorp.com",
      "revenue": 5000000,
      "employees": 250,
      "address": {
        "street": "123 Tech Street",
        "city": "San Francisco",
        "state": "California",
        "postal_code": "94105",
        "country": "United States"
      },
      "description": "Leading technology solutions provider",
      "rating": "Hot"
    },
    {
      "name": "Global Enterprises Inc",
      "industry": "Finance",
      "type": "Prospect",
      "phone": "+1-555-0200",
      "website": "https://www.globalenterprises.com",
      "revenue": 15000000,
      "employees": 500,
      "address": {
        "street": "456 Finance Ave",
        "city": "New York",
        "state": "New York",
        "postal_code": "10001",
        "country": "United States"
      },
      "description": "International financial services company",
      "rating": "Warm"
    },
    {
      "name": "Tech Solutions Ltd",
      "industry": "Technology",
      "type": "Partner",
      "phone": "+1-555-0300",
      "website": "https://www.techsolutions.com",
      "revenue": 3000000,
      "employees": 150,
      "address": {
        "street": "789 Innovation Blvd",
        "city": "Austin",
        "state": "Texas",
        "postal_code": "78701",
        "country": "United States"
      },
      "description": "Custom software development partner",
      "rating": "Hot"
    }
  ],
  "contacts": [
    {
      "first_name": "John",
      "last_name": "Doe",
      "email": "john.doe@acmecorp.com",
      "phone": "+1-555-0101",
      "mobile": "+1-555-0102",
      "title": "VP of Technology",
      "department": "IT",
      "address": {
        "street": "123 Tech Street",
        "city": "San Francisco",
        "state": "California",
        "postal_code": "94105",
        "country": "United States"
      },
      "description": "Key decision maker for technology purchases",
      "source": "Web"
    },
    {
      "first_name": "Jane",
      "last_name": "Smith",
      "email": "jane.smith@globalenterprises.com",
      "phone": "+1-555-0201",
      "mobile": "+1-555-0202",
      "title": "Chief Financial Officer",
      "department": "Finance",
      "address": {
        "street": "456 Finance Ave",
        "city": "New York",
        "state": "New York",
        "postal_code": "10001",
        "country": "United States"
      },
      "description": "Budget approver and executive sponsor",
      "source": "Phone Inquiry"
    },
    {
      "first_name": "Bob",
      "last_name": "Johnson",
      "email": "bob.johnson@techsolutions.com",
      "phone": "+1-555-0301",
      "mobile": "+1-555-0302",
      "title": "Director of Operations",
      "department": "Operations",
      "address": {
        "street": "789 Innovation Blvd",
        "city": "Austin",
        "state": "Texas",
        "postal_code": "78701",
        "country": "United States"
      },
      "description": "Partnership coordinator and technical lead",
      "source": "Partner Referral"
    },
    {
      "first_name": "Alice",
      "last_name": "Williams",
      "email": "alice.williams@acmecorp.com",
      "phone": "+1-555-0103",
      "title": "Product Manager",
      "department": "Product",
      "source": "Web"
    },
    {
      "first_name": "Charlie",
      "last_name": "Brown",
      "email": "charlie.brown@globalenterprises.com",
      "phone": "+1-555-0203",
      "title": "IT Manager",
      "department": "IT",
      "source": "Trade Show"
    }
  ],
  "leads": [
    {
      "first_name": "David",
      "last_name": "Martinez",
      "company": "Startup Innovations Inc",
      "email": "david.martinez@startupinnovations.com",
      "phone": "+1-555-0400",
      "mobile": "+1-555-0401",
      "title": "Founder & CEO",
      "status": "Open - Not Contacted",
      "source": "Web",
      "industry": "Technology",
      "rating": "Hot",
      "address": {
        "street": "321 Startup Lane",
        "city": "Seattle",
        "state": "Washington",
        "postal_code": "98101",
        "country": "United States"
      },
      "website": "https://www.startupinnovations.com",
      "employees": 25,
      "revenue": 500000,
      "description": "Fast-growing startup looking for enterprise solutions"
    },
    {
      "first_name": "Emma",
      "last_name": "Garcia",
      "company": "Healthcare Systems LLC",
      "email": "emma.garcia@healthcaresystems.com",
      "phone": "+1-555-0500",
      "title": "Director of IT",
      "status": "Working - Contacted",
      "source": "Phone Inquiry",
      "industry": "Healthcare",
      "rating": "Warm",
      "address": {
        "city": "Boston",
        "state": "Massachusetts",
        "country": "United States"
      },
      "employees": 300,
      "description": "Exploring new healthcare IT solutions"
    },
    {
      "first_name": "Frank",
      "last_name": "Wilson",
      "company": "Manufacturing Corp",
      "email": "frank.wilson@manufacturingcorp.com",
      "phone": "+1-555-0600",
      "title": "Operations Manager",
      "status": "Open - Not Contacted",
      "source": "Partner Referral",
      "industry": "Manufacturing",
      "rating": "Warm",
      "address": {
        "city": "Detroit",
        "state": "Michigan",
        "country": "United States"
      },
      "description": "Interested in automation solutions"
    }
  ],
  "opportunities": [
    {
      "name": "Acme Corp - Q4 Enterprise Deal",
      "stage": "Qualification",
      "close_date": "2025-12-31",
      "amount": 250000,
      "probability": 75,
      "type": "New Business",
      "source": "Web",
      "next_step": "Schedule executive demo",
      "description": "Large enterprise deal for full platform implementation"
    },
    {
      "name": "Global Enterprises - Annual Subscription",
      "stage": "Proposal/Price Quote",
      "close_date": "2026-02-28",
      "amount": 500000,
      "probability": 50,
      "type": "New Business",
      "source": "Phone Inquiry",
      "next_step": "Present pricing proposal to CFO",
      "description": "Multi-year subscription for financial services platform"
    },
    {
      "name": "Tech Solutions - Partnership Expansion",
      "stage": "Negotiation/Review",
      "close_date": "2025-12-07",
      "amount": 150000,
      "probability": 80,
      "type": "Existing Business",
      "source": "Partner Referral",
      "next_step": "Finalize contract terms",
      "description": "Expanding existing partnership agreement"
    },
    {
      "name": "Acme Corp - Additional Licenses",
      "stage": "Prospecting",
      "close_date": "2026-02-28",
      "amount": 75000,
      "probability": 60,
      "type": "Existing Business",
      "source": "Web",
      "next_step": "Identify additional use cases",
      "description": "Upsell opportunity for additional user licenses"
    }
  ],
  "cases": [
    {
      "subject": "Login Issues - Urgent",
      "status": "New",
      "priority": "High",
      "origin": "Phone",
      "type": "Problem",
      "description": "Customer reporting intermittent login failures affecting multiple users",
      "customer_email": "support@acmecorp.com",
      "customer_name": "John Doe",
      "customer_phone": "+1-555-0101"
    },
    {
      "subject": "Feature Request - Custom Reporting",
      "status": "Working",
      "priority": "Medium",
      "origin": "Email",
      "type": "Feature Request",
      "reason": "Enhancement",
      "description": "Customer requesting custom reporting capabilities for executive dashboard"
    },
    {
      "subject": "API Integration Question",
      "status": "New",
      "priority": "Low",
      "origin": "Web",
      "type": "Question",
      "description": "Developer needs clarification on API authentication flow",
      "customer_email": "developer@techsolutions.com"
    },
    {
      "subject": "Performance Degradation",
      "status": "Escalated",
      "priority": "High",
      "origin": "Phone",
      "type": "Problem",
      "description": "System response times have increased significantly during peak hours"
    },
    {
      "subject": "Training Request",
      "status": "New",
      "priority": "Medium",
      "origin": "Email",
      "type": "Question",
      "description": "New admin team needs comprehensive platform training"
    }
  ],
  "campaigns": [
    {
      "name": "Q4 2024 Product Launch",
      "type": "Email",
      "status": "In Progress",
      "start_date": "2024-10-01",
      "end_date": "2024-12-31",
      "expected_revenue": 1000000,
      "budget": 50000,
      "actual_cost": 25000,
      "description": "Major product launch campaign targeting enterprise customers",
      "active": true
    },
    {
      "name": "Partner Webinar Series",
      "type": "Webinar",
      "status": "Planned",
      "start_date": "2025-01-15",
      "end_date": "2025-03-31",
      "expected_revenue": 250000,
      "budget": 15000,
      "description": "Educational webinar series for partner network",
      "active": false
    },
    {
      "name": "Industry Conference 2024",
      "type": "Conference",
      "status": "Completed",
      "start_date": "2024-09-15",
      "end_date": "2024-09-17",
      "expected_revenue": 500000,
      "budget": 75000,
      "actual_cost": 80000,
      "description": "Annual industry conference with booth and speaking sessions",
      "active": false
    }
  ]
}
'
import requests

url = "https://api.klavis.ai/sandbox/salesforce/{sandbox_id}/initialize"

payload = {
"accounts": [
{
"name": "Acme Corporation",
"industry": "Technology",
"type": "Customer",
"phone": "+1-555-0100",
"website": "https://www.acmecorp.com",
"revenue": 5000000,
"employees": 250,
"address": {
"street": "123 Tech Street",
"city": "San Francisco",
"state": "California",
"postal_code": "94105",
"country": "United States"
},
"description": "Leading technology solutions provider",
"rating": "Hot"
},
{
"name": "Global Enterprises Inc",
"industry": "Finance",
"type": "Prospect",
"phone": "+1-555-0200",
"website": "https://www.globalenterprises.com",
"revenue": 15000000,
"employees": 500,
"address": {
"street": "456 Finance Ave",
"city": "New York",
"state": "New York",
"postal_code": "10001",
"country": "United States"
},
"description": "International financial services company",
"rating": "Warm"
},
{
"name": "Tech Solutions Ltd",
"industry": "Technology",
"type": "Partner",
"phone": "+1-555-0300",
"website": "https://www.techsolutions.com",
"revenue": 3000000,
"employees": 150,
"address": {
"street": "789 Innovation Blvd",
"city": "Austin",
"state": "Texas",
"postal_code": "78701",
"country": "United States"
},
"description": "Custom software development partner",
"rating": "Hot"
}
],
"contacts": [
{
"first_name": "John",
"last_name": "Doe",
"email": "john.doe@acmecorp.com",
"phone": "+1-555-0101",
"mobile": "+1-555-0102",
"title": "VP of Technology",
"department": "IT",
"address": {
"street": "123 Tech Street",
"city": "San Francisco",
"state": "California",
"postal_code": "94105",
"country": "United States"
},
"description": "Key decision maker for technology purchases",
"source": "Web"
},
{
"first_name": "Jane",
"last_name": "Smith",
"email": "jane.smith@globalenterprises.com",
"phone": "+1-555-0201",
"mobile": "+1-555-0202",
"title": "Chief Financial Officer",
"department": "Finance",
"address": {
"street": "456 Finance Ave",
"city": "New York",
"state": "New York",
"postal_code": "10001",
"country": "United States"
},
"description": "Budget approver and executive sponsor",
"source": "Phone Inquiry"
},
{
"first_name": "Bob",
"last_name": "Johnson",
"email": "bob.johnson@techsolutions.com",
"phone": "+1-555-0301",
"mobile": "+1-555-0302",
"title": "Director of Operations",
"department": "Operations",
"address": {
"street": "789 Innovation Blvd",
"city": "Austin",
"state": "Texas",
"postal_code": "78701",
"country": "United States"
},
"description": "Partnership coordinator and technical lead",
"source": "Partner Referral"
},
{
"first_name": "Alice",
"last_name": "Williams",
"email": "alice.williams@acmecorp.com",
"phone": "+1-555-0103",
"title": "Product Manager",
"department": "Product",
"source": "Web"
},
{
"first_name": "Charlie",
"last_name": "Brown",
"email": "charlie.brown@globalenterprises.com",
"phone": "+1-555-0203",
"title": "IT Manager",
"department": "IT",
"source": "Trade Show"
}
],
"leads": [
{
"first_name": "David",
"last_name": "Martinez",
"company": "Startup Innovations Inc",
"email": "david.martinez@startupinnovations.com",
"phone": "+1-555-0400",
"mobile": "+1-555-0401",
"title": "Founder & CEO",
"status": "Open - Not Contacted",
"source": "Web",
"industry": "Technology",
"rating": "Hot",
"address": {
"street": "321 Startup Lane",
"city": "Seattle",
"state": "Washington",
"postal_code": "98101",
"country": "United States"
},
"website": "https://www.startupinnovations.com",
"employees": 25,
"revenue": 500000,
"description": "Fast-growing startup looking for enterprise solutions"
},
{
"first_name": "Emma",
"last_name": "Garcia",
"company": "Healthcare Systems LLC",
"email": "emma.garcia@healthcaresystems.com",
"phone": "+1-555-0500",
"title": "Director of IT",
"status": "Working - Contacted",
"source": "Phone Inquiry",
"industry": "Healthcare",
"rating": "Warm",
"address": {
"city": "Boston",
"state": "Massachusetts",
"country": "United States"
},
"employees": 300,
"description": "Exploring new healthcare IT solutions"
},
{
"first_name": "Frank",
"last_name": "Wilson",
"company": "Manufacturing Corp",
"email": "frank.wilson@manufacturingcorp.com",
"phone": "+1-555-0600",
"title": "Operations Manager",
"status": "Open - Not Contacted",
"source": "Partner Referral",
"industry": "Manufacturing",
"rating": "Warm",
"address": {
"city": "Detroit",
"state": "Michigan",
"country": "United States"
},
"description": "Interested in automation solutions"
}
],
"opportunities": [
{
"name": "Acme Corp - Q4 Enterprise Deal",
"stage": "Qualification",
"close_date": "2025-12-31",
"amount": 250000,
"probability": 75,
"type": "New Business",
"source": "Web",
"next_step": "Schedule executive demo",
"description": "Large enterprise deal for full platform implementation"
},
{
"name": "Global Enterprises - Annual Subscription",
"stage": "Proposal/Price Quote",
"close_date": "2026-02-28",
"amount": 500000,
"probability": 50,
"type": "New Business",
"source": "Phone Inquiry",
"next_step": "Present pricing proposal to CFO",
"description": "Multi-year subscription for financial services platform"
},
{
"name": "Tech Solutions - Partnership Expansion",
"stage": "Negotiation/Review",
"close_date": "2025-12-07",
"amount": 150000,
"probability": 80,
"type": "Existing Business",
"source": "Partner Referral",
"next_step": "Finalize contract terms",
"description": "Expanding existing partnership agreement"
},
{
"name": "Acme Corp - Additional Licenses",
"stage": "Prospecting",
"close_date": "2026-02-28",
"amount": 75000,
"probability": 60,
"type": "Existing Business",
"source": "Web",
"next_step": "Identify additional use cases",
"description": "Upsell opportunity for additional user licenses"
}
],
"cases": [
{
"subject": "Login Issues - Urgent",
"status": "New",
"priority": "High",
"origin": "Phone",
"type": "Problem",
"description": "Customer reporting intermittent login failures affecting multiple users",
"customer_email": "support@acmecorp.com",
"customer_name": "John Doe",
"customer_phone": "+1-555-0101"
},
{
"subject": "Feature Request - Custom Reporting",
"status": "Working",
"priority": "Medium",
"origin": "Email",
"type": "Feature Request",
"reason": "Enhancement",
"description": "Customer requesting custom reporting capabilities for executive dashboard"
},
{
"subject": "API Integration Question",
"status": "New",
"priority": "Low",
"origin": "Web",
"type": "Question",
"description": "Developer needs clarification on API authentication flow",
"customer_email": "developer@techsolutions.com"
},
{
"subject": "Performance Degradation",
"status": "Escalated",
"priority": "High",
"origin": "Phone",
"type": "Problem",
"description": "System response times have increased significantly during peak hours"
},
{
"subject": "Training Request",
"status": "New",
"priority": "Medium",
"origin": "Email",
"type": "Question",
"description": "New admin team needs comprehensive platform training"
}
],
"campaigns": [
{
"name": "Q4 2024 Product Launch",
"type": "Email",
"status": "In Progress",
"start_date": "2024-10-01",
"end_date": "2024-12-31",
"expected_revenue": 1000000,
"budget": 50000,
"actual_cost": 25000,
"description": "Major product launch campaign targeting enterprise customers",
"active": True
},
{
"name": "Partner Webinar Series",
"type": "Webinar",
"status": "Planned",
"start_date": "2025-01-15",
"end_date": "2025-03-31",
"expected_revenue": 250000,
"budget": 15000,
"description": "Educational webinar series for partner network",
"active": False
},
{
"name": "Industry Conference 2024",
"type": "Conference",
"status": "Completed",
"start_date": "2024-09-15",
"end_date": "2024-09-17",
"expected_revenue": 500000,
"budget": 75000,
"actual_cost": 80000,
"description": "Annual industry conference with booth and speaking sessions",
"active": False
}
]
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.post(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accounts: [
{
name: 'Acme Corporation',
industry: 'Technology',
type: 'Customer',
phone: '+1-555-0100',
website: 'https://www.acmecorp.com',
revenue: 5000000,
employees: 250,
address: {
street: '123 Tech Street',
city: 'San Francisco',
state: 'California',
postal_code: '94105',
country: 'United States'
},
description: 'Leading technology solutions provider',
rating: 'Hot'
},
{
name: 'Global Enterprises Inc',
industry: 'Finance',
type: 'Prospect',
phone: '+1-555-0200',
website: 'https://www.globalenterprises.com',
revenue: 15000000,
employees: 500,
address: {
street: '456 Finance Ave',
city: 'New York',
state: 'New York',
postal_code: '10001',
country: 'United States'
},
description: 'International financial services company',
rating: 'Warm'
},
{
name: 'Tech Solutions Ltd',
industry: 'Technology',
type: 'Partner',
phone: '+1-555-0300',
website: 'https://www.techsolutions.com',
revenue: 3000000,
employees: 150,
address: {
street: '789 Innovation Blvd',
city: 'Austin',
state: 'Texas',
postal_code: '78701',
country: 'United States'
},
description: 'Custom software development partner',
rating: 'Hot'
}
],
contacts: [
{
first_name: 'John',
last_name: 'Doe',
email: 'john.doe@acmecorp.com',
phone: '+1-555-0101',
mobile: '+1-555-0102',
title: 'VP of Technology',
department: 'IT',
address: {
street: '123 Tech Street',
city: 'San Francisco',
state: 'California',
postal_code: '94105',
country: 'United States'
},
description: 'Key decision maker for technology purchases',
source: 'Web'
},
{
first_name: 'Jane',
last_name: 'Smith',
email: 'jane.smith@globalenterprises.com',
phone: '+1-555-0201',
mobile: '+1-555-0202',
title: 'Chief Financial Officer',
department: 'Finance',
address: {
street: '456 Finance Ave',
city: 'New York',
state: 'New York',
postal_code: '10001',
country: 'United States'
},
description: 'Budget approver and executive sponsor',
source: 'Phone Inquiry'
},
{
first_name: 'Bob',
last_name: 'Johnson',
email: 'bob.johnson@techsolutions.com',
phone: '+1-555-0301',
mobile: '+1-555-0302',
title: 'Director of Operations',
department: 'Operations',
address: {
street: '789 Innovation Blvd',
city: 'Austin',
state: 'Texas',
postal_code: '78701',
country: 'United States'
},
description: 'Partnership coordinator and technical lead',
source: 'Partner Referral'
},
{
first_name: 'Alice',
last_name: 'Williams',
email: 'alice.williams@acmecorp.com',
phone: '+1-555-0103',
title: 'Product Manager',
department: 'Product',
source: 'Web'
},
{
first_name: 'Charlie',
last_name: 'Brown',
email: 'charlie.brown@globalenterprises.com',
phone: '+1-555-0203',
title: 'IT Manager',
department: 'IT',
source: 'Trade Show'
}
],
leads: [
{
first_name: 'David',
last_name: 'Martinez',
company: 'Startup Innovations Inc',
email: 'david.martinez@startupinnovations.com',
phone: '+1-555-0400',
mobile: '+1-555-0401',
title: 'Founder & CEO',
status: 'Open - Not Contacted',
source: 'Web',
industry: 'Technology',
rating: 'Hot',
address: {
street: '321 Startup Lane',
city: 'Seattle',
state: 'Washington',
postal_code: '98101',
country: 'United States'
},
website: 'https://www.startupinnovations.com',
employees: 25,
revenue: 500000,
description: 'Fast-growing startup looking for enterprise solutions'
},
{
first_name: 'Emma',
last_name: 'Garcia',
company: 'Healthcare Systems LLC',
email: 'emma.garcia@healthcaresystems.com',
phone: '+1-555-0500',
title: 'Director of IT',
status: 'Working - Contacted',
source: 'Phone Inquiry',
industry: 'Healthcare',
rating: 'Warm',
address: {city: 'Boston', state: 'Massachusetts', country: 'United States'},
employees: 300,
description: 'Exploring new healthcare IT solutions'
},
{
first_name: 'Frank',
last_name: 'Wilson',
company: 'Manufacturing Corp',
email: 'frank.wilson@manufacturingcorp.com',
phone: '+1-555-0600',
title: 'Operations Manager',
status: 'Open - Not Contacted',
source: 'Partner Referral',
industry: 'Manufacturing',
rating: 'Warm',
address: {city: 'Detroit', state: 'Michigan', country: 'United States'},
description: 'Interested in automation solutions'
}
],
opportunities: [
{
name: 'Acme Corp - Q4 Enterprise Deal',
stage: 'Qualification',
close_date: '2025-12-31',
amount: 250000,
probability: 75,
type: 'New Business',
source: 'Web',
next_step: 'Schedule executive demo',
description: 'Large enterprise deal for full platform implementation'
},
{
name: 'Global Enterprises - Annual Subscription',
stage: 'Proposal/Price Quote',
close_date: '2026-02-28',
amount: 500000,
probability: 50,
type: 'New Business',
source: 'Phone Inquiry',
next_step: 'Present pricing proposal to CFO',
description: 'Multi-year subscription for financial services platform'
},
{
name: 'Tech Solutions - Partnership Expansion',
stage: 'Negotiation/Review',
close_date: '2025-12-07',
amount: 150000,
probability: 80,
type: 'Existing Business',
source: 'Partner Referral',
next_step: 'Finalize contract terms',
description: 'Expanding existing partnership agreement'
},
{
name: 'Acme Corp - Additional Licenses',
stage: 'Prospecting',
close_date: '2026-02-28',
amount: 75000,
probability: 60,
type: 'Existing Business',
source: 'Web',
next_step: 'Identify additional use cases',
description: 'Upsell opportunity for additional user licenses'
}
],
cases: [
{
subject: 'Login Issues - Urgent',
status: 'New',
priority: 'High',
origin: 'Phone',
type: 'Problem',
description: 'Customer reporting intermittent login failures affecting multiple users',
customer_email: 'support@acmecorp.com',
customer_name: 'John Doe',
customer_phone: '+1-555-0101'
},
{
subject: 'Feature Request - Custom Reporting',
status: 'Working',
priority: 'Medium',
origin: 'Email',
type: 'Feature Request',
reason: 'Enhancement',
description: 'Customer requesting custom reporting capabilities for executive dashboard'
},
{
subject: 'API Integration Question',
status: 'New',
priority: 'Low',
origin: 'Web',
type: 'Question',
description: 'Developer needs clarification on API authentication flow',
customer_email: 'developer@techsolutions.com'
},
{
subject: 'Performance Degradation',
status: 'Escalated',
priority: 'High',
origin: 'Phone',
type: 'Problem',
description: 'System response times have increased significantly during peak hours'
},
{
subject: 'Training Request',
status: 'New',
priority: 'Medium',
origin: 'Email',
type: 'Question',
description: 'New admin team needs comprehensive platform training'
}
],
campaigns: [
{
name: 'Q4 2024 Product Launch',
type: 'Email',
status: 'In Progress',
start_date: '2024-10-01',
end_date: '2024-12-31',
expected_revenue: 1000000,
budget: 50000,
actual_cost: 25000,
description: 'Major product launch campaign targeting enterprise customers',
active: true
},
{
name: 'Partner Webinar Series',
type: 'Webinar',
status: 'Planned',
start_date: '2025-01-15',
end_date: '2025-03-31',
expected_revenue: 250000,
budget: 15000,
description: 'Educational webinar series for partner network',
active: false
},
{
name: 'Industry Conference 2024',
type: 'Conference',
status: 'Completed',
start_date: '2024-09-15',
end_date: '2024-09-17',
expected_revenue: 500000,
budget: 75000,
actual_cost: 80000,
description: 'Annual industry conference with booth and speaking sessions',
active: false
}
]
})
};

fetch('https://api.klavis.ai/sandbox/salesforce/{sandbox_id}/initialize', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
accounts: [
{
name: 'Acme Corporation',
industry: 'Technology',
type: 'Customer',
phone: '+1-555-0100',
website: 'https://www.acmecorp.com',
revenue: 5000000,
employees: 250,
address: {
street: '123 Tech Street',
city: 'San Francisco',
state: 'California',
postal_code: '94105',
country: 'United States'
},
description: 'Leading technology solutions provider',
rating: 'Hot'
},
{
name: 'Global Enterprises Inc',
industry: 'Finance',
type: 'Prospect',
phone: '+1-555-0200',
website: 'https://www.globalenterprises.com',
revenue: 15000000,
employees: 500,
address: {
street: '456 Finance Ave',
city: 'New York',
state: 'New York',
postal_code: '10001',
country: 'United States'
},
description: 'International financial services company',
rating: 'Warm'
},
{
name: 'Tech Solutions Ltd',
industry: 'Technology',
type: 'Partner',
phone: '+1-555-0300',
website: 'https://www.techsolutions.com',
revenue: 3000000,
employees: 150,
address: {
street: '789 Innovation Blvd',
city: 'Austin',
state: 'Texas',
postal_code: '78701',
country: 'United States'
},
description: 'Custom software development partner',
rating: 'Hot'
}
],
contacts: [
{
first_name: 'John',
last_name: 'Doe',
email: 'john.doe@acmecorp.com',
phone: '+1-555-0101',
mobile: '+1-555-0102',
title: 'VP of Technology',
department: 'IT',
address: {
street: '123 Tech Street',
city: 'San Francisco',
state: 'California',
postal_code: '94105',
country: 'United States'
},
description: 'Key decision maker for technology purchases',
source: 'Web'
},
{
first_name: 'Jane',
last_name: 'Smith',
email: 'jane.smith@globalenterprises.com',
phone: '+1-555-0201',
mobile: '+1-555-0202',
title: 'Chief Financial Officer',
department: 'Finance',
address: {
street: '456 Finance Ave',
city: 'New York',
state: 'New York',
postal_code: '10001',
country: 'United States'
},
description: 'Budget approver and executive sponsor',
source: 'Phone Inquiry'
},
{
first_name: 'Bob',
last_name: 'Johnson',
email: 'bob.johnson@techsolutions.com',
phone: '+1-555-0301',
mobile: '+1-555-0302',
title: 'Director of Operations',
department: 'Operations',
address: {
street: '789 Innovation Blvd',
city: 'Austin',
state: 'Texas',
postal_code: '78701',
country: 'United States'
},
description: 'Partnership coordinator and technical lead',
source: 'Partner Referral'
},
{
first_name: 'Alice',
last_name: 'Williams',
email: 'alice.williams@acmecorp.com',
phone: '+1-555-0103',
title: 'Product Manager',
department: 'Product',
source: 'Web'
},
{
first_name: 'Charlie',
last_name: 'Brown',
email: 'charlie.brown@globalenterprises.com',
phone: '+1-555-0203',
title: 'IT Manager',
department: 'IT',
source: 'Trade Show'
}
],
leads: [
{
first_name: 'David',
last_name: 'Martinez',
company: 'Startup Innovations Inc',
email: 'david.martinez@startupinnovations.com',
phone: '+1-555-0400',
mobile: '+1-555-0401',
title: 'Founder & CEO',
status: 'Open - Not Contacted',
source: 'Web',
industry: 'Technology',
rating: 'Hot',
address: {
street: '321 Startup Lane',
city: 'Seattle',
state: 'Washington',
postal_code: '98101',
country: 'United States'
},
website: 'https://www.startupinnovations.com',
employees: 25,
revenue: 500000,
description: 'Fast-growing startup looking for enterprise solutions'
},
{
first_name: 'Emma',
last_name: 'Garcia',
company: 'Healthcare Systems LLC',
email: 'emma.garcia@healthcaresystems.com',
phone: '+1-555-0500',
title: 'Director of IT',
status: 'Working - Contacted',
source: 'Phone Inquiry',
industry: 'Healthcare',
rating: 'Warm',
address: {city: 'Boston', state: 'Massachusetts', country: 'United States'},
employees: 300,
description: 'Exploring new healthcare IT solutions'
},
{
first_name: 'Frank',
last_name: 'Wilson',
company: 'Manufacturing Corp',
email: 'frank.wilson@manufacturingcorp.com',
phone: '+1-555-0600',
title: 'Operations Manager',
status: 'Open - Not Contacted',
source: 'Partner Referral',
industry: 'Manufacturing',
rating: 'Warm',
address: {city: 'Detroit', state: 'Michigan', country: 'United States'},
description: 'Interested in automation solutions'
}
],
opportunities: [
{
name: 'Acme Corp - Q4 Enterprise Deal',
stage: 'Qualification',
close_date: '2025-12-31',
amount: 250000,
probability: 75,
type: 'New Business',
source: 'Web',
next_step: 'Schedule executive demo',
description: 'Large enterprise deal for full platform implementation'
},
{
name: 'Global Enterprises - Annual Subscription',
stage: 'Proposal/Price Quote',
close_date: '2026-02-28',
amount: 500000,
probability: 50,
type: 'New Business',
source: 'Phone Inquiry',
next_step: 'Present pricing proposal to CFO',
description: 'Multi-year subscription for financial services platform'
},
{
name: 'Tech Solutions - Partnership Expansion',
stage: 'Negotiation/Review',
close_date: '2025-12-07',
amount: 150000,
probability: 80,
type: 'Existing Business',
source: 'Partner Referral',
next_step: 'Finalize contract terms',
description: 'Expanding existing partnership agreement'
},
{
name: 'Acme Corp - Additional Licenses',
stage: 'Prospecting',
close_date: '2026-02-28',
amount: 75000,
probability: 60,
type: 'Existing Business',
source: 'Web',
next_step: 'Identify additional use cases',
description: 'Upsell opportunity for additional user licenses'
}
],
cases: [
{
subject: 'Login Issues - Urgent',
status: 'New',
priority: 'High',
origin: 'Phone',
type: 'Problem',
description: 'Customer reporting intermittent login failures affecting multiple users',
customer_email: 'support@acmecorp.com',
customer_name: 'John Doe',
customer_phone: '+1-555-0101'
},
{
subject: 'Feature Request - Custom Reporting',
status: 'Working',
priority: 'Medium',
origin: 'Email',
type: 'Feature Request',
reason: 'Enhancement',
description: 'Customer requesting custom reporting capabilities for executive dashboard'
},
{
subject: 'API Integration Question',
status: 'New',
priority: 'Low',
origin: 'Web',
type: 'Question',
description: 'Developer needs clarification on API authentication flow',
customer_email: 'developer@techsolutions.com'
},
{
subject: 'Performance Degradation',
status: 'Escalated',
priority: 'High',
origin: 'Phone',
type: 'Problem',
description: 'System response times have increased significantly during peak hours'
},
{
subject: 'Training Request',
status: 'New',
priority: 'Medium',
origin: 'Email',
type: 'Question',
description: 'New admin team needs comprehensive platform training'
}
],
campaigns: [
{
name: 'Q4 2024 Product Launch',
type: 'Email',
status: 'In Progress',
start_date: '2024-10-01',
end_date: '2024-12-31',
expected_revenue: 1000000,
budget: 50000,
actual_cost: 25000,
description: 'Major product launch campaign targeting enterprise customers',
active: true
},
{
name: 'Partner Webinar Series',
type: 'Webinar',
status: 'Planned',
start_date: '2025-01-15',
end_date: '2025-03-31',
expected_revenue: 250000,
budget: 15000,
description: 'Educational webinar series for partner network',
active: false
},
{
name: 'Industry Conference 2024',
type: 'Conference',
status: 'Completed',
start_date: '2024-09-15',
end_date: '2024-09-17',
expected_revenue: 500000,
budget: 75000,
actual_cost: 80000,
description: 'Annual industry conference with booth and speaking sessions',
active: false
}
]
})
};

fetch('https://api.klavis.ai/sandbox/salesforce/{sandbox_id}/initialize', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
{
  "sandbox_id": "<string>",
  "message": "<string>"
}
{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}

Authorizations

Authorization
string
header
required

Your Klavis AI API key.

Path Parameters

sandbox_id
string
required

The unique sandbox identifier

Query Parameters

init_default_data
boolean
default:false

If true, use default test data for initialization

Body

application/json

Complete Salesforce sandbox data

accounts
Account · object[] | null
contacts
Contact · object[] | null
opportunities
Opportunity · object[] | null
leads
Lead · object[] | null
cases
Case · object[] | null
campaigns
Campaign · object[] | null

Response

Successful Response

Response model for sandbox initialization

sandbox_id
string
required

Sandbox identifier

status
enum<string>
required

Current status

Available options:
idle,
occupied,
error
message
string
required

Initialization result message