Chilkat Online Tools

BatchGetBuildBatches Swift3 Example

AWS CodeBuild

func chilkatTest() {
    // This example requires the Chilkat API to have been previously unlocked.
    // See Global Unlock Sample for sample code.

    let rest = CkoRest()!
    var success: Bool

    let authAws = CkoAuthAws()!
    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", port: 443, tls: true, autoReconnect: true)
    if success != true {
        print("ConnectFailReason: \(rest.connectFailReason.intValue)")
        print("\(rest.lastErrorText!)")
        return
    }

    // 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

    let json = CkoJsonObject()!
    json.update("ids[0]", value: "string")

    // The JSON request body created by the above code:

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

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

    let sbRequestBody = CkoStringBuilder()!
    json.emitSb(sbRequestBody)
    let sbResponseBody = CkoStringBuilder()!
    success = rest.fullRequestSb("POST", uriPath: "/", requestBody: sbRequestBody, responseBody: sbResponseBody)
    if success != true {
        print("\(rest.lastErrorText!)")
        return
    }

    var respStatusCode: Int = rest.responseStatusCode.intValue
    print("response status code = \(respStatusCode)")
    if respStatusCode != 200 {
        print("Response Header:")
        print("\(rest.responseHeader!)")
        print("Response Body:")
        print("\(sbResponseBody.getAsString()!)")
        return
    }

    let jResp = CkoJsonObject()!
    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

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

    var i: Int = 0
    var count_i: Int = jResp.size(ofArray: "buildBatches").intValue
    while i < count_i {
        jResp.i = i
        arn = jResp.string(of: "buildBatches[i].arn")
        ArtifactIdentifier = jResp.string(of: "buildBatches[i].artifacts.artifactIdentifier")
        BucketOwnerAccess = jResp.string(of: "buildBatches[i].artifacts.bucketOwnerAccess")
        EncryptionDisabled = jResp.int(of: "buildBatches[i].artifacts.encryptionDisabled").intValue
        Location = jResp.string(of: "buildBatches[i].artifacts.location")
        Md5sum = jResp.string(of: "buildBatches[i].artifacts.md5sum")
        OverrideArtifactName = jResp.int(of: "buildBatches[i].artifacts.overrideArtifactName").intValue
        Sha256sum = jResp.string(of: "buildBatches[i].artifacts.sha256sum")
        BatchReportMode = jResp.string(of: "buildBatches[i].buildBatchConfig.batchReportMode")
        CombineArtifacts = jResp.int(of: "buildBatches[i].buildBatchConfig.combineArtifacts").intValue
        MaximumBuildsAllowed = jResp.int(of: "buildBatches[i].buildBatchConfig.restrictions.maximumBuildsAllowed").intValue
        ServiceRole = jResp.string(of: "buildBatches[i].buildBatchConfig.serviceRole")
        TimeoutInMins = jResp.int(of: "buildBatches[i].buildBatchConfig.timeoutInMins").intValue
        buildBatchNumber = jResp.int(of: "buildBatches[i].buildBatchNumber").intValue
        buildBatchStatus = jResp.string(of: "buildBatches[i].buildBatchStatus")
        buildTimeoutInMinutes = jResp.int(of: "buildBatches[i].buildTimeoutInMinutes").intValue
        cacheLocation = jResp.string(of: "buildBatches[i].cache.location")
        v_Type = jResp.string(of: "buildBatches[i].cache.type")
        complete = jResp.int(of: "buildBatches[i].complete").intValue
        currentPhase = jResp.string(of: "buildBatches[i].currentPhase")
        debugSessionEnabled = jResp.int(of: "buildBatches[i].debugSessionEnabled").intValue
        encryptionKey = jResp.string(of: "buildBatches[i].encryptionKey")
        endTime = jResp.int(of: "buildBatches[i].endTime").intValue
        Certificate = jResp.string(of: "buildBatches[i].environment.certificate")
        ComputeType = jResp.string(of: "buildBatches[i].environment.computeType")
        Image = jResp.string(of: "buildBatches[i].environment.image")
        ImagePullCredentialsType = jResp.string(of: "buildBatches[i].environment.imagePullCredentialsType")
        PrivilegedMode = jResp.int(of: "buildBatches[i].environment.privilegedMode").intValue
        Credential = jResp.string(of: "buildBatches[i].environment.registryCredential.credential")
        CredentialProvider = jResp.string(of: "buildBatches[i].environment.registryCredential.credentialProvider")
        environmentType = jResp.string(of: "buildBatches[i].environment.type")
        id = jResp.string(of: "buildBatches[i].id")
        initiator = jResp.string(of: "buildBatches[i].initiator")
        GroupName = jResp.string(of: "buildBatches[i].logConfig.cloudWatchLogs.groupName")
        Status = jResp.string(of: "buildBatches[i].logConfig.cloudWatchLogs.status")
        StreamName = jResp.string(of: "buildBatches[i].logConfig.cloudWatchLogs.streamName")
        S3LogsBucketOwnerAccess = jResp.string(of: "buildBatches[i].logConfig.s3Logs.bucketOwnerAccess")
        S3LogsEncryptionDisabled = jResp.int(of: "buildBatches[i].logConfig.s3Logs.encryptionDisabled").intValue
        S3LogsLocation = jResp.string(of: "buildBatches[i].logConfig.s3Logs.location")
        S3LogsStatus = jResp.string(of: "buildBatches[i].logConfig.s3Logs.status")
        projectName = jResp.string(of: "buildBatches[i].projectName")
        queuedTimeoutInMinutes = jResp.int(of: "buildBatches[i].queuedTimeoutInMinutes").intValue
        resolvedSourceVersion = jResp.string(of: "buildBatches[i].resolvedSourceVersion")
        serviceRole = jResp.string(of: "buildBatches[i].serviceRole")
        Resource = jResp.string(of: "buildBatches[i].source.auth.resource")
        AuthType = jResp.string(of: "buildBatches[i].source.auth.type")
        Buildspec = jResp.string(of: "buildBatches[i].source.buildspec")
        Context = jResp.string(of: "buildBatches[i].source.buildStatusConfig.context")
        TargetUrl = jResp.string(of: "buildBatches[i].source.buildStatusConfig.targetUrl")
        GitCloneDepth = jResp.int(of: "buildBatches[i].source.gitCloneDepth").intValue
        FetchSubmodules = jResp.int(of: "buildBatches[i].source.gitSubmodulesConfig.fetchSubmodules").intValue
        InsecureSsl = jResp.int(of: "buildBatches[i].source.insecureSsl").intValue
        sourceLocation = jResp.string(of: "buildBatches[i].source.location")
        ReportBuildStatus = jResp.int(of: "buildBatches[i].source.reportBuildStatus").intValue
        SourceIdentifier = jResp.string(of: "buildBatches[i].source.sourceIdentifier")
        sourceType = jResp.string(of: "buildBatches[i].source.type")
        sourceVersion = jResp.string(of: "buildBatches[i].sourceVersion")
        startTime = jResp.int(of: "buildBatches[i].startTime").intValue
        VpcId = jResp.string(of: "buildBatches[i].vpcConfig.vpcId")
        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].buildBatchConfig.restrictions.computeTypesAllowed").intValue
        while j < count_j {
            jResp.j = j
            strVal = jResp.string(of: "buildBatches[i].buildBatchConfig.restrictions.computeTypesAllowed[j]")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].buildGroups").intValue
        while j < count_j {
            jResp.j = j
            Arn = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.arn")
            BuildStatus = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.buildStatus")
            Identifier = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.identifier")
            PrimaryArtifactLocation = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.location")
            PrimaryArtifactType = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.primaryArtifact.type")
            RequestedOn = jResp.int(of: "buildBatches[i].buildGroups[j].currentBuildSummary.requestedOn").intValue
            identifier = jResp.string(of: "buildBatches[i].buildGroups[j].identifier")
            ignoreFailure = jResp.int(of: "buildBatches[i].buildGroups[j].ignoreFailure").intValue
            k = 0
            count_k = jResp.size(ofArray: "buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts").intValue
            while k < count_k {
                jResp.k = k
                identifier = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].identifier")
                location = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].location")
                v_type = jResp.string(of: "buildBatches[i].buildGroups[j].currentBuildSummary.secondaryArtifacts[k].type")
                k = k + 1
            }

            k = 0
            count_k = jResp.size(ofArray: "buildBatches[i].buildGroups[j].dependsOn").intValue
            while k < count_k {
                jResp.k = k
                strVal = jResp.string(of: "buildBatches[i].buildGroups[j].dependsOn[k]")
                k = k + 1
            }

            k = 0
            count_k = jResp.size(ofArray: "buildBatches[i].buildGroups[j].priorBuildSummaryList").intValue
            while k < count_k {
                jResp.k = k
                arn = jResp.string(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].arn")
                buildStatus = jResp.string(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].buildStatus")
                primaryArtifactIdentifier = jResp.string(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.identifier")
                primaryArtifactLocation = jResp.string(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.location")
                primaryArtifactType = jResp.string(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].primaryArtifact.type")
                requestedOn = jResp.int(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k].requestedOn").intValue

                json1 = jResp.object(of: "buildBatches[i].buildGroups[j].priorBuildSummaryList[k]")
                i1 = 0
                count_i1 = json1!.size(ofArray: "secondaryArtifacts").intValue
                while i1 < count_i1 {
                    json1.i = i1
                    identifier = json1!.string(of: "secondaryArtifacts[i].identifier")
                    location = json1!.string(of: "secondaryArtifacts[i].location")
                    v_type = json1!.string(of: "secondaryArtifacts[i].type")
                    i1 = i1 + 1
                }

                json1 = nil
                k = k + 1
            }

            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].cache.modes").intValue
        while j < count_j {
            jResp.j = j
            strVal = jResp.string(of: "buildBatches[i].cache.modes[j]")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].environment.environmentVariables").intValue
        while j < count_j {
            jResp.j = j
            name = jResp.string(of: "buildBatches[i].environment.environmentVariables[j].name")
            v_type = jResp.string(of: "buildBatches[i].environment.environmentVariables[j].type")
            value = jResp.string(of: "buildBatches[i].environment.environmentVariables[j].value")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].fileSystemLocations").intValue
        while j < count_j {
            jResp.j = j
            identifier = jResp.string(of: "buildBatches[i].fileSystemLocations[j].identifier")
            location = jResp.string(of: "buildBatches[i].fileSystemLocations[j].location")
            mountOptions = jResp.string(of: "buildBatches[i].fileSystemLocations[j].mountOptions")
            mountPoint = jResp.string(of: "buildBatches[i].fileSystemLocations[j].mountPoint")
            v_type = jResp.string(of: "buildBatches[i].fileSystemLocations[j].type")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].phases").intValue
        while j < count_j {
            jResp.j = j
            durationInSeconds = jResp.int(of: "buildBatches[i].phases[j].durationInSeconds").intValue
            endTime = jResp.int(of: "buildBatches[i].phases[j].endTime").intValue
            phaseStatus = jResp.string(of: "buildBatches[i].phases[j].phaseStatus")
            phaseType = jResp.string(of: "buildBatches[i].phases[j].phaseType")
            startTime = jResp.int(of: "buildBatches[i].phases[j].startTime").intValue
            k = 0
            count_k = jResp.size(ofArray: "buildBatches[i].phases[j].contexts").intValue
            while k < count_k {
                jResp.k = k
                message = jResp.string(of: "buildBatches[i].phases[j].contexts[k].message")
                statusCode = jResp.string(of: "buildBatches[i].phases[j].contexts[k].statusCode")
                k = k + 1
            }

            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].secondaryArtifacts").intValue
        while j < count_j {
            jResp.j = j
            artifactIdentifier = jResp.string(of: "buildBatches[i].secondaryArtifacts[j].artifactIdentifier")
            bucketOwnerAccess = jResp.string(of: "buildBatches[i].secondaryArtifacts[j].bucketOwnerAccess")
            encryptionDisabled = jResp.int(of: "buildBatches[i].secondaryArtifacts[j].encryptionDisabled").intValue
            location = jResp.string(of: "buildBatches[i].secondaryArtifacts[j].location")
            md5sum = jResp.string(of: "buildBatches[i].secondaryArtifacts[j].md5sum")
            overrideArtifactName = jResp.int(of: "buildBatches[i].secondaryArtifacts[j].overrideArtifactName").intValue
            sha256sum = jResp.string(of: "buildBatches[i].secondaryArtifacts[j].sha256sum")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].secondarySources").intValue
        while j < count_j {
            jResp.j = j
            authResource = jResp.string(of: "buildBatches[i].secondarySources[j].auth.resource")
            authType = jResp.string(of: "buildBatches[i].secondarySources[j].auth.type")
            buildspec = jResp.string(of: "buildBatches[i].secondarySources[j].buildspec")
            buildStatusConfigContext = jResp.string(of: "buildBatches[i].secondarySources[j].buildStatusConfig.context")
            buildStatusConfigTargetUrl = jResp.string(of: "buildBatches[i].secondarySources[j].buildStatusConfig.targetUrl")
            gitCloneDepth = jResp.int(of: "buildBatches[i].secondarySources[j].gitCloneDepth").intValue
            gitSubmodulesConfigFetchSubmodules = jResp.int(of: "buildBatches[i].secondarySources[j].gitSubmodulesConfig.fetchSubmodules").intValue
            insecureSsl = jResp.int(of: "buildBatches[i].secondarySources[j].insecureSsl").intValue
            location = jResp.string(of: "buildBatches[i].secondarySources[j].location")
            reportBuildStatus = jResp.int(of: "buildBatches[i].secondarySources[j].reportBuildStatus").intValue
            sourceIdentifier = jResp.string(of: "buildBatches[i].secondarySources[j].sourceIdentifier")
            v_type = jResp.string(of: "buildBatches[i].secondarySources[j].type")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].secondarySourceVersions").intValue
        while j < count_j {
            jResp.j = j
            sourceIdentifier = jResp.string(of: "buildBatches[i].secondarySourceVersions[j].sourceIdentifier")
            sourceVersion = jResp.string(of: "buildBatches[i].secondarySourceVersions[j].sourceVersion")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].vpcConfig.securityGroupIds").intValue
        while j < count_j {
            jResp.j = j
            strVal = jResp.string(of: "buildBatches[i].vpcConfig.securityGroupIds[j]")
            j = j + 1
        }

        j = 0
        count_j = jResp.size(ofArray: "buildBatches[i].vpcConfig.subnets").intValue
        while j < count_j {
            jResp.j = j
            strVal = jResp.string(of: "buildBatches[i].vpcConfig.subnets[j]")
            j = j + 1
        }

        i = i + 1
    }

    i = 0
    count_i = jResp.size(ofArray: "buildBatchesNotFound").intValue
    while i < count_i {
        jResp.i = i
        strVal = jResp.string(of: "buildBatchesNotFound[i]")
        i = i + 1
    }

    // 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"
    //   ]
    // }

}