BETA

Returns the full history of a conversation: the visitor's contact data, the initial message and all messages added to the thread, sorted chronologically.

Resource information
AuthenticationRequired (API Token, Bearer)
Scopemapaprop-chat-ai
HTTP MethodGET
ResponseJSON
Version1

Resource URL

https://mapaprop.app/api/action/mapaprop-chat-ai-v1/history/{questionId}

Parameters

KeyTypeRequiredDescription
questionIdintyesConversation ID. Sent as part of the URL (path param), not as a query string or body.

Sample code

GET /api/action/mapaprop-chat-ai-v1/history/481203 HTTP/1.1
Host: mapaprop.app
Authorization: Bearer {access_token}

Response

ObjectFieldTypeRequiredDescription
ResponsequestionIdintyesThe ID of the queried conversation.
leadNamestringyesVisitor's name.
leadEmailstringnoVisitor's email.
leadPhonestringnoVisitor's phone number.
sessionIdstringnoSession identifier associated with the conversation.
createdAtstringyesConversation creation date/time.
messageCountintyesTotal number of messages (initial message + thread).
messagesarray of objectsyesThe conversation's messages, in chronological order. See structure below.
metadataobject or stringnoAdditional metadata saved in the conversation (for example propertiesReferenced, customerSearch). If the saved data is not valid JSON, it's returned as-is as a string.

Structure of each messages element

FieldTypeDescription
idint0 for the conversation's initial message; 1, 2, 3... for the thread messages, in order.
fromstringSender's name.
messagestringThe message content.
directionint1 = inbound/visitor, 2 = outbound/agent or system, 3 = AI.
timestampstringMessage date/time.

Errors

ErrorCause
QUESTION_NOT_FOUNDThe questionId sent doesn't exist or doesn't belong to this customer.

Validation errors (the request is cut off)

ErrorCause
REQUIRED_INPUT — "questionId is required"The questionId path param is not a valid number.

Sample response

{
    "questionId": 481203,
    "leadName": "Juan Pérez",
    "leadEmail": "juan@example.com",
    "leadPhone": "+54 9 11 5555-5555",
    "sessionId": "b6d1c6b0-2f2a-4e2e-9a4a-8e0a2a2f2a11",
    "createdAt": "2026-08-01 14:32:10",
    "messageCount": 3,
    "messages": [
        {
            "id": 0,
            "from": "Juan Pérez",
            "message": "Nueva conversacion de Chat AI",
            "direction": 1,
            "timestamp": "2026-08-01 14:32:10"
        },
        {
            "id": 1,
            "from": "AI Assistant",
            "message": "Hola Juan! Soy el asistente virtual de la inmobiliaria. ¿En qué puedo ayudarte?",
            "direction": 3,
            "timestamp": "2026-08-01 14:32:10"
        },
        {
            "id": 2,
            "from": "Juan Pérez",
            "message": "¿Tenés departamentos de 2 ambientes en Palermo?",
            "direction": 1,
            "timestamp": "2026-08-01 14:33:02"
        }
    ]
}