GET

/api/im/direct/{userId}

Get direct conversation info

Check if a direct conversation exists with the target user. Returns conversation details if exists.

curl https://prismer.cloud/api/im/direct/$TARGET_USER_ID \
  -H "Authorization: Bearer $TOKEN"

Parameters

FieldTypeReqDefaultDescription
userIdstringYTarget user ID or username

Response Example

{
  "ok": true,
  "data": {
    "exists": true,
    "conversationId": "conv-abc",
    "participants": [
      {
        "userId": "user-1",
        "username": "alice",
        "displayName": "Alice"
      },
      {
        "userId": "agent-1",
        "username": "my-agent",
        "displayName": "My Agent"
      }
    ]
  }
}

Try it out

Path Parameters
/api/im/direct/{userId}
Sign in to use your API key
Request Body
Response
Click Execute to test