Interface Assessments


public interface Assessments
Resource collection API of Assessments.
  • Method Details

    • list

      com.azure.core.http.rest.PagedIterable<SecurityAssessmentResponse> list(String scope)
      Get security assessments on all your scanned resources inside a scope.
      Parameters:
      scope - Scope of the query, can be subscription (/subscriptions/0b06d9ea-afe6-4779-bd59-30e5c2d9d13f) or management group (/providers/Microsoft.Management/managementGroups/mgName).
      Returns:
      security assessments on all your scanned resources inside a scope as paginated response with PagedIterable.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • list

      com.azure.core.http.rest.PagedIterable<SecurityAssessmentResponse> list(String scope, com.azure.core.util.Context context)
      Get security assessments on all your scanned resources inside a scope.
      Parameters:
      scope - Scope of the query, can be subscription (/subscriptions/0b06d9ea-afe6-4779-bd59-30e5c2d9d13f) or management group (/providers/Microsoft.Management/managementGroups/mgName).
      context - The context to associate with this operation.
      Returns:
      security assessments on all your scanned resources inside a scope as paginated response with PagedIterable.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • get

      SecurityAssessmentResponse get(String resourceId, String assessmentName)
      Get a security assessment on your scanned resource.
      Parameters:
      resourceId - The identifier of the resource.
      assessmentName - The Assessment Key - Unique key for the assessment type.
      Returns:
      a security assessment on your scanned resource.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getWithResponse

      com.azure.core.http.rest.Response<SecurityAssessmentResponse> getWithResponse(String resourceId, String assessmentName, ExpandEnum expand, com.azure.core.util.Context context)
      Get a security assessment on your scanned resource.
      Parameters:
      resourceId - The identifier of the resource.
      assessmentName - The Assessment Key - Unique key for the assessment type.
      expand - OData expand. Optional.
      context - The context to associate with this operation.
      Returns:
      a security assessment on your scanned resource along with Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • deleteByResourceGroup

      void deleteByResourceGroup(String resourceId, String assessmentName)
      Delete a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result.
      Parameters:
      resourceId - The identifier of the resource.
      assessmentName - The Assessment Key - Unique key for the assessment type.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • deleteWithResponse

      com.azure.core.http.rest.Response<Void> deleteWithResponse(String resourceId, String assessmentName, com.azure.core.util.Context context)
      Delete a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result.
      Parameters:
      resourceId - The identifier of the resource.
      assessmentName - The Assessment Key - Unique key for the assessment type.
      context - The context to associate with this operation.
      Returns:
      the Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getById

      Get a security assessment on your scanned resource.
      Parameters:
      id - the resource ID.
      Returns:
      a security assessment on your scanned resource along with Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • getByIdWithResponse

      com.azure.core.http.rest.Response<SecurityAssessmentResponse> getByIdWithResponse(String id, ExpandEnum expand, com.azure.core.util.Context context)
      Get a security assessment on your scanned resource.
      Parameters:
      id - the resource ID.
      expand - OData expand. Optional.
      context - The context to associate with this operation.
      Returns:
      a security assessment on your scanned resource along with Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • deleteById

      void deleteById(String id)
      Delete a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result.
      Parameters:
      id - the resource ID.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • deleteByIdWithResponse

      com.azure.core.http.rest.Response<Void> deleteByIdWithResponse(String id, com.azure.core.util.Context context)
      Delete a security assessment on your resource. An assessment metadata that describes this assessment must be predefined with the same name before inserting the assessment result.
      Parameters:
      id - the resource ID.
      context - The context to associate with this operation.
      Returns:
      the Response.
      Throws:
      IllegalArgumentException - thrown if parameters fail the validation.
      com.azure.core.management.exception.ManagementException - thrown if the request is rejected by server.
      RuntimeException - all other wrapped checked exceptions if the request fails to be sent.
    • define

      Begins definition for a new SecurityAssessmentResponse resource.
      Parameters:
      name - resource name.
      Returns:
      the first stage of the new SecurityAssessmentResponse definition.