Amazon CodeGuru Reviewer · JSON Structure

Amazon Codeguru Reviewer Source Code Type Structure

Specifies the source code that is analyzed in a code review.

Type: object Properties: 5
AmazonCode ReviewSecurityDevOpsMachine LearningDeveloper Tools

SourceCodeType is a JSON Structure definition published by Amazon CodeGuru Reviewer, describing 5 properties. It conforms to the https://json-structure.org/meta/core/v0/# meta-schema.

Properties

CommitDiff RepositoryHead BranchDiff S3BucketRepository RequestMetadata

Meta-schema: https://json-structure.org/meta/core/v0/#

JSON Structure

Raw ↑
{
  "$schema": "https://json-structure.org/meta/core/v0/#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/amazon-codeguru-reviewer/refs/heads/main/json-structure/amazon-codeguru-reviewer-source-code-type-structure.json",
  "name": "SourceCodeType",
  "description": "Specifies the source code that is analyzed in a code review.",
  "type": "object",
  "properties": {
    "CommitDiff": {
      "allOf": [
        {
          "$ref": "#/components/schemas/CommitDiffSourceCodeType"
        },
        {
          "description": "A <a href=\"https://docs.aws.amazon.com/codeguru/latest/reviewer-api/API_SourceCodeType\">SourceCodeType</a> that specifies a commit diff created by a pull request on an associated repository."
        }
      ]
    },
    "RepositoryHead": {
      "$ref": "#/components/schemas/RepositoryHeadSourceCodeType"
    },
    "BranchDiff": {
      "allOf": [
        {
          "$ref": "#/components/schemas/BranchDiffSourceCodeType"
        },
        {
          "description": "A type of <a href=\"https://docs.aws.amazon.com/codeguru/latest/reviewer-api/API_SourceCodeType\">SourceCodeType</a> that specifies a source branch name and a destination branch name in an associated repository."
        }
      ]
    },
    "S3BucketRepository": {
      "allOf": [
        {
          "$ref": "#/components/schemas/S3BucketRepository"
        },
        {
          "description": "Information about an associated repository in an S3 bucket that includes its name and an <code>S3RepositoryDetails</code> object. The <code>S3RepositoryDetails</code> object includes the name of an S3 bucket, an S3 key for a source code .zip file, and an S3 key for a build artifacts .zip file. <code>S3BucketRepository</code> is required in <a href=\"https://docs.aws.amazon.com/codeguru/latest/reviewer-api/API_SourceCodeType\">SourceCodeType</a> for <code>S3BucketRepository</code> based code reviews."
        }
      ]
    },
    "RequestMetadata": {
      "allOf": [
        {
          "$ref": "#/components/schemas/RequestMetadata"
        },
        {
          "description": "Metadata that is associated with a code review. This applies to any type of code review supported by CodeGuru Reviewer. The <code>RequestMetadaa</code> field captures any event metadata. For example, it might capture metadata associated with an event trigger, such as a push or a pull request."
        }
      ]
    }
  }
}