# Contact , Location, Venue

Xabarlar orasida, yana e'tiborga olishimiz kerak bo'lgan turlar bu - **contact,** **location** va **venue**. Ushbu mavzuda shu kabi xabar turlari bilan ishlashni ko'rib chiqamiz.

Birinchi qadamda **contact** turi bilan tanishib chiqamiz.

```csharp
private async void Xabar_Kelganda(object sender, MessageEventArgs e)
{
    if (e.Message.Text == "contact yubor")
    {
        await client.SendContactAsync(
            chatId: e.Message.Chat.Id,
            // telefon raqami
            phoneNumber: "+9981234567",
            // ismi
            firstName: "Khan",
            // familyasi
            lastName: "Blogs"
        );
    }
}
```

**Natija:**

![](/files/-MR5nMR4yuDUZIYcULBp)

Joylashuv  odatda koordinatalar(kenglik) ga nisbat topiladi. **Location** - toifasida ham 2 ta asosiy maydon mavjud **longitude** va **latitude**.Ma'lum bir manzilni joylashuvini ko'rsatish uchun, uning kengliklarini berish kifoya.

```csharp
private async void Xabar_Kelganda(object sender, MessageEventArgs e)
{
    if (e.Message.Text == "lokatsiya yubor")
    {
        await client.SendLocationAsync(
            chatId: e.Message.Chat.Id,                                    
            latitude: 40.783368f,                                    
            longitude: 72.350654f,
            // qancha vaqt ko'rsatib turishi
            livePeriod: 100 // sekundlarda
        );
    }
}
```

**Natija:**

![](/files/-MR5vBITxiW7ckqxs5Jt)

{% hint style="info" %}
**livePeriod** - maydoni 60 dan 86400 gacha oraliqdagi qiymatni qabul qiladi.
{% endhint %}

**Venue** xabar turi ham joylashuvni belgilashda foydalaniladi. Undan qo'shimcha tarzda **title**, hamda **address** ni belgilash mumkin.

```csharp
private async void Xabar_Kelganda(object sender, MessageEventArgs e)
{
    if (e.Message.Text == "lokatsiya yubor")
    {
        await client.SendVenueAsync(
            chatId: e.Message.Chat.Id, 
            latitude: 40.783368f,                                    
            longitude: 72.350654f,
            title: "Andijon",
            address: "Paxtaobod, Yangi yo'l"
        );
    }
}
```

![](/files/-MR5xDJJw_uoj_3kwx1k)


---

# 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.dot-net.uz/c-.net/telegram-bot/starter/xabar-turlari-va-xabar-yuborish/boshqa-xabar-turlari.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.
