> ## 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 工作流的完整配置，包括功能开关、阈值和可接受的证件。按次计费。



获取工作流 API 提示词
        将提示词复制到剪贴板



      
      

\<pre>

\`Fetch the full configuration of a single Didit workflow through the Management API.

Endpoint:
GET https://verification.didit.me/v3/workflows/{settings_uuid}/

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

Goal:
\- Retrieve every editable field on the workflow (feature toggles, score thresholds, documents_allowed per country, KYB role config, retry policy, callback config, etc.).
\- Useful for back-office "view workflow" screens, debugging why a verification declined/routed to review, or verifying a freshly published version.

Path parameter:
\- settings_uuid — the per-version workflow UUID returned by GET /v3/workflows/ or POST /v3/workflows/. Each workflow version has its own settings_uuid; workflow_id is the stable group id shared by every version.

Example call:
curl -X GET "https://verification.didit.me/v3/workflows/{settings_uuid}/" \
-H "x-api-key: YOUR_API_KEY"

What to read from the response:
\- workflow_id — stable group id; compare across versions to walk version history.
\- features and the underlying workflow_graph — describes which checks run and in what order.
\- Threshold and action fields per feature — see /management-api/workflows/feature-configs for the full reference.

Failure modes:
\- 401 — missing or malformed x-api-key.
\- 403 — canonical { "detail": "You do not have permission to perform this action." } envelope when the workflow belongs to a different application than the API key.
\- 404 — workflow not found in this application (also returned when settings_uuid is valid in another application).

Side effects: none. This is a pure read.

For the full integration shape, see /integration/integration-prompt.`

\</pre>



      
      

粘贴到



## OpenAPI

````yaml zh/openapi-25.json GET /v3/workflows/{settings_uuid}/
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/{settings_uuid}/:
    get:
      tags:
        - Workflows
      summary: 获取工作流
      description: 通过 `settings_uuid` 获取某个工作流版本的完整配置：功能开关、阈值、允许的证件、图谱、重试策略、回调和定价。
      operationId: get_workflow
      parameters:
        - name: settings_uuid
          in: path
          required: true
          schema:
            type: string
            format: uuid
          description: >-
            工作流每个版本对应的 UUID（列表 endpoint 返回的 `uuid` 值）。工作流的每个版本都有其自己的
            `settings_uuid`。
      responses:
        '200':
          description: >-
            完整的工作流配置。其结构为原始的 `VerificationSettings` 序列化结果（约 190
            个字段：涵盖每个功能开关、阈值、警告操作、允许证件配置、`workflow_graph`、重试策略、回调以及定价）。以下示例已简化。注意事项：`features`
            为用 `" + "` 连接的字符串（例如 `"OCR + LIVENESS"`），价格为 JSON 数字，且仅对于 `draft` 版本
            `is_editable` 为 `true`。
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkflowDetail'
              examples:
                KYC workflow with face match (abbreviated):
                  value:
                    uuid: a1b2c3d4-5678-90ab-cdef-111111111111
                    workflow_id: a1b2c3d4-5678-90ab-cdef-111111111111
                    workflow_label: Standard KYC
                    workflow_type: kyc
                    is_default: true
                    is_archived: false
                    is_liveness_enabled: true
                    face_liveness_method: passive
                    face_liveness_score_decline_threshold: 50
                    face_liveness_score_review_threshold: 70
                    is_face_match_enabled: true
                    face_match_score_decline_threshold: 40
                    face_match_score_review_threshold: 60
                    is_aml_enabled: false
                    is_phone_verification_enabled: false
                    is_email_verification_enabled: false
                    is_database_validation_enabled: false
                    is_ip_analysis_enabled: false
                    is_nfc_enabled: false
                    duplicated_user_action: no_action
                    documents_allowed:
                      ESP:
                        P:
                          sides: 1
                          enabled: 1
                          subtypes:
                            - EPASSPORT
                            - PASSPORT_GENERIC
                          preferred_characters: latin
                          expiration_check_mode: strict
                    max_retry_attempts: 3
                    retry_window_days: 7
                    session_expiration_time: 604800
                    version: 2
                    status: published
                    published_at: '2026-04-12T10:30:00Z'
                    is_simple_workflow: false
                    is_editable: false
                    workflow_url: https://verify.didit.me/u/_yljPOx8RWG3UAz5ZRQGVQ
                    total_price: 0.15
                    min_price: 0.15
                    max_price: 0.15
                    features: OCR + LIVENESS + FACE_MATCH
                    created_at: '2025-01-15T10:30:00Z'
                    updated_at: '2026-04-12T10:30:00Z'
        '403':
          description: API 密钥缺失、格式错误、已过期或作用域属于其他应用。
          content:
            application/json:
              examples:
                Invalid token:
                  value:
                    detail: You do not have permission to perform this action.
        '404':
          description: >-
            已验证身份的应用中不存在具有此 `settings_uuid` 的工作流。可能是 UUID 错误，或者它属于另一个应用；Didit
            刻意不对这两种情况进行区分，以避免泄露跨应用记录的存在。
          content:
            application/json:
              examples:
                Not found:
                  value:
                    detail: Not found.
        '429':
          description: 超出速率限制。请使用指数退避重试。
        '500':
          description: 意外服务器错误。可安全重试。
      security:
        - ApiKeyAuth: []
      x-codeSamples:
        - lang: curl
          label: cURL
          source: >-
            curl -X GET
            'https://verification.didit.me/v3/workflows/a1b2c3d4-5678-90ab-cdef-111111111111/'
            \
              -H 'x-api-key: YOUR_API_KEY'
        - lang: python
          label: Python
          source: |-
            from didit import Didit

            # Reads DIDIT_API_KEY.
            client = Didit()

            result = client.workflows.retrieve(
                "11111111-2222-3333-4444-555555555555",
            )
            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.retrieve("11111111-2222-3333-4444-555555555555");

            console.log(result);
        - lang: go
          label: Go
          source: "ctx := context.Background()\n// Reads DIDIT_API_KEY.\nclient := didit.NewClient()\n\nresult, err := client.Workflows.Retrieve(ctx, \"11111111-2222-3333-4444-555555555555\")\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.workflows().retrieve("11111111-2222-3333-4444-555555555555");

            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->retrieve('11111111-2222-3333-4444-555555555555');

            print_r($result->toArray());
        - lang: ruby
          label: Ruby
          source: >-
            require "didit"


            # Reads DIDIT_API_KEY.

            didit = Didit::Client.new


            result =
            didit.workflows.retrieve("11111111-2222-3333-4444-555555555555")

            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.Workflows.RetrieveAsync("11111111-2222-3333-4444-555555555555");

            Console.WriteLine(JsonSerializer.Serialize(result));
components:
  schemas:
    WorkflowDetail:
      type: object
      description: >-
        以下字段均为类型化字段；该对象还包含工作流配置的每个其他列（功能开关、阈值、警告操作、允许的证件、回调）作为附加属性。不适用于该
        `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: 当工作流没有自定义 `workflow_graph` 时为 `true`。
        is_editable:
          type: boolean
          description: 仅对 `draft` 版本为 `true`。
        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`）。未知键将被丢弃。每个键均为可选，缺少的键保持其默认值，因此 `{}`
            表示全部使用默认值。参见[银行验证设置](/zh/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
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key
      description: >-
        您的应用 API 密钥，可在 Business Console 的“开发者 -> API
        密钥”中获取。主密钥拥有完整访问权限。指定名称的密钥可设置作用域：针对每个资源设为无权限、只读或读写，限定于特定工作流或已通过的会话、限定于
        IP 地址列表，以及设置到期日期。401 表示密钥错误、已撤销或已过期；403 表示未发送密钥、密钥无权访问该资源或操作，或请求来自其 IP
        列表之外的地址；在会话路由上返回 404 表示该会话不在该密钥允许的工作流或状态范围内。没有媒体访问权限的密钥获取到的图片、视频和 PDF
        URL 将为 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.