Inspector2 / Client / get_code_security_scan

get_code_security_scan

Inspector2.Client.get_code_security_scan(**kwargs)

Retrieves information about a specific code security scan.

See also: AWS API Documentation

Request Syntax

response = client.get_code_security_scan(
    resource={
        'projectId': 'string'
    },
    scanId='string'
)
Parameters:
  • resource (dict) –

    [REQUIRED]

    The resource identifier for the code repository that was scanned.

    Note

    This is a Tagged Union structure. Only one of the following top level keys can be set: projectId.

    • projectId (string) –

      The unique identifier of the project in the code repository.

  • scanId (string) –

    [REQUIRED]

    The unique identifier of the scan to retrieve.

Return type:

dict

Returns:

Response Syntax

{
    'accountId': 'string',
    'createdAt': datetime(2015, 1, 1),
    'lastCommitId': 'string',
    'resource': {
        'projectId': 'string'
    },
    'scanId': 'string',
    'status': 'IN_PROGRESS'|'SUCCESSFUL'|'FAILED'|'SKIPPED',
    'statusReason': 'string',
    'updatedAt': datetime(2015, 1, 1)
}

Response Structure

  • (dict) –

    • accountId (string) –

      The Amazon Web Services account ID associated with the scan.

    • createdAt (datetime) –

      The timestamp when the scan was created.

    • lastCommitId (string) –

      The identifier of the last commit that was scanned. This is only returned if the scan was successful or skipped.

    • resource (dict) –

      The resource identifier for the code repository that was scanned.

      Note

      This is a Tagged Union structure. Only one of the following top level keys will be set: projectId. If a client receives an unknown member it will set SDK_UNKNOWN_MEMBER as the top level key, which maps to the name or tag of the unknown member. The structure of SDK_UNKNOWN_MEMBER is as follows:

      'SDK_UNKNOWN_MEMBER': {'name': 'UnknownMemberName'}
      
      • projectId (string) –

        The unique identifier of the project in the code repository.

    • scanId (string) –

      The unique identifier of the scan.

    • status (string) –

      The current status of the scan.

    • statusReason (string) –

      The reason for the current status of the scan.

    • updatedAt (datetime) –

      The timestamp when the scan was last updated.

Exceptions