> For the complete documentation index, see [llms.txt](https://docs.mavibot.ai/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.mavibot.ai/doc/ar/chatbot/ttbyqat-almraslh/line_chatbot/api.md).

# وظائف الحاسبة

## **كيفية إرسال الرسائل عبر الحاسبة**

```
line_send_message(platform_id, text, buttons, attachments, quote_token, bot_group_id)
```

تساعدك هذه الدالة على إرسال الرسائل إلى المحادثة المحددة.

<table><thead><tr><th width="310.76171875">المعلمات</th><th>الوصف</th></tr></thead><tbody><tr><td><mark style="color:$danger;"><strong>!</strong></mark><strong> platform_id</strong></td><td><p><strong>معرّف الدردشة في LINE.</strong> </p><p>يمكنك تمرير متغير النظام <a href="/pages/2a5890eaa7d4841f097090e7427e035bb7fb71b4"><code>platform_id</code>.</a></p></td></tr><tr><td><strong>text</strong></td><td><p><strong>نص الرسالة.</strong> </p><p>معلمة اختيارية إذا كان <code>attachments</code> مُقدَّمة.</p></td></tr><tr><td><strong>buttons</strong></td><td><p><strong>مصفوفة من الأزرار في الرسالة.</strong></p><p><a href="#an-array-of-buttons-in-the-message">معلمة اختيارية.</a></p></td></tr><tr><td><strong>attachments</strong></td><td><p><strong>مصفوفة من المرفقات.</strong></p><p><a href="#an-array-of-attachments">معلمة اختيارية.</a></p></td></tr><tr><td><strong>quote_token</strong></td><td><strong>رمز الرد للرد على رسالة محددة.</strong> يمكنك تمرير <code>line_quote_token</code> متغير.</td></tr><tr><td><strong>bot_group_id</strong></td><td><p><strong>معرّف مجموعة البوت.</strong></p><p>يمكن توفيره إذا كنت بحاجة إلى إرسال رسالة نيابةً عن بوت متصل آخر. معلمة اختيارية.</p></td></tr></tbody></table>

### **مصفوفة من الأزرار في الرسالة**

يتم إنشاء معلمة buttons بالطريقة نفسها كما تُنشأ الأزرار في كتلة القمع. ولتبسيط إنشاء المصفوفة، يمكنك إنشاء الأزرار في كتلة القمع باستخدام الواجهة ونسخ البيانات التي تم إنشاؤها.

الخطوة 1. أنشئ الأزرار في الكتلة.

<div data-with-frame="true"><figure><img src="/files/6f88cd3f8923d1e99d38578f68b035398bcf2440" alt=""><figcaption></figcaption></figure></div>

الخطوة 2. انسخ إعدادات الزر المتقدمة.

<div data-with-frame="true"><figure><img src="/files/bdcc56dca78d69f890f00479d9c2e56cb90b59b2" alt=""><figcaption></figcaption></figure></div>

**مثال على مصفوفة أزرار:**

`[{"line":0,"index_in_line":0,"text":"Visit site","type":"inline","url":"`[`https://google.com","callback_link":false`](about:blank)`}]`

### **مصفوفة من المرفقات**

الـ `attachments` المعلمة هي مصفوفة من القواميس التي تحدد المرفقات المراد إرسالها.&#x20;

يجب أن يتضمن كل مرفق في المصفوفة نوع المرفق (`attachment_type`) ورابطه (`attachment_url`).

مثال:

attach\_list = \[{"attachment\_type": "image", "attachment\_url": "[https://files.site.com/my\_image.jpg](https://files.mavibot.ai/uploads/message_files/ca31b6d2ff3c2eef9c86bb0cc820412057b0ca004bd6c0e402c8df793c42f17d.jpg)"}]

القيم الممكنة لـ `attachment_type`:

* image
* video
* audio


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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.mavibot.ai/doc/ar/chatbot/ttbyqat-almraslh/line_chatbot/api.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.
