messages.search
Find chat messages
Searches for messages based on your query and additional conditions, such as author, date, or attachment type.
| Name | Typ | Erforderlich | Beschreibung |
|---|---|---|---|
peer | InputPeer | Ja | Chatten Sie, um zu suchen. |
q | string | Ja | Search query text. |
from_id | InputPeer | Nein | The author by whom the sample is limited. |
saved_peer_id | InputPeer | Nein | Search within the [saved message dialog »](https://core.telegram.org/api/saved-messages.md) with this ID. |
saved_reaction | Vector<Reaction> | Nein | You may search for [saved messages tagged »](https://core.telegram.org/api/saved-messages.md#tags) with one or more reactions using this flag. |
top_msg_id | int | Nein | ID of the thread's topic or top message. |
filter | MessagesFilter | Ja | Filter by type of message or attachment. |
min_date | int | Ja | Lower bound for message date in Unix seconds. |
max_date | int | Ja | Upper limit of the message date in Unix seconds. |
offset_id | int | Ja | Only return messages starting from the specified message ID |
add_offset | int | Ja | [Additional offset](https://core.telegram.org/api/offsets.md) |
limit | int | Ja | Maximum number of results per issue. |
max_id | int | Ja | [Maximum message ID to return](https://core.telegram.org/api/offsets.md) |
min_id | int | Ja | [Minimum message ID to return](https://core.telegram.org/api/offsets.md) |
hash | long | Ja | [Hash](https://core.telegram.org/api/offsets.md) |
Antworten
messages.Messages
MTProto RPC
- 400 · CHANNEL_INVALID – Der angegebene Kanal ist ungültig.
- 400 · CHANNEL_PRIVATE — Du bist diesem Kanal/dieser Supergruppe nicht beigetreten.
- 403 · CHAT_ADMIN_REQUIRED — Um dies zu tun, müssen Sie in diesem Chat Administrator sein.
- 400 · CHAT_ID_INVALID – Die angegebene Chat-ID ist ungültig.
- 400 · FROM_PEER_INVALID – Die angegebene from_id ist ungültig.
- 400 · INPUT_FILTER_INVALID – Der angegebene Filter ist ungültig.
- 400 · INPUT_USER_DEACTIVATED – Der angegebene Benutzer wurde gelöscht.
- 400 · MSG_ID_INVALID – Ungültige Nachrichten-ID angegeben.
- 400 · PEER_ID_INVALID – Die angegebene Peer-ID ist ungültig.
- 400 · PEER_ID_NOT_SUPPORTED – Die angegebene Peer-ID wird nicht unterstützt.
- 400 · SEARCH_QUERY_EMPTY – Die Suchanfrage ist leer.
- 400 · TAKEOUT_INVALID – Die angegebene Takeout-ID ist ungültig.
- 400 · USER_ID_INVALID – Die angegebene Benutzer-ID ist ungültig.