وثائق بوابة القرار

تقييم بوابة حتمي وقابل لإعادة التشغيل مع قرارات قابلة للتدقيق.

وثائق Asset Core

providercontractget

احصل على JSON عقد المزود القياسي وهاش لمزود.

ملاحظات رئيسية

  • يعيد عقد المزود كما تم تحميله بواسطة خادم MCP.
  • يتضمن تجزئة معيارية للتدقيق وإعادة الإنتاج.
  • خاضع لسياسة إفصاح المزود والتفويض.

مدخلات

  • provider_id (required): معرف المزود.

مخطط الإدخال

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "properties": {
    "provider_id": {
      "description": "Provider identifier.",
      "type": "string"
    }
  },
  "required": [
    "provider_id"
  ],
  "type": "object"
}

المخرجات

  • عقد (مطلوب): النوع: كائن.
  • contract_hash (مطلوب): النوع: object.
  • provider_id (required): معرف المزود.
  • المصدر (مطلوب): مصدر أصل العقد.
  • version (مطلوب): تسمية إصدار العقد الاختيارية.

مخطط الإخراج

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "additionalProperties": false,
  "properties": {
    "contract": {
      "additionalProperties": false,
      "properties": {
        "checks": {
          "items": {
            "additionalProperties": false,
            "properties": {
              "allowed_comparators": {
                "description": "Comparator allow-list for this check.",
                "items": {
                  "description": "Comparator applied to evidence values.",
                  "enum": [
                    "equals",
                    "not_equals",
                    "greater_than",
                    "greater_than_or_equal",
                    "less_than",
                    "less_than_or_equal",
                    "lex_greater_than",
                    "lex_greater_than_or_equal",
                    "lex_less_than",
                    "lex_less_than_or_equal",
                    "contains",
                    "in_set",
                    "deep_equals",
                    "deep_not_equals",
                    "exists",
                    "not_exists"
                  ],
                  "type": "string"
                },
                "type": "array"
              },
              "anchor_types": {
                "description": "Anchor types emitted by this check.",
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "check_id": {
                "description": "Check identifier.",
                "type": "string"
              },
              "content_types": {
                "description": "Content types for check output.",
                "items": {
                  "type": "string"
                },
                "type": "array"
              },
              "description": {
                "description": "Check description.",
                "type": "string"
              },
              "determinism": {
                "description": "Determinism classification for provider checks.",
                "enum": [
                  "deterministic",
                  "time_dependent",
                  "external"
                ],
                "type": "string"
              },
              "examples": {
                "items": {
                  "additionalProperties": false,
                  "properties": {
                    "description": {
                      "description": "Short example description.",
                      "type": "string"
                    },
                    "params": {
                      "description": "Example params payload.",
                      "type": [
                        "null",
                        "boolean",
                        "number",
                        "string",
                        "array",
                        "object"
                      ]
                    },
                    "result": {
                      "description": "Example result value.",
                      "type": [
                        "null",
                        "boolean",
                        "number",
                        "string",
                        "array",
                        "object"
                      ]
                    }
                  },
                  "required": [
                    "description",
                    "params",
                    "result"
                  ],
                  "type": "object"
                },
                "type": "array"
              },
              "params_required": {
                "description": "Whether params are required for this check.",
                "type": "boolean"
              },
              "params_schema": {
                "description": "JSON schema for check params.",
                "type": [
                  "null",
                  "boolean",
                  "number",
                  "string",
                  "array",
                  "object"
                ]
              },
              "result_schema": {
                "description": "JSON schema for check result values.",
                "type": [
                  "null",
                  "boolean",
                  "number",
                  "string",
                  "array",
                  "object"
                ]
              }
            },
            "required": [
              "check_id",
              "description",
              "determinism",
              "params_required",
              "params_schema",
              "result_schema",
              "allowed_comparators",
              "anchor_types",
              "content_types",
              "examples"
            ],
            "type": "object"
          },
          "type": "array"
        },
        "config_schema": {
          "description": "Provider configuration schema.",
          "type": [
            "null",
            "boolean",
            "number",
            "string",
            "array",
            "object"
          ]
        },
        "description": {
          "description": "Provider description.",
          "type": "string"
        },
        "name": {
          "description": "Provider display name.",
          "type": "string"
        },
        "notes": {
          "description": "Provider notes and guidance.",
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "provider_id": {
          "description": "Provider identifier.",
          "type": "string"
        },
        "transport": {
          "description": "Provider transport kind.",
          "enum": [
            "builtin",
            "mcp"
          ],
          "type": "string"
        }
      },
      "required": [
        "provider_id",
        "name",
        "description",
        "transport",
        "config_schema",
        "checks",
        "notes"
      ],
      "type": "object"
    },
    "contract_hash": {
      "additionalProperties": false,
      "properties": {
        "algorithm": {
          "enum": [
            "sha256"
          ],
          "type": "string"
        },
        "value": {
          "description": "Lowercase hex digest.",
          "type": "string"
        }
      },
      "required": [
        "algorithm",
        "value"
      ],
      "type": "object"
    },
    "provider_id": {
      "description": "Provider identifier.",
      "type": "string"
    },
    "source": {
      "description": "Contract source origin.",
      "enum": [
        "builtin",
        "file"
      ],
      "type": "string"
    },
    "version": {
      "description": "Optional contract version label.",
      "oneOf": [
        {
          "type": "null"
        },
        {
          "type": "string"
        }
      ]
    }
  },
  "required": [
    "provider_id",
    "contract",
    "contract_hash",
    "source",
    "version"
  ],
  "type": "object"
}

أمثلة

احصل على JSON العقد لمزود الخدمة.

مدخل:

{
  "provider_id": "json"
}

Output:

{
  "contract": {
    "checks": [],
    "config_schema": {
      "additionalProperties": false,
      "type": "object"
    },
    "description": "Reads JSON or YAML files and evaluates JSONPath.",
    "name": "JSON Provider",
    "notes": [],
    "provider_id": "json",
    "transport": "builtin"
  },
  "contract_hash": {
    "algorithm": "sha256",
    "value": "5c3a5b6bce0f4a2c9e22c4fa6a1e6d8d90b0f2dfed1b7f1e9b3d3b3d1f0c9b21"
  },
  "provider_id": "json",
  "source": "builtin",
  "version": null
}