# Basic Search Commands

You can use these commands before or after entering search terms:

* from:me to search for messages only created by the current user.
* from:user.name to search for messages created by a specific user. The username entered must be the format without spaces (i.e., “john.doe” and not “John Doe.”) Search for any mentions of a user by searching for their username.
* has:star returns messages that are starred by the current user.
* is:pinned or has:pin returns messages that pin in the current channel.
* has:url or has:link returns messages that contain a link.
* has:location or has:map returns messages that have a location attached.
* before:dd/mm/yyyy, after:dd/mm/yyyy and on:dd/mm/yyyy return message that were created before, after, or on the provided date.\
  Dashes dd-mm-yyyy or dots dd.mm.yyyy can be used instead of slashes. order:asc, order:ascend, or order:ascending sorts messages by ascending timestamp.
* order:desc, order:descend, or order:descending sorts messages by descending timestamp.\
  You can also jump to where a message is located by hovering the mouse over the search result and selecting jump to message.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.orgchat.com/how-can-i-search-for-messages-in-channel/basic-search-commands.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
