---
title: list-git-repositories-linked-to-namespace-by-provider
product: vercel
url: /docs/rest-api/integrations/list-git-repositories-linked-to-namespace-by-provider
type: reference
prerequisites:
  []
related:
  - /docs/rest-api
summary: Learn about list-git-repositories-linked-to-namespace-by-provider on Vercel.
install_vercel_plugin: npx plugins add vercel/vercel-plugin
---

# List git repositories linked to namespace by provider

```http
GET /v1/integrations/search-repo
```

Lists git repositories linked to a namespace `id` for a supported provider. A specific namespace `id` can be obtained via the `git-namespaces`  endpoint. Supported providers are `github`, `gitlab` and `bitbucket`. If the provider or namespace is not provided, it will try to obtain it from the user that authenticated the request.

## Authentication

**bearerToken**: HTTP bearer

## Query parameters

| Name | Type | Required | Description |
|---|---|---|---|
| `query` | string | No |  |
| `namespaceId` | object, nullable | No |  |
| `provider` | object. enum: github, github-limited, github-custom-host, gitlab, bitbucket | No |  |
| `installationId` | string | No |  |
| `host` | string | No | The custom Git host if using a custom Git provider, like GitHub Enterprise Server |
| `teamId` | string | No | The Team identifier to perform the request on behalf of. |
| `slug` | string | No | The Team slug to perform the request on behalf of. |


## Responses

### 200: No description

Content-Type: `application/json`

```json
{
  "oneOf": [
    {
      "type": "object"
    },
    {
      "type": "object",
      "required": [
        "gitAccount",
        "repos"
      ],
      "properties": {
        "gitAccount": {
          "type": "object",
          "required": [
            "namespaceId",
            "provider"
          ],
          "properties": {
            "provider": {
              "type": "string",
              "enum": [
                "github",
                "github-limited",
                "github-custom-host",
                "gitlab",
                "bitbucket",
                "vercel"
              ]
            },
            "namespaceId": {
              "nullable": true,
              "oneOf": [
                {
                  "type": "string"
                },
                {
                  "type": "number"
                }
              ]
            }
          }
        },
        "repos": {
          "type": "array",
          "items": {
            "type": "object",
            "required": [
              "defaultBranch",
              "id",
              "name",
              "namespace",
              "owner",
              "ownerType",
              "private",
              "provider",
              "slug",
              "updatedAt",
              "url"
            ],
            "properties": {
              "id": {
                "oneOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "number"
                  }
                ]
              },
              "provider": {
                "type": "string",
                "enum": [
                  "github",
                  "github-limited",
                  "github-custom-host",
                  "gitlab",
                  "bitbucket",
                  "vercel"
                ]
              },
              "url": {
                "type": "string"
              },
              "name": {
                "type": "string"
              },
              "slug": {
                "type": "string"
              },
              "namespace": {
                "type": "string"
              },
              "owner": {
                "type": "object",
                "required": [
                  "id",
                  "name"
                ],
                "properties": {
                  "id": {
                    "oneOf": [
                      {
                        "type": "string"
                      },
                      {
                        "type": "number"
                      }
                    ]
                  },
                  "name": {
                    "type": "string"
                  }
                }
              },
              "ownerType": {
                "type": "string",
                "enum": [
                  "user",
                  "team"
                ]
              },
              "private": {
                "type": "boolean",
                "enum": [
                  false,
                  true
                ]
              },
              "defaultBranch": {
                "type": "string"
              },
              "updatedAt": {
                "type": "number"
              }
            }
          }
        }
      }
    }
  ]
}
```

### 400: One of the provided values in the request query is invalid.

### 401: No description

### 403: You do not have permission to access this resource.

### 404: No description

### 429: No description

### 500: No description

---

## Related

- [integrations endpoints](/docs/rest-api#integrations)

- [REST API overview](/docs/rest-api)

- [OpenAPI spec](https://openapi.vercel.sh/) (machine-readable, all endpoints)

---

[View full sitemap](/docs/sitemap)
