REST · Version 1.0.0

    malma API

    Baue eigene Integrationen und Wrapper auf deinem Workspace: Leads anlegen und anrufen lassen, Agenten konfigurieren, Gesprächsanalysen abholen — oder sie dir direkt zuschicken lassen.

    https://app.malma.aiAPI-Key im Workspace

    Authentifizierung

    Jeder Aufruf erwartet einen Workspace-Token imAuthorization-Header. Den Token findest du in der Plattform unter Integrationen → API Key (anzeigen, kopieren, rotieren).

    Anfrage
    curl https://app.malma.ai/api/workspace/leads \
      -H "Authorization: Bearer ws_live_xxxxxxxxxxxxxxxx"

    Der Token hat vollen Zugriff auf seinen Workspace — behandle ihn wie ein Passwort und halte ihn serverseitig. Jede Ressource ist strikt auf den Workspace des Tokens begrenzt: Zugriff auf fremde IDs liefert 404.

    Namens-Konvention

    Ein Stolperstein beim Bauen eines Wrappers: die Schreibweise ist nicht überall gleich.

    camelCase

    Alle CRUD-Endpunkte — z. B. firstName, phoneNumber.

    snake_case

    Nur die Ingestion-Pipeline: create-lead und der Webhook — z. B. first_name, phone_number.

    Fehlercodes

    400Ungültige/fehlende Felder
    401Kein/ungültiger Token
    402Kein aktives Abo für Anrufe (nur Bulk-Call)
    403Plan-Limit erreicht (z. B. Agent-Limit)
    404Ressource nicht gefunden / gehört fremdem Workspace
    422Validierung fehlgeschlagen (nur create-lead)
    500Serverfehler

    Call-Webhook statt Polling

    Statt GET /calls/{id} abzufragen, schickt malma dir den fertig analysierten Call aktiv an deine URL — direkt nach Anrufende und Analyse. Konfiguriert wird das pro Agent:

    Aktivierung
    PATCH /api/workspace/agents/{id}
    {
      "webhookForwardingEnabled": true,
      "webhookForwardingUrl": "https://example.com/malma-webhook",
      "webhookForwardingHeaders": { "X-Api-Key": "geheim" }
    }
    • Idempotent: genau eine Zustellung pro Call, keine Doppel-Events.
    • Ziel-URL muss HTTPS sein, eigene Header (z. B. Auth) sind möglich.
    • Ein Zustellversuch, keine Retries — ist dein Endpunkt gerade nicht erreichbar, geht das Event verloren. Plane deinen Empfänger entsprechend robust.

    Leads

    Leads auflisten, anlegen, aktualisieren und Anrufketten starten.

    get/api/workspace/leads

    Leads auflisten

    Parameter

    limitQueryDefault: 50
    integer
    offsetQueryDefault: 0
    integer
    statusQuery

    Wird nicht validiert — unbekannter Wert liefert eine leere Liste (kein 400)

    string
    searchQuery

    Freitext (Name/Telefon)

    string

    Antworten

    200Liste
    data
    Lead[]
    total
    integer
    limit
    integer
    offset
    integer
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/leads \
      -H "Authorization: Bearer ws_live_dein_token"
    get/api/workspace/leads/{id}

    Lead abrufen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Lead
    id
    string · uuid
    workspaceId
    string · uuid
    firstNamenullable
    string
    lastNamenullable
    string
    phoneNumbernullable
    string
    userEmailnullable
    string
    status
    stagedreachedbookednot_reachedacceptedparkedinvalid
    string
    variables
    object
    parkedReasonnullable
    string
    leadFunnelIdnullable
    string · uuid
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/leads/{id} \
      -H "Authorization: Bearer ws_live_dein_token"
    patch/api/workspace/leads/{id}

    Lead aktualisieren (Whitelist)

    Parameter

    idPfaderforderlich
    string · uuid

    Request Body

    firstName
    string
    lastName
    string
    phoneNumber
    string
    userEmail
    string · email
    status
    stagedreachedbookednot_reachedacceptedparkedinvalid
    string
    variables
    object
    parkedReason
    string
    leadFunnelId
    string · uuid

    Antworten

    200Aktualisierter Lead
    id
    string · uuid
    workspaceId
    string · uuid
    firstNamenullable
    string
    lastNamenullable
    string
    phoneNumbernullable
    string
    userEmailnullable
    string
    status
    stagedreachedbookednot_reachedacceptedparkedinvalid
    string
    variables
    object
    parkedReasonnullable
    string
    leadFunnelIdnullable
    string · uuid
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400Leerer Body oder ungültiger status (Enum)
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X PATCH https://app.malma.ai/api/workspace/leads/{id} \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "firstName": "text",
        "lastName": "text",
        "phoneNumber": "text",
        "userEmail": "kunde@firma.de",
        "status": "staged"
      }'
    delete/api/workspace/leads/{id}

    Lead löschen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Gelöscht
    success
    boolean
    message

    Optional — Lead-DELETE liefert nur success, Contact/Ticket-DELETE auch message

    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X DELETE https://app.malma.ai/api/workspace/leads/{id} \
      -H "Authorization: Bearer ws_live_dein_token"
    post/api/workspace/create-lead

    Lead anlegen und Anruf auslösen

    Legt einen Lead im API-Default-Funnel des Workspace an und startet die Anrufkette. Nutzt die Ingestion-Validierung (4 Felder). `agent_id` überschreibt optional den Funnel-Agenten. Achtung: dieser Endpunkt nutzt snake_case, nicht camelCase.

    Löst echte, kostenpflichtige Anrufe aus.

    Request Body

    first_name
    string
    last_name
    string
    phone_numbererforderlich
    string
    email
    string · email
    agent_id

    Optionaler Agent-Override

    string · uuid

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    Antworten

    202Lead angenommen / Anruf eingeplant (asynchron)
    status
    string
    leadId
    string · uuid
    duplicate
    boolean
    blocked

    Nur bei DNC-Treffer (true)

    boolean
    reason

    Nur bei DNC-Treffer, z. B. do_not_contact

    string
    400Ungültiger Request-Body
    401Kein/ungültiger Token
    error
    string
    code
    string
    422Validierung fehlgeschlagen (Pflichtfelder / ungültige agent_id)
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/create-lead \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "phone_number": "+4915212345678",
        "first_name": "text",
        "last_name": "text",
        "email": "kunde@firma.de",
        "agent_id": "3f9a..."
      }'

    Calls

    Geführte Anrufe inklusive Transkript und Analyse abrufen.

    get/api/workspace/calls

    Calls auflisten

    Parameter

    limitQueryDefault: 50
    integer
    offsetQueryDefault: 0
    integer

    Antworten

    200Liste
    data
    Call[]
    total
    integer
    limit
    integer
    offset
    integer
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/calls \
      -H "Authorization: Bearer ws_live_dein_token"
    get/api/workspace/calls/{id}

    Call abrufen (inkl. Analyse)

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Call
    id
    string · uuid
    workspaceId
    string · uuid
    leadIdnullable
    string · uuid
    contactIdnullable
    string · uuid
    agentIdnullable
    string · uuid
    status
    string
    durationnullable
    number
    transcriptnullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/calls/{id} \
      -H "Authorization: Bearer ws_live_dein_token"

    Agents

    KI-Agenten anlegen, konfigurieren und löschen.

    post/api/workspace/agents

    Agent anlegen

    Alle Felder optional — fehlende Felder werden mit den Plattform-Defaults (inkl. deutscher Standard-Skripte) belegt. Am Included-Agent-Limit → 403 (die API kauft keine Stripe-Seats automatisch dazu).

    Request Body (optional)

    name
    string
    agentType

    Alternativ zu callDirection

    outboundinboundpersonal-assistant
    string
    callDirection
    outbound_onlyinbound_onlyinbound_outbound
    string
    voiceId
    string
    language
    string
    greeting
    string
    greetingOutbound
    string
    greetingInbound
    string
    scriptText
    string
    character
    string
    callLogic
    string
    isActive
    boolean
    imageUrl
    string

    Antworten

    201Angelegter Agent
    id
    string · uuid
    workspaceId
    string · uuid
    name
    string
    voiceId
    string
    language
    string
    greeting
    string
    scriptText
    string
    character
    string
    callLogic
    string
    callDirection
    outbound_onlyinbound_onlyinbound_outbound
    string
    isActive
    boolean
    fromNumbernullable
    string
    livekitAgentNamenullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    403Agent-Limit erreicht
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/agents \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "name": "text",
        "agentType": "outbound",
        "callDirection": "outbound_only",
        "voiceId": "text",
        "language": "de-DE"
      }'
    get/api/workspace/agents/{id}

    Agent abrufen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Agent
    id
    string · uuid
    workspaceId
    string · uuid
    name
    string
    voiceId
    string
    language
    string
    greeting
    string
    scriptText
    string
    character
    string
    callLogic
    string
    callDirection
    outbound_onlyinbound_onlyinbound_outbound
    string
    isActive
    boolean
    fromNumbernullable
    string
    livekitAgentNamenullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/agents/{id} \
      -H "Authorization: Bearer ws_live_dein_token"
    patch/api/workspace/agents/{id}

    Agent aktualisieren

    Aktualisiert die übergebenen Felder (Whitelist). Änderungen an Name/Voice/Sprache/fromNumber werden zu LiveKit synchronisiert. Hier wird auch der Call-Analyzed-Webhook konfiguriert.

    Parameter

    idPfaderforderlich
    string · uuid

    Request Body (optional)

    name
    string
    voiceId
    string
    voiceEngine
    string
    sttProvider
    string
    language
    string
    greeting
    string
    greetingOutbound
    string
    greetingInbound
    string
    scriptText
    string
    character
    string
    callLogic
    string
    callDirection
    outbound_onlyinbound_onlyinbound_outbound
    string
    isActive
    boolean
    fromNumber
    string
    maxRetries
    integer
    calEventTypeId
    string
    recordCalls
    boolean
    webhookForwardingEnabled

    Push des call_analyzed-Events an eigene URL an/aus

    boolean
    webhookForwardingUrl

    Ziel-URL für den Push, muss HTTPS sein

    string
    webhookForwardingHeadersnur schreibend

    Eigene HTTP-Header (z. B. Auth) — setzbar, wird aus Sicherheitsgründen NICHT in Responses zurückgegeben

    object

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    Antworten

    200Aktualisierter Agent
    id
    string · uuid
    workspaceId
    string · uuid
    name
    string
    voiceId
    string
    language
    string
    greeting
    string
    scriptText
    string
    character
    string
    callLogic
    string
    callDirection
    outbound_onlyinbound_onlyinbound_outbound
    string
    isActive
    boolean
    fromNumbernullable
    string
    livekitAgentNamenullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    403Feature im Workspace nicht verfügbar (z. B. s2s/elevenlabs)
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X PATCH https://app.malma.ai/api/workspace/agents/{id} \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "name": "text",
        "voiceId": "text",
        "voiceEngine": "text",
        "sttProvider": "text",
        "language": "text"
      }'
    delete/api/workspace/agents/{id}

    Agent löschen

    Löscht Agent inkl. LiveKit-Ressourcen. 400 wenn Agent in aktiven Funnels/Tasks genutzt wird.

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Gelöscht
    message
    string
    400Agent in Verwendung
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X DELETE https://app.malma.ai/api/workspace/agents/{id} \
      -H "Authorization: Bearer ws_live_dein_token"

    Kontakte

    Kontaktstamm verwalten (ab Growth-Plan).

    get/api/workspace/contacts

    Kontakte auflisten

    Parameter

    limitQueryDefault: 50
    integer
    offsetQueryDefault: 0
    integer

    Antworten

    200Liste
    data
    Contact[]
    total
    integer
    limit
    integer
    offset
    integer
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/contacts \
      -H "Authorization: Bearer ws_live_dein_token"
    post/api/workspace/contacts

    Kontakt anlegen

    Ab Growth-Plan verfügbar. Dedup läuft über die Telefonnummer.

    Request Body

    phoneNumbererforderlich
    string
    firstName
    string
    lastName
    string
    userEmail
    string · email
    agentId
    string · uuid
    type
    string
    companyName
    string
    contactPerson
    string
    address
    string
    department
    string
    source
    string
    notes
    string

    Antworten

    201Angelegter Kontakt
    id
    string · uuid
    workspaceId
    string · uuid
    companyId
    string · uuid
    firstNamenullable
    string
    lastNamenullable
    string
    phoneNumber
    string
    userEmailnullable
    string
    type
    string
    companyNamenullable
    string
    contactPersonnullable
    string
    addressnullable
    string
    departmentnullable
    string
    sourcenullable
    string
    notesnullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400Ungültige/fehlende Felder
    error
    string
    code
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    403Erst ab Growth-Plan verfügbar
    409Telefonnummer existiert bereits
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/contacts \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "phoneNumber": "text",
        "firstName": "text",
        "lastName": "text",
        "userEmail": "kunde@firma.de",
        "agentId": "3f9a..."
      }'
    get/api/workspace/contacts/{id}

    Kontakt abrufen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Kontakt
    id
    string · uuid
    workspaceId
    string · uuid
    companyId
    string · uuid
    firstNamenullable
    string
    lastNamenullable
    string
    phoneNumber
    string
    userEmailnullable
    string
    type
    string
    companyNamenullable
    string
    contactPersonnullable
    string
    addressnullable
    string
    departmentnullable
    string
    sourcenullable
    string
    notesnullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/contacts/{id} \
      -H "Authorization: Bearer ws_live_dein_token"
    patch/api/workspace/contacts/{id}

    Kontakt aktualisieren

    Parameter

    idPfaderforderlich
    string · uuid

    Request Body (optional)

    phoneNumbererforderlich
    string
    firstName
    string
    lastName
    string
    userEmail
    string · email
    agentId
    string · uuid
    type
    string
    companyName
    string
    contactPerson
    string
    address
    string
    department
    string
    source
    string
    notes
    string
    departmentIds
    string[]

    Antworten

    200Aktualisierter Kontakt
    id
    string · uuid
    workspaceId
    string · uuid
    companyId
    string · uuid
    firstNamenullable
    string
    lastNamenullable
    string
    phoneNumber
    string
    userEmailnullable
    string
    type
    string
    companyNamenullable
    string
    contactPersonnullable
    string
    addressnullable
    string
    departmentnullable
    string
    sourcenullable
    string
    notesnullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400Telefonnummer bereits vergeben
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X PATCH https://app.malma.ai/api/workspace/contacts/{id} \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "phoneNumber": "text",
        "firstName": "text",
        "lastName": "text",
        "userEmail": "kunde@firma.de",
        "agentId": "3f9a..."
      }'
    delete/api/workspace/contacts/{id}

    Kontakt löschen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Gelöscht
    success
    boolean
    message

    Optional — Lead-DELETE liefert nur success, Contact/Ticket-DELETE auch message

    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X DELETE https://app.malma.ai/api/workspace/contacts/{id} \
      -H "Authorization: Bearer ws_live_dein_token"

    Tickets

    Aus Anrufen entstandene Anliegen verwalten.

    get/api/workspace/tickets

    Tickets auflisten

    Parameter

    limitQueryDefault: 50
    integer
    offsetQueryDefault: 0
    integer

    Antworten

    200Liste
    data
    Ticket[]
    total
    integer
    limit
    integer
    offset
    integer
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/tickets \
      -H "Authorization: Bearer ws_live_dein_token"
    post/api/workspace/tickets

    Ticket anlegen

    Request Body

    ticketTypeerforderlich
    callback_requestgeneral_requestdo_not_contactdocument_sent
    string
    titleerforderlich
    string
    description
    string
    status
    openin_progressresolvedcancelled
    string
    agentId
    string · uuid
    callId
    string · uuid
    leadId
    string · uuid
    contactId
    string · uuid
    assignedTo
    string

    Antworten

    201Angelegtes Ticket
    id
    string · uuid
    workspaceId
    string · uuid
    ticketType
    callback_requestgeneral_requestdo_not_contactdocument_sent
    string
    title
    string
    descriptionnullable
    string
    status
    openin_progressresolvedcancelled
    string
    agentIdnullable
    string · uuid
    callIdnullable
    string · uuid
    leadIdnullable
    string · uuid
    contactIdnullable
    string · uuid
    assignedTonullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400Ungültige/fehlende Felder
    error
    string
    code
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/tickets \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "ticketType": "callback_request",
        "title": "text",
        "description": "text",
        "status": "open",
        "agentId": "3f9a..."
      }'
    get/api/workspace/tickets/{id}

    Ticket abrufen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Ticket
    id
    string · uuid
    workspaceId
    string · uuid
    ticketType
    callback_requestgeneral_requestdo_not_contactdocument_sent
    string
    title
    string
    descriptionnullable
    string
    status
    openin_progressresolvedcancelled
    string
    agentIdnullable
    string · uuid
    callIdnullable
    string · uuid
    leadIdnullable
    string · uuid
    contactIdnullable
    string · uuid
    assignedTonullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/tickets/{id} \
      -H "Authorization: Bearer ws_live_dein_token"
    patch/api/workspace/tickets/{id}

    Ticket-Status ändern

    Parameter

    idPfaderforderlich
    string · uuid

    Request Body

    statuserforderlich
    openin_progressresolvedcancelled
    string

    Antworten

    200Aktualisiertes Ticket
    id
    string · uuid
    workspaceId
    string · uuid
    ticketType
    callback_requestgeneral_requestdo_not_contactdocument_sent
    string
    title
    string
    descriptionnullable
    string
    status
    openin_progressresolvedcancelled
    string
    agentIdnullable
    string · uuid
    callIdnullable
    string · uuid
    leadIdnullable
    string · uuid
    contactIdnullable
    string · uuid
    assignedTonullable
    string
    createdAt
    string · date-time

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400Ungültiger/fehlender Status
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X PATCH https://app.malma.ai/api/workspace/tickets/{id} \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "status": "open"
      }'
    delete/api/workspace/tickets/{id}

    Ticket löschen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Gelöscht
    success
    boolean
    message

    Optional — Lead-DELETE liefert nur success, Contact/Ticket-DELETE auch message

    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X DELETE https://app.malma.ai/api/workspace/tickets/{id} \
      -H "Authorization: Bearer ws_live_dein_token"

    Knowledge Base

    Wissensbasis für Agenten pflegen (max. 3 pro Agent).

    get/api/workspace/knowledge-bases

    Knowledge Bases auflisten

    Antworten

    200Liste
    data
    KnowledgeBase[]
    total
    integer
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X GET https://app.malma.ai/api/workspace/knowledge-bases \
      -H "Authorization: Bearer ws_live_dein_token"
    post/api/workspace/knowledge-bases

    Knowledge Base anlegen

    Maximal 3 Knowledge Bases pro Agent.

    Request Body

    titleerforderlich
    string
    agentId

    Optional an Agent binden

    string · uuid
    text
    string
    pdfUrl
    string
    pdfFilename
    string

    Antworten

    201Angelegt
    id
    string · uuid
    workspaceId
    string · uuid
    agentIdnullable
    string · uuid
    title
    string
    textnullable
    string
    pdfUrlnullable
    string
    pdfFilenamenullable
    string

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    400title fehlt / KB-Limit erreicht / ungültiger Agent
    401Kein/ungültiger Token
    error
    string
    code
    string
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/knowledge-bases \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "title": "text",
        "agentId": "3f9a...",
        "text": "text",
        "pdfUrl": "text",
        "pdfFilename": "text"
      }'
    put/api/workspace/knowledge-bases/{id}

    Knowledge Base aktualisieren

    Parameter

    idPfaderforderlich
    string · uuid

    Request Body (optional)

    title
    string
    text
    string
    pdfUrl
    string
    pdfFilename
    string

    Antworten

    200Aktualisiert
    id
    string · uuid
    workspaceId
    string · uuid
    agentIdnullable
    string · uuid
    title
    string
    textnullable
    string
    pdfUrlnullable
    string
    pdfFilenamenullable
    string

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X PUT https://app.malma.ai/api/workspace/knowledge-bases/{id} \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "title": "text",
        "text": "text",
        "pdfUrl": "text",
        "pdfFilename": "text"
      }'
    delete/api/workspace/knowledge-bases/{id}

    Knowledge Base löschen

    Parameter

    idPfaderforderlich
    string · uuid

    Antworten

    200Gelöscht
    message
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X DELETE https://app.malma.ai/api/workspace/knowledge-bases/{id} \
      -H "Authorization: Bearer ws_live_dein_token"

    Bulk-Anrufe

    Mehrere Leads, Kontakte oder Tickets in einem Rutsch anrufen.

    post/api/workspace/leads/bulk-call

    Mehrere Leads anrufen

    Löst echte, kostenpflichtige Anrufe aus.

    Löst echte, kostenpflichtige Anrufe aus.

    Request Body

    leadIdserforderlich
    string[]
    agentIderforderlich
    string · uuid
    scheduleTypeerforderlich
    nowlater
    string
    scheduledFor

    Pflicht bei later, muss in der Zukunft liegen

    string · date-time
    personalMessage
    string

    Antworten

    200Ergebnis
    success
    boolean
    scheduled
    integer
    failed
    integer
    results
    object[]
    400Ungültige/fehlende Felder
    error
    string
    code
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/leads/bulk-call \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "leadIds": [
          "3f9a..."
        ],
        "agentId": "3f9a...",
        "scheduleType": "now",
        "scheduledFor": "2026-01-31T09:00:00Z",
        "personalMessage": "text"
      }'
    post/api/workspace/contacts/bulk-call

    Mehrere Kontakte anrufen

    Löst echte, kostenpflichtige Anrufe aus.

    Löst echte, kostenpflichtige Anrufe aus.

    Request Body

    contactIdserforderlich
    string[]
    agentIderforderlich
    string · uuid
    scheduleTypeerforderlich
    nowlater
    string
    scheduledFor
    string · date-time
    personalMessage
    string

    Antworten

    200Ergebnis
    success
    boolean
    scheduled
    integer
    failed
    integer
    results
    object[]
    400Ungültige/fehlende Felder
    error
    string
    code
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/contacts/bulk-call \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "contactIds": [
          "3f9a..."
        ],
        "agentId": "3f9a...",
        "scheduleType": "now",
        "scheduledFor": "2026-01-31T09:00:00Z",
        "personalMessage": "text"
      }'
    post/api/workspace/tickets/bulk-call

    Mehrere Tickets per Anruf lösen

    Nur offene oder als not_reached markierte Tickets; do_not_contact wird übersprungen. Achtung: die Antwort nutzt andere Feldnamen als die übrigen Bulk-Calls.

    Löst echte, kostenpflichtige Anrufe aus.

    Request Body

    ticketIdserforderlich
    string[]
    agentIderforderlich
    string · uuid
    resolutionMessage
    string
    scheduleType
    nowlater
    string
    scheduledFor
    string · date-time

    Antworten

    200Ergebnis — abweichende Feldnamen
    success
    boolean
    successCount
    integer
    totalCount
    integer
    results
    object[]
    400Ungültige/fehlende Felder
    error
    string
    code
    string
    401Kein/ungültiger Token
    error
    string
    code
    string
    402Kein aktives Abo für Anrufe
    404Nicht gefunden / fremder Workspace
    error
    string
    code
    string
    Beispiel
    curl -X POST https://app.malma.ai/api/workspace/tickets/bulk-call \
      -H "Authorization: Bearer ws_live_dein_token" \
      -H "Content-Type: application/json" \
      -d '{
        "ticketIds": [
          "3f9a..."
        ],
        "agentId": "3f9a...",
        "resolutionMessage": "text",
        "scheduleType": "now",
        "scheduledFor": "2026-01-31T09:00:00Z"
      }'

    Webhooks

    Eingehende Leads aus No-Code-Tools und ausgehender Call-Push.

    post/api/webhooks/create-lead

    Lead per Webhook anlegen (Make / Zapier / HubSpot)

    Ingestion-Endpoint für No-Code-Tools und externe Systeme. Feld-Aliase werden gemappt (z. B. vorname→first_name, phone/telefon→phone_number, email→user_email); alle weiteren Felder landen als Custom-Variablen am Lead. Telefon-Validierung: nur DACH-Nummern (+49/+43/+41) in E.164.

    Löst echte, kostenpflichtige Anrufe aus.

    Nutzt einen eigenen Webhook-Source-Token (pro Webhook-Quelle in der Plattform erstellt), NICHT den Workspace-Token. Fallback: Token als Query-Parameter ?token= für Tools, die nur einen Auth-Weg können.

    Request Body

    first_name
    string
    last_name
    string
    user_email
    string · email
    phone_numbererforderlich
    string

    Zusätzliche Felder erlaubt — sie landen als Custom-Variablen am Objekt.

    Antworten

    202Lead angenommen, Anruf eingeplant
    status
    string
    leadId
    string · uuid
    duplicate
    boolean
    400Ungültiges JSON / kein Funnel zugeordnet / Funnel inaktiv
    401Fehlender/ungültiger Webhook-Token
    403Webhook deaktiviert oder IP nicht erlaubt
    409Webhook noch nicht aktiv (Sample/Variablen-Bestätigung ausstehend)
    422Validierung fehlgeschlagen (Pflichtfelder, Nicht-DACH-Nummer → error_code INVALID_PHONE_NUMBER)
    429Rate-Limit überschritten
    Beispiel
    curl -X POST https://app.malma.ai/api/webhooks/create-lead \
      -H "Authorization: Bearer whsec_dein_webhook_token" \
      -H "Content-Type: application/json" \
      -d '{
        "phone_number": "+4915212345678",
        "first_name": "text",
        "last_name": "text",
        "user_email": "kunde@firma.de"
      }'

    Fragen zur Integration?

    Wenn du einen Wrapper baust und etwas unklar ist oder ein Endpunkt fehlt, melde dich — wir antworten direkt aus dem Team.