S
SecurelyChannel API · واجهة القناة

Introduction · مقدّمة

English العربية
The Securely Channel API lets a system you already own, a CRM, an ERP, an accounting package, open a secure conversation with a customer and send messages and invitations tied to the right record. Requesting a document is coming: today POST /file-requests answers 501 (see Known gaps). Plain HTTPS, a Bearer key, and signed webhooks. واجهة القناة في سكيورلي تتيح لنظام تملكه أصلاً، إدارة علاقات عملاء أو نظام موارد أو برنامج محاسبة، أن يفتح محادثة آمنة مع عميل ويرسل الرسائل والدعوات مرتبطةً بالسجل الصحيح. طلب المستندات قادم: اليوم تردّ POST /file-requests بـ 501 (راجع «الفجوات المعروفة»). طلبات HTTPS عادية، ومفتاح، وأحداث موقَّعة.
There is no marketplace connector to install and no vendor approval to wait for. Any application that can call a URL and receive a webhook is integrable today. لا يوجد موصّل من متجر يُثبَّت ولا موافقة مورّد تُنتظر. أي تطبيق يستطيع نداء عنوان واستقبال حدث قابل للربط اليوم.
One field carries the whole idea: externalRef. You send it when you open a session; it comes back on every event about that session. That is what makes the integration bidirectional instead of one-way. فكرة واحدة يحملها حقل واحد: externalRef. ترسله عند فتح الجلسة، فيعود إليك مع كل حدث يخصّها. وهذا ما يجعل الربط بالاتجاهين لا باتجاه واحد.

Base URL · العنوان الأساسي

https://api.securely.ae

English العربية
The Channel API is a server-to-server surface. It is exempt from CSRF because it is not a browser surface, and it refuses browser-originated requests before it even checks your key. Never call it from front-end JavaScript. واجهة القناة سطح خادم-لخادم. وهي معفاة من فحص CSRF لأنها ليست سطح متصفّح، وترفض الطلبات القادمة من متصفّح قبل أن تفحص مفتاحك أصلاً. لا تنادها من جافاسكربت في الواجهة إطلاقاً.

Read the Known gaps page before you build. Requesting a file is not available yet, and the file.uploaded event is not sent yet. Both are described there plainly.اقرأ صفحة «الفجوات المعروفة» قبل أن تبني. طلب الملف غير متاح بعد، والحدث file.uploaded لا يُرسَل بعد. وكلاهما موصوف هناك بوضوح.

Quickstart · البداية السريعة

# English العربية
1 Get a key from your company administrator: API & Integrations in the Securely company panel. A key that can send must be created from the Securely app, not the web panel (see Authentication). It is shown once, at creation, and stored SHA-256 hashed. If you lose it, you issue a new one; nobody can read it back. احصل على مفتاح من مدير شركتك: شاشة الواجهات والتكاملات في لوحة الشركة في سكيورلي. المفتاح القادر على الإرسال يُنشأ من تطبيق سكيورلي لا من لوحة الويب (انظر المصادقة). يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً. إن ضاع تُصدر غيره، ولا أحد يستطيع قراءته لاحقاً.
2 Open a session and put your record's identity in externalRef. افتح جلسة وضع هوية سجلّك في externalRef.
3 Ask your administrator to add a webhook destination on the same API & Integrations screen, and keep its secret. It is shown once. اطلب من المدير إضافة وجهة للأحداث في شاشة الواجهات والتكاملات نفسها، واحتفظ بسرّها. يُعرض مرة واحدة.
4 Verify X-Securely-Signature on every event you receive. Reject anything that fails. تحقّق من X-Securely-Signature في كل حدث يصلك. وارفض ما يسقط في التحقق.
5 Read externalRef off the event and write back onto that record. اقرأ externalRef من الحدث واكتب على ذلك السجل.

Your first call · أول نداء

curl -X POST https://api.securely.ae/api/channel/v1/sessions \
  -H "Authorization: Bearer ck_live_xxxxxxxxxxxx" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{
    "customerDisplayName": "Acme Trading LLC",
    "externalRef": {
      "system": "salesforce",
      "recordType": "Opportunity",
      "recordId": "0065g00000XyZaB"
    }
  }'
English العربية
A 401 means the key is missing, invalid or revoked. A 403 means one of three things: the scope is not on the key, the tenant's plan does not enable the Channel API, or the tenant is not verified yet. جواب 401 يعني أن المفتاح مفقود أو غير صالح أو مُبطَل. وجواب 403 يعني أحد ثلاثة: النطاق غير موجود في المفتاح، أو الباقة لا تُفعّل واجهة القناة، أو المستأجر لم يُوثَّق بعد.

Authentication & scopes · المصادقة والنطاقات

Authorization: Bearer ck_live_xxxxxxxxxxxx
English العربية
Keys are shown once and stored SHA-256 hashed. A key belongs to exactly one tenant, and tenancy is resolved from the key alone, never from anything in the request body. يُعرض المفتاح مرة واحدة ويُخزَّن مجزّأً. وكل مفتاح يخصّ مستأجراً واحداً، وهوية المستأجر تُستخرج من المفتاح وحده، لا من أي شيء في جسم الطلب.
A new key defaults to ["sessions:read","sessions:write"] when you do not name scopes. That default is a sending key, it can open sessions and post messages. المفتاح الجديد يأخذ افتراضياً ["sessions:read","sessions:write"] إن لم تُسمِّ نطاقات. وهذا الافتراضي مفتاح مُرسِل، يفتح الجلسات ويرسل الرسائل.

Where keys and webhooks are createdأين تُنشأ المفاتيح ووجهات الأحداث

English العربية
Keys and webhook destinations are created by your company's own administrators in the Securely company panel (portal.securely.ae), on the API & Integrations screen. The same screen lists keys, revokes them, and adds, disables or removes webhook destinations. Securely staff do not issue keys for you. المفاتيح ووجهات الأحداث يُنشئها مديرو شركتك أنفسهم في لوحة الشركة في سكيورلي (portal.securely.ae)، في شاشة الواجهات والتكاملات. والشاشة نفسها تعرض المفاتيح وتُبطلها، وتضيف وجهات الأحداث أو توقفها أو تحذفها. فريق سكيورلي لا يُصدر المفاتيح نيابة عنك.
Who may. The screen and the calls behind it need the permission Manage API & Integrations. By default the Client Admin and IT Admin roles have it. Your company can change that in its own role settings. من يستطيع. الشاشة وما خلفها يتطلبان صلاحية إدارة الواجهات والتكاملات. افتراضياً يملكها دور مدير الشركة ودور مسؤول تقنية المعلومات، وتستطيع شركتك تغيير ذلك من إعدادات الأدوار لديها.
Which plan. The Channel API needs a plan that includes it. In the current plan catalogue that is Scale, and Enterprise when the contract includes it. For the launch trial period the Channel API is open on every plan, so you can connect from day one; it will later be limited to the plans that include it, and we will tell you before that changes. Once it is limited, a plan without it gets 403 PREMIUM_ONLY when creating a key or a webhook, and 403 CHANNEL_API_NOT_IN_PLAN on every /channel/v1 call. Your keys are kept and work again when the plan includes the Channel API. أي باقة. واجهة القناة تحتاج باقة تشملها. في كتالوج الباقات الحالي هي باقة Scale، وباقة Enterprise إن نصّ العقد عليها. خلال فترة التجربة عند الإطلاق، واجهة القناة مفتوحة على كل الباقات لتتمكن من الربط من اليوم الأول، وسيُحصر استخدامها لاحقاً في الباقات التي تشملها، وسنبلغك قبل أي تغيير. وبعد الحصر، الباقة التي لا تشملها يردّ لها إنشاء المفتاح أو وجهة الأحداث بـ 403 PREMIUM_ONLY، وكل نداء على /channel/v1 بـ 403 CHANNEL_API_NOT_IN_PLAN. مفاتيحك تبقى محفوظة وتعود للعمل عندما تشمل الباقة واجهة القناة.
Sending keys come from the app, not the web. A key that carries sessions:write (or files:write) cannot be created from the web panel: the server refuses it with 403. On the web the panel creates read-only keys (sessions:read). To create a key that can open sessions, send messages and create invitations, the administrator signs in to the Securely app (iPhone, iPad, Android, macOS or Windows) and uses the same API & Integrations screen there. Most integrations need a sending key. مفاتيح الإرسال تُنشأ من التطبيق لا من الويب. المفتاح الذي يحمل sessions:write (أو files:write) لا يمكن إنشاؤه من لوحة الويب، والخادم يرفضه بـ 403. على الويب تُنشئ اللوحة مفاتيح قراءة فقط (sessions:read). ولإنشاء مفتاح يفتح الجلسات ويرسل الرسائل وينشئ الدعوات، يسجّل المدير الدخول إلى تطبيق سكيورلي (آيفون أو آيباد أو أندرويد أو macOS أو ويندوز) ويستخدم شاشة الواجهات والتكاملات نفسها هناك. ومعظم التكاملات تحتاج مفتاح إرسال.

The nine defined scopes · النطاقات التسعة

Scope English العربية
sessions:read List and read sessions. سرد الجلسات وقراءتها.
sessions:write Create sessions, send messages, close sessions, create invitations. إنشاء الجلسات وإرسال الرسائل وإغلاقها وإنشاء الدعوات.
files:write Create file requests. The endpoint is not available yet and answers 501. إنشاء طلبات الملفات. والنقطة غير متاحة بعد وتردّ بـ 501.
files:read Defined. No endpoint on this surface requires it today. معرَّف. ولا نقطة في هذا السطح تطلبه اليوم.
audit:read Defined. Not required by any endpoint here. معرَّف. لا تطلبه أي نقطة هنا.
webhooks:read · webhooks:write Defined. Not required by any endpoint here. معرَّفان. لا تطلبهما أي نقطة هنا.
archive:read · archive:write Defined. Not required by any endpoint here. معرَّفان. لا تطلبهما أي نقطة هنا.

Note the trap: invitations do not use an invites:write scope and messages do not use messages:write. Both are covered by sessions:write. File requests use files:write. انتبه للمصيدة: الدعوات لا تستخدم نطاقاً اسمه invites:write، والرسائل لا تستخدم messages:write. كلاهما تحت sessions:write. وطلبات الملفات تحت files:write.

Idempotency · منع التكرار

English العربية
Idempotency-Key is required on every write. Not optional, not recommended, the request is refused with 400 without it. ترويسة Idempotency-Key مطلوبة على كل كتابة. ليست خياراً ولا توصية، الطلب يُرفض بـ400 بدونها.
The reason is concrete: every automation platform that will call this API retries on timeout by default. Without a key, one slow request creates the same session, message or invitation twice, and the caller has no way to stop it. والسبب ملموس: كل منصة أتمتة ستنادي هذه الواجهة تُعيد المحاولة تلقائياً عند التأخير. فبلا مفتاح، طلب بطيء واحد يُنشئ نفس الجلسة أو الرسالة أو الدعوة مرتين، ولا يملك المُنادي ما يمنع ذلك.
Generate the key once per business action and reuse it on every retry of that action. A new key per retry defeats the whole mechanism. ولّد المفتاح مرة واحدة لكل فعل تجاري، وأعد استخدامه في كل إعادة محاولة لذلك الفعل. مفتاح جديد لكل محاولة يُبطل الآلية كلها.

Every outcome · كل الحالات

Situation Response العربية
Header missing 400 الترويسة مفقودة
Length out of range 400 الطول خارج المدى المسموح
First use passes through to the handler أول استخدام، يمرّ إلى المعالج
Retry, same body the stored response, plus header Idempotent-Replay: true إعادة بنفس الجسم، الجواب المخزَّن ومعه ترويسة Idempotent-Replay: true
Same key, different body 422, a client error, not a retry. Use a new key. نفس المفتاح بجسم مختلف، 422. خطأ عميل لا إعادة محاولة. استخدم مفتاحاً جديداً.
Original still running 409, retry shortly with the same key الأصل ما زال يعمل، 409، أعد بعد قليل بنفس المفتاح
Claim could not be established 503-no write was performed. Retry with the same key. تعذّر تثبيت المطالبة، 503. لم تتم أي كتابة. أعد بنفس المفتاح.
English العربية
Field order does not matter. Two bodies with the same content in a different key order are the same request, not a conflict, that is the real production case, because most HTTP clients do not preserve order. ترتيب الحقول لا يهمّ. جسمان بنفس المحتوى وترتيب مختلف هما نفس الطلب لا تعارض، وهذه هي الحالة الإنتاجية الحقيقية، لأن أكثر عملاء HTTP لا يحفظون الترتيب.
The concurrency control is the database, not application logic: the claim is an insert on a composite primary key. Eight simultaneous identical requests produce exactly one write. ضابط التزامن هو قاعدة البيانات لا منطق التطبيق: المطالبة إدراج على مفتاح أساسي مركّب. ثمانية طلبات متزامنة متطابقة تنتج كتابة واحدة بالضبط.

externalRef · حقل الربط

English العربية
This is the field the whole integration turns on. You send it when you open a session or create an invitation; Securely stores it and returns it on every event about that session. هذا هو الحقل الذي يدور عليه الربط كله. ترسله عند فتح جلسة أو إنشاء دعوة، فيحفظه سكيورلي ويعيده مع كل حدث يخصّ تلك الجلسة.
Without it, a document arriving two days later has nothing that says which record it belongs to, and the calling system has to keep its own mapping table or give up on filing the result. بدونه، المستند الذي يصل بعد يومين لا يحمل ما يدلّ على سجله، فيضطر النظام المُنادي إلى جدول ربط خاص به أو يتخلّى عن الحفظ التلقائي.
It cannot be added later. Send it on the first call. ولا يمكن إضافته لاحقاً. أرسله مع أول نداء.

Schema · المخطَّط

Field Type Required English العربية
system string 1..64 ✅ The calling system, e.g. salesforce النظام المُنادي، مثل salesforce
recordType string ≤64 - The record type, e.g. Opportunity نوع السجل، مثل Opportunity
recordId string 1..128 ✅ The record id in your system رقم السجل في نظامك
url valid URL ≤512 - Link back to the record رابط يعود إلى السجل

The object is strict: an unknown key is rejected, not ignored. الكائن صارم: أي حقل غير معروف يُرفض ولا يُتجاهل.

⚠ Security · أمان

English العربية
This field is caller-supplied and untrusted. It never influences authorization or tenant resolution, tenancy comes from the API key alone. هذا الحقل من المُنادي وغير موثوق. ولا يؤثّر إطلاقاً في الصلاحية ولا في تحديد المستأجر، المستأجر من المفتاح وحده.
It is stored and logged verbatim. Put opaque identifiers in it and nothing else, no names, no personal data, no confidential text. ويُخزَّن ويُسجَّل حرفياً. ضع فيه معرّفات مبهمة فقط، لا أسماء ولا بيانات شخصية ولا نصاً سرياً.

Webhooks & signature · الأحداث والتوقيع

Headers on every delivery · ترويسات كل تسليم

X-Securely-Event-Id: <delivery id>
X-Securely-Timestamp: 2026-08-29T04:10:22.000Z
X-Securely-Signature: sha256=<hex HMAC-SHA256 of the raw body>
User-Agent: Securely-Webhook/1.0
English العربية
Verify HMAC-SHA256(rawBody, webhookSecret) against the value after sha256=. Use the raw body bytes, before any JSON parsing, reserialising changes the bytes and the signature will never match. تحقّق من HMAC-SHA256(rawBody, webhookSecret) مقابل القيمة بعد sha256=. استخدم الجسم الخام قبل أي تحليل JSON، إعادة الترميز تغيّر البايتات فلا يطابق التوقيع أبداً.
Compare in constant time. And reject anything that fails, an endpoint that accepts unverified events lets anyone who learns its URL write into your CRM. قارن بزمن ثابت. وارفض ما يسقط، العنوان الذي يقبل حدثاً غير متحقَّق منه يسمح لأي شخص يعرف رابطه بالكتابة في نظامك.

Verifying · مثال التحقق

import crypto from "node:crypto";

// express: app.post('/hook', express.raw({type:'application/json'}), handler)
function verify(rawBody, header, secret) {
  const expected = "sha256=" + crypto.createHmac("sha256", secret)
                                     .update(rawBody).digest("hex");
  const a = Buffer.from(header || "", "utf8");
  const b = Buffer.from(expected, "utf8");
  return a.length === b.length && crypto.timingSafeEqual(a, b);
}

Delivery, retry and dead-letter · التسليم وإعادة المحاولة

English العربية
Retries run at 30s · 2m · 10m · 1h · 6h, then the delivery goes to dead_letter, six attempts across about seven hours. A destination down for ten minutes loses nothing. إعادة المحاولة على ٣٠ث · ٢د · ١٠د · ١س · ٦س، ثم تنتقل إلى dead_letter · ست محاولات على نحو سبع ساعات. عنوان يتعطّل عشر دقائق لا يُضيّع شيئاً.
The destination URL is re-validated against SSRF immediately before every delivery, not only when it was registered. A hostname that resolved to a public address at registration can be re-pointed at an internal one later; re-resolving closes that window. ويُعاد التحقق من العنوان ضد SSRF قبل كل تسليم، لا عند التسجيل فقط. فالمضيف الذي كان يشير إلى عنوان عام وقت التسجيل قد يُعاد توجيهه إلى عنوان داخلي لاحقاً، وإعادة الفحص تغلق هذه الثغرة.
A delivery blocked by that check goes straight to dead_letter with next_attempt_at = null. It is not retried, because retrying would not change the answer. والتسليم الذي يحجبه هذا الفحص يذهب مباشرة إلى dead_letter بـnext_attempt_at = null. ولا يُعاد، لأن الإعادة لن تغيّر النتيجة.

Events · الأحداث

Event Emitted today? English العربية
session.created ✅ yes A secure session was opened. Carries externalRef. فُتحت جلسة آمنة. تحمل externalRef.
message.created ✅ yes A message was posted. Carries sessionId, messageId, senderType, contentLength-not the message text. نُشرت رسالة. تحمل معرّف الجلسة والرسالة ونوع المرسل وطول المحتوى، لا نصّ الرسالة.
session.closed ✅ yes The session was closed. أُغلقت الجلسة.
file.uploaded ❌ no Declared in the event type. No production code emits it. See Known gaps. معرَّف في نوع الحدث. ولا يُصدره أي كود إنتاجي. انظر «الفجوات المعروفة».

Errors & rate limits · الأخطاء والحدود

Rate limit · الحدّ

English العربية
120 requests per 60 seconds, per key. Exceeding it answers 429 with a body carrying error, retryAfterSeconds, and a human sentence plus a next step in both English and Arabic (message/errorAr, action/actionAr). ١٢٠ طلباً كل ٦٠ ثانية لكل مفتاح. التجاوز يردّ 429 بجسم يحمل error وretryAfterSeconds وجملة بشرية وخطوة تالية بالعربية والإنجليزية معاً.
Back off on retryAfterSeconds. Do not tighten your retry loop on a 429, that is what produced it. تراجع بمقدار retryAfterSeconds. ولا تُسرّع حلقة الإعادة عند 429، هي التي أنتجته.

Status codes · رموز الحالة

Code English العربية
400 Body failed validation, or Idempotency-Key is missing or the wrong length. فشل التحقق من الجسم، أو ترويسة منع التكرار مفقودة أو بطول خاطئ.
401 Key missing, invalid or revoked. المفتاح مفقود أو غير صالح أو مُبطَل.
403 One of three: scope not on the key · the tenant's plan does not enable the Channel API · the tenant is not verified yet. The third answers in both languages and is not a bug, an unverified account cannot contact anyone outside the company. أحد ثلاثة: النطاق غير موجود في المفتاح · الباقة لا تُفعّل واجهة القناة · المستأجر غير موثَّق بعد. والثالث يردّ باللغتين وليس عطلاً، الحساب غير الموثَّق لا يتواصل مع أحد خارج الشركة.
404 The session, or the employee, does not exist in this tenant. الجلسة أو الموظف غير موجود في هذا المستأجر.
409 The session is not active, or the original idempotent request is still running. الجلسة ليست نشطة، أو الطلب الأصل ما زال يعمل.
422 The same Idempotency-Key with a different body. نفس مفتاح منع التكرار بجسم مختلف.
429 Rate limit. تجاوز الحدّ.
501 Not available yet. Only POST /file-requests answers this today. Nothing was created. غير متاح بعد. لا يردّ بهذا اليوم إلا POST /file-requests. لم يُنشأ شيء.
503 Idempotency could not be established. No write happened. Retry with the same key. تعذّر تثبيت منع التكرار. لم تتم كتابة. أعد بنفس المفتاح.

Known gapsالفجوات المعروفة

A specification that hides what does not work is worse than no specification. Everything here was checked against the running code on 28 September 2026.وصفٌ يُخفي ما لا يعمل أسوأ من لا وصف. وكل ما هنا رُوجع مقابل الكود العامل في ٢٨ سبتمبر ٢٠٢٦.

1 · file.uploaded is not sent yet١ · الحدث file.uploaded لا يُرسَل بعد

English العربية
The event is declared in the event type union, and the delivery layer is written to attach externalRef to it. But no production code path emits it. The only callers are two test files. الحدث معرَّف في نوع الأحداث، وطبقة التسليم مكتوبة لتُلحق به externalRef. لكن لا يوجد مسار إنتاجي واحد يُصدره. المُنادون الوحيدون ملفا اختبار.
Three events reach a customer endpoint today: session.created, message.created, session.closed. ثلاثة أحداث تصل اليوم إلى عنوان العميل: session.created وmessage.created وsession.closed.
Consequence, stated plainly: the return leg does not close by itself yet. You can open a session from your CRM and send messages. You cannot yet be notified by Securely that a document arrived. والنتيجة بصراحة: الشقّ العائد لا يُغلق تلقائياً بعد. تستطيع فتح جلسة من نظامك وإرسال الرسائل. ولا تستطيع بعد أن يُخبرك سكيورلي بوصول مستند.
Everything on the outbound leg, the key, the scopes, idempotency, externalRef, the signature, the retry schedule, the SSRF re-check, is built and tested. The missing piece is one emit call at the point a file lands. وكل ما في الشقّ الصادر، المفتاح والنطاقات ومنع التكرار وexternalRef والتوقيع وجدول الإعادة وإعادة فحص SSRF، مبنيّ ومختبَر. الناقص استدعاء إصدار واحد عند لحظة وصول الملف.

2 · POST /file-requests is not available yetغير متاحة بعد

English العربية
The endpoint answers 501 with FILE_REQUESTS_NOT_IMPLEMENTED. No file request is created, no upload location exists, and no file.uploaded event follows. It still checks your key and the files:write scope first, so a 401 or 403 can come before the 501. النقطة تردّ بـ 501 مع FILE_REQUESTS_NOT_IMPLEMENTED. لا يُنشأ طلب ملف، ولا يوجد موقع رفع، ولا يتبعها حدث file.uploaded. وهي ما زالت تفحص مفتاحك ونطاق files:write أولاً، فقد يأتي 401 أو 403 قبل 501.
Do not build a customer flow on it until it answers 201. There is no Channel API workaround today. See Request a file. لا تبنِ رحلة عميل عليها حتى تردّ بـ 201. ولا يوجد بديل عبر واجهة القناة اليوم. انظر طلب ملف.

3 · Older material describes paths that do not exist٣ · مواد قديمة تصف مسارات غير موجودة

English العربية
Earlier drafts described conversations under /api/integrations/*. Those paths answer 404. The running server uses sessions under /api/channel/v1/*, and this documentation follows the running server. مسودات سابقة وصفت conversations تحت /api/integrations/*، وهذه المسارات تردّ 404. الخادم العامل يستخدم sessions تحت /api/channel/v1/*، وهذا التوثيق يتبع الخادم العامل.

4 · Invitation links٤ · روابط الدعوات

English العربية
Invitation links point to https://web.securely.ae/invite/…, the customer site. A fix that makes every link use that host is going into the next release; until it ships, the url field may carry a different Securely host. Always send the customer the url exactly as returned. Do not build the link yourself. روابط الدعوات تشير إلى https://web.securely.ae/invite/…، موقع العملاء. وإصلاح يجعل كل الروابط على هذا المضيف يدخل في الإصدار القادم، وإلى أن يُنشر قد يحمل الحقل url مضيفاً آخر من مضيفات سكيورلي. أرسل للعميل قيمة url كما وصلتك تماماً، ولا تبنِ الرابط بنفسك.

Connect Securely to the apps your team already usesاربط سكيورلي بالتطبيقات التي يستخدمها فريقك أصلاً

Any application that can call a URL and receive a webhook can be connected. There is no connector to install and no marketplace review to wait for. The General Guide shows the one pattern every integration follows: open a session with externalRef, then write back from the signed events.أي تطبيق يستطيع نداء عنوان واستقبال حدث يمكن ربطه. لا موصّل يُثبَّت ولا مراجعة متجر تُنتظر. والدليل العام يشرح النمط الواحد الذي يتبعه كل تكامل: افتح جلسة مع externalRef، ثم اكتب على السجل من الأحداث الموقَّعة.

POST/api/channel/v1/sessions

Create a sessionإنشاء جلسة آمنة

Opens a secure session against a record in your own system. This is the first call of every bidirectional integration: whatever you put in externalRef here is what comes back on every event about this session.يفتح جلسة آمنة مرتبطة بسجل في نظامك أنت. هذا أول نداء في أي ربط بالاتجاهين: ما تضعه في externalRef هنا هو ما يعود إليك مع كل حدث يخصّ هذه الجلسة.

Required scopeالنطاق المطلوب sessions:write · Idempotency-Key requiredتتطلب Idempotency-Key

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Idempotency-Keya1b2c3d4-…requiredRequired on every write. A retry with the same key and body returns the stored response instead of creating a duplicate.مطلوب على كل كتابة. إعادة الإرسال بنفس المفتاح ونفس الجسم تُعيد الجواب المخزَّن بدل إنشاء نسخة ثانية.
Content-Typeapplication/jsonrequired

Body parametersحقول الجسم

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
employeeIdstring-The owning employee. Defaults to the key's creator.الموظف صاحب الجلسة. إن أُهمل يُستخدم منشئ المفتاح.
customerDisplayNamestring-Display name for the customer.اسم العرض للعميل.
sourceTypestring-Where the session originated.من أين جاءت الجلسة.
externalRefobject-Reference to the record in your system, see the table below.مرجع السجل في نظامك، انظر الجدول أدناه.
externalRef.systemstring 1..64requiredThe calling system, e.g. salesforce.معرّف النظام المُنادي، مثل salesforce.
externalRef.recordTypestring ≤64-The record type, e.g. Opportunity.نوع السجل، مثل Opportunity.
externalRef.recordIdstring 1..128requiredThe record id in your system.رقم السجل في نظامك.
externalRef.urlurl ≤512-Link to the record. Must be a valid URL.رابط السجل. يجب أن يكون عنواناً صالحاً.

Responsesالردود

201Session created.أُنشئت الجلسة.
404Employee not found in this tenant.الموظف غير موجود في هذا المستأجر.
400Idempotency-Key missing, or its length is out of range.Idempotency-Key مفقودة أو طولها خارج المدى.
409The original request with this key is still in progress. Retry shortly.الطلب الأصل بنفس المفتاح ما زال قيد المعالجة. أعد المحاولة بعد قليل.
422This key was already used with a different body. That is a client error, not a retry, use a new key.نفس المفتاح استُخدم بجسم مختلف. هذا خطأ عميل لا إعادة محاولة، استخدم مفتاحاً جديداً.
503Could not establish idempotency. **No write was performed.** Retry with the same key.تعذّر تثبيت منع التكرار. **لم تتم أي كتابة.** أعد المحاولة بنفس المفتاح.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
GET/api/channel/v1/sessions

List sessionsسرد الجلسات

Returns sessions for the key's tenant, newest first.يعيد جلسات مستأجر المفتاح، الأحدث أولاً.

Required scopeالنطاق المطلوب sessions:read

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Content-Typeapplication/jsonrequired

Query parametersمعاملات الاستعلام

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
statusstring-Filter by status.تصفية بالحالة.
limitinteger 1..200-How many rows to return.عدد النتائج.

Responsesالردود

200An array of sessions.مصفوفة جلسات.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
GET/api/channel/v1/sessions/{id}

Get a session with its messagesجلب جلسة برسائلها

Returns one session, its externalRef, and its messages with content decrypted for the tenant.يعيد جلسة واحدة، ومرجعها الخارجي، ورسائلها بمحتوى مفكوك التشفير لهذا المستأجر.

Required scopeالنطاق المطلوب sessions:read

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Content-Typeapplication/jsonrequired

Path parametersمعاملات المسار

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
idstringrequiredThe session id.معرّف الجلسة.

Responsesالردود

200The session and its messages.الجلسة ورسائلها.
404Session not found.الجلسة غير موجودة.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
POST/api/channel/v1/sessions/{id}/messages

Send a messageإرسال رسالة

Posts a message into an active session. The session must be active, a closed session answers 409.يضع رسالة في جلسة نشطة. يجب أن تكون الجلسة نشطة، الجلسة المغلقة تردّ 409.

Required scopeالنطاق المطلوب sessions:write · Idempotency-Key requiredتتطلب Idempotency-Key

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Idempotency-Keya1b2c3d4-…requiredRequired on every write. A retry with the same key and body returns the stored response instead of creating a duplicate.مطلوب على كل كتابة. إعادة الإرسال بنفس المفتاح ونفس الجسم تُعيد الجواب المخزَّن بدل إنشاء نسخة ثانية.
Content-Typeapplication/jsonrequired

Path parametersمعاملات المسار

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
idstringrequiredThe session id.معرّف الجلسة.

Body parametersحقول الجسم

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
contentstring ≥1requiredThe message text. Stored encrypted with the tenant's key.نص الرسالة. يُخزَّن مشفَّراً بمفتاح المستأجر.
senderTypestring-Who is sending.من المرسِل.
senderDisplayNamestring-Display name of the sender.اسم العرض للمرسِل.

Responsesالردود

201Message sent.أُرسلت الرسالة.
404Session not found.الجلسة غير موجودة.
409Session is not active.الجلسة ليست نشطة.
400Idempotency-Key missing, or its length is out of range.Idempotency-Key مفقودة أو طولها خارج المدى.
409The original request with this key is still in progress. Retry shortly.الطلب الأصل بنفس المفتاح ما زال قيد المعالجة. أعد المحاولة بعد قليل.
422This key was already used with a different body. That is a client error, not a retry, use a new key.نفس المفتاح استُخدم بجسم مختلف. هذا خطأ عميل لا إعادة محاولة، استخدم مفتاحاً جديداً.
503Could not establish idempotency. **No write was performed.** Retry with the same key.تعذّر تثبيت منع التكرار. **لم تتم أي كتابة.** أعد المحاولة بنفس المفتاح.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
POST/api/channel/v1/sessions/{id}/close

Close a sessionإغلاق جلسة

Closes the session and emits session.closed. Closing an already-closed session answers 200, not an error.يغلق الجلسة ويُصدر الحدث session.closed. إغلاق جلسة مغلقة أصلاً يردّ 200 لا خطأ.

Required scopeالنطاق المطلوب sessions:write · Idempotency-Key requiredتتطلب Idempotency-Key

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Idempotency-Keya1b2c3d4-…requiredRequired on every write. A retry with the same key and body returns the stored response instead of creating a duplicate.مطلوب على كل كتابة. إعادة الإرسال بنفس المفتاح ونفس الجسم تُعيد الجواب المخزَّن بدل إنشاء نسخة ثانية.
Content-Typeapplication/jsonrequired

Path parametersمعاملات المسار

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
idstringrequiredThe session id.معرّف الجلسة.

Responsesالردود

200Session closed.أُغلقت الجلسة.
404Session not found.الجلسة غير موجودة.
400Idempotency-Key missing, or its length is out of range.Idempotency-Key مفقودة أو طولها خارج المدى.
409The original request with this key is still in progress. Retry shortly.الطلب الأصل بنفس المفتاح ما زال قيد المعالجة. أعد المحاولة بعد قليل.
422This key was already used with a different body. That is a client error, not a retry, use a new key.نفس المفتاح استُخدم بجسم مختلف. هذا خطأ عميل لا إعادة محاولة، استخدم مفتاحاً جديداً.
503Could not establish idempotency. **No write was performed.** Retry with the same key.تعذّر تثبيت منع التكرار. **لم تتم أي كتابة.** أعد المحاولة بنفس المفتاح.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
POST/api/channel/v1/invites

Create an invitationإنشاء دعوة

Creates a one-time invitation link you can send to a customer. The response carries the raw code once, it is not retrievable later.ينشئ رابط دعوة لمرة واحدة تُرسله للعميل. الجواب يحمل الرمز الخام مرة واحدة، لا يمكن استرجاعه لاحقاً.

The link in url points to https://web.securely.ae/invite/…. A fix that makes every link use that host is going into the next release; until then the host may differ. Send the url exactly as returned.الرابط في url يشير إلى https://web.securely.ae/invite/…. وإصلاح يجعل كل الروابط على هذا المضيف يدخل في الإصدار القادم، وإلى ذلك الحين قد يختلف المضيف. أرسل قيمة url كما وصلتك تماماً.

Required scopeالنطاق المطلوب sessions:write · Idempotency-Key requiredتتطلب Idempotency-Key

Headersالترويسات

HeaderالترويسةExampleمثالReq.إلزاميDescriptionالوصف
AuthorizationBearer ck_live_…requiredThe channel API key. Shown once at creation, stored SHA-256 hashed.مفتاح القناة. يُعرض مرة واحدة عند إنشائه ويُخزَّن مجزّأً.
Idempotency-Keya1b2c3d4-…requiredRequired on every write. A retry with the same key and body returns the stored response instead of creating a duplicate.مطلوب على كل كتابة. إعادة الإرسال بنفس المفتاح ونفس الجسم تُعيد الجواب المخزَّن بدل إنشاء نسخة ثانية.
Content-Typeapplication/jsonrequired

Body parametersحقول الجسم

FieldالحقلTypeالنوعReq.إلزاميDescriptionالوصف
labelstring-An internal label for the invite.وسم داخلي للدعوة.
ttlHoursnumber-Lifetime in hours (clamped by the server).مدة الصلاحية بالساعات (تُقيَّد بحدّ الخادم).
externalRefobject-The same externalRef schema.نفس مخطّط المرجع الخارجي.
externalRef.systemstring 1..64requiredThe calling system, e.g. salesforce.معرّف النظام المُنادي، مثل salesforce.
externalRef.recordTypestring ≤64-The record type, e.g. Opportunity.نوع السجل، مثل Opportunity.
externalRef.recordIdstring 1..128requiredThe record id in your system.رقم السجل في نظامك.
externalRef.urlurl ≤512-Link to the record. Must be a valid URL.رابط السجل. يجب أن يكون عنواناً صالحاً.

Responsesالردود

201Invite created.أُنشئت الدعوة.
404The API key's creator employee was not found in this tenant.موظف منشئ المفتاح غير موجود في هذا المستأجر.
400Idempotency-Key missing, or its length is out of range.Idempotency-Key مفقودة أو طولها خارج المدى.
409The original request with this key is still in progress. Retry shortly.الطلب الأصل بنفس المفتاح ما زال قيد المعالجة. أعد المحاولة بعد قليل.
422This key was already used with a different body. That is a client error, not a retry, use a new key.نفس المفتاح استُخدم بجسم مختلف. هذا خطأ عميل لا إعادة محاولة، استخدم مفتاحاً جديداً.
503Could not establish idempotency. **No write was performed.** Retry with the same key.تعذّر تثبيت منع التكرار. **لم تتم أي كتابة.** أعد المحاولة بنفس المفتاح.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403Required scope not on the key, the tenant's plan does not enable the Channel API, or the tenant is not yet verified.النطاق المطلوب غير موجود في المفتاح، أو باقة المستأجر لا تُفعّل واجهة القناة، أو المستأجر غير موثَّق بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key. The body carries retryAfterSeconds.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح. الجسم يحمل retryAfterSeconds.
POST/api/channel/v1/file-requests

Request a fileطلب ملف

Meant to ask a customer for a document inside a session. Not available yet.الغرض منها أن تطلب من العميل مستنداً داخل جلسة. غير متاحة بعد.

Not available yet. This endpoint answers 501 FILE_REQUESTS_NOT_IMPLEMENTED. No file request is created, there is no upload location, and no file.uploaded event will follow. Do not build on it until it answers 201. There is no Channel API workaround today.غير متاحة بعد. هذه النقطة تردّ بـ 501 FILE_REQUESTS_NOT_IMPLEMENTED. لا يُنشأ طلب ملف، ولا يوجد موقع رفع، ولن يتبعها حدث file.uploaded. لا تبنِ عليها حتى تردّ بـ 201. ولا يوجد بديل عبر واجهة القناة اليوم.

Required scopeالنطاق المطلوب files:write

Responsesالردود

501Not implemented. Nothing was created. The body carries error, message, errorAr, action and actionAr.غير منفَّذة. لم يُنشأ شيء. الجسم يحمل error وmessage وerrorAr وaction وactionAr.
401Key missing, invalid or revoked.المفتاح مفقود أو غير صالح أو مُبطَل.
403The key does not carry files:write, the plan does not include the Channel API, or the company is not verified yet.المفتاح لا يحمل files:write، أو الباقة لا تشمل واجهة القناة، أو الشركة غير موثَّقة بعد.
429Rate limit exceeded: 120 requests per 60 seconds per key.تجاوز الحدّ: ١٢٠ طلباً في ٦٠ ثانية لكل مفتاح.

The General Guide · الدليل العام

Not available yet: the document step of this pattern. POST /file-requests answers 501 and file.uploaded is not sent yet. Sessions, messages, invitations and the three live events work today.غير متاح بعد: خطوة المستند في هذا النمط. POST /file-requests تردّ بـ 501 والحدث file.uploaded لا يُرسَل بعد. الجلسات والرسائل والدعوات والأحداث الثلاثة الحية تعمل اليوم.

One method for every app. Whatever system you connect, the integration is the same pattern, described below.طريقة واحدة لكل تطبيق. أيّاً كان النظام الذي تربطه، فالتكامل هو النمط نفسه الموصوف أدناه.

١ · الفكرة كلها في جملة / The whole idea in one sentence

English العربية
Securely does not build an app inside your customer's system. Your customer's system calls Securely with an API key, and Securely calls back with a signed event, and a single field, externalRef, remembers which record the conversation belongs to. سكيورلي لا يبني تطبيقاً داخل نظام عميلك. نظام عميلك ينادي سكيورلي بمفتاح، وسكيورلي يردّ عليه بحدث موقَّع، وحقل واحد اسمه externalRef يتذكّر إلى أي سجل تنتمي المحادثة.
That one field is what makes the integration bidirectional rather than one-way. Without it, a document arrives and nobody knows where it belongs. هذا الحقل وحده هو ما يجعل الربط بالاتجاهين لا باتجاه واحد. بدونه يصل المستند ولا أحد يعرف مكانه.
There is no marketplace connector to install and no vendor approval to wait for. This was a deliberate decision, not a shortcut. لا يوجد موصّل من متجر يُثبَّت ولا موافقة مورّد تُنتظر. هذا قرار متعمَّد لا اختصار.

٢ · الاتجاه الأول: من تطبيق العميل إلى سكيورلي / Direction A: their app → Securely

Step English العربية
1 An employee acts inside their own screen, a button on a CRM record, a workflow rule, an automation step. الموظف يتصرّف داخل شاشته هو، زر على سجل، أو قاعدة سير عمل، أو خطوة أتمتة.
2 That action sends one HTTPS request to https://api.securely.ae/api/channel/v1/... carrying Authorization: Bearer ck_live_... and Idempotency-Key. ذلك الفعل يرسل طلباً واحداً إلى https://api.securely.ae/api/channel/v1/... يحمل المفتاح وترويسة منع التكرار.
3 The request carries externalRef, which system, which record type, which record id, and the record's link. الطلب يحمل externalRef · أي نظام، وأي نوع سجل، وأي رقم سجل، ورابط السجل.
4 Securely opens the secure session, sends the invitation or the document request, and answers immediately. سكيورلي يفتح الجلسة الآمنة، ويرسل الدعوة أو طلب المستند، ويردّ فوراً.

٣ · الاتجاه الثاني: من سكيورلي إلى تطبيق العميل / Direction B: Securely → their app

Step English العربية
1 The customer uploads the document inside Securely. Nothing leaves the secure channel except the notification. العميل يرفع المستند داخل سكيورلي. لا يخرج شيء من القناة الآمنة سوى الإشعار.
2 Securely emits file.uploaded to the endpoint the tenant registered, signed with HMAC-SHA256, and the event carries the same externalRef it was given. سكيورلي يُصدر حدث file.uploaded إلى العنوان الذي سجّله المستأجر، موقَّعاً بـHMAC-SHA256، ويحمل الحدث نفس externalRef الذي أُعطي له.
3 The receiving side verifies the signature, reads externalRef.recordId, and writes the file onto that exact record. الطرف المستقبِل يتحقّق من التوقيع، ويقرأ externalRef.recordId، ويكتب الملف على ذلك السجل بعينه.
4 The loop is closed. The employee never left their screen, and the document never travelled by email. تُغلق الحلقة. الموظف لم يغادر شاشته، والمستند لم يسافر بالبريد.

٤ · الأحداث الأربعة / The four events

Event English العربية
session.created A secure session was opened. فُتحت جلسة آمنة.
message.created A message was posted in the session. نُشرت رسالة في الجلسة.
file.uploaded The one that matters. A document arrived; this is what files it back. الحدث المهم. وصل مستند؛ هذا ما يعيده إلى سجله.
session.closed The session was closed. أُغلقت الجلسة.

٥ · ثلاث حمايات لا تُلغى / Three protections that are not optional

English العربية
Idempotency. Idempotency-Key is required on every write. Automation platforms retry on timeout by default; without this header a slow request would create the same session, invite or message twice. منع التكرار. ترويسة Idempotency-Key مطلوبة على كل كتابة. منصات الأتمتة تعيد المحاولة تلقائياً عند التأخير؛ بدون هذه الترويسة يُنشأ الشيء نفسه مرتين.
Signature verification. Every outbound event is signed HMAC-SHA256 over the raw body. An unverified event must be rejected, otherwise anyone who learns the endpoint can write into the CRM. التحقق من التوقيع. كل حدث صادر موقَّع. الحدث غير المتحقَّق منه يُرفض، وإلا استطاع أي شخص يعرف العنوان أن يكتب في نظام العميل.
Retry is built in. 30s · 2m · 10m · 1h · 6h, then dead-letter, six attempts over about seven hours. A customer endpoint down for ten minutes loses nothing. إعادة المحاولة مبنية. ٣٠ث · ٢د · ١٠د · ١س · ٦س ثم حالة ميتة، ست محاولات على نحو سبع ساعات. عطل عشر دقائق عند العميل لا يُضيّع شيئاً.

٦ · أي تطبيق يختاره العميل، شجرة قرار / Any app the customer picks, decision tree

Question English العربية
Does the app let you call an outside URL (webhook, workflow action, HTTP step)? If yes → Direction A is native. Use it. إن نعم → الاتجاه الأول جاهز في التطبيق نفسه. استخدمه.
Does the app have a REST API that can attach a file to a record? If yes → Direction B is native. Use it. إن نعم → الاتجاه الثاني جاهز. استخدمه.
Either answer is no? Put an automation platform in the middle, n8n first, because it is self-hostable inside the UAE and the data never leaves the country. أحد الجوابين لا؟ ضع منصة أتمتة في المنتصف، n8n أولاً، لأنها تُستضاف داخل الإمارات ولا تغادر البيانات البلد.
Both answers are no, and there is no automation connector? Then it is not bidirectional, and the page for it says so plainly. Tally Prime is the honest example. كلاهما لا، ولا يوجد موصّل أتمتة؟ إذاً ليس بالاتجاهين، وصفحته تقول ذلك صراحةً. Tally Prime هو المثال الصريح.

٧ · خطوات الربط العامة / Generic setup steps

# English العربية
1 Issue a Securely API key for the tenant. It is shown once. أصدر مفتاح سكيورلي للمستأجر. يُعرض مرة واحدة فقط.
2 Register the webhook destination and store the signing secret. سجّل وجهة الويبهوك واحفظ سرّ التوقيع.
3 Create the custom field on the other app that will hold the Securely session id. أنشئ الحقل المخصّص في التطبيق الآخر ليحمل رقم جلسة سكيورلي.
4 Wire Direction A: the button/rule that calls POST /api/channel/v1/sessions with externalRef. اربط الاتجاه الأول: الزر أو القاعدة التي تنادي إنشاء الجلسة ومعها externalRef.
5 Wire Direction B: verify signature → read externalRef → attach the file. اربط الاتجاه الثاني: تحقّق من التوقيع ← اقرأ externalRef ← أرفق الملف.
6 Test the round trip once end to end before going live. اختبر الرحلة كاملة مرة واحدة قبل التشغيل.

٨ · أخطاء شائعة / Common failures

Symptom Cause Fix
The same session appears twice Idempotency-Key missing or regenerated on retry Generate the key once per business action and reuse it on retries
Document arrives but lands nowhere externalRef was not sent at session creation It cannot be added later, send it on the first call
Events stop arriving Endpoint returned 5xx six times and went to dead_letter Fix the endpoint, then replay from the delivery log
422 on a retry Same key, different body Never reuse a key for a different payload
409 The original request is still being processed Wait and retry the same key

٩ · المصادر / Sources

  • Securely Channel API, live code, artifacts/api-server/src/routes/channel.ts
  • /home/claude/wiki/SECURELY-SIDE-FACTS.md
Nothing matches that search.لا نتيجة مطابقة.