Secure Scores - Get

Get secure score for a specific Microsoft Defender for Cloud initiative within your current scope. For the ASC Default initiative, use 'ascScore'.

GET https://management.azure.com/subscriptions/{subscriptionId}/providers/Microsoft.Security/secureScores/{secureScoreName}?api-version=2020-01-01

URI Parameters

Name In Required Type Description
secureScoreName
path True

string

The initiative name. For the ASC Default initiative, use 'ascScore' as in the sample request below.

subscriptionId
path True

string (uuid)

The ID of the target subscription. The value must be an UUID.

api-version
query True

string

minLength: 1

The API version to use for this operation.

Responses

Name Type Description
200 OK

SecureScoreItem

Azure operation completed successfully.

Other Status Codes

Common.CloudError

An unexpected error response.

Security

azure_auth

Azure Active Directory OAuth2 Flow.

Type: oauth2
Flow: implicit
Authorization URL: https://login.microsoftonline.com/common/oauth2/authorize

Scopes

Name Description
user_impersonation impersonate your user account

Examples

Get single secure score

Sample request

GET https://management.azure.com/subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/providers/Microsoft.Security/secureScores/ascScore?api-version=2020-01-01

Sample response

{
  "name": "ascScore",
  "type": "Microsoft.Security/secureScores",
  "id": "/subscriptions/20ff7fc3-e762-44dd-bd96-b71116dcdc23/providers/Microsoft.Security/secureScores/ascScore",
  "properties": {
    "displayName": "ASC score",
    "score": {
      "current": 23.53,
      "max": 39,
      "percentage": 0.6033
    },
    "weight": 67
  }
}

Definitions

Name Description
Common.CloudError

Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

Common.CloudErrorBody

The error detail.

createdByType

The type of identity that created the resource.

ErrorAdditionalInfo

The resource management error additional info.

SecureScoreItem

Secure score item data model

systemData

Metadata pertaining to creation and last modification of the resource.

Common.CloudError

Common error response for all Azure Resource Manager APIs to return error details for failed operations. (This also follows the OData error response format.).

Name Type Description
error.additionalInfo

ErrorAdditionalInfo[]

The error additional info.

error.code

string

The error code.

error.details

Common.CloudErrorBody[]

The error details.

error.message

string

The error message.

error.target

string

The error target.

Common.CloudErrorBody

The error detail.

Name Type Description
additionalInfo

ErrorAdditionalInfo[]

The error additional info.

code

string

The error code.

details

Common.CloudErrorBody[]

The error details.

message

string

The error message.

target

string

The error target.

createdByType

The type of identity that created the resource.

Value Description
User
Application
ManagedIdentity
Key

ErrorAdditionalInfo

The resource management error additional info.

Name Type Description
info

object

The additional info.

type

string

The additional info type.

SecureScoreItem

Secure score item data model

Name Type Description
id

string (arm-id)

Fully qualified resource ID for the resource. E.g. "/subscriptions/{subscriptionId}/resourceGroups/{resourceGroupName}/providers/{resourceProviderNamespace}/{resourceType}/{resourceName}"

name

string

The name of the resource

properties.displayName

string

The initiative's name

properties.score.current

number (double)

minimum: 0

Current score

properties.score.max

integer (int32)

minimum: 0

Maximum score available

properties.score.percentage

number (double)

minimum: 0
maximum: 1

Ratio of the current score divided by the maximum. Rounded to 4 digits after the decimal point

properties.weight

integer (int64)

minimum: 0

The relative weight for each subscription. Used when calculating an aggregated secure score for multiple subscriptions.

systemData

systemData

Azure Resource Manager metadata containing createdBy and modifiedBy information.

type

string

The type of the resource. E.g. "Microsoft.Compute/virtualMachines" or "Microsoft.Storage/storageAccounts"

systemData

Metadata pertaining to creation and last modification of the resource.

Name Type Description
createdAt

string (date-time)

The timestamp of resource creation (UTC).

createdBy

string

The identity that created the resource.

createdByType

createdByType

The type of identity that created the resource.

lastModifiedAt

string (date-time)

The timestamp of resource last modification (UTC)

lastModifiedBy

string

The identity that last modified the resource.

lastModifiedByType

createdByType

The type of identity that last modified the resource.