GeezerVison is showing docs.coderabbit.ai — Post apiv1reportgenerate - CodeRabbit curl --request POST \
--url https://api.coderabbit.ai/api/v1/report.generate \
--header 'Content-Type: application/json' \
--header 'x-coderabbitai-api-key: <api-key>' \
--data '
{
"from": "2024-05-01",
"to": "2024-05-15"
}
'
import requests
url = "https://api.coderabbit.ai/api/v1/report.generate"
payload = {
"from": "2024-05-01",
"to": "2024-05-15"
}
headers = {
"x-coderabbitai-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
const options = {
method: 'POST',
headers: {'x-coderabbitai-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({from: '2024-05-01', to: '2024-05-15'})
};
fetch('https://api.coderabbit.ai/api/v1/report.generate', 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/api/v1/report.generate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'from' => '2024-05-01',
'to' => '2024-05-15'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.coderabbit.ai/api/v1/report.generate"
payload := strings.NewReader("{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-coderabbitai-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
HttpResponse<String> response = Unirest.post("https://api.coderabbit.ai/api/v1/report.generate")
.header("x-coderabbitai-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}")
.asString();
require 'uri'
require 'net/http'
url = URI("https://api.coderabbit.ai/api/v1/report.generate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-coderabbitai-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}"
response = http.request(request)
puts response.read_body
[
{
"group": "Developer Activity",
"report": "*Developer Activity*:\n\n 🟢 **Update README.md** [#10](https://gitlab.com/master-group123/sub-group/project1/-/merge_requests/10)\n• Summary: The change updates the project description and modifies a section header for clearer instructions.\n• Last activity: 1 day ago, mergeable\n• Insights:\n - :magnifying_glass: @user2 Suggested updating the wording to make it clearer"
}
]
{
"errors": [
{
"code": "INVALID_PARAMETER",
"message": "start_date: start_date is required"
}
]
}
{
"message": "Invalid or missing API key",
"code": "UNAUTHORIZED"
}
{
"message": "API access requires a Pro plan subscription",
"code": "FORBIDDEN"
}
{
"message": "Rate limit exceeded. Please retry after 60 seconds.",
"code": "RATE_LIMITED"
}
curl --request POST \
--url https://api.coderabbit.ai/api/v1/report.generate \
--header 'Content-Type: application/json' \
--header 'x-coderabbitai-api-key: <api-key>' \
--data '
{
"from": "2024-05-01",
"to": "2024-05-15"
}
'
import requests
url = "https://api.coderabbit.ai/api/v1/report.generate"
payload = {
"from": "2024-05-01",
"to": "2024-05-15"
}
headers = {
"x-coderabbitai-api-key": "<api-key>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)
const options = {
method: 'POST',
headers: {'x-coderabbitai-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({from: '2024-05-01', to: '2024-05-15'})
};
fetch('https://api.coderabbit.ai/api/v1/report.generate', 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/api/v1/report.generate",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'from' => '2024-05-01',
'to' => '2024-05-15'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"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"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.coderabbit.ai/api/v1/report.generate"
payload := strings.NewReader("{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("x-coderabbitai-api-key", "<api-key>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}
HttpResponse<String> response = Unirest.post("https://api.coderabbit.ai/api/v1/report.generate")
.header("x-coderabbitai-api-key", "<api-key>")
.header("Content-Type", "application/json")
.body("{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}")
.asString();
require 'uri'
require 'net/http'
url = URI("https://api.coderabbit.ai/api/v1/report.generate")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["x-coderabbitai-api-key"] = '<api-key>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"from\": \"2024-05-01\",\n \"to\": \"2024-05-15\"\n}"
response = http.request(request)
puts response.read_body
[
{
"group": "Developer Activity",
"report": "*Developer Activity*:\n\n 🟢 **Update README.md** [#10](https://gitlab.com/master-group123/sub-group/project1/-/merge_requests/10)\n• Summary: The change updates the project description and modifies a section header for clearer instructions.\n• Last activity: 1 day ago, mergeable\n• Insights:\n - :magnifying_glass: @user2 Suggested updating the wording to make it clearer"
}
]
{
"errors": [
{
"code": "INVALID_PARAMETER",
"message": "start_date: start_date is required"
}
]
}
{
"message": "Invalid or missing API key",
"code": "UNAUTHORIZED"
}
{
"message": "API access requires a Pro plan subscription",
"code": "FORBIDDEN"
}
{
"message": "Rate limit exceeded. Please retry after 60 seconds.",
"code": "RATE_LIMITED"
}
API key for authentication. You can create an API key from the CodeRabbit dashboard. Start date for the report in ISO 8601 format (YYYY-MM-DD) End date for the report in ISO 8601 format (YYYY-MM-DD) Custom prompt to specify what information should be included in the report and how it should be formatted Pre-defined template for the report format Available options: Daily Standup Report,
Sprint Report,
Release Notes,
Custom
Array of filter parameters to narrow down the report scope Primary grouping for the report Available options: NONE,
REPOSITORY,
LABEL,
TEAM,
USER,
SOURCEBRANCH,
TARGETBRANCH,
STATE
Secondary grouping for the report Available options: NONE,
REPOSITORY,
LABEL,
TEAM,
USER,
SOURCEBRANCH,
TARGETBRANCH,
STATE
Organization ID (optional) The name of the report group The formatted report content as a markdown string |