Chilkat Online Tools

BatchGetBuildBatches VB.NET Example

AWS CodeBuild

' This example requires the Chilkat API to have been previously unlocked.
' See Global Unlock Sample for sample code.

Dim rest As New Chilkat.Rest
Dim success As Boolean

Dim authAws As New Chilkat.AuthAws
authAws.AccessKey = "AWS_ACCESS_KEY"
authAws.SecretKey = "AWS_SECRET_KEY"

' Don't forget to change the region to your particular region. (Also make the same change in the call to Connect below.)
authAws.Region = "us-west-2"
authAws.ServiceName = "codebuild"
' SetAuthAws causes Chilkat to automatically add the following headers: Authorization, X-Amz-Date
rest.SetAuthAws(authAws)

' URL: https://codebuild.us-west-2.amazonaws.com/
' Use the same region as specified above.
success = rest.Connect("codebuild.us-west-2.amazonaws.com",443,True,True)
If (success <> True) Then
    Debug.WriteLine("ConnectFailReason: " & rest.ConnectFailReason)
    Debug.WriteLine(rest.LastErrorText)
    Exit Sub
End If


' The following code creates the JSON request body.
' The JSON created by this code is shown below.

' Use this online tool to generate code from sample JSON:
' Generate Code to Create JSON

Dim json As New Chilkat.JsonObject
json.UpdateString("ids[0]","string")

' The JSON request body created by the above code:

' {
'   "ids": [
'     "string"
'   ]
' }

rest.AddHeader("Content-Type","application/x-amz-json-1.1")
rest.AddHeader("X-Amz-Target","CodeBuild_20161006.BatchGetBuildBatches")

Dim sbRequestBody As New Chilkat.StringBuilder
json.EmitSb(sbRequestBody)
Dim sbResponseBody As New Chilkat.StringBuilder
success = rest.FullRequestSb("POST","/",sbRequestBody,sbResponseBody)
If (success <> True) Then
    Debug.WriteLine(rest.LastErrorText)
    Exit Sub
End If

Dim respStatusCode As Integer = rest.ResponseStatusCode
Debug.WriteLine("response status code = " & respStatusCode)
If (respStatusCode <> 200) Then
    Debug.WriteLine("Response Header:")
    Debug.WriteLine(rest.ResponseHeader)
    Debug.WriteLine("Response Body:")
    Debug.WriteLine(sbResponseBody.GetAsString())
    Exit Sub
End If


Dim jResp As New Chilkat.JsonObject
jResp.LoadSb(sbResponseBody)

' The following code parses the JSON response.
' A sample JSON response is shown below the sample code.

' Use this online tool to generate parsing code from sample JSON:
' Generate Parsing Code from JSON



Dim arn As String
Dim ArtifactIdentifier As String
Dim BucketOwnerAccess As String
Dim EncryptionDisabled As Integer
Dim Location As String
Dim Md5sum As String
Dim OverrideArtifactName As Integer
Dim Sha256sum As String
Dim BatchReportMode As String
Dim CombineArtifacts As Integer
Dim MaximumBuildsAllowed As Integer
Dim ServiceRole As String
Dim TimeoutInMins As Integer
Dim buildBatchNumber As Integer
Dim buildBatchStatus As String
Dim buildTimeoutInMinutes As Integer
Dim cacheLocation As String
Dim v_Type As String
Dim complete As Integer
Dim currentPhase As String
Dim debugSessionEnabled As Integer
Dim encryptionKey As String
Dim endTime As Integer
Dim Certificate As String
Dim ComputeType As String
Dim Image As String
Dim ImagePullCredentialsType As String
Dim PrivilegedMode As Integer
Dim Credential As String
Dim CredentialProvider As String
Dim environmentType As String
Dim id As String
Dim initiator As String
Dim GroupName As String
Dim Status As String
Dim StreamName As String
Dim S3LogsBucketOwnerAccess As String
Dim S3LogsEncryptionDisabled As Integer
Dim S3LogsLocation As String
Dim S3LogsStatus As String
Dim projectName As String
Dim queuedTimeoutInMinutes As Integer
Dim resolvedSourceVersion As String
Dim serviceRole As String
Dim Resource As String
Dim AuthType As String
Dim Buildspec As String
Dim Context As String
Dim TargetUrl As String
Dim GitCloneDepth As Integer
Dim FetchSubmodules As Integer
Dim InsecureSsl As Integer
Dim sourceLocation As String
Dim ReportBuildStatus As Integer
Dim SourceIdentifier As String
Dim sourceType As String
Dim sourceVersion As String
Dim startTime As Integer
Dim VpcId As String
Dim j As Integer
Dim count_j As Integer
Dim strVal As String
Dim Arn As String
Dim BuildStatus As String
Dim Identifier As String
Dim PrimaryArtifactLocation As String
Dim PrimaryArtifactType As String
Dim RequestedOn As Integer
Dim identifier As String
Dim ignoreFailure As Integer
Dim k As Integer
Dim count_k As Integer
Dim location As String
Dim v_type As String
Dim buildStatus As String
Dim primaryArtifactIdentifier As String
Dim primaryArtifactLocation As String
Dim primaryArtifactType As String
Dim requestedOn As Integer
Dim json1 As Chilkat.JsonObject
Dim i1 As Integer
Dim count_i1 As Integer
Dim name As String
Dim value As String
Dim mountOptions As String
Dim mountPoint As String
Dim durationInSeconds As Integer
Dim phaseStatus As String
Dim phaseType As String
Dim message As String
Dim statusCode As String
Dim artifactIdentifier As String
Dim bucketOwnerAccess As String
Dim encryptionDisabled As Integer
Dim md5sum As String
Dim overrideArtifactName As Integer
Dim sha256sum As String
Dim authResource As String
Dim authType As String
Dim buildspec As String
Dim buildStatusConfigContext As String
Dim buildStatusConfigTargetUrl As String
Dim gitCloneDepth As Integer
Dim gitSubmodulesConfigFetchSubmodules As Integer
Dim insecureSsl As Integer
Dim reportBuildStatus As Integer
Dim sourceIdentifier As String

Dim i As Integer = 0
Dim count_i As Integer = jResp.SizeOfArray("buildBatches")
While i < count_i
    jResp.I = i
    arn = jResp.StringOf("buildBatches[i].arn")
    ArtifactIdentifier = jResp.StringOf("buildBatches[i].artifacts.artifactIdentifier")
    BucketOwnerAccess = jResp.StringOf("buildBatches[i].artifacts.bucketOwnerAccess")
    EncryptionDisabled = jResp.IntOf("buildBatches[i].artifacts.encryptionDisabled")
    Location = jResp.StringOf("buildBatches[i].artifacts.location")
    Md5sum = jResp.StringOf("buildBatches[i].artifacts.md5sum")
    OverrideArtifactName = jResp.IntOf("buildBatches[i].artifacts.overrideArtifactName")
    Sha256sum = jResp.StringOf("buildBatches[i].artifacts.sha256sum")
    BatchReportMode = jResp.StringOf("buildBatches[i].buildBatchConfig.batchReportMode")
    CombineArtifacts = jResp.IntOf("buildBatches[i].buildBatchConfig.combineArtifacts")
    MaximumBuildsAllowed = jResp.IntOf("buildBatches[i].buildBatchConfig.restrictions.maximumBuildsAllowed")
    ServiceRole = jResp.StringOf("buildBatches[i].buildBatchConfig.serviceRole")
    TimeoutInMins = jResp.IntOf("buildBatches[i].buildBatchConfig.timeoutInMins")
    buildBatchNumber = jResp.IntOf("buildBatches[i].buildBatchNumber")
    buildBatchStatus = jResp.StringOf("buildBatches[i].buildBatchStatus")
    buildTimeoutInMinutes = jResp.IntOf("buildBatches[i].buildTimeoutInMinutes")
    cacheLocation = jResp.StringOf("buildBatches[i].cache.location")
    v_Type = jResp.StringOf("buildBatches[i].cache.type")
    complete = jResp.IntOf("buildBatches[i].complete")
    currentPhase = jResp.StringOf("buildBatches[i].currentPhase")
    debugSessionEnabled = jResp.IntOf("buildBatches[i].debugSessionEnabled")
    encryptionKey = jResp.StringOf("buildBatches[i].encryptionKey")
    endTime = jResp.IntOf("buildBatches[i].endTime")
    Certificate = jResp.StringOf("buildBatches[i].environment.certificate")
    ComputeType = jResp.StringOf("buildBatches[i].environment.computeType")
    Image = jResp.StringOf("buildBatches[i].environment.image")
    ImagePullCredentialsType = jResp.StringOf("buildBatches[i].environment.imagePullCredentialsType")
    PrivilegedMode = jResp.IntOf("buildBatches[i].environment.privilegedMode")
    Credential = jResp.StringOf("buildBatches[i].environment.registryCredential.credential")
    CredentialProvider = jResp.StringOf("buildBatches[i].environment.registryCredential.credentialProvider")
    environmentType = jResp.StringOf("buildBatches[i].environment.type")
    id = jResp.StringOf("buildBatches[i].id")
    initiator = jResp.StringOf("buildBatches[i].initiator")
    GroupName = jResp.StringOf("buildBatches[i].logConfig.cloudWatchLogs.groupName")
    Status = jResp.StringOf("buildBatches[i].logConfig.cloudWatchLogs.status")
    StreamName = jResp.StringOf("buildBatches[i].logConfig.cloudWatchLogs.streamName")
    S3LogsBucketOwnerAccess = jResp.StringOf("buildBatches[i].logConfig.s3Logs.bucketOwnerAccess")
    S3LogsEncryptionDisabled = jResp.IntOf("buildBatches[i].logConfig.s3Logs.encryptionDisabled")
    S3LogsLocation = jResp.StringOf("buildBatches[i].logConfig.s3Logs.location")
    S3LogsStatus = jResp.StringOf("buildBatches[i].logConfig.s3Logs.status")
    projectName = jResp.StringOf("buildBatches[i].projectName")
    queuedTimeoutInMinutes = jResp.IntOf("buildBatches[i].queuedTimeoutInMinutes")
    resolvedSourceVersion = jResp.StringOf("buildBatches[i].resolvedSourceVersion")
    serviceRole = jResp.StringOf("buildBatches[i].serviceRole")
    Resource = jResp.StringOf("buildBatches[i].source.auth.resource")
    AuthType = jResp.StringOf("buildBatches[i].source.auth.type")
    Buildspec = jResp.StringOf("buildBatches[i].source.buildspec")
    Context = jResp.StringOf("buildBatches[i].source.buildStatusConfig.context")
    TargetUrl = jResp.StringOf("buildBatches[i].source.buildStatusConfig.targetUrl")
    GitCloneDepth = jResp.IntOf("buildBatches[i].source.gitCloneDepth")
    FetchSubmodules = jResp.IntOf("buildBatches[i].source.gitSubmodulesConfig.fetchSubmodules")
    InsecureSsl = jResp.IntOf("buildBatches[i].source.insecureSsl")
    sourceLocation = jResp.StringOf("buildBatches[i].source.location")
    ReportBuildStatus = jResp.IntOf("buildBatches[i].source.reportBuildStatus")
    SourceIdentifier = jResp.StringOf("buildBatches[i].source.sourceIdentifier")
    sourceType = jResp.StringOf("buildBatches[i].source.type")
    sourceVersion = jResp.StringOf("buildBatches[i].sourceVersion")
    startTime = jResp.IntOf("buildBatches[i].startTime")
    VpcId = jResp.StringOf("buildBatches[i].vpcConfig.vpcId")
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].buildBatchConfig.restrictions.computeTypesAllowed")
    While j < count_j
        jResp.J = j
        strVal = jResp.StringOf("buildBatches[i].buildBatchConfig.restrictions.computeTypesAllowed[j]")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].buildGroups")
    While j < count_j
        jResp.J = j
        Arn = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.arn")
        BuildStatus = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.buildStatus")
        Identifier = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.identifier")
        PrimaryArtifactLocation = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.location")
        PrimaryArtifactType = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.type")
        RequestedOn = jResp.IntOf("buildBatches[i].buildGroups[j].currentBuildSummary.requestedOn")
        identifier = jResp.StringOf("buildBatches[i].buildGroups[j].identifier")
        ignoreFailure = jResp.IntOf("buildBatches[i].buildGroups[j].ignoreFailure")
        k = 0
        count_k = jResp.SizeOfArray("buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts")
        While k < count_k
            jResp.K = k
            identifier = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].identifier")
            location = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].location")
            v_type = jResp.StringOf("buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].type")
            k = k + 1
        End While
        k = 0
        count_k = jResp.SizeOfArray("buildBatches[i].buildGroups[j].dependsOn")
        While k < count_k
            jResp.K = k
            strVal = jResp.StringOf("buildBatches[i].buildGroups[j].dependsOn[k]")
            k = k + 1
        End While
        k = 0
        count_k = jResp.SizeOfArray("buildBatches[i].buildGroups[j].priorBuildSummaryList")
        While k < count_k
            jResp.K = k
            arn = jResp.StringOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].arn")
            buildStatus = jResp.StringOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].buildStatus")
            primaryArtifactIdentifier = jResp.StringOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.identifier")
            primaryArtifactLocation = jResp.StringOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.location")
            primaryArtifactType = jResp.StringOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.type")
            requestedOn = jResp.IntOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k].requestedOn")

            json1 = jResp.ObjectOf("buildBatches[i].buildGroups[j].priorBuildSummaryList[k]")
            i1 = 0
            count_i1 = json1.SizeOfArray("secondaryArtifacts")
            While i1 < count_i1
                json1.I = i1
                identifier = json1.StringOf("secondaryArtifacts[i].identifier")
                location = json1.StringOf("secondaryArtifacts[i].location")
                v_type = json1.StringOf("secondaryArtifacts[i].type")
                i1 = i1 + 1
            End While

            k = k + 1
        End While
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].cache.modes")
    While j < count_j
        jResp.J = j
        strVal = jResp.StringOf("buildBatches[i].cache.modes[j]")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].environment.environmentVariables")
    While j < count_j
        jResp.J = j
        name = jResp.StringOf("buildBatches[i].environment.environmentVariables[j].name")
        v_type = jResp.StringOf("buildBatches[i].environment.environmentVariables[j].type")
        value = jResp.StringOf("buildBatches[i].environment.environmentVariables[j].value")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].fileSystemLocations")
    While j < count_j
        jResp.J = j
        identifier = jResp.StringOf("buildBatches[i].fileSystemLocations[j].identifier")
        location = jResp.StringOf("buildBatches[i].fileSystemLocations[j].location")
        mountOptions = jResp.StringOf("buildBatches[i].fileSystemLocations[j].mountOptions")
        mountPoint = jResp.StringOf("buildBatches[i].fileSystemLocations[j].mountPoint")
        v_type = jResp.StringOf("buildBatches[i].fileSystemLocations[j].type")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].phases")
    While j < count_j
        jResp.J = j
        durationInSeconds = jResp.IntOf("buildBatches[i].phases[j].durationInSeconds")
        endTime = jResp.IntOf("buildBatches[i].phases[j].endTime")
        phaseStatus = jResp.StringOf("buildBatches[i].phases[j].phaseStatus")
        phaseType = jResp.StringOf("buildBatches[i].phases[j].phaseType")
        startTime = jResp.IntOf("buildBatches[i].phases[j].startTime")
        k = 0
        count_k = jResp.SizeOfArray("buildBatches[i].phases[j].contexts")
        While k < count_k
            jResp.K = k
            message = jResp.StringOf("buildBatches[i].phases[j].contexts[k].message")
            statusCode = jResp.StringOf("buildBatches[i].phases[j].contexts[k].statusCode")
            k = k + 1
        End While
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].secondaryArtifacts")
    While j < count_j
        jResp.J = j
        artifactIdentifier = jResp.StringOf("buildBatches[i].secondaryArtifacts[j].artifactIdentifier")
        bucketOwnerAccess = jResp.StringOf("buildBatches[i].secondaryArtifacts[j].bucketOwnerAccess")
        encryptionDisabled = jResp.IntOf("buildBatches[i].secondaryArtifacts[j].encryptionDisabled")
        location = jResp.StringOf("buildBatches[i].secondaryArtifacts[j].location")
        md5sum = jResp.StringOf("buildBatches[i].secondaryArtifacts[j].md5sum")
        overrideArtifactName = jResp.IntOf("buildBatches[i].secondaryArtifacts[j].overrideArtifactName")
        sha256sum = jResp.StringOf("buildBatches[i].secondaryArtifacts[j].sha256sum")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].secondarySources")
    While j < count_j
        jResp.J = j
        authResource = jResp.StringOf("buildBatches[i].secondarySources[j].auth.resource")
        authType = jResp.StringOf("buildBatches[i].secondarySources[j].auth.type")
        buildspec = jResp.StringOf("buildBatches[i].secondarySources[j].buildspec")
        buildStatusConfigContext = jResp.StringOf("buildBatches[i].secondarySources[j].buildStatusConfig.context")
        buildStatusConfigTargetUrl = jResp.StringOf("buildBatches[i].secondarySources[j].buildStatusConfig.targetUrl")
        gitCloneDepth = jResp.IntOf("buildBatches[i].secondarySources[j].gitCloneDepth")
        gitSubmodulesConfigFetchSubmodules = jResp.IntOf("buildBatches[i].secondarySources[j].gitSubmodulesConfig.fetchSubmodules")
        insecureSsl = jResp.IntOf("buildBatches[i].secondarySources[j].insecureSsl")
        location = jResp.StringOf("buildBatches[i].secondarySources[j].location")
        reportBuildStatus = jResp.IntOf("buildBatches[i].secondarySources[j].reportBuildStatus")
        sourceIdentifier = jResp.StringOf("buildBatches[i].secondarySources[j].sourceIdentifier")
        v_type = jResp.StringOf("buildBatches[i].secondarySources[j].type")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].secondarySourceVersions")
    While j < count_j
        jResp.J = j
        sourceIdentifier = jResp.StringOf("buildBatches[i].secondarySourceVersions[j].sourceIdentifier")
        sourceVersion = jResp.StringOf("buildBatches[i].secondarySourceVersions[j].sourceVersion")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].vpcConfig.securityGroupIds")
    While j < count_j
        jResp.J = j
        strVal = jResp.StringOf("buildBatches[i].vpcConfig.securityGroupIds[j]")
        j = j + 1
    End While
    j = 0
    count_j = jResp.SizeOfArray("buildBatches[i].vpcConfig.subnets")
    While j < count_j
        jResp.J = j
        strVal = jResp.StringOf("buildBatches[i].vpcConfig.subnets[j]")
        j = j + 1
    End While
    i = i + 1
End While
i = 0
count_i = jResp.SizeOfArray("buildBatchesNotFound")
While i < count_i
    jResp.I = i
    strVal = jResp.StringOf("buildBatchesNotFound[i]")
    i = i + 1
End While


' A sample JSON response body parsed by the above code:

' {
'   "buildBatches": [
'     {
'       "arn": "string",
'       "artifacts": {
'         "artifactIdentifier": "string",
'         "bucketOwnerAccess": "string",
'         "encryptionDisabled": boolean,
'         "location": "string",
'         "md5sum": "string",
'         "overrideArtifactName": boolean,
'         "sha256sum": "string"
'       },
'       "buildBatchConfig": {
'         "batchReportMode": "string",
'         "combineArtifacts": boolean,
'         "restrictions": {
'           "computeTypesAllowed": [
'             "string"
'           ],
'           "maximumBuildsAllowed": number
'         },
'         "serviceRole": "string",
'         "timeoutInMins": number
'       },
'       "buildBatchNumber": number,
'       "buildBatchStatus": "string",
'       "buildGroups": [
'         {
'           "currentBuildSummary": {
'             "arn": "string",
'             "buildStatus": "string",
'             "primaryArtifact": {
'               "identifier": "string",
'               "location": "string",
'               "type": "string"
'             },
'             "requestedOn": number,
'             "secondaryArtifacts": [
'               {
'                 "identifier": "string",
'                 "location": "string",
'                 "type": "string"
'               }
'             ]
'           },
'           "dependsOn": [
'             "string"
'           ],
'           "identifier": "string",
'           "ignoreFailure": boolean,
'           "priorBuildSummaryList": [
'             {
'               "arn": "string",
'               "buildStatus": "string",
'               "primaryArtifact": {
'                 "identifier": "string",
'                 "location": "string",
'                 "type": "string"
'               },
'               "requestedOn": number,
'               "secondaryArtifacts": [
'                 {
'                   "identifier": "string",
'                   "location": "string",
'                   "type": "string"
'                 }
'               ]
'             }
'           ]
'         }
'       ],
'       "buildTimeoutInMinutes": number,
'       "cache": {
'         "location": "string",
'         "modes": [
'           "string"
'         ],
'         "type": "string"
'       },
'       "complete": boolean,
'       "currentPhase": "string",
'       "debugSessionEnabled": boolean,
'       "encryptionKey": "string",
'       "endTime": number,
'       "environment": {
'         "certificate": "string",
'         "computeType": "string",
'         "environmentVariables": [
'           {
'             "name": "string",
'             "type": "string",
'             "value": "string"
'           }
'         ],
'         "image": "string",
'         "imagePullCredentialsType": "string",
'         "privilegedMode": boolean,
'         "registryCredential": {
'           "credential": "string",
'           "credentialProvider": "string"
'         },
'         "type": "string"
'       },
'       "fileSystemLocations": [
'         {
'           "identifier": "string",
'           "location": "string",
'           "mountOptions": "string",
'           "mountPoint": "string",
'           "type": "string"
'         }
'       ],
'       "id": "string",
'       "initiator": "string",
'       "logConfig": {
'         "cloudWatchLogs": {
'           "groupName": "string",
'           "status": "string",
'           "streamName": "string"
'         },
'         "s3Logs": {
'           "bucketOwnerAccess": "string",
'           "encryptionDisabled": boolean,
'           "location": "string",
'           "status": "string"
'         }
'       },
'       "phases": [
'         {
'           "contexts": [
'             {
'               "message": "string",
'               "statusCode": "string"
'             }
'           ],
'           "durationInSeconds": number,
'           "endTime": number,
'           "phaseStatus": "string",
'           "phaseType": "string",
'           "startTime": number
'         }
'       ],
'       "projectName": "string",
'       "queuedTimeoutInMinutes": number,
'       "resolvedSourceVersion": "string",
'       "secondaryArtifacts": [
'         {
'           "artifactIdentifier": "string",
'           "bucketOwnerAccess": "string",
'           "encryptionDisabled": boolean,
'           "location": "string",
'           "md5sum": "string",
'           "overrideArtifactName": boolean,
'           "sha256sum": "string"
'         }
'       ],
'       "secondarySources": [
'         {
'           "auth": {
'             "resource": "string",
'             "type": "string"
'           },
'           "buildspec": "string",
'           "buildStatusConfig": {
'             "context": "string",
'             "targetUrl": "string"
'           },
'           "gitCloneDepth": number,
'           "gitSubmodulesConfig": {
'             "fetchSubmodules": boolean
'           },
'           "insecureSsl": boolean,
'           "location": "string",
'           "reportBuildStatus": boolean,
'           "sourceIdentifier": "string",
'           "type": "string"
'         }
'       ],
'       "secondarySourceVersions": [
'         {
'           "sourceIdentifier": "string",
'           "sourceVersion": "string"
'         }
'       ],
'       "serviceRole": "string",
'       "source": {
'         "auth": {
'           "resource": "string",
'           "type": "string"
'         },
'         "buildspec": "string",
'         "buildStatusConfig": {
'           "context": "string",
'           "targetUrl": "string"
'         },
'         "gitCloneDepth": number,
'         "gitSubmodulesConfig": {
'           "fetchSubmodules": boolean
'         },
'         "insecureSsl": boolean,
'         "location": "string",
'         "reportBuildStatus": boolean,
'         "sourceIdentifier": "string",
'         "type": "string"
'       },
'       "sourceVersion": "string",
'       "startTime": number,
'       "vpcConfig": {
'         "securityGroupIds": [
'           "string"
'         ],
'         "subnets": [
'           "string"
'         ],
'         "vpcId": "string"
'       }
'     }
'   ],
'   "buildBatchesNotFound": [
'     "string"
'   ]
' }