> ## 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.

# الحصول على المستخدم: كيان مستخدم البائع في Didit

> جلب مستخدم بائع واحد من Didit باستخدام vendor_data مع حقول الهوية والحالة وعدادات KYC وخريطة الميزات. هوية KYC دائمة، بالدفع لكل استدعاء.



طلب الحصول على المستخدم
        نسخ الموجّه إلى الحافظة



      
      

\<pre>

\`Goal: Fetch a single Didit User entity by your own vendor_data.

Endpoint: GET https://verification.didit.me/v3/users/{vendor_data}/
Auth header: x-api-key: <DIDIT_API_KEY>

Path param:
\- vendor_data (string, REQUIRED) — your unique identifier. Free-form string, NOT a UUID. Matching is case-insensitive after Didit normalisation. URL-encode it.

curl:
curl -X GET 'https://verification.didit.me/v3/users/user-abc-123/' \
-H 'x-api-key: YOUR_API_KEY'

Response 200 (UserDetailItem) — extends the list shape with metadata, comments (activity log), and updated_at. Key fields:
\- didit_internal_id (UUID — Didit's stable internal identifier)
\- vendor_data (string)
\- display_name, full_name, date_of_birth, effective_name, portrait_image_url
\- status: "ACTIVE" | "FLAGGED" | "BLOCKED" (VendorUserStatusChoices)
\- session_count, approved_count, declined_count, in_review_count (aggregate counters)
\- features (map of feature -> latest status)
\- approved_emails, approved_phones, issuing_states
\- metadata (arbitrary JSON you attached)
\- comments (chronological activity log: status changes, manual notes, system events)
\- created_at, updated_at
See /reference/data-models for the full schema.

Notes:
\- Aggregate counters update in real time as sessions reach terminal status.
\- For bulk lookups, prefer paging GET /v3/users/ and indexing locally on vendor_data instead of fanning out one call per identifier.

Failure modes (envelope {"detail": "..."}):
\- 401 — missing or invalid x-api-key.
\- 403 — the API key is revoked or is not valid for this application.
\- 404 — no user with that vendor_data in this application.
\- 429 — rate-limited.

For end-to-end Didit integration, paste in the full prompt at /integration/integration-prompt.`

\</pre>



      
      

الصق في

## نظرة عامةتُرجع كيان [المستخدم](https://docs.didit.me/ar/entities/users/overview.md) واحدًا مُعرَّفًا بواسطة `vendor_data`. تتضمن الاستجابات `didit_internal_id`، وهو معرّف Didit الداخلي الثابت.## متى تستخدمه- **البحث** عن حالة التحقق الحالية للمستخدم. يمنحك الكائن `features` أحدث حالة لكل ميزة في كائن واحد.
- **عروض التفاصيل** في واجهة المستخدم الخاصة بك. اجلب الملف الشخصي عند الطلب قبل عرضه.
- **احتساب درجات المخاطر**. ادمج عدادات الجلسات والكائن `features` لتقييم كل مستخدم من جهتك.## ملاحظات- قيمة `vendor_data` في عنوان URL حساسة لحالة الأحرف.
- تُرجع الاستجابة `404` إذا لم يوجد مستخدم بقيمة `vendor_data` هذه في التطبيق.
- تُحدَّث العدادات المجمّعة (`session_count` و`approved_count` و`declined_count` و`in_review_count`) في الوقت الفعلي عند اكتمال الجلسات.
- راجع [نموذج بيانات المستخدم](https://docs.didit.me/ar/entities/users/data-model.md) للاطلاع على كل حقل.## الأذوناتيمكن لأي مفتاح API نشط للتطبيق استدعاء endpoint هذا. مفاتيح API في Didit **مرتبطة بالتطبيق، لا بالأدوار**. أما [الأدوار والأذونات](https://docs.didit.me/ar/console/roles-permissions.md) في Console، مثل `read:users` وغيرها، فتحدد ما يمكن *للشخص* فعله في Console، ولا تُطبَّق على حركة Management API. للتحكم في من يستطيع استدعاء endpoint هذا، تحكّم في من يستطيع قراءة مفتاح API الخاص بالتطبيق.## ذات صلة- [نظرة عامة على المستخدمين](https://docs.didit.me/ar/entities/users/overview.md)
- [نموذج البيانات](https://docs.didit.me/ar/entities/users/data-model.md)
- [عرض قائمة المستخدمين](https://docs.didit.me/ar/management-api/users/list.md)


## OpenAPI

````yaml ar/openapi-25.json GET /v3/users/{vendor_data}/
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/users/{vendor_data}/:
    get:
      tags:
        - Users
      summary: الحصول على المستخدم
      description: >-
        جلب [مستخدم](/entities/users) واحد حسب `vendor_data` (تطابق تام). يضيف
        `metadata` و`comments` و`updated_at` إلى عرض القائمة، ويحوّل `tags` إلى
        شكل ارتباط العلامات التفصيلي.
      operationId: get_user
      parameters:
        - name: vendor_data
          in: path
          required: true
          schema:
            type: string
          description: >-
            معرّفك الفريد للمستخدم — سلسلة نصية حرة (وليس UUID). هذه هي نفس
            القيمة التي مررتها كـ `vendor_data` عند إنشاء الجلسة التي عرّفت هذا
            المستخدم للمرة الأولى، وتتم مطابقتها تماماً كما أُرسلت.
          example: user-abc-123
      responses:
        '200':
          description: >-
            تفاصيل المستخدم الكاملة بما في ذلك البيانات الوصفية، والتعليقات/سجل
            النشاط، وبيانات الجلسة المجمعة.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserDetailItem'
              examples:
                Active user:
                  value:
                    didit_internal_id: f4e5e1f2-94a9-4f86-8c16-2b7d9b4db418
                    vendor_data: user-abc-123
                    display_name: null
                    full_name: John Michael Doe
                    date_of_birth: '1990-05-15'
                    effective_name: John Michael Doe
                    status: ACTIVE
                    metadata:
                      tier: premium
                      source: website
                    portrait_image_url: https://<media-host>/...
                    session_count: 3
                    approved_count: 2
                    declined_count: 0
                    in_review_count: 1
                    issuing_states:
                      - USA
                    approved_emails:
                      - john@example.com
                    approved_phones:
                      - '+14155551234'
                    features:
                      ID_VERIFICATION: Approved
                      LIVENESS: Approved
                      FACE_MATCH: Approved
                      AML: Approved
                    features_list:
                      - feature: ID_VERIFICATION
                        status: Approved
                      - feature: LIVENESS
                        status: Approved
                      - feature: FACE_MATCH
                        status: Approved
                      - feature: AML
                        status: Approved
                    last_session_at: '2025-06-15T10:30:00Z'
                    last_activity_at: '2025-06-15T10:30:00Z'
                    first_session_at: '2025-06-01T08:00:00Z'
                    tags:
                      - uuid: 9a8b7c6d-5e4f-4a3b-8c2d-1e0f9a8b7c6d
                        tag:
                          uuid: e1f2a3b4-c5d6-4e7f-8a9b-0c1d2e3f4a5b
                          name: VIP
                          color: '#2567FF'
                          description: null
                          source: custom
                          created_at: '2025-05-01T09:00:00Z'
                          updated_at: '2025-05-01T09:00:00Z'
                        added_by_email: analyst@acme.com
                        added_by_name: Jane Analyst
                        created_at: '2025-06-02T11:00:00Z'
                    comments:
                      - uuid: c1111111-2222-4333-8444-555555555555
                        comment_type: STATUS_CHANGED
                        comment: null
                        actor_email: analyst@acme.com
                        actor_name: Jane Analyst
                        previous_status: FLAGGED
                        new_status: ACTIVE
                        previous_value: null
                        new_value: null
                        changed_fields: []
                        metadata: null
                        mentioned_emails: []
                        created_at: '2025-06-01T10:30:00Z'
                    created_at: '2025-06-01T08:00:00Z'
                    updated_at: '2025-06-15T10:30:00Z'
        '401':
          description: >-
            لم يتم توفير بيانات اعتماد. الطلبات المرسلة إلى مسارات `/v3/users/*`
            بدون رأس `x-api-key` (أو رمز `Authorization: Bearer`) يتم رفضها
            بواسطة برمجية المصادقة الوسيطة قبل وصولها إلى الـ API.
          content:
            application/json:
              examples:
                Missing credentials:
                  value:
                    detail: >-
                      You must be authenticated with a valid access token to
                      access this endpoint.
        '403':
          description: >-
            مفتاح API غير صالح أو تم إلغاؤه، أو أن المفتاح لا يملك صلاحية قراءة
            مستخدمي هذا التطبيق. يُرجع المفتاح المفقود `403`؛ بينما يُرجع
            المفتاح الخاطئ أو المُلغى أو المنتهي الصلاحية `401`.
          content:
            application/json:
              examples:
                Forbidden:
                  value:
                    detail: You do not have permission to perform this action.
        '404':
          description: لا يوجد مستخدم بقيمة `vendor_data` المقدمة لهذا التطبيق.
          content:
            application/json:
              examples:
                Not found:
                  value:
                    detail: Not found.
        '429':
          description: >-
            تم تجاوز حد المعدل؛ تراجع مؤقتاً وأعد المحاولة بعد الفاصل الزمني
            الموضح في `Retry-After`.
          content:
            application/json:
              examples:
                Rate limited:
                  value:
                    detail: Request was throttled. Expected available in 30 seconds.
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: curl
          source: |-
            curl -X GET 'https://verification.didit.me/v3/users/user-abc-123/' \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.users.retrieve(
                "user-abc-123",
            )
            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.users.retrieve("user-abc-123");
            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Users.Retrieve(ctx, \"user-abc-123\")\nif err != nil {\n\tlog.Fatal(err)\n}\nfmt.Printf(\"%+v\\n\", result)"
        - lang: java
          label: Java
          source: |-
            import me.didit.Didit;

            // Reads DIDIT_API_KEY.
            Didit client = new Didit();

            var result = client.users().retrieve("user-abc-123");
            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->users->retrieve('user-abc-123');
            print_r($result->toArray());
        - lang: ruby
          label: Ruby
          source: |-
            require "didit"

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

            result = didit.users.retrieve("user-abc-123")
            puts result.to_h
        - lang: csharp
          label: .NET
          source: |-
            using System;
            using System.Text.Json;
            using Didit;

            // Reads DIDIT_API_KEY.
            using var client = new DiditClient();

            var result = await client.Users.RetrieveAsync("user-abc-123");
            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    UserDetailItem:
      type: object
      description: >-
        تفاصيل المستخدم الكاملة. يوسع UserListItem بالبيانات الوصفية،
        والتعليقات، وحقل updated_at.
      allOf:
        - $ref: '#/components/schemas/UserListItem'
        - type: object
          properties:
            metadata:
              type: object
              description: >-
                بيانات وصفية مخصصة بتنسيق JSON أرفقتها بهذا المستخدم. القيمة
                الافتراضية هي `{}`.
            tags:
              type: array
              description: >-
                تعيينات العلامات. ملاحظة: في استجابات التفاصيل يكون كل إدخال
                كائن *ربط* علامة (`{uuid, tag: {...}, added_by_email,
                added_by_name, created_at}`)، على عكس التنسيق المسطح `{uuid,
                name, color}` المُستخدم في استجابات القوائم.
              items:
                type: object
                properties:
                  uuid:
                    type: string
                    format: uuid
                    description: معرّف UUID لتعيين الوسم (وليس الوسم نفسه).
                  tag:
                    type: object
                    properties:
                      uuid:
                        type: string
                        format: uuid
                      name:
                        type: string
                      color:
                        type: string
                      description:
                        type: string
                        nullable: true
                      source:
                        type: string
                        enum:
                          - didit
                          - custom
                      created_at:
                        type: string
                        format: date-time
                      updated_at:
                        type: string
                        format: date-time
                  added_by_email:
                    type: string
                    nullable: true
                  added_by_name:
                    type: string
                    nullable: true
                  created_at:
                    type: string
                    format: date-time
            comments:
              type: array
              items:
                type: object
                properties:
                  uuid:
                    type: string
                    format: uuid
                  comment_type:
                    type: string
                    enum:
                      - COMMENT
                      - STATUS_CHANGED
                      - METADATA_UPDATED
                      - TAG_ADDED
                      - TAG_REMOVED
                      - PROFILE_UPDATED
                  comment:
                    type: string
                    nullable: true
                  actor_email:
                    type: string
                    nullable: true
                  actor_name:
                    type: string
                    nullable: true
                  previous_status:
                    type: string
                    nullable: true
                    enum:
                      - ACTIVE
                      - FLAGGED
                      - BLOCKED
                      - null
                  new_status:
                    type: string
                    nullable: true
                    enum:
                      - ACTIVE
                      - FLAGGED
                      - BLOCKED
                      - null
                  previous_value:
                    type: object
                    nullable: true
                    description: قيم الحقول السابقة لإدخالات PROFILE_UPDATED.
                  new_value:
                    type: object
                    nullable: true
                    description: قيم الحقول الجديدة لمدخلات PROFILE_UPDATED.
                  changed_fields:
                    type: array
                    items:
                      type: string
                    description: أسماء الحقول التي تم تغييرها بواسطة إدخال PROFILE_UPDATED.
                  metadata:
                    type: object
                    nullable: true
                  mentioned_emails:
                    type: array
                    items:
                      type: string
                  created_at:
                    type: string
                    format: date-time
              description: >-
                سجل الأنشطة والتعليقات الخاصة بهذا المستخدم (تغييرات الحالة،
                تعديلات الملف التعريفي، الملاحظات اليدوية).
            updated_at:
              type: string
              format: date-time
    UserListItem:
      type: object
      description: مستخدم تم التحقق منه.
      properties:
        didit_internal_id:
          type: string
          format: uuid
          description: معرّف UUID الداخلي الثابت من Didit لهذا المستخدم.
        vendor_data:
          type: string
          nullable: true
          description: >-
            معرّفك الفريد لهذا المستخدم (يتم تمريره عند إنشاء الجلسات). يمكن أن
            يكون هذا null في حال عدم تقديم معرّف بائع.
        display_name:
          type: string
          nullable: true
          description: اسم عرض مخصص تم تعيينه بواسطتك
        full_name:
          type: string
          nullable: true
          description: الاسم الكامل المستخرج من المستندات التي تم التحقق منها
        date_of_birth:
          type: string
          format: date
          nullable: true
        effective_name:
          type: string
          nullable: true
          description: 'أفضل اسم متاح: display_name إذا كان محدداً، وإلا فـ full_name'
        status:
          type: string
          enum:
            - ACTIVE
            - FLAGGED
            - BLOCKED
          description: >-
            حالة دورة حياة سجل المستخدم (ليست حالة جلسة). القيمة الافتراضية هي
            `ACTIVE`، و`FLAGGED` تميز المستخدم للمراجعة اليدوية، و`BLOCKED` تمنع
            إنشاء جلسات جديدة لقيمة `vendor_data` هذه.
        portrait_image_url:
          type: string
          nullable: true
          description: >-
            رابط موقع مسبقاً للصورة الشخصية للمستخدم (تنتهي صلاحيته بعد بضع
            ساعات)
        session_count:
          type: integer
          description: العدد الإجمالي لجلسات التحقق لهذا المستخدم
        approved_count:
          type: integer
          description: عدد الجلسات المقبولة
        declined_count:
          type: integer
          description: عدد الجلسات المرفوضة
        in_review_count:
          type: integer
          description: عدد الجلسات قيد المراجعة
        issuing_states:
          type: array
          items:
            type: string
          description: >-
            رموز ISO 3166-1 alpha-3 لدول الإصدار الواردة في مستندات الهوية
            المقبولة لهذا المستخدم، مثل `["USA", "ESP"]`. مصفوفة فارغة في حال
            عدم وجود أي منها.
        approved_emails:
          type: array
          items:
            type: string
          description: >-
            عناوين البريد الإلكتروني التي تم التحقق منها والمجمعة من الجلسات
            المقبولة لهذا المستخدم، على سبيل المثال `["john@example.com"]`.
        approved_phones:
          type: array
          items:
            type: string
          description: >-
            أرقام الهواتف التي تم التحقق منها والمجمعة من الجلسات المقبولة لهذا
            المستخدم، على سبيل المثال `["+14155551234"]`.
        features:
          type: object
          description: >-
            الحالة المجمعة لكل ميزة عبر جميع جلسات هذا المستخدم. المفاتيح
            المحتملة: `ID_VERIFICATION`، `NFC`، `LIVENESS`، `FACE_MATCH`، `POA`،
            `QUESTIONNAIRE`، `EMAIL_VERIFICATION`، `PHONE`، `AML`،
            `IP_ANALYSIS`، `AGE_ESTIMATION`، `DATABASE_VALIDATION`. القيم
            المحتملة: `Approved`، `Declined`، `In Review`، `Not Finished`،
            `Resub Requested`.
        features_list:
          type: array
          items:
            type: object
            properties:
              feature:
                type: string
              status:
                type: string
          description: >-
            البيانات نفسها مثل `features`، كمصفوفة مرتبة من كائنات `{feature,
            status}`.
        last_session_at:
          type: string
          format: date-time
          nullable: true
          description: الطابع الزمني لأحدث جلسة
        first_session_at:
          type: string
          format: date-time
          nullable: true
          description: الطابع الزمني للجلسة الأولى
        last_activity_at:
          type: string
          format: date-time
          nullable: true
          description: >-
            الطابع الزمني لأحدث نشاط لهذا المستخدم (جلسة، معاملة، تغيير حالة،
            تعديل بيانات، إلخ).
        tags:
          type: array
          items:
            type: object
            properties:
              uuid:
                type: string
                format: uuid
              name:
                type: string
              color:
                type: string
          description: العلامات المعيّنة لهذا المستخدم
        created_at:
          type: string
          format: date-time
  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.