List onboarded repositories for an organization
curl --request GET \
--url https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories \
--header 'x-coderabbitai-api-key: <api-key>'import requests
url = "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories"
headers = {"x-coderabbitai-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-coderabbitai-api-key': '<api-key>'}};
fetch('https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-coderabbitai-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-coderabbitai-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories")
.header("x-coderabbitai-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-coderabbitai-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"repositories": [
{
"repository_id": "<string>",
"repository_name": "acme/backend",
"private": true,
"group_path": "<string>",
"is_installed": true
}
],
"next_cursor": "<string>"
}List organization repositories
Lists repositories that CodeRabbit currently records as active for an organization. The organization_id is the CodeRabbit organization UUID returned by GET /organizations. Enterprise plan only.
GET
/
v1
/
organizations
/
{organization_id}
/
repositories
List onboarded repositories for an organization
curl --request GET \
--url https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories \
--header 'x-coderabbitai-api-key: <api-key>'import requests
url = "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories"
headers = {"x-coderabbitai-api-key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'x-coderabbitai-api-key': '<api-key>'}};
fetch('https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"x-coderabbitai-api-key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("x-coderabbitai-api-key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories")
.header("x-coderabbitai-api-key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.coderabbit.ai/v1/organizations/{organization_id}/repositories")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["x-coderabbitai-api-key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"repositories": [
{
"repository_id": "<string>",
"repository_name": "acme/backend",
"private": true,
"group_path": "<string>",
"is_installed": true
}
],
"next_cursor": "<string>"
}Requires the
repository_management:read permission. Workspace API key owners must also remain workspace admins.Organization scope
Use the CodeRabbit organization UUID returned in theid field from GET /v1/organizations as organization_id. Do not use the Git provider identifier from provider_organization_id.
| API key type | Allowed organization |
|---|---|
| Organization | Only the active organization bound to the API key. |
| Workspace | Any active organization in the workspace. |
Installation status
Useis_installed to identify repositories that CodeRabbit currently records as installed. The value reflects cached state, so recent provider-side changes may not appear immediately.
Pagination
Whennext_cursor is not null, pass it in the next request’s cursor query parameter. The cursor retains the original page size, so you can omit limit from subsequent requests. If you include limit, it must match the value used for the first request.
Rate limit
This endpoint is limited to 10 requests per minute.Authorizations
API key for authentication. You can create an API key from the CodeRabbit dashboard.
Headers
User-scoped organization or workspace API key.
Path Parameters
Query Parameters
Required range:
1 <= x <= 100Opaque pagination cursor returned by the previous page.
Was this page helpful?