> ## Documentation Index
> Fetch the complete documentation index at: https://docs.didit.me/llms.txt
> Use this file to discover all available pages before exploring further.

# إنشاء سير العمل عبر API: بناء سير عمل KYC

> أنشئ سير عمل التحقق في Didit برمجياً بميزات مرتبة: KYC وKYB وAML والبيومترية في سير عمل واحد. دفع لكل استدعاء، دون عقود.



موجّه إنشاء سير العمل عبر API
        نسخ الموجّه إلى الحافظة



      
      

\<pre>

\`Create a simple Didit workflow through the Management API.

Endpoint:
POST https://verification.didit.me/v3/workflows/

Authentication:
Use the x-api-key header with my Didit API key.

Requirements:
\- Use the simple v3 API shape with features.
\- Send features in the exact order users should complete them.
\- Do not send workflow_graph, branches, actions, webhooks, or conditional logic.
\- Didit will convert the features array into a linear node-based workflow and add the final status step automatically.
\- Use uppercase feature values such as OCR, LIVENESS, FACE_MATCH, AML, QUESTIONNAIRE, EMAIL_VERIFICATION, PHONE_VERIFICATION, or PROOF_OF_ADDRESS.
\- Configure each feature with the fields from /management-api/workflows/feature-configs.
\- For an OCR feature, omit config.documents_allowed or send an empty object to allow every supported document type. Send config.documents_allowed only to restrict the allowed documents.
\- Put dependency features first. For example, put OCR before FACE_MATCH, NFC, DATABASE_VALIDATION, or user AML checks that depend on document data.
\- For a QUESTIONNAIRE feature, first create the questionnaire with POST /v3/questionnaires/ and use the returned questionnaire_id as config.questionnaire_uuid.
\- Store the workflow uuid returned by the response. Use it as workflow_id when creating sessions and as settings_uuid when updating this workflow.

Example KYC request body:
\{
"workflow_label": "Standard KYC",
"features": [
\{
  "feature": "OCR",
  "config": {
    "documents_allowed": {
      "USA": {
        "DL": {
          "enabled": 1,
          "sides": 2
        }
      }
    },
    "duplicated_user_action": "REVIEW"
  }
},
\{
  "feature": "LIVENESS",
  "config": {
    "face_liveness_method": "PASSIVE"
  }
},
\{
  "feature": "FACE_MATCH"
}
]
}

Example questionnaire workflow body:
\{
"workflow_label": "Source of Funds",
"features": [
\{
  "feature": "QUESTIONNAIRE",
  "config": {
    "questionnaire_uuid": "11111111-2222-3333-4444-555555555555",
    "review_questionnaire_manually": true
  }
}
]
}

Build the API call, handle validation errors, and return the workflow uuid from the response.`

\</pre>



      
      

الصق في

استخدم نقطة النهاية هذه لإنشاء سير عمل عبر API دون بناء عُقد مخطط سير العمل بنفسك. أرسل مصفوفة `features` بالترتيب الذي يجب أن يُنفّذ به المستخدمون الفحوصات. يحوّلها Didit داخليًا إلى سير عمل قائم على العُقد، ويضيف خطوة الحالة النهائية تلقائيًا.تُنشئ نقطة النهاية `POST /v3/workflows/` هذه سير عمل **بسيطًا وخطيًا** فقط، أي قائمة `features` مسطّحة. أما **التفرّع والتوجيه الشرطي وDocument AI وعُقد الرفض والقرار**، فاستخدم [تنسيق المخطط البياني للعقد](#سير-عمل-قائم-على-الفروع-والعُقد-مخطط) الموثّق أدناه، فهو يشغّل المُنشئ المرئي في الكونسول و[أدوات سير العمل في Didit MCP](https://docs.didit.me/ar/integration/mcp/overview.md).راجع [إعدادات ميزات سير العمل](https://docs.didit.me/ar/management-api/workflows/feature-configs.md) لكل حقل `config` تقبله كل ميزة.## سير عمل KYC الأساسي```json theme={null}
{
  "workflow_label": "Standard KYC",
  "features": [
    {
      "feature": "OCR",
      "config": {
        "documents_allowed": {
          "USA": {
            "DL": {
              "enabled": 1,
              "sides": 2
            }
          }
        },
        "duplicated_user_action": "REVIEW"
      }
    },
    {
      "feature": "LIVENESS",
      "config": {
        "face_liveness_method": "PASSIVE"
      }
    },
    {
      "feature": "FACE_MATCH"
    }
  ]
}
```## سير عمل الاستبيانأنشئ أولاً الاستبيان باستخدام `POST /v3/questionnaires/`. ثم استخدم `questionnaire_id` المُعاد كقيمة لـ `questionnaire_uuid`.```json theme={null}
{
  "workflow_label": "Source of Funds",
  "features": [
    {
      "feature": "QUESTIONNAIRE",
      "config": {
        "questionnaire_uuid": "11111111-2222-3333-4444-555555555555",
        "review_questionnaire_manually": true
      }
    }
  ]
}
```ترتيب الميزات مهم. على سبيل المثال، ضع `OCR` قبل `FACE_MATCH` أو `NFC` أو `DATABASE_VALIDATION` أو فحوصات AML للمستخدم التي تعتمد على بيانات المستند.## مرجع إعدادات الميزاتيتّبع كل عنصر في `features[]` هذا الشكل:```json theme={null}
{
  "feature": "OCR",
  "label": "ID Verification",
  "config": {}
}
```يعتمد كائن `config` الدقيق على الميزة. راجع قائمة الحقول الكاملة والقيم الافتراضية والإعدادات المطلوبة ونطاقات القيم والأمثلة في [إعدادات ميزات سير العمل](https://docs.didit.me/ar/management-api/workflows/feature-configs.md).بالنسبة إلى `OCR`، احذف `config.documents_allowed`، أو أرسل `null`، أو أرسل `{}` للسماح بكل أنواع المستندات المدعومة. أدرجه فقط عندما تريد قصر سير العمل على دول أو أنواع مستندات محددة. أما بالنسبة إلى `QUESTIONNAIRE`، فإن `config.questionnaire_uuid` مطلوب.## إعدادات سير العمل الاختياريةيمكنك إدراج أي من هذه الحقول على المستوى الأعلى عند إنشاء سير عمل للتحكم في سلوك الجلسة. كلها اختيارية، وتعود إلى القيم الافتراضية لسير العمل عند عدم إدراجها.| الحقل | النوع | الوصف |
| - | - | - |
| `is_white_label_enabled` | قيمة منطقية | تفعيل تخصيص العلامة البيضاء للجلسات المُنشأة بسير العمل هذا. الافتراضي `false`. |
| `is_desktop_allowed` | قيمة منطقية | السماح بتشغيل مسار التحقق على متصفحات سطح المكتب. الافتراضي `false`. |
| `max_retry_attempts` | عدد صحيح (0–10) | الحد الأقصى لمحاولات إعادة المحاولة المسموح بها بعد عملية تحقق مرفوضة. القيمة `0` تحظر المستخدم بعد أول رفض. الافتراضي `3`. |
| `retry_window_days` | عدد صحيح (1–365) أو `null` | نافذة متدحرجة بالأيام تُستخدم لاحتساب المحاولات (`null` = حد غير مقيّد بمدة زمنية). الافتراضي `7`. |
| `session_expiration_time` | عدد صحيح (3600–2419200) | عدد الثواني قبل انتهاء صلاحية الجلسة غير المكتملة. الحد الأدنى ساعة واحدة، والحد الأقصى 4 أسابيع. الافتراضي `604800` (7 أيام). |
| `response_attributes` | كائن أو `null` | يحدد الحقول المُعادة لكل ميزة، مثلاً `{"id_verifications": ["full_name", "document_number"], "face_matches": null}`. القيمة `null` أو غياب المفتاح يعيدان كل الحقول. القائمة الفارغة تعيد فقط `status` و`warnings` و`node_id` و`is_nfc_skipped` و`skip_reason`، وتعود الحقول الأخرى `null`. |```json theme={null}
{
  "workflow_label": "Standard KYC",
  "is_white_label_enabled": true,
  "is_desktop_allowed": true,
  "max_retry_attempts": 5,
  "retry_window_days": 14,
  "session_expiration_time": 86400,
  "features": [
    { "feature": "OCR" },
    { "feature": "LIVENESS" },
    { "feature": "FACE_MATCH" }
  ]
}
```## سير عمل قائم على الفروع والعُقد (مخطط)لا تستطيع قائمة `features` الخطية التعبير عن "إذا حدث X فافعل Y". للتفرّع الشرطي (الرفض بناءً على الحالة، أو التوجيه بناءً على حقل مستخرج، أو جعل خطوة مشروطة بنتيجة مطابقة)، أو لخطوة طلب **Document AI**، أو لعُقد **الرفض/القرار** النهائية، تستخدم سير عمل Didit **مخططاً من العُقد**، وهو البنية نفسها التي ينتجها المنشئ المرئي في وحدة التحكم.> [!NOTE]
>
> أبسط طريقة لبناء سير عمل بمخطط هي **[Didit MCP](https://docs.didit.me/ar/integration/mcp/overview.md)**. اطلب من وكيل بلغة عادية (مثلاً: "بعد التحقق من الهوية، إذا كانت المهنة ≈ 'Software Engineer'، فأضف خطوة إثبات الأموال")، وسيُنشئ المخطط ويتحقق منه ويحفظه لك. البنية أدناه هي ما تنتجه هذه الأدوات (وكذلك وحدة التحكم).### بنية المخططالمخطط كائن بالشكل `{ start_node, nodes }`. وحقل `nodes` خريطة من معرّف العقدة إلى العقدة. الروابط ضمنية: كل عقدة تشير إلى ما بعدها عبر `next` (بلا شرط) و/أو `branches[].goto` (بشرط).| نوع العقدة | البنية |
| - | - |
| `feature` | `{ "node_type": "feature", "feature": "OCR", "config": {…}, "next": "<id>", "branches": [] }` |
| `branch` | `{ "node_type": "branch", "branches": [ { "id", "logic": "and"\|"or", "rules": [<rule>], "goto": "<id>" } ], "next": "<fallback id>" }` |
| `status` (نهائية) | `{ "node_type": "status", "session_status": "Approved"\|"Declined"\|"In Review"\|"Determine" }` |
| `action` | `{ "node_type": "action", "actions": [ { "type": "add_tag"\|"add_review"\|… } ], "next": "<id>" }` |
| `webhook` | `{ "node_type": "webhook", "config": { "url", "method" }, "branches": [], "next": "<id>" }` |يجب أن تكون `start_node` عقدة من نوع feature. تُقيَّم الفروع بالترتيب، و**أول تطابق يفوز**. والفرع الذي يحتوي على `rules: []` فارغة هو الفرع الاحتياطي "else" الذي يشمل كل ما عداه، ويجب أن يأتي في الآخر. تقرّر القيمة `session_status: "Determine"` النتيجة تلقائياً من مجموع نتائج الميزات.> [!WARNING]
>
> **يجب أن تحتوي كل عقدة فرع على فرع else صريح**، أي فرع بـ `rules: []` يوجّه الجلسات التي لا تطابق أيّاً من الشروط. لا تعتمد على `next` الخاصة بعقدة الفرع كبديل احتياطي: فحقل `next` المفرد يظهر كحافة غامضة في المنشئ المرئي، ويسهل نسيانه. عندما ترسل عقدة فرع تحمل `next` دون فرع else، يحوّل الـ API هذا الـ `next` إلى فرع else صريح نيابةً عنك (فالمدخل `{ …, "branches": [<conditions>], "next": "liveness" }` يُحفظ بالشكل `branches: [<conditions>, { "id": "else", "rules": [], "goto": "liveness" }]`). أنشئ فرع else بنفسك لتكون واضحاً؛ فهذا التحويل شبكة أمان وليس بديلاً عن ذلك.### قواعد الفروع والمعاملاتتقارن كل قاعدة **حقلاً** بـ **قيمة** باستخدام **معامل**:```json theme={null}
{ "field": "kyc.extra_fields.profession", "operator": "fuzzy_match", "value": "Software Engineer", "score": 80 }
```- **الحقول** تسمّي نتيجة ميزة (`kyc.status`، `aml.status`، `document_ai.status`، `face_match.score`، …) أو قيمة مستخرجة (`kyc.full_name`، `kyc.age`، `kyc.nationality`، `kyc.extra_fields.profession`، أو حقل Document AI `document_ai.<key>`، أو `expected_details.*`). ولا يجوز لفرع أن يقرأ حقلاً إلا إذا كانت ميزته قد نُفِّذت على كل مسار يصل إلى ذلك الفرع.
- **المعاملات:** `equals`، و`not_equals`، و`greater_than(_or_equals)`، و`less_than(_or_equals)`، و`contains`، و`not_contains`، و`in`، و`not_in`، و`is_empty`، و`is_not_empty`، و`regex`، و**`fuzzy_match`** (للحقول النصية فقط؛ ويتطلب `score` بين 0 و100، وهو عتبة تشابه، مثلاً: المهنة مشابهة بنسبة 80% على الأقل لـ "Software Engineer").### التفرّع حسب سبب عدم تنفيذ NFCبعد عقدة `NFC`، استخدم `nfc.skip_reason` مع `equals` أو `in` لتوجيه الجلسات بحسب سبب عدم قراءة الشريحة. للحقل سبع قيم ثابتة:- `USER_SKIPPED`
- `DOCUMENT_WITHOUT_CHIP`
- `CHIP_CERTIFICATE_UNAVAILABLE`
- `DEVICE_WITHOUT_NFC`
- `INTEGRATION_WITHOUT_NFC_ACCESS`
- `MRZ_KEY_UNAVAILABLE`
- `JPKI_UNAVAILABLE`راجع [أسباب تخطي NFC](https://docs.didit.me/ar/core-technology/nfc-verification/warnings-nfc-verification.md#أسباب-التخطي) لمعرفة ما تعنيه كل قيمة. وعندما ينجح NFC تكون قيمة `nfc.skip_reason` هي `null`، فلا تطابق قاعدة `equals` أو `in` لسبب التخطي.يُحسب هذا الحقل أيضاً للعُقد التي **تخطّتها البوابة**. ويشمل ذلك الحالات التي لا يوجد فيها تقرير أو تحذير لـ NFC، والحالات التي تكون فيها القيمة `allow_nfc_skip` مساوية لـ `false` لكن بوابة المستند أو الجهاز تمنع تشغيل NFC. لذلك يمكنك توجيه هذه الجلسات دون الاعتماد على وجود عنصر في `nfc_verifications[]`.> [!NOTE]
>
> قد تحمل الجلسات المحفوظة قبل أن تصبح قدرة NFC ثلاثية الحالات القيمة `has_device_nfc_support: false`. لذلك قد تُحسب جلسة ويب قديمة على أنها `DEVICE_WITHOUT_NFC` بدلاً من `INTEGRATION_WITHOUT_NFC_ACCESS`.يستخدم هذا المخطط المعامل `equals` لتخطي المستخدم، والمعامل `in` لتخطي البوابة أو القدرة، ووجود فرع else صريح لحالة نجاح NFC. يأتي الفرع بعد عقدة `NFC`، وتشير كل الوجهات إلى الأمام نحو عقدة نهائية:```json theme={null}
{
  "start_node": "ocr",
  "nodes": {
    "ocr": {
      "node_type": "feature",
      "feature": "OCR",
      "next": "nfc"
    },
    "nfc": {
      "node_type": "feature",
      "feature": "NFC",
      "config": { "allow_nfc_skip": false },
      "next": "route_nfc"
    },
    "route_nfc": {
      "node_type": "branch",
      "branches": [
        {
          "id": "user_skipped",
          "logic": "and",
          "rules": [
            { "field": "nfc.skip_reason", "operator": "equals", "value": "USER_SKIPPED" }
          ],
          "goto": "manual_review"
        },
        {
          "id": "nfc_unavailable",
          "logic": "and",
          "rules": [
            {
              "field": "nfc.skip_reason",
              "operator": "in",
              "value": [
                "DOCUMENT_WITHOUT_CHIP",
                "CHIP_CERTIFICATE_UNAVAILABLE",
                "DEVICE_WITHOUT_NFC",
                "INTEGRATION_WITHOUT_NFC_ACCESS",
                "MRZ_KEY_UNAVAILABLE",
                "JPKI_UNAVAILABLE"
              ]
            }
          ],
          "goto": "manual_review"
        },
        {
          "id": "else",
          "logic": "and",
          "rules": [],
          "goto": "approved"
        }
      ]
    },
    "manual_review": { "node_type": "status", "session_status": "In Review" },
    "approved": { "node_type": "status", "session_status": "Approved" }
  }
}
```لتعبّر عن "لم يُنفَّذ NFC لأي سبب معروف"، استخدم المعامل `in` مع **القيم السبع جميعها**. واحتفظ بفرع else صريح لحالة نجاح NFC (`nfc.skip_reason: null`) ولأي قيمة مستقبلية لا يتعرف عليها مخططك بعد.### Document AI (مثل إثبات الأموال)تطلب عقدة الميزة `DOCUMENT_AI` مستنداً واحداً أو أكثر، وتستخرج حقولاً مسماة:```json theme={null}
{
  "node_type": "feature",
  "feature": "DOCUMENT_AI",
  "label": "Proof of Funds",
  "config": {
    "document_ai_documents": [
      {
        "document_key": "proof_of_funds",
        "title": "Proof of Funds",
        "description": "Upload a recent bank statement.",
        "fields": [
          {
            "key": "account_holder",
            "name": "Account holder",
            "instruction": "The full name of the account holder as printed on the statement.",
            "type": "text",
            "required": true,
            "is_full_name": true
          },
          {
            "key": "closing_balance",
            "name": "Closing balance",
            "instruction": "The closing balance amount.",
            "type": "number",
            "required": true
          }
        ]
      }
    ],
    "document_ai_missing_required_fields_action": "REVIEW",
    "document_ai_name_mismatch_action": "REVIEW"
  },
  "next": "final_decision"
}
```يصبح كل حقل مُعدّ قيمة قابلة للتفرّع بالاسم `document_ai.<key>`، وتكون نتيجة الخطوة في `document_ai.status`.اضبط `"is_full_name": true` على الحقل الذي يحتوي على الاسم الكامل لحامل المستند. تُقارن قيمته المستخرجة بالاسم الكامل للهوية المتحقَّق منها (اسم OCR أو اسم التحقق من الهوية، أو التفاصيل المتوقعة للجلسة)، ويحدد `document_ai_name_mismatch_action` ما يحدث عندما تكون درجة المطابقة أدنى من `document_ai_name_match_score_threshold`. هذه العلامة **اختيارية**، فقد لا يحدد المستند أي حقل، و**لا يجوز** لأكثر من حقل واحد في كل مستند أن يضبطها. راجع [إعدادات ميزات سير العمل ← Document AI](https://docs.didit.me/ar/management-api/workflows/feature-configs.md#document-ai) لمعرفة كل حقل إعداد في Document AI.### نقاط endpoint ودورة حياة المسودةيتم تحرير المخطط لكل تطبيق، ويستخدم نقاط endpoint الخاصة بوحدة التحكم والإدارة (Bearer للمستخدم مع `read:workflows`/`write:workflows`). ولا يمكن تعديل المخطط إلا في نسخة **مسودة**، لذلك تكون دورة الحياة: **إنشاء المسودة ← تعيين المخطط ← النشر**.| الطريقة | المسار | الغرض |
| - | - | - |
| `GET` | `…/verification-settings/{settings_uuid}/workflow-graph/` | المخطط الحالي مع `status`/`is_editable` |
| `POST` | `…/application/{app}/workflow-graph/validate/` (body `{ "graph": … }`) | التحقق التجريبي |
| `GET` | `…/application/{app}/workflow-graph/field-definitions/` | الحقول القابلة للتفريع والعوامل الصالحة |
| `POST` | `…/verification-settings/{settings_uuid}/create-draft/` | مسودة قابلة للتعديل من نسخة منشورة |
| `PUT` | `…/verification-settings/{settings_uuid}/workflow-graph/` (body `{ "graph": … }`) | حفظ المخطط |
| `PATCH` | `…/verification-settings/{settings_uuid}/` (body `{ "status": "published" }`) | نشر المسودة |#### تحذيرات التحققتُرجع نقطة التحقق `{ "is_valid": true, "graph": …, "warnings": [] }`. التحذير **إرشادي**: المخطط صالح، ويُحفظ وينشر حتى مع وجود تحذيرات. يتضمن كل عنصر عقدة الفرع والذراع المعني بها، ليتمكن المنشئ من تحديد الشرط الدقيق:```json theme={null}
{
  "type": "branch_outcome_contradiction",
  "node_id": "after_ocr",
  "branch_id": "b1",
  "severity": "warning",
  "message": "Branch 1 only matches sessions where ID Verification Status is Approved or In Review, but every path from it ends in the session outcome \"Declined\". Check the condition or the outcome.",
  "params": { "branchNumber": 1, "field": "ID Verification Status", "allowed": "Approved or In Review", "outcome": "Declined" }
}
```| `type` | ماذا يعني |
| - | - |
| `branch_outcome_contradiction` | يتعارض شرط المسار مع النتيجة التي تصل إليها كل المسارات المنبثقة منه. مثلاً `kyc.status NOT EQUALS Declined` الموجَّه إلى نتيجة `Declined`. قد تكون النتيجة على بُعد عدة خطوات في المسار. |
| `branch_condition_unreachable` | لا يمكن أن يتحقق المسار أبداً، لأن كل مسار يصل إلى هذا الفرع يقيّد بالفعل حقل الحالة بقيم يستثنيها الشرط. |
| `else_branch_unreachable` | لا يمكن أن يُنفَّذ مسار else أبداً: المسارات الأخرى تغطي بالفعل كل قيمة يمكن أن يحملها الحقل هنا. |ترجع المخططات غير الصالحة الاستجابة `400` مع قائمة `errors` **و** قائمة `warnings` بأفضل جهد ممكن. فقط `errors` تمنع الحفظ.### مثال عملي: توجيه مهندسي البرمجيات إلى إثبات الأموال> بعد التحقق من الهوية: إذا كانت النتيجة **مرفوضة**، فارفض الجلسة؛ وإذا كانت **مهنة حامل الوثيقة ≈ "Software Engineer"** (بتشابه 80% أو أكثر)، فاطلب مستنداً **لإثبات الأموال**؛ ثم اتخذ القرار النهائي.```json theme={null}
{
  "start_node": "ocr_1",
  "nodes": {
    "ocr_1": { "node_type": "feature", "feature": "OCR", "label": "ID Verification", "next": "after_ocr" },
    "after_ocr": {
      "node_type": "branch",
      "label": "Route after ID verification",
      "branches": [
        { "id": "declined", "logic": "or", "rules": [ { "field": "kyc.status", "operator": "equals", "value": "Declined" } ], "goto": "decline" },
        { "id": "software_engineer", "logic": "and", "rules": [ { "field": "kyc.extra_fields.profession", "operator": "fuzzy_match", "value": "Software Engineer", "score": 80 } ], "goto": "proof_of_funds" },
        { "id": "else", "logic": "and", "rules": [], "goto": "final_decision" }
      ]
    },
    "proof_of_funds": {
      "node_type": "feature",
      "feature": "DOCUMENT_AI",
      "label": "Proof of Funds",
      "config": {
        "document_ai_documents": [
          { "document_key": "proof_of_funds", "title": "Proof of Funds", "description": "Upload a recent bank statement.",
            "fields": [
              { "key": "account_holder", "name": "Account holder", "type": "text", "required": true },
              { "key": "closing_balance", "name": "Closing balance", "type": "number", "required": true }
            ] }
        ],
        "document_ai_missing_required_fields_action": "REVIEW"
      },
      "next": "final_decision"
    },
    "final_decision": { "node_type": "status", "session_status": "Determine", "label": "Final decision" },
    "decline": { "node_type": "status", "session_status": "Declined", "label": "Declined" }
  }
}
```تستخدم العقدة النهائية `session_status: "Determine"`، التي **تتخذ القرار تلقائياً** (مقبولة / مرفوضة / قيد المراجعة) استناداً إلى الميزات التي نُفذت فعلياً في الجلسة. لذلك يُحسم كل من مسار إثبات الأموال ومسار else بشكل صحيح، دون أن يقرأ أي فرع الحقل `document_ai.status`، لأن هذا الحقل غير موجود في المسار الذي يتجاوز Document AI. تذكّر: يجوز للفرع أن يقرأ حقلاً فقط إذا نُفذت ميزته على *كل* مسار يصل إليه.أرسله بالشكل `{ "graph": <above> }` إلى نقطة `…/workflow-graph/` (تحقّق منه أولاً). لإنشاء سير عمل **جديد** من الصفر، استخدم أداة `didit_workflow_set_graph` في MCP. ولتعديل سير عمل **موجود**، استخدم `didit_workflow_edit_graph` (عمليات صغيرة، تحافظ على العقد الموجودة وقوائم السماح). راجع [Didit MCP](https://docs.didit.me/ar/integration/mcp/tools.md).


## OpenAPI

````yaml ar/openapi-25.json POST /v3/workflows/
openapi: 3.0.0
info:
  version: 3.0.0
  title: Didit Verification API
  description: API التحقق من الهوية. قم بالمصادقة باستخدام الرأس x-api-key.
servers:
  - url: https://verification.didit.me
security: []
tags: []
paths:
  /v3/workflows/:
    post:
      tags:
        - Workflows
      summary: إنشاء سير عمل
      description: >-
        أنشئ سير عمل بسيطاً. أرسل `features` بترتيب التنفيذ (تُطبق قواعد
        الترتيب)؛ القيمة الافتراضية هي الإصدار الأول v1 `published`. يقبل نص
        الطلب الحقول المدرجة في `SimpleWorkflowRequest` فقط — وأي مفتاح آخر (بما
        في ذلك `workflow_type`) يتم رفضه برمز 400. لا تتمتع العملية بخاصية
        idempotency — كل استدعاء يُنشئ سير عمل جديداً. الحد الأقصى 50 سير عمل
        لكل تطبيق.
      operationId: create_workflow
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/SimpleWorkflowRequest'
            examples:
              Simple KYC:
                summary: سير عمل خطي للتحقق من الهوية وكشف الحيوية ومطابقة الوجه
                value:
                  workflow_label: Standard KYC
                  features:
                    - feature: OCR
                      config:
                        duplicated_user_action: review
                    - feature: LIVENESS
                      config:
                        face_liveness_method: passive
                    - feature: FACE_MATCH
                      config:
                        face_match_score_decline_threshold: 40
                        face_match_score_review_threshold: 60
              KYC + AML:
                summary: تشغيل فحص AML بعد التحقق من الهوية
                value:
                  workflow_label: KYC with AML
                  features:
                    - feature: OCR
                    - feature: AML
                      config:
                        aml_score_review_threshold: 70
                        aml_score_approve_threshold: 30
              Questionnaire workflow:
                summary: تشغيل استبيان تم إنشاؤه عبر POST /v3/questionnaires/
                value:
                  workflow_label: Source of Funds
                  features:
                    - feature: QUESTIONNAIRE
                      config:
                        questionnaire_uuid: 11111111-2222-3333-4444-555555555555
                        review_questionnaire_manually: true
      responses:
        '201':
          description: >-
            تم إنشاء سير العمل. نص الاستجابة هو التكوين الكامل لسير العمل — نفس
            التسلسل الخام لـ `VerificationSettings` الذي يعود من `GET
            /v3/workflows/{settings_uuid}/` (حوالي 190 حقلاً: كل تبديل ميزة،
            وحد، وإجراء، و`workflow_graph` المُنشأ)، وليس عنصر القائمة المضغوط.
            قم بتخزين `uuid` (المعروض أيضاً باسم `workflow_id`) لتتمكن من الرجوع
            إليه في استدعاءات إنشاء الجلسة لاحقاً. ملاحظة: `features` هي سلسلة
            متصلة بـ `" + "` والأسعار هي أرقام JSON.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowDetail'
              examples:
                Created (abbreviated):
                  summary: الحقول الرئيسية لكائن التكوين الكامل
                  value:
                    uuid: c3d4e5f6-7890-12cd-ef34-333333333333
                    workflow_id: c3d4e5f6-7890-12cd-ef34-333333333333
                    workflow_label: Standard KYC
                    workflow_type: null
                    is_default: false
                    is_archived: false
                    total_price: 0.15
                    min_price: 0.15
                    max_price: 0.15
                    features: OCR + LIVENESS + FACE_MATCH
                    is_simple_workflow: false
                    is_editable: false
                    workflow_url: https://verify.didit.me/u/w9TkPOx8RWG3UAz5ZRQGVQ
                    workflow_graph:
                      start_node: ocr
                      nodes: ... one node per feature plus a final status node ...
                    max_retry_attempts: 3
                    retry_window_days: 7
                    session_expiration_time: 604800
                    version: 1
                    status: published
                    published_at: '2026-05-17T10:30:00Z'
                    created_at: '2026-05-17T10:30:00Z'
                    updated_at: '2026-05-17T10:30:00Z'
        '400':
          description: >-
            خطأ في التحقق. الأسباب الشائعة: مفتاح من المستوى الأعلى خارج القائمة
            البيضاء المقبولة (مثل `workflow_type`)، أو قيمة `feature` غير
            معروفة، أو وضع ميزة قبل متطلبها السابق (مثل `FACE_MATCH` قبل `OCR`)،
            أو استخدام ميزة سلبية (`AML`، `IP_ANALYSIS`، `DATABASE_VALIDATION`،
            `KYB_KEY_PEOPLE`) كخطوة أولى، أو ميزة `QUESTIONNAIRE` التي لا يتوفر
            `config.questionnaire_uuid` الخاص بها لهذا التطبيق، أو ميزة
            `SIGNATURE` التي سيتم إطلاقها بدون مستند للتوقيع، أو ميزة
            `SIGNATURE` بمستوى `signature_level: "aes"` في حين أن التوقيع
            المتقدم (AES) غير متاح (`aes_not_available`، راجع
            `signature_availability` في سير العمل)، أو حد خارج النطاق. نص
            الاستجابة هو كائن خطأ في التحقق من DRF — المفاتيح هي أسماء الحقول،
            والقيم عبارة عن مصفوفات من الرسائل المقروءة بشرياً.
          content:
            application/json:
              examples:
                Advanced (AES) not available:
                  value:
                    features:
                      signature_level:
                        - >-
                          Node 'signature': Advanced (AES) is not available yet
                          (aes_not_available).
                Signature step with no document:
                  value:
                    features:
                      non_field_errors:
                        - >-
                          Node 'signature': Add a document to sign, or let each
                          session bring its own.
                Missing feature:
                  value:
                    features:
                      - At least one feature is required.
                Unknown top-level field:
                  value:
                    workflow_type:
                      - >-
                        The v3 workflow API only accepts `workflow_label`,
                        `is_default`, `status`, `features`,
                        `is_white_label_enabled`, `is_desktop_allowed`,
                        `max_retry_attempts`, `retry_window_days`,
                        `session_expiration_time`, `face_liveness_max_attempts`,
                        `face_match_max_attempts`.
                Unknown feature:
                  value:
                    features:
                      - >-
                        Invalid feature 'FOO'. Allowed values: AGE_ESTIMATION,
                        AML, DATABASE_VALIDATION, EMAIL_VERIFICATION,
                        FACE_MATCH, IP_ANALYSIS, KYB_DOCUMENTS, KYB_KEY_PEOPLE,
                        KYB_REGISTRY, LIVENESS, NFC, OCR, PHONE_VERIFICATION,
                        PROOF_OF_ADDRESS, QUESTIONNAIRE.
                Ordering:
                  value:
                    features:
                      - 'Feature ''FACE_MATCH'' must appear after one of: OCR.'
                Questionnaire not found:
                  value:
                    features: >-
                      Questionnaire '11111111-2222-3333-4444-555555555555' was
                      not found for this application. Create the questionnaire
                      first, then use its questionnaire_id.
        '403':
          description: >-
            مفتاح API مفقود أو غير صالح أو منتهي الصلاحية أو مخصص لتطبيق مختلف.
            قم بالتحديث عبر [Auth API](/ar/auth-api/get-credentials) وأعد
            المحاولة.
          content:
            application/json:
              examples:
                Invalid token:
                  value:
                    detail: You do not have permission to perform this action.
        '415':
          description: >-
            نوع وسائط غير مدعوم. عيّن `Content-Type: application/json` وأرسل نص
            طلب بصيغة JSON.
        '429':
          description: تم تجاوز حد المعدل. أعد المحاولة مع تراجع أسي.
        '500':
          description: >-
            خطأ غير متوقع في الخادم أثناء إنشاء سير العمل. يمكن إعادة المحاولة
            بأمان.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: cURL
          source: |-
            curl -X POST 'https://verification.didit.me/v3/workflows/' \
              -H 'x-api-key: YOUR_API_KEY' \
              -H 'Content-Type: application/json' \
              -d '{
                "workflow_label": "Standard KYC",
                "features": [
                  {"feature": "OCR"},
                  {"feature": "LIVENESS", "config": {"face_liveness_method": "passive"}},
                  {"feature": "FACE_MATCH", "config": {"face_match_score_decline_threshold": 40, "face_match_score_review_threshold": 60}}
                ]
              }'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.workflows.create(
                workflow_label="Standard KYC",
                features=[{
                    "feature": "OCR",
                    "config": {"duplicated_user_action": "review"},
                }, {
                    "feature": "LIVENESS",
                    "config": {"face_liveness_method": "passive"},
                }, {
                    "feature": "FACE_MATCH",
                    "config": {"face_match_score_decline_threshold": 40, "face_match_score_review_threshold": 60},
                }],
            )
            print(result)
        - lang: javascript
          label: Node.js
          source: |-
            import Didit from "@didit-protocol/sdk-node";

            // Reads DIDIT_API_KEY.
            const didit = new Didit();

            const result = await didit.workflows.create({
              workflow_label: "Standard KYC",
              features: [{
                feature: "OCR",
                config: { duplicated_user_action: "review" },
              }, {
                feature: "LIVENESS",
                config: { face_liveness_method: "passive" },
              }, {
                feature: "FACE_MATCH",
                config: { face_match_score_decline_threshold: 40, face_match_score_review_threshold: 60 },
              }],
            });
            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Workflows.Create(ctx, didit.SimpleWorkflowRequest{\n\tWorkflowLabel: didit.String(\"Standard KYC\"),\n\tFeatures: []didit.SimpleWorkflowFeature{{\n\t\tFeature: \"OCR\",\n\t\tConfig:  didit.Some(map[string]any{\"duplicated_user_action\": \"review\"}),\n\t}, {\n\t\tFeature: \"LIVENESS\",\n\t\tConfig:  didit.Some(map[string]any{\"face_liveness_method\": \"passive\"}),\n\t}, {\n\t\tFeature: \"FACE_MATCH\",\n\t\tConfig:  didit.Some(map[string]any{\"face_match_score_decline_threshold\": 40, \"face_match_score_review_threshold\": 60}),\n\t}},\n})\nif err != nil {\n\tlog.Fatal(err)\n}\nfmt.Printf(\"%+v\\n\", result)"
        - lang: java
          label: Java
          source: >-
            import java.util.List;

            import java.util.Map;

            import me.didit.Didit;

            import me.didit.types.SimpleWorkflowFeature;

            import me.didit.types.SimpleWorkflowRequest;


            // Reads DIDIT_API_KEY.

            Didit client = new Didit();


            var result =
            client.workflows().create(SimpleWorkflowRequest.builder()
                    .workflowLabel("Standard KYC")
                    .features(List.of(
                            SimpleWorkflowFeature.builder()
                                    .feature(SimpleWorkflowFeature.Feature.of("OCR"))
                                    .config(Map.of("duplicated_user_action", "review"))
                                    .build(),
                            SimpleWorkflowFeature.builder()
                                    .feature(SimpleWorkflowFeature.Feature.of("LIVENESS"))
                                    .config(Map.of("face_liveness_method", "passive"))
                                    .build(),
                            SimpleWorkflowFeature.builder()
                                    .feature(SimpleWorkflowFeature.Feature.of("FACE_MATCH"))
                                    .config(Map.of("face_match_score_decline_threshold", 40, "face_match_score_review_threshold", 60))
                                    .build()))
                    .build());
            System.out.println(result);
        - lang: php
          label: PHP
          source: |-
            <?php

            require 'vendor/autoload.php';

            use Didit\DiditClient;

            // Reads DIDIT_API_KEY.
            $didit = new DiditClient();

            $result = $didit->workflows->create([
                'workflow_label' => 'Standard KYC',
                'features' => [[
                    'feature' => 'OCR',
                    'config' => ['duplicated_user_action' => 'review'],
                ], [
                    'feature' => 'LIVENESS',
                    'config' => ['face_liveness_method' => 'passive'],
                ], [
                    'feature' => 'FACE_MATCH',
                    'config' => ['face_match_score_decline_threshold' => 40, 'face_match_score_review_threshold' => 60],
                ]],
            ]);
            print_r($result->toArray());
        - lang: ruby
          label: Ruby
          source: |-
            require "didit"

            # Reads DIDIT_API_KEY.
            didit = Didit::Client.new

            result = didit.workflows.create(
              workflow_label: "Standard KYC",
              features: [{
                feature: "OCR",
                config: { duplicated_user_action: "review" },
              }, {
                feature: "LIVENESS",
                config: { face_liveness_method: "passive" },
              }, {
                feature: "FACE_MATCH",
                config: { face_match_score_decline_threshold: 40, face_match_score_review_threshold: 60 },
              }]
            )
            puts result.to_h
        - lang: csharp
          label: .NET
          source: >-
            using System;

            using System.Collections.Generic;

            using System.Text.Json;

            using Didit;


            // Reads DIDIT_API_KEY.

            using var client = new DiditClient();


            var result = await client.Workflows.CreateAsync(new
            SimpleWorkflowRequest

            {
                WorkflowLabel = "Standard KYC",
                Features = new SimpleWorkflowFeature[]
                {
                    new()
                    {
                        Feature = "OCR",
                        Config = new Dictionary<string, object> { ["duplicated_user_action"] = "review" },
                    },
                    new()
                    {
                        Feature = "LIVENESS",
                        Config = new Dictionary<string, object> { ["face_liveness_method"] = "passive" },
                    },
                    new()
                    {
                        Feature = "FACE_MATCH",
                        Config = new Dictionary<string, object> { ["face_match_score_decline_threshold"] = 40, ["face_match_score_review_threshold"] = 60 },
                    },
                },
            });

            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    SimpleWorkflowRequest:
      type: object
      description: >-
        أنشئ سير عمل خطياً بسيطاً. تحوّل API قائمة الميزات هذه داخلياً إلى مخطط
        سير عمل قائم على العقد. قائمة بيضاء صارمة للحقول: أي مفتاح غير مدرج هنا
        (بما في ذلك `workflow_type`) يتم رفضه برمز 400.
      required:
        - features
      properties:
        workflow_label:
          type: string
          maxLength: 50
          default: ID Verification
          description: >-
            اسم العرض لسير العمل (بحد أقصى 50 حرفاً). القيمة الافتراضية هي `"ID
            Verification"` عند حذفه — احرص دائماً على تعيينه لتبقى مسارات سير
            العمل قابلة للتمييز.
          example: Standard KYC
        is_default:
          type: boolean
          description: تعيين سير العمل هذا كافتراضي للجلسات الجديدة.
        status:
          type: string
          enum:
            - draft
            - published
          description: >-
            احذف هذا الحقل لإنشاء سير عمل منشور وجاهز للجلسات. استخدم `draft`
            فقط عندما تريد الحفظ دون نشر.
        features:
          type: array
          minItems: 1
          description: >-
            ميزات التحقق حسب ترتيب التنفيذ. تربط واجهة API كل عنصر بالعنصر
            التالي وتضيف عقدة حالة نهائية واحدة تلقائياً.
          items:
            $ref: '#/components/schemas/SimpleWorkflowFeature'
        is_white_label_enabled:
          type: boolean
          description: >-
            تمكين تخصيص العلامة البيضاء للجلسات التي تم إنشاؤها باستخدام سير
            العمل هذا.
          default: false
        is_desktop_allowed:
          type: boolean
          description: السماح بتشغيل مسار التحقق على متصفحات أجهزة سطح المكتب.
          default: false
        max_retry_attempts:
          type: integer
          minimum: 0
          maximum: 10
          default: 3
          description: >-
            الحد الأقصى لمحاولات إعادة المحاولة المسموح بها بعد عملية تحقق
            مرفوضة. القيمة `0` تحظر المستخدم بعد الرفض الأول.
        retry_window_days:
          type: integer
          minimum: 1
          maximum: 365
          nullable: true
          default: 7
          description: >-
            النافذة الزمنية المتجددة بالأيام المستخدمة لحساب عمليات إعادة
            المحاولة. تفرض القيمة `null` حداً طوال الوقت.
        face_liveness_max_attempts:
          type: integer
          minimum: 1
          maximum: 3
          default: 3
          description: >-
            الحد الأقصى لعمليات إرسال كشف الحيوية لكل جلسة. القيمة الافتراضية 3:
            محاولة أولية واحدة بالإضافة إلى محاولتي إعادة. يتم أيضاً نسخ هذه
            القيمة في عُقد سير عمل كشف الحيوية وتقدير العمر المنشأة ما لم
            يستبدلها إعداد على مستوى الميزة.
        face_match_max_attempts:
          type: integer
          minimum: 1
          maximum: 3
          default: 3
          description: >-
            الحد الأقصى لعمليات إرسال مطابقة الوجه لكل جلسة. القيمة الافتراضية
            3: محاولة أولية واحدة بالإضافة إلى محاولتي إعادة. يتم أيضاً نسخ هذه
            القيمة في عُقد سير عمل مطابقة الوجه المنشأة ما لم يستبدلها إعداد على
            مستوى الميزة.
        session_expiration_time:
          type: integer
          minimum: 3600
          maximum: 2419200
          default: 604800
          description: >-
            عدد الثواني قبل انتهاء صلاحية الجلسة غير المكتملة. الحد الأدنى ساعة
            واحدة (3600)، والحد الأقصى 4 أسابيع (2419200).
    WorkflowDetail:
      type: object
      description: >-
        الحقول أدناه ذات أنواع محددة (typed)؛ ويحمل الكائن أيضاً كل عمود آخر من
        تكوين سير العمل (مفاتيح تبديل الميزات، والحدود، وإجراءات التحذير،
        والمستندات المسموح بها، وعمليات الاستدعاء) كخصائص إضافية. الحقول التي لا
        تنطبق على `workflow_type` تكون `null`.
      properties:
        uuid:
          type: string
          format: uuid
          description: >-
            معرّف لكل إصدار (`settings_uuid`). لكل إصدار من سير العمل معرّف خاص
            به.
        workflow_id:
          type: string
          format: uuid
          description: >-
            معرّف ثابت تشترك فيه جميع إصدارات سير العمل. تستخدم الجلسات التي يتم
            إنشاؤها باستخدامه أحدث إصدار منشور.
        workflow_label:
          type: string
          description: اسم العرض لسير العمل.
        workflow_type:
          type: string
          nullable: true
          enum:
            - kyc
            - kyb
            - adaptive_age_verification
            - biometric_authentication
            - address_verification
            - questionnaire_verification
            - email_verification
            - phone_verification
            - null
          description: >-
            قالب سير العمل. يكون `null` لمخططات سير العمل التي تم إنشاؤها بدون
            قالب.
        is_default:
          type: boolean
          description: ما إذا كان هذا هو سير العمل الافتراضي للتطبيق.
        is_archived:
          type: boolean
          description: لا يمكن لمهام سير العمل المؤرشفة بدء جلسات جديدة.
        version:
          type: integer
          description: رقم الإصدار ضمن سير العمل.
        status:
          type: string
          enum:
            - draft
            - published
          description: >-
            إصدارات المسودة قابلة للتعديل؛ أما الإصدارات المنشورة فغير قابلة
            للتغيير وتُستخدم للجلسات الجديدة.
        published_at:
          type: string
          format: date-time
          nullable: true
          description: وقت نشر هذا الإصدار. القيمة `null` للمسودات.
        is_simple_workflow:
          type: boolean
          description: تكون `true` عندما لا يحتوي سير العمل على `workflow_graph` مخصص.
        is_editable:
          type: boolean
          description: تكون القيمة `true` فقط لإصدارات `draft`.
        workflow_url:
          type: string
          format: uri
          description: رابط URL عام يبدأ جلسة باستخدام سير العمل هذا.
        workflow_graph:
          type: object
          nullable: true
          additionalProperties: true
          description: هيكل المخطط لسير العمل (العقد والحواف). `null` لسير العمل البسيط.
        features:
          type: string
          description: >-
            الميزات المُمكّنة مفصولة بـ `" + "`، على سبيل المثال `"OCR +
            LIVENESS"`.
        total_price:
          type: number
          nullable: true
          description: >-
            السعر لكل جلسة؛ بالنسبة لمسارات سير العمل القائمة على المخطط، يمثل
            المسار الأكثر تكلفة.
        min_price:
          type: number
          nullable: true
          description: سعر المسار الأقل تكلفة عبر سير العمل.
        max_price:
          type: number
          nullable: true
          description: سعر المسار الأكثر تكلفة عبر سير العمل.
        special_add_on_prices:
          type: object
          nullable: true
          additionalProperties: true
          description: أسعار الإضافات الخاصة بالمؤسسة، أو `null` عند عدم تعيين أي منها.
        max_retry_attempts:
          type: integer
          description: عمليات إعادة المحاولة المسموح بها بعد عملية تحقق مرفوضة.
        retry_window_days:
          type: integer
          nullable: true
          description: الأيام التي يُسمح خلالها بإعادة المحاولة.
        session_expiration_time:
          type: integer
          description: عدد الثواني قبل انتهاء صلاحية الجلسة غير المكتملة.
        questionnaire:
          type: object
          nullable: true
          additionalProperties: true
          description: الاستبيان المرفق بسير العمل، أو `null`.
        kyb_role_settings:
          type: array
          items:
            type: object
            additionalProperties: true
          description: إعدادات التحقق لكل دور للأشخاص الرئيسيين في KYB.
        created_at:
          type: string
          format: date-time
        updated_at:
          type: string
          format: date-time
        signature_availability:
          type: object
          description: >-
            أي مستويات التوقيع الإلكتروني يمكنها التوقيع الآن. تحقق منها قبل
            تعيين `signature_level`. يتم إرجاعها في مسارات عمل `kyc` و`kyb`
            والمخطط.
          properties:
            simple:
              type: boolean
              description: Simple متاح دائماً.
            aes:
              type: boolean
              description: >-
                ما إذا كان المتقدم (AES) قادراً على التوقيع الآن. بينما تكون
                قيمته `false`، يُرفض حفظ خطوة جديدة عند `signature_level: "aes"`
                مع الخطأ `aes_not_available`.
            qes:
              type: boolean
              description: >-
                ما إذا كان المؤهل (QES) قادراً على التوقيع الآن. تظل قيمته
                `false` حتى يتم ربط مزوّد مؤهل.
        is_bank_verification_enabled:
          type: boolean
          description: >-
            ما إذا كان سير عمل KYC أو KYB البسيط يشغّل التحقق المصرفي. يعمل بعد
            خطوات التواصل (والتحقق من الموقع) وقبل التحقق من قواعد البيانات وفحص
            AML وتحليل IP. التحقق المصرفي غير متاح بشكل عام بعد: يتم رفض تفعيله
            أينما لم يكن مُمكّناً.
        bank_verification_config:
          type: object
          additionalProperties: true
          description: >-
            إعدادات التحقق البنكي لسير عمل بسيط، مع نفس المفاتيح التي تقبلها
            عقدة `BANK_VERIFICATION` (على سبيل المثال `bank_countries`
            و`bank_method_order`). يتم تجاهل المفاتيح غير المعروفة. كل مفتاح
            اختياري والمفتاح الغائب يحتفظ بقيمته الافتراضية، لذا يعني `{}` تطبيق
            جميع القيم الافتراضية. راجع [إعدادات التحقق
            البنكي](/ar/management-api/workflows/feature-configs#التحقق-من-الحساب-البنكي).
          example: {}
        is_geolocation_enabled:
          type: boolean
          description: >-
            ما إذا كان سير عمل KYC البسيط يشغّل التحقق من الموقع. يعمل بعد خطوات
            التواصل وقبل التحقق المصرفي والتحقق من قواعد البيانات. لا يمكن لسير
            عمل الشركات (KYB) تشغيله.
        geolocation_config:
          type: object
          additionalProperties: true
          description: >-
            إعدادات التحقق من الموقع لسير عمل بسيط، مع نفس المفاتيح التي تأخذها
            عقدة `GEOLOCATION` (على سبيل المثال
            `is_geolocation_geofencing_enabled` و `geolocation_max_attempts`).
            يتم تجاهل المفاتيح غير المعروفة. كل مفتاح اختياري ويحتفظ المفتاح
            الغائب بقيمته الافتراضية، لذا فإن `{}` تعني جميع القيم الافتراضية.
          example: {}
      additionalProperties: true
    SimpleWorkflowFeature:
      type: object
      required:
        - feature
      properties:
        feature:
          type: string
          description: >-
            الميزة المراد تشغيلها. استخدم القيم المكتوبة بالأحرف الكبيرة الموضحة
            هنا.
          enum:
            - OCR
            - NFC
            - LIVENESS
            - FACE_MATCH
            - PROOF_OF_ADDRESS
            - QUESTIONNAIRE
            - DOCUMENT_AI
            - PHONE_VERIFICATION
            - EMAIL_VERIFICATION
            - DATABASE_VALIDATION
            - AML
            - IP_ANALYSIS
            - AGE_ESTIMATION
            - KYB_REGISTRY
            - KYB_DOCUMENTS
            - KYB_KEY_PEOPLE
            - SIGNATURE
        config:
          type: object
          description: >-
            إعدادات خاصة بالميزة. بالنسبة لـ `QUESTIONNAIRE`، قم بتضمين
            `questionnaire_uuid` مع `questionnaire_id` الذي يرجعه endpoint إنشاء
            الاستبيان. بالنسبة لـ `SIGNATURE`، يحتاج سير العمل الذي يدخل حيز
            الإنتاج إلى مستند للتوقيع: اضبط `signature_documents_source` على
            `session` أو `both` حتى تتمكن كل جلسة من تقديم مستنداتها الخاصة، أو
            أرسل `status: "draft"` وأضف المستندات قبل النشر. يُرفض
            `signature_level: "aes"` مع `aes_not_available` طالما أن
            `signature_availability.aes` هي `false` في سير العمل. بالنسبة لـ
            `OCR`، يحدد `methods` طرق التحقق من الهوية التي يجوز لكل دولة
            استخدامها (التقاط المستندات، والبحث بدون مستندات في مصدر حكومي أو
            مصدر موثوق آخر، ومحافظ الهوية الرقمية)؛ احذفه وستكون جميع الدول
            مقتصرة على التقاط المستندات فقط. بالنسبة لـ `SIGNATURE`، راجع
            [إعدادات التوقيع
            الإلكتروني](/ar/management-api/workflows/feature-configs#التوقيع-الإلكتروني):
            يقبل `signature_level` القيمة `simple` (الافتراضية، لا يلزم التحقق
            من الهوية أو البريد الإلكتروني أو الهاتف) و`aes` حاليًا، وتتم إدارة
            مستندات سير العمل وحقولها في لوحة التحكم، لذا أرسل المستندات والحقول
            لكل جلسة عبر API مع `signature_documents_source: "session"`.
          additionalProperties: true
        label:
          type: string
          description: تسمية داخلية اختيارية لعقدة سير العمل هذه.
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        مفتاح API الخاص بتطبيقك، من Developers -> API keys في Business Console.
        يمتلك المفتاح الأساسي وصولاً كاملاً. يمكن تحديد نطاق المفتاح المسمى: لا
        شيء، أو قراءة، أو كتابة لكل مورد، ومحدوداً ببعض مسارات العمل أو بالجلسات
        المقبولة، وبقائمة من عناوين IP، وبتاريخ انتهاء الصلاحية. يشير 401 إلى أن
        المفتاح غير صحيح أو ملغى أو منتهي الصلاحية؛ ويشير 403 إلى أنه لم يتم
        إرسال أي مفتاح، أو أن المفتاح ليس لديه حق الوصول إلى هذا المورد أو
        الإجراء، أو أن الطلب جاء من عنوان خارج قائمة عناوين IP الخاصة به؛ ويشير
        404 في مسار جلسة إلى أن الجلسة خارج مسارات العمل أو الحالات الخاصة
        بالمفتاح. يتلقى المفتاح الذي لا يمتلك حق الوصول إلى الوسائط عناوين URL
        للصور ومقاطع الفيديو وملفات PDF كـ null، ويتلقى المفتاح الذي لا يمتلك
        إذن كتابة للجلسات روابط الجلسة وtoken كـ null. راجع
        https://docs.didit.me/console/api-keys.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.