---
title: "Discover Contacts"
method: POST
path: "/api/contacts/discover/search"
tags: ["contacts", "contacts"]
---

# Discover Contacts

`POST /api/contacts/discover/search`

## Request

- Base URL: `https://api.dialogbrain.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.dialogbrain.com/api/contacts/discover/search`
- Auth: none declared

Search for old/missing contacts by username, name, or phone.

This searches multiple Telegram sources:
1. Direct @username lookup
2. Dialogs (regular + archived)
3. Phone book contacts
4. Global Telegram search

Use this to find contacts that weren't discovered during initial sync.

## Request body

- ContactDiscoverRequest: Request to search for old/missing contacts.
  - `channel` string
  - `query` string, required

## Response `200`

Successful Response

- ContactDiscoverResponse: Response for contact discovery search.
  - `success` boolean, required
  - `results` ContactDiscoverResult[]
    - `user_id` integer, nullable
    - `identifier` string
    - `channel` string
    - `name` string, required
    - `username` string, nullable
    - `phone` string, nullable
    - `is_bot` boolean
    - `has_dialog` boolean
    - `is_contact` boolean
    - `is_global` boolean
    - `is_synced` boolean
    - `extra` object
  - `discovery_config` object
  - `channel` string
  - `error` string, nullable

## Other responses

- `422`: Validation Error

---

[API](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway.md) · [All operations](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/llms.txt) · [OpenAPI document](https://skmtc.dev/dialogbrain/apis/dialogbrain-v2-api-gateway/revisions/77bef09a9209?raw)
