Get Conversation

Returns a single conversation by ID

GEThttps://api.pact.im/api/p2/conversations/<CONVERSATION_ID>

Returns a conversation of the company by ID.

URL Parameters

ParameterDescription
CONVERSATION_IDID of the conversation

Query Parameters

ParameterRequiredValidationsDescription
private_api_tokentrueMust be a stringYOUR_API_TOKEN
company_idtrueMust be an integerID of the company

Example

Request

shell
curl -X GET 'https://api.pact.im/api/p2/conversations/CONVERSATION_ID' \
  --header 'Content-Type: application/json' \
  --data '{
    "private_api_token": YOUR_API_TOKEN,
    "company_id": COMPANY_ID
  }'

Response

json
{
  "conversation": {
    "id": 18642847,
    "company_id": 52204,
    "sender_name": "79517591813",
    "sender_phone": "79517591813",
    "sender_external_id": "79517591813",
    "sender_external_public_id": "79517591813",
    "provider": "whatsapp",
    "avatar_url": "http://localhost:3000/avatars/original/missing.png",
    "created_at": "2024-11-11T12:35:57.995Z",
    "last_updated_at": "2024-11-21T08:37:36.000Z",
    "last_message_id": 14056,
    "operational_state": "open",
    "replied_state": "replied",
    "group": false
  }
}

Search…

Start typing to search