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

# Retrieve the scan status of an external group.

> Retrieve the scan status of an external group.

## OpenAPI

````json GET /sys/v1/groups/{group_id}/hmg/scans
{
  "openapi": "3.0.0",
  "info": {
    "title": "Fortanix DSM REST API",
    "description": "This is a set of REST APIs for accessing the Fortanix Data Security Manager. This includes APIs for managing accounts, and for performing cryptographic and key management operations. \n\n **Note:** \n- All binary input should be base64-encoded. These fields are marked with `format: byte`. \n- For forward compatibility, any API client is expected to ignore any fields in the response not explicitly mentioned in the documentation. We reserve the right to add new fields at any time to provide new functionality without affecting existing API clients.",
    "termsOfService": "https://www.fortanix.com/legal/terms/",
    "contact": {
      "name": "Fortanix Support",
      "url": "https://support.fortanix.com/",
      "email": "support@fortanix.com"
    },
    "license": {
      "name": "Apache 2.0",
      "url": "http://www.apache.org/licenses/LICENSE-2.0.html"
    },
    "version": "0.1.0-20260526"
  },
  "servers": [
    {
      "url": "https://amer.smartkey.io"
    }
  ],
  "paths": {
    "/sys/v1/groups/{group_id}/hmg/scans": {
      "get": {
        "operationId": "GetAllHmgScans",
        "tags": [
          "Groups"
        ],
        "security": [
          {
            "bearerToken": []
          },
          {
            "apiKeyAuth": []
          }
        ],
        "summary": "Retrieve the scan status of an external group.",
        "description": "Retrieve the scan status of an external group.",
        "parameters": [
          {
            "name": "group_id",
            "in": "path",
            "required": true,
            "schema": {
              "type": "string",
              "format": "uuid"
            }
          }
        ],
        "responses": {
          "2XX": {
            "description": "Success result",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/GetAllHmgScansResponse"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "GetAllHmgScansResponse": {
        "allOf": [
          {
            "type": "object",
            "description": "Information about a group's recent scans.",
            "properties": {
              "items": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/Scan"
                },
                "description": "List of all tracked scans, from newest to oldest."
              }
            },
            "required": [
              "items"
            ]
          }
        ]
      },
      "Scan": {
        "allOf": [
          {
            "type": "object",
            "description": "An object for representing a scan of objects from a source HSM,\nDSM cluster, or cloud KMS.",
            "properties": {
              "scan_id": {
                "type": "string",
                "format": "uuid",
                "description": "The ID of the scan."
              },
              "is_async": {
                "type": "boolean",
                "description": "Whether the scan is async or not."
              },
              "started_at": {
                "type": "string",
                "pattern": "^\\d{4}\\d{2}\\d{2}T\\d{2}\\d{2}\\d{2}Z$",
                "example": "20170509T070912Z",
                "description": "The time the scan began."
              },
              "finished_at": {
                "type": "string",
                "pattern": "^\\d{4}\\d{2}\\d{2}T\\d{2}\\d{2}\\d{2}Z$",
                "example": "20170509T070912Z",
                "description": "The time the scan finished."
              },
              "scan_result": {
                "$ref": "#/components/schemas/ScanResult"
              },
              "warnings": {
                "type": "array",
                "items": {
                  "$ref": "#/components/schemas/ScanWarning"
                },
                "nullable": true,
                "description": "Any warnings thrown during the scan."
              }
            },
            "required": [
              "scan_id",
              "is_async",
              "started_at"
            ]
          }
        ]
      },
      "ScanResult": {
        "description": "The result of a scan.",
        "oneOf": [
          {
            "$ref": "#/components/schemas/ScanResultVariantSuccess"
          },
          {
            "$ref": "#/components/schemas/ScanResultVariantFailed"
          }
        ],
        "discriminator": {
          "propertyName": "$type",
          "mapping": {
            "Success": "ScanResultVariantSuccess",
            "Failed": "ScanResultVariantFailed"
          }
        }
      },
      "ScanWarning": {
        "allOf": [
          {
            "type": "object",
            "description": "A warning \"thrown\" by a scan.",
            "properties": {
              "source_key_id": {
                "type": "string",
                "format": "uuid",
                "nullable": true,
                "description": "The ID of the source key for which the warning applies to."
              },
              "virtual_key_id": {
                "type": "string",
                "format": "uuid",
                "nullable": true,
                "description": "The ID of the virtual key for which the warning applies to."
              },
              "message": {
                "type": "string",
                "description": "The warning message associated with the warning."
              }
            },
            "required": [
              "message"
            ]
          }
        ]
      },
      "ScanResultVariantSuccess": {
        "allOf": [
          {
            "type": "object",
            "properties": {
              "$type": {
                "type": "string",
                "enum": [
                  "Success"
                ]
              }
            },
            "required": [
              "$type"
            ]
          },
          {
            "type": "object",
            "properties": {}
          }
        ]
      },
      "ScanResultVariantFailed": {
        "allOf": [
          {
            "type": "object",
            "properties": {
              "$type": {
                "type": "string",
                "enum": [
                  "Failed"
                ]
              }
            },
            "required": [
              "$type"
            ]
          },
          {
            "$ref": "#/components/schemas/ScanResultFailed"
          }
        ]
      },
      "ScanResultFailed": {
        "allOf": [
          {
            "type": "object",
            "description": "Indicates that a scan has failed. The most recent error is included\n(taken from the last retry).",
            "properties": {
              "message": {
                "type": "string"
              }
            },
            "required": [
              "message"
            ]
          }
        ]
      }
    }
  }
}
````

