volkern_create_contact
Add new contacts (people or companies) to the Volkern CRM system with details like name, email, phone, and job title.
Instructions
Create a new contact (person or company)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| nombre | Yes | Contact/company name (required) | |
| No | Email address | ||
| telefono | No | Phone number | |
| tipo | No | Contact type (default: person) | |
| cargo | No | Job title (for persons) | |
| ubicacion | No | Location/address | |
| companyId | No | ID of parent company (for persons) | |
| No | LinkedIn profile URL | ||
| notas | No | Notes about the contact | |
| tags | No | Tags for categorization |
Implementation Reference
- src/index.ts:860-861 (handler)Handler case for volkern_create_contact tool - makes a POST request to /contacts endpoint with the provided arguments
case "volkern_create_contact": return volkernRequest("/contacts", "POST", args); - src/index.ts:754-757 (handler)Main handleToolCall function that dispatches tool calls to their respective handlers
async function handleToolCall( name: string, args: Record<string, unknown> ): Promise<unknown> { - src/index.ts:431-454 (schema)Schema definition for volkern_create_contact tool - defines input parameters including nombre, email, telefono, tipo, cargo, ubicacion, companyId, linkedin, notas, and tags
{ name: "volkern_create_contact", description: "Create a new contact (person or company)", inputSchema: { type: "object", properties: { nombre: { type: "string", description: "Contact/company name (required)" }, email: { type: "string", description: "Email address" }, telefono: { type: "string", description: "Phone number" }, tipo: { type: "string", enum: ["person", "company"], description: "Contact type (default: person)" }, cargo: { type: "string", description: "Job title (for persons)" }, ubicacion: { type: "string", description: "Location/address" }, companyId: { type: "string", description: "ID of parent company (for persons)" }, linkedin: { type: "string", description: "LinkedIn profile URL" }, notas: { type: "string", description: "Notes about the contact" }, tags: { type: "array", items: { type: "string" }, description: "Tags for categorization" } }, required: ["nombre"] } }, - src/index.ts:26-55 (helper)volkernRequest helper function that makes HTTP requests to the Volkern API with authentication and error handling
async function volkernRequest( endpoint: string, method: string = "GET", body?: Record<string, unknown> ): Promise<unknown> { const url = `${VOLKERN_API_URL}${endpoint}`; const options: RequestInit = { method, headers: { "Authorization": `Bearer ${VOLKERN_API_KEY}`, "Content-Type": "application/json", }, }; if (body && method !== "GET") { options.body = JSON.stringify(body); } const response = await fetch(url, options); if (!response.ok) { const errorData = await response.json().catch(() => ({})); throw new Error( `Volkern API Error (${response.status}): ${JSON.stringify(errorData)}` ); } return response.json(); } - src/index.ts:60-61 (registration)Tools array declaration where all MCP tools including volkern_create_contact are registered
const tools: Tool[] = [ // === LEADS ===