---
title: "Get code repository detail"
method: GET
path: "/repositories/code/{code_repo_id}"
---

# Get code repository detail

`GET /repositories/code/{code_repo_id}`

## Request

- Base URL: `https://app.aikido.dev/api/public/v1`
- URL: `https://app.aikido.dev/api/public/v1/repositories/code/{code_repo_id}`
- Auth: OAuth 2
  - Client credentials
  - Token URL: `https://app.aikido.io/api/oauth/token` scopes: `repositories:read`

Returns the details of a code repository

## Path parameters

- `code_repo_id` integer, required

## Response `200`

A code repository

- object
  - `id` integer, required: The repository's id in Aikido.
  - `name` string, required: The name of the code repository.
  - `provider` 'github' | 'gitlab' | 'gitlab-server' | 'bitbucket' | 'azure_devops' | 'selfscan', required: The place where the code repository is hosted
  - `external_repo_id` string: The id of the repository from the provider.
  - `external_repo_numeric_id` integer: The numeric id of the repository from the provider.
  - `active` boolean: Indicates if this repository is currently active.
  - `branch` string, required: The branch set up to scan in the repository.
  - `url` string: External URL to the repo
  - `last_scanned_at` integer: A timestamp indicating when the repository was last scanned. Value will be -1 if no scan has occurred.
  - `linked_teams` object[]: List of teams linked to this code repository.
    - `id` integer: The team's id.
    - `name` string: The name of the team.
  - `excluded_paths` object[]: List of excluded paths in this code repository.
    - `id` integer: The id of the excluded path.
    - `path` string: The path that is excluded.
  - `connectivity` 'connected' | 'not_connected' | 'unknown': Tells Aikido if this code runs in an internet-connected server.
  - `sensitivity` 'extreme' | 'sensitive' | 'normal' | 'not_sensitive' | 'no_data': The sensitivity of the repository.
  - `labels` object[]: List of labels for this code repository.
    - `id` integer: The label's id.
    - `name` string: The name of the label.
    - `is_imported` boolean: Indicates if this label was imported from the provider.

---

[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)
