v1

latestOpenAPI 3.0.3MIT2026-07-1792846.7 KB
CWE

The ancestors of a specified weakness, sampling by the view

get/cwe/{id}/ancestors

Path parameters

idstring required

CWE ID

Query parameters

viewstring

The View_ID field specifies which view to follow in the Has_Member entries and ChildOf relationships to determine the appropriate ancestors. If there are no ancestors, the response will be empty. If no view is provided, the ancestors in all views will be returned

primaryboolean

Limit ancestors to include only primary parents

Response

success

Example response

{
  "Data": {
    "Type": "class_weakness",
    "ID": "74",
    "ViewID": "1000"
  },
  "Parents": [
    {
      "Data": {
        "Type": "pillar_weakness",
        "ID": "707",
        "ViewID": "1000"
      },
      "Parents": [
        {
          "Data": {
            "Type": "view",
            "ID": "1000",
            "ViewID": "1000"
          },
          "Parents": null
        }
      ]
    }
  ]
}