---
title: "Update repository path limitation for a team"
method: POST
path: "/teams/{team_id}/updateRepoPathLimitation"
---

# Update repository path limitation for a team

`POST /teams/{team_id}/updateRepoPathLimitation`

## Request

- Base URL: `https://app.aikido.dev/api/public/v1`
- URL: `https://app.aikido.dev/api/public/v1/teams/{team_id}/updateRepoPathLimitation`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `https://app.aikido.io/api/oauth/token` scopes: `teams:write`

Update the path limitations for a repository that is already linked to a team. This works for both manually created and imported teams (e.g. GitHub teams), and does not change which resources are linked to the team.

## Path parameters

- `team_id` integer, required

## Request body

- object
  - `repo_id` integer, required: The id of a repository already linked to the team.
  - `repo_path_limitation` object, required: Object to define the path limitations for the repo
    - `limitation_type` 'include' | 'exclude', required: Whether the paths are included or excluded
    - `paths` string[], required: The paths to include or exclude. Pass an empty array to clear path limitations.

## Response `200`

The repository path limitation has successfully been updated

- object
  - `status` string: ok indicating success

## Other responses

- `400`: One or more of the provided fields are invalid, or the repository is not linked to the team.
- `404`: The team or repository was not found.

---

[API](https://skmtc.dev/aikido/apis/aikido-security-api-documentation.md) - [All operations](https://skmtc.dev/aikido/apis/aikido-security-api-documentation/llms.txt) - [OpenAPI document](https://skmtc.dev/aikido/apis/aikido-security-api-documentation/revisions/da8691338133?raw)
