create_scan
¶
create_scan(
resource_id: ResourceId,
scan_name: ScanName,
*,
config_overrides: Optional[CodeGuruSecurityClientConfig] = None,
client_token: Optional[ClientToken] = None,
scan_type: Optional[ScanType] = None,
analysis_type: Optional[AnalysisType] = None,
tags: Optional[TagMap] = None,
) -> CreateScanResponse
Use to create a scan using code uploaded to an Amazon S3 bucket.
Parameters:
-
client_token(Optional[ClientToken], default:None) –The idempotency token for the request. Amazon CodeGuru Security uses this value to prevent the accidental creation of duplicate scans if there are failures and retries.
-
resource_id(ResourceId) –The identifier for the resource object to be scanned.
-
scan_name(ScanName) –The unique name that CodeGuru Security uses to track revisions across multiple scans of the same resource. Only allowed for a
STANDARDscan type. -
scan_type(Optional[ScanType], default:None) –The type of scan, either
StandardorExpress. Defaults toStandardtype if missing.Expressscans run on limited resources and use a limited set of detectors to analyze your code in near-real time.Standardscans have standard resource limits and use the full set of detectors to analyze your code. -
analysis_type(Optional[AnalysisType], default:None) –The type of analysis you want CodeGuru Security to perform in the scan, either
SecurityorAll. TheSecuritytype only generates findings related to security. TheAlltype generates both security findings and quality findings. Defaults toSecuritytype if missing. -
tags(Optional[TagMap], default:None) –An array of key-value pairs used to tag a scan. A tag is a custom attribute label with two parts:
-
A tag key. For example,
CostCenter,Environment, orSecret. Tag keys are case sensitive. -
An optional tag value field. For example,
111122223333,Production, or a team name. Omitting the tag value is the same as using an empty string. Tag values are case sensitive.
-
Raises:
-
AccessDeniedException–You do not have sufficient access to perform this action.
-
ConflictException–The requested operation would cause a conflict with the current state of a service resource associated with the request. Resolve the conflict before retrying this request.
-
InternalServerException–The server encountered an internal error and is unable to complete the request.
-
ResourceNotFoundException–The resource specified in the request was not found.
-
ThrottlingException–The request was denied due to request throttling.
-
ValidationException–The input fails to satisfy the specified constraints.
-
UnknownServiceError–The service returned an error code this client does not model.