# ...ربط Telegram-pay

كيفية إنشاء زر دفع مثبت كما هو موضح أدناه:

!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

يتم ذلك في خطوتين فقط:

**الخطوة الأولى:**&#x20;

أولاً وقبل كل شيء، نحتاج إلى الاتصال بنظام دفع. للحصول على تعليمات مفصلة حول كيفية القيام بذلك، اقرأ هذا [المقال](https://docs.salebot.ai/integrations/payment-systems/telegram)

**الخطوة الثانية:**&#x20;

ثبّت هذه الرسالة. ستجد وصفًا لوظيفة تثبيت الرسائل في هذا [المقال ](https://docs.salebot.ai/variables/api-in-calculator)

**مثال:**

الخطوة الأولى:

prices = \[\["product", 200], \["tax", 40], \["packaging", 10]] result = tg\_send\_invoice('632593626:TEST:sandbox\_i38014109764', platform\_id, 'Phone U-200', 'The best of the best', 'UAH', prices, 'shorturl.at/cwyA3', 'phone\_best', 0, 0, 1, 1, 1)

الخطوة الثانية:

نتيجةً لإكمال الخطوة الأولى، ستحصل على إجابة ستحتاج منها إلى الحصول على قيمة message\_id بمساعدة الدالة get(): res=get(result,'result') m\_id=get(res,'message\_id')

ثم نثبّت الرسالة: tg\_pin\_chat\_message(#{platform\_id}, #{m\_id}, 1)

!!!!!!!!!!!!!!!!!!!!


---

# 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.mavibot.ai/doc/ar/faq/questions/payment.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.
