شرح الربط

كل اللي محتاجه عشان توصّل متجرك وشركات الشحن وواتساب بتوصيلة. لو وقفت في أي خطوة كلّمنا.

Shopify — بتطبيق توصيلة الأسهل

التطبيق بيربط متجرك في دقيقة من غير ما تنسخ أي مفاتيح: الأوردرات الجديدة بتنزل عندك لحظيًا، وحالة التسليم بترجع لـ Shopify، والمخزون بيتسحب.

لو عندك حساب على توصيلة

  1. ادخل بحساب مدير الشركة ← «الربط» ← تبويب Shopify.
  2. اكتب رابط متجرك بالشكل ده mystore.myshopify.com واضغط «ربط Shopify».
  3. هتتحوّل لصفحة Shopify — راجع الصلاحيات واضغط Install.
  4. هترجع لتوصيلة ومكتوب «مربوط» — خلاص.

لو بدأت من متجر تطبيقات Shopify

  1. ثبّت تطبيق «توصيلة» على متجرك.
  2. هيفتح لك صفحة الدخول على توصيلة: ادخل بحساب مدير الشركة، أو سجّل شركة جديدة (14 يوم مجانًا).
  3. أول ما تدخل المتجر بيتربط بشركتك تلقائيًا.
الصلاحيات اللي بنطلبها: قراءة وتعديل الأوردرات (عشان نعلّمها اتشحنت/اتسلمت)، قراءة المنتجات والمخزون والمخازن. مش بنطلب بيانات الدفع.
لو مسحت التطبيق من Shopify الربط بيتقفل عندنا تلقائيًا، وأوردراتك القديمة بتفضل موجودة.

Shopify — بمفاتيح يدوية (Custom app)

استخدم الطريقة دي بس لو مش عايز تثبّت التطبيق.

  1. من حسابك على Shopify افتح Settings ← Apps and sales channels ← Develop apps (أو الـ Dev Dashboard) واعمل تطبيق جديد باسم «توصيلة».
  2. في صلاحيات Admin API فعّل: read_orders write_orders read_products read_inventory read_locations read_merchant_managed_fulfillment_orders write_merchant_managed_fulfillment_orders.
  3. ثبّت التطبيق على متجرك وانسخ Admin API access token (بيبدأ بـ shpat_) — أو انسخ Client ID و Client secret.
  4. في توصيلة: «الربط» ← «مفاتيح الربط»: حط SHOPIFY_STORE = mystore.myshopify.com، و SHOPIFY_ACCESS_TOKEN = التوكن (أو SHOPIFY_CLIENT_ID و SHOPIFY_CLIENT_SECRET).
  5. ارجع لتبويب Shopify واضغط «سجّلها» جنب الـ Webhooks عشان الأوردرات تنزل لحظيًا.

سحب مخزون Shopify

  1. لازم كل منتج يكون له SKU ومفعّل عليه «Track quantity» في Shopify.
  2. سجّل Cost per item لكل منتج في Shopify عشان قيمة المخزون تطلع صح في الحسابات.
  3. من «الربط ← Shopify» أو «المشتريات ← المخزون والتكلفة» اضغط «سحب المخزون». تقدر تفعّل السحب التلقائي كل ساعة.
الرصيد عندنا = المتاح في Shopify + الكميات في أوردرات لسه ما اتسلمتش (لأن Shopify بيخصمها وقت الطلب وإحنا بنخصمها وقت التسليم) — فمفيش خصم مرتين. أول سحب بيتسجل رصيد مخزون افتتاحي في الحسابات، وأي فرق بعد كده بيتسجل تسوية مخزون.

بوسطة

  1. من حسابك على بوسطة: Settings ← API Integration واعمل API key.
  2. في توصيلة: «مفاتيح الربط» ← BOSTA_API_KEY.
  3. من «المناديب» ضيف بوسطة كـ«شركة شحن»، وبعدين «الربط ← شركات الشحن» واختار نوعها «بوسطة — ربط مباشر».
  4. من شاشة الأوردرات اختار الأوردرات وابعتها لبوسطة — رقم البوليصة والحالة بيتحدّثوا لوحدهم.

شركات الشحن التانية (J&T، أرامكس، R2S، Mylerz وغيرها)

  1. ضيف الشركة من «المناديب» (نوع: شركة شحن)، واختار نوعها من «الربط ← شركات الشحن».
  2. ربط البوالص: ارفع شيت فيه عمود رقم الأوردر وعمود رقم البوليصة.
  3. تحديث الحالات: ارفع شيت الحالات اللي بتبعتهولك الشركة، أو ادّيهم رابط الـ Webhook اللي ظاهر تحت اسم الشركة يبعتوا عليه التحديثات.
  4. التصفية والتحصيل بيتعملوا من «الكاش» زي أي مندوب.

واتساب (تأكيد الأوردرات)

  1. اعمل حساب على Meta for Developers وتطبيق فيه منتج WhatsApp، وضيف رقم شركتك.
  2. في «مفاتيح الربط» حط: WHATSAPP_TOKEN (توكن دائم من System User)، WHATSAPP_PHONE_ID، WHATSAPP_APP_SECRET، و WHATSAPP_VERIFY (أي كلمة من اختيارك).
  3. في إعدادات Webhook عند Meta حط الرابط اللي ظاهر في «الربط ← واتساب» واشترك في messages.
  4. اعمل Template تأكيد فيه 3 متغيرات (الاسم، رقم الطلب، المبلغ) وزرارين رد سريع (تأكيد / إلغاء) واستنى موافقة Meta.
  5. رد العميل بيأكد أو يلغي الأوردر تلقائيًا ويظهر في شاشة «التأكيد».

API للمطورين

  1. من «الربط ← API للمطورين» اعمل مفتاح (قراءة بس، أو قراءة وكتابة لإنشاء أوردرات).
  2. ابعت كل طلب بهيدر Authorization: Bearer ck_live_… على https://tivhzchjvhltymlseocn.supabase.co/functions/v1/api?v1=orders.
  3. عشان يوصلك كل تحديث على الأوردرات ضيف رابطك في تبويب «Webhooks» — كل طلب موقّع بـ X-Signature (HMAC-SHA256).

نون وأمازون وترينديول

الربط معاهم جاي قريب — هتلاقي أوردراتهم ومستحقاتهم في نفس الحسابات.

Integration guides

Everything you need to connect your store, carriers and WhatsApp to Tawseela. Stuck on a step? Contact us.

Shopify — with the Tawseela app Easiest

The app connects your store in a minute with no keys to copy: new orders arrive instantly, delivery status goes back to Shopify, and inventory is pulled in.

If you already have a Tawseela account

  1. Sign in as the company admin → Integrations → Shopify tab.
  2. Type your store address like mystore.myshopify.com and click “Connect Shopify”.
  3. Shopify opens — review the permissions and click Install.
  4. You come back to Tawseela showing “Connected”. Done.

If you start from the Shopify App Store

  1. Install the Tawseela app on your store.
  2. The Tawseela sign-in page opens: sign in as company admin, or create a new company (14 days free).
  3. The store links to your company automatically once you're in.
Permissions we ask for: read and update orders (to mark them shipped/delivered), read products, inventory and locations. We never request payment data.
If you uninstall the app from Shopify, the connection is closed on our side automatically; your existing orders stay.

Shopify — manual keys (custom app)

Only if you'd rather not install the app.

  1. In Shopify open Settings → Apps and sales channels → Develop apps (or the Dev Dashboard) and create an app named “Tawseela”.
  2. Enable these Admin API scopes: read_orders write_orders read_products read_inventory read_locations read_merchant_managed_fulfillment_orders write_merchant_managed_fulfillment_orders.
  3. Install it on your store and copy the Admin API access token (starts with shpat_) — or the Client ID and Client secret.
  4. In Tawseela: Integrations → Keys: set SHOPIFY_STORE = mystore.myshopify.com and SHOPIFY_ACCESS_TOKEN (or SHOPIFY_CLIENT_ID and SHOPIFY_CLIENT_SECRET).
  5. Back on the Shopify tab, click “Register” next to Webhooks so orders arrive in real time.

Pulling Shopify inventory

  1. Each product needs a SKU and “Track quantity” enabled in Shopify.
  2. Fill in Cost per item in Shopify so stock value is right in your accounts.
  3. From Integrations → Shopify, or Purchases → Stock & cost, click “Pull inventory”. You can turn on hourly auto-sync.
Our balance = Shopify available + quantities in orders not yet delivered (Shopify deducts at order time, we deduct at delivery), so nothing is deducted twice. The first pull is posted as opening inventory; later differences are posted as inventory adjustments.

Bosta

  1. In Bosta: Settings → API Integration and create an API key.
  2. In Tawseela: Keys → BOSTA_API_KEY.
  3. Add Bosta under Couriers as a “shipping company”, then in Integrations → Carriers pick “Bosta — direct”.
  4. Select orders on the Orders screen and send them to Bosta — waybill numbers and status update by themselves.

Other carriers (J&T, Aramex, R2S, Mylerz…)

  1. Add the carrier under Couriers (type: shipping company) and choose its type in Integrations → Carriers.
  2. Link waybills: upload a sheet with an order-number column and a waybill column.
  3. Update statuses: upload the status sheet the carrier sends you, or give them the webhook URL shown under the carrier's name.
  4. Settlement and collection run from Cash like any courier.

WhatsApp (order confirmation)

  1. Create a Meta for Developers app with the WhatsApp product and add your business number.
  2. In Keys set WHATSAPP_TOKEN (permanent System User token), WHATSAPP_PHONE_ID, WHATSAPP_APP_SECRET and WHATSAPP_VERIFY (any word you choose).
  3. In Meta's webhook settings paste the URL shown in Integrations → WhatsApp and subscribe to messages.
  4. Create a confirmation template with 3 variables (name, order number, amount) and two quick-reply buttons (Confirm / Cancel), and wait for Meta's approval.
  5. The customer's reply confirms or cancels the order automatically and shows on the Confirmation screen.

Developer API

  1. In Integrations → Developer API create a key (read-only, or read & write to create orders).
  2. Send every request with Authorization: Bearer ck_live_… to https://tivhzchjvhltymlseocn.supabase.co/functions/v1/api?v1=orders.
  3. To receive every order update, add your URL under Webhooks — each request is signed with X-Signature (HMAC-SHA256).

Noon, Amazon and Trendyol

Coming soon — their orders and payouts will land in the same accounts.