Output only. The email address of the service account identity that will be used for a build by default.
This is returned in the format projects/{project}/serviceAccounts/{serviceAccount} where {serviceAccount} could be the legacy Cloud Build SA, in the format [PROJECT_NUMBER]@cloudbuild.gserviceaccount.com or the Compute SA, in the format [PROJECT_NUMBER]-compute@developer.gserviceaccount.com.
If no service account will be used by default, this will be empty.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-07-17 UTC."],[[["\u003cp\u003eThis API endpoint retrieves the default service account used by a project for Cloud Build operations.\u003c/p\u003e\n"],["\u003cp\u003eThe HTTP request is a \u003ccode\u003eGET\u003c/code\u003e operation to a URL that follows gRPC Transcoding syntax, requiring a formatted name parameter to identify the resource.\u003c/p\u003e\n"],["\u003cp\u003eThe request body must be empty, and the response body contains the default service account's \u003ccode\u003ename\u003c/code\u003e and \u003ccode\u003eserviceAccountEmail\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eAuthorization requires the \u003ccode\u003ecloudbuild.builds.get\u003c/code\u003e IAM permission on the specified resource and the \u003ccode\u003ehttps://www.googleapis.com/auth/cloud-platform\u003c/code\u003e OAuth scope.\u003c/p\u003e\n"],["\u003cp\u003eThe endpoint retrieves the service account email in the format \u003ccode\u003eprojects/{project}/serviceAccounts/{serviceAccount}\u003c/code\u003e, or empty if none will be used by default.\u003c/p\u003e\n"]]],[],null,["# Method: projects.locations.getDefaultServiceAccount\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n - [JSON representation](#body.DefaultServiceAccount.SCHEMA_REPRESENTATION)\n- [Authorization scopes](#body.aspect)\n- [Try it!](#try-it)\n\nReturns the `DefaultServiceAccount` used by the project.\n\n### HTTP request\n\n`GET https://cloudbuild.googleapis.com/v1/{name=projects/*/locations/*/defaultServiceAccount}`\n\nThe URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n### Request body\n\nThe request body must be empty.\n\n### Response body\n\nThe default service account used for `Builds`.\n\nIf successful, the response body contains data with the following structure:\n\n### Authorization scopes\n\nRequires the following OAuth scope:\n\n- `https://www.googleapis.com/auth/cloud-platform`\n\nFor more information, see the [Authentication Overview](https://cloud.google.com/docs/authentication/)."]]