Cloud Source Repositories API (sourcerepo:v1)

2024-06-23

11 new methods | New API

Additions

    Methods
  • sourcerepo.projects.getConfig

      Path: v1/{+name}/config

      Flat Path: v1/projects/{projectsId}/config

      HTTP Method: GET

      Parameters:

        name

          Description: The name of the requested project. Values are of the form `projects/`.

          Pattern: ^projects/[^/]+$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: name

      Scopes: https://www.googleapis.com/auth/cloud-platform

      Description: Returns the Cloud Source Repositories configuration of the project.

  • sourcerepo.projects.updateConfig

      Path: v1/{+name}/config

      Flat Path: v1/projects/{projectsId}/config

      HTTP Method: PATCH

      Parameters:

        name

          Description: The name of the requested project. Values are of the form `projects/`.

          Pattern: ^projects/[^/]+$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: name

      Scopes: https://www.googleapis.com/auth/cloud-platform

      Description: Updates the Cloud Source Repositories configuration of the project.

  • sourcerepo.projects.repos.list

      Path: v1/{+name}/repos

      Flat Path: v1/projects/{projectsId}/repos

      HTTP Method: GET

      Parameters:

        name

          Description: The project ID whose repos should be listed. Values are of the form `projects/`.

          Pattern: ^projects/[^/]+$

          Location: path

          Required: Yes

          Type: string

        pageSize

          Description: Maximum number of repositories to return; between 1 and 500. If not set or zero, defaults to 100 at the server.

          Location: query

          Type: integer

          Format: int32

        pageToken

          Description: Resume listing repositories where a prior ListReposResponse left off. This is an opaque token that must be obtained from a recent, prior ListReposResponse's next_page_token field.

          Location: query

          Type: string

      Parameter Order: name

      Scopes:

    • https://www.googleapis.com/auth/cloud-platform
    • https://www.googleapis.com/auth/source.full_control
    • https://www.googleapis.com/auth/source.read_only
    • https://www.googleapis.com/auth/source.read_write
    • Description: Returns all repos belonging to a project. The sizes of the repos are not set by ListRepos. To get the size of a repo, use GetRepo.

  • sourcerepo.projects.repos.get

  • sourcerepo.projects.repos.patch

      Path: v1/{+name}

      Flat Path: v1/projects/{projectsId}/repos/{reposId}

      HTTP Method: PATCH

      Parameters:

        name

          Description: The name of the requested repository. Values are of the form `projects//repos/`.

          Pattern: ^projects/[^/]+/repos/.*$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: name

      Scopes: https://www.googleapis.com/auth/cloud-platform

      Description: Updates information about a repo.

  • sourcerepo.projects.repos.create

      Path: v1/{+parent}/repos

      Flat Path: v1/projects/{projectsId}/repos

      HTTP Method: POST

      Parameters:

        parent

          Description: The project in which to create the repo. Values are of the form `projects/`.

          Pattern: ^projects/[^/]+$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: parent

      Scopes:

    • https://www.googleapis.com/auth/cloud-platform
    • https://www.googleapis.com/auth/source.full_control
    • Description: Creates a repo in the given project with the given name. If the named repository already exists, `CreateRepo` returns `ALREADY_EXISTS`.

  • sourcerepo.projects.repos.delete

  • sourcerepo.projects.repos.sync

      Path: v1/{+name}:sync

      Flat Path: v1/projects/{projectsId}/repos/{reposId}:sync

      HTTP Method: POST

      Parameters:

        name

          Description: The name of the repo to synchronize. Values are of the form `projects//repos/`.

          Pattern: ^projects/[^/]+/repos/.*$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: name

      Scopes: https://www.googleapis.com/auth/cloud-platform

      Description: Synchronize a connected repo. The response contains SyncRepoMetadata in the metadata field.

  • sourcerepo.projects.repos.setIamPolicy

      Path: v1/{+resource}:setIamPolicy

      Flat Path: v1/projects/{projectsId}/repos/{reposId}:setIamPolicy

      HTTP Method: POST

      Parameters:

        resource

          Description: REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

          Pattern: ^projects/[^/]+/repos/.*$

          Location: path

          Required: Yes

          Type: string

      Parameter Order: resource

      Scopes:

    • https://www.googleapis.com/auth/cloud-platform
    • https://www.googleapis.com/auth/source.full_control
    • Description: Sets the IAM policy on the specified resource. Replaces any existing policy.

  • sourcerepo.projects.repos.getIamPolicy

      Path: v1/{+resource}:getIamPolicy

      Flat Path: v1/projects/{projectsId}/repos/{reposId}:getIamPolicy

      HTTP Method: GET

      Parameters:

        resource

          Description: REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.

          Pattern: ^projects/[^/]+/repos/.*$

          Location: path

          Required: Yes

          Type: string

        options.requestedPolicyVersion

          Description: Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).

          Location: query

          Type: integer

          Format: int32

      Parameter Order: resource

      Scopes:

    • https://www.googleapis.com/auth/cloud-platform
    • https://www.googleapis.com/auth/source.full_control
    • https://www.googleapis.com/auth/source.read_only
    • https://www.googleapis.com/auth/source.read_write
    • Description: Gets the IAM policy policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

  • sourcerepo.projects.repos.testIamPermissions