Required. The project in which to create the repository. Values are of the form projects/{project_number}/locations/{locationId}
Query parameters
Parameters
repositoryId
string
Required. The ID to use for the repository, which will become the final component of the repository's resource name. This value should be 4-63 characters, and valid characters are /[a-z][0-9]-/.
Request body
The request body contains an instance of Repository.
Response body
If successful, the response body contains a newly created instance of Operation.
[[["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-28 UTC."],[],[],null,["# Method: projects.locations.repositories.create\n\n- [HTTP request](#body.HTTP_TEMPLATE)\n- [Path parameters](#body.PATH_PARAMETERS)\n- [Query parameters](#body.QUERY_PARAMETERS)\n- [Request body](#body.request_body)\n- [Response body](#body.response_body)\n- [Authorization scopes](#body.aspect)\n- [IAM Permissions](#body.aspect_1)\n\nCreates a new repository in a given project and location.\n\nThe Repository.Instance field is required in the request body for requests using the securesourcemanager.googleapis.com endpoint.\n\n### HTTP request\n\nChoose a location: \nasia-east1 asia-northeast1 asia-northeast3 australia-southeast1 europe-west4 me-west1 northamerica-northeast1 us-central1 \n\n\u003cbr /\u003e\n\nThe URLs use [gRPC Transcoding](https://google.aip.dev/127) syntax.\n\n### Path parameters\n\n### Query parameters\n\n### Request body\n\nThe request body contains an instance of [Repository](/secure-source-manager/docs/reference/rest/v1/projects.locations.repositories#Repository).\n\n### Response body\n\nIf successful, the response body contains a newly created instance of [Operation](/secure-source-manager/docs/reference/rest/v1/projects.locations.operations#Operation).\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](/docs/authentication#authorization-gcp).\n\n### IAM Permissions\n\nRequires the following [IAM](https://cloud.google.com/iam/docs) permission on the `parent` resource:\n\n- `securesourcemanager.repositories.create`\n\nFor more information, see the [IAM documentation](https://cloud.google.com/iam/docs)."]]