UNPKG

@iriseller/mcp-server

Version:

Model Context Protocol (MCP) server providing access to IRISeller's AI sales intelligence platform with 7 AI agents, multi-CRM integration, advanced sales workflows, email automation, Rosa demo functionality with action scoring, DNC compliance checking, G

340 lines (339 loc) 12.4 kB
import { z } from 'zod'; export declare const LeadSchema: z.ZodObject<{ id: z.ZodString; name: z.ZodString; email: z.ZodOptional<z.ZodString>; company: z.ZodString; title: z.ZodOptional<z.ZodString>; phone: z.ZodOptional<z.ZodString>; status: z.ZodOptional<z.ZodString>; industry: z.ZodOptional<z.ZodString>; source: z.ZodOptional<z.ZodString>; score: z.ZodOptional<z.ZodNumber>; }, "strip", z.ZodTypeAny, { id: string; name: string; company: string; email?: string | undefined; title?: string | undefined; phone?: string | undefined; status?: string | undefined; industry?: string | undefined; source?: string | undefined; score?: number | undefined; }, { id: string; name: string; company: string; email?: string | undefined; title?: string | undefined; phone?: string | undefined; status?: string | undefined; industry?: string | undefined; source?: string | undefined; score?: number | undefined; }>; export declare const OpportunitySchema: z.ZodObject<{ id: z.ZodString; name: z.ZodString; amount: z.ZodOptional<z.ZodNumber>; stage: z.ZodString; probability: z.ZodOptional<z.ZodNumber>; closeDate: z.ZodOptional<z.ZodString>; accountId: z.ZodOptional<z.ZodString>; ownerId: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id: string; name: string; stage: string; amount?: number | undefined; probability?: number | undefined; closeDate?: string | undefined; accountId?: string | undefined; ownerId?: string | undefined; }, { id: string; name: string; stage: string; amount?: number | undefined; probability?: number | undefined; closeDate?: string | undefined; accountId?: string | undefined; ownerId?: string | undefined; }>; export declare const ContactSchema: z.ZodObject<{ id: z.ZodString; name: z.ZodString; email: z.ZodOptional<z.ZodString>; phone: z.ZodOptional<z.ZodString>; title: z.ZodOptional<z.ZodString>; accountId: z.ZodOptional<z.ZodString>; department: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { id: string; name: string; email?: string | undefined; title?: string | undefined; phone?: string | undefined; accountId?: string | undefined; department?: string | undefined; }, { id: string; name: string; email?: string | undefined; title?: string | undefined; phone?: string | undefined; accountId?: string | undefined; department?: string | undefined; }>; export declare const CompanySchema: z.ZodObject<{ name: z.ZodString; industry: z.ZodOptional<z.ZodString>; size: z.ZodOptional<z.ZodString>; website: z.ZodOptional<z.ZodString>; location: z.ZodOptional<z.ZodString>; revenue: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { name: string; industry?: string | undefined; size?: string | undefined; website?: string | undefined; location?: string | undefined; revenue?: string | undefined; }, { name: string; industry?: string | undefined; size?: string | undefined; website?: string | undefined; location?: string | undefined; revenue?: string | undefined; }>; export declare const AgentExecutionRequestSchema: z.ZodObject<{ agent_name: z.ZodEnum<["rosa_sdr", "prospecting", "personalization", "sequence", "social_selling", "nurturing", "objection_handling"]>; input_data: z.ZodRecord<z.ZodString, z.ZodAny>; options: z.ZodOptional<z.ZodObject<{ timeout: z.ZodOptional<z.ZodNumber>; priority: z.ZodOptional<z.ZodEnum<["low", "medium", "high"]>>; include_research: z.ZodOptional<z.ZodBoolean>; }, "strip", z.ZodTypeAny, { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; include_research?: boolean | undefined; }, { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; include_research?: boolean | undefined; }>>; }, "strip", z.ZodTypeAny, { agent_name: "rosa_sdr" | "prospecting" | "personalization" | "sequence" | "social_selling" | "nurturing" | "objection_handling"; input_data: Record<string, any>; options?: { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; include_research?: boolean | undefined; } | undefined; }, { agent_name: "rosa_sdr" | "prospecting" | "personalization" | "sequence" | "social_selling" | "nurturing" | "objection_handling"; input_data: Record<string, any>; options?: { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; include_research?: boolean | undefined; } | undefined; }>; export declare const WorkflowExecutionRequestSchema: z.ZodObject<{ workflow_type: z.ZodEnum<["full_sdr_workflow", "account_based_prospecting", "lead_qualification_enhancement", "outreach_sequence_creation", "social_selling_campaign", "lead_nurturing_setup"]>; input_data: z.ZodRecord<z.ZodString, z.ZodAny>; agents_to_include: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; options: z.ZodOptional<z.ZodObject<{ timeout: z.ZodOptional<z.ZodNumber>; priority: z.ZodOptional<z.ZodEnum<["low", "medium", "high"]>>; }, "strip", z.ZodTypeAny, { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; }, { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; }>>; }, "strip", z.ZodTypeAny, { input_data: Record<string, any>; workflow_type: "full_sdr_workflow" | "account_based_prospecting" | "lead_qualification_enhancement" | "outreach_sequence_creation" | "social_selling_campaign" | "lead_nurturing_setup"; options?: { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; } | undefined; agents_to_include?: string[] | undefined; }, { input_data: Record<string, any>; workflow_type: "full_sdr_workflow" | "account_based_prospecting" | "lead_qualification_enhancement" | "outreach_sequence_creation" | "social_selling_campaign" | "lead_nurturing_setup"; options?: { timeout?: number | undefined; priority?: "low" | "medium" | "high" | undefined; } | undefined; agents_to_include?: string[] | undefined; }>; export declare const CRMQuerySchema: z.ZodObject<{ entity_type: z.ZodEnum<["leads", "opportunities", "contacts", "accounts"]>; filters: z.ZodEffects<z.ZodOptional<z.ZodUnion<[z.ZodRecord<z.ZodString, z.ZodAny>, z.ZodArray<z.ZodObject<{ field: z.ZodString; value: z.ZodAny; }, "strip", z.ZodTypeAny, { field: string; value?: any; }, { field: string; value?: any; }>, "many">]>>, Record<string, any> | undefined, Record<string, any> | { field: string; value?: any; }[] | undefined>; limit: z.ZodDefault<z.ZodNumber>; offset: z.ZodDefault<z.ZodNumber>; sort_by: z.ZodOptional<z.ZodString>; sort_order: z.ZodDefault<z.ZodEnum<["asc", "desc"]>>; }, "strip", z.ZodTypeAny, { entity_type: "leads" | "opportunities" | "contacts" | "accounts"; limit: number; offset: number; sort_order: "asc" | "desc"; filters?: Record<string, any> | undefined; sort_by?: string | undefined; }, { entity_type: "leads" | "opportunities" | "contacts" | "accounts"; filters?: Record<string, any> | { field: string; value?: any; }[] | undefined; limit?: number | undefined; offset?: number | undefined; sort_by?: string | undefined; sort_order?: "asc" | "desc" | undefined; }>; export declare const CompanyResearchRequestSchema: z.ZodObject<{ company_name: z.ZodString; industry: z.ZodOptional<z.ZodString>; research_depth: z.ZodDefault<z.ZodEnum<["basic", "comprehensive", "competitive"]>>; include_competitors: z.ZodDefault<z.ZodBoolean>; include_news: z.ZodDefault<z.ZodBoolean>; include_financials: z.ZodDefault<z.ZodBoolean>; }, "strip", z.ZodTypeAny, { company_name: string; research_depth: "basic" | "comprehensive" | "competitive"; include_competitors: boolean; include_news: boolean; include_financials: boolean; industry?: string | undefined; }, { company_name: string; industry?: string | undefined; research_depth?: "basic" | "comprehensive" | "competitive" | undefined; include_competitors?: boolean | undefined; include_news?: boolean | undefined; include_financials?: boolean | undefined; }>; export declare const PersonalizationRequestSchema: z.ZodObject<{ prospect_data: z.ZodObject<{ name: z.ZodString; company: z.ZodString; title: z.ZodOptional<z.ZodString>; industry: z.ZodOptional<z.ZodString>; email: z.ZodOptional<z.ZodString>; linkedin_url: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { name: string; company: string; email?: string | undefined; title?: string | undefined; industry?: string | undefined; linkedin_url?: string | undefined; }, { name: string; company: string; email?: string | undefined; title?: string | undefined; industry?: string | undefined; linkedin_url?: string | undefined; }>; message_type: z.ZodEnum<["email", "linkedin", "phone_script", "sequence"]>; tone: z.ZodDefault<z.ZodEnum<["professional", "casual", "consultative", "friendly"]>>; objectives: z.ZodOptional<z.ZodArray<z.ZodString, "many">>; context: z.ZodOptional<z.ZodString>; }, "strip", z.ZodTypeAny, { prospect_data: { name: string; company: string; email?: string | undefined; title?: string | undefined; industry?: string | undefined; linkedin_url?: string | undefined; }; message_type: "email" | "sequence" | "linkedin" | "phone_script"; tone: "professional" | "casual" | "consultative" | "friendly"; objectives?: string[] | undefined; context?: string | undefined; }, { prospect_data: { name: string; company: string; email?: string | undefined; title?: string | undefined; industry?: string | undefined; linkedin_url?: string | undefined; }; message_type: "email" | "sequence" | "linkedin" | "phone_script"; tone?: "professional" | "casual" | "consultative" | "friendly" | undefined; objectives?: string[] | undefined; context?: string | undefined; }>; export type Lead = z.infer<typeof LeadSchema>; export type Opportunity = z.infer<typeof OpportunitySchema>; export type Contact = z.infer<typeof ContactSchema>; export type Company = z.infer<typeof CompanySchema>; export type AgentExecutionRequest = z.infer<typeof AgentExecutionRequestSchema>; export type WorkflowExecutionRequest = z.infer<typeof WorkflowExecutionRequestSchema>; export type CRMQuery = z.infer<typeof CRMQuerySchema>; export type CompanyResearchRequest = z.infer<typeof CompanyResearchRequestSchema>; export type PersonalizationRequest = z.infer<typeof PersonalizationRequestSchema>; export interface APIResponse<T = any> { success: boolean; data?: T; error?: string; message?: string; metadata?: any; timestamp?: string; } export interface AgentExecutionResponse { execution_id: string; status: 'success' | 'error' | 'pending' | 'running' | 'completed' | 'failed' | 'completed_with_fallback'; agent_name: string; results?: any; execution_time?: number; error?: string; } export interface WorkflowExecutionResponse { workflow_id: string; status: 'success' | 'error' | 'pending' | 'completed_with_fallback'; workflow_type: string; results?: any; execution_time?: number; agents_executed?: string[]; error?: string; } export interface MCPServerConfig { name: string; version: string; iriseller_api_url: string; crewai_api_url: string; crm_connect_api_url: string; api_key?: string; jwt_secret?: string; rate_limit?: { requests_per_minute: number; burst: number; }; cache?: { ttl_seconds: number; enabled: boolean; }; debug?: boolean; }