Get feedback
Returns paginated user feedback with optional filtering
Authenticate with an admin API key.
Use this endpoint to export user feedback collected from your documentation. Feedback includes contextual feedback from page ratings, code snippet feedback, and agent feedback.
Paginate through results using the cursor parameter returned in the response. Continue fetching while hasMore is true.
Filtering
Section titled “Filtering”Filter feedback by:
- Date range: Use
dateFromanddateToto limit results to a specific time period - Source: Filter by
code_snippet,contextual, oragentfeedback types - Status: Filter by status values like
pending,in_progress,resolved, ordismissed
Response types
Section titled “Response types”The response contains different feedback types based on the source:
- Contextual feedback: Includes
helpfulboolean and optionalcontactemail - Code snippet feedback: Includes
code,filename, andlangfields - Agent feedback: Includes a
commentwith the agent's feedback text and thepathof the page it relates to
Rate limits
Section titled “Rate limits”This endpoint allows 100 requests per organization per hour. All analytics endpoints share this limit.
OpenAPI
Related topics
/v1/analytics/{projectId}/feedbackGet user feedback
7 parameters
- projectIdstringpathrequired
- dateFromstringquery
- dateTostringquery
- sourcestringquery
- statusstringquery
- limitnumberquery
- cursorstringquery
curl --request GET \
--url https://api.mintlify.com/v1/analytics/{projectId}/feedback \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.mintlify.com/v1/analytics/{projectId}/feedback"
headers = {
"Authorization": "Bearer <token>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: "GET", headers: {"Authorization": "Bearer <token>"}};
fetch("https://api.mintlify.com/v1/analytics/{projectId}/feedback", 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.mintlify.com/v1/analytics/{projectId}/feedback",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$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.mintlify.com/v1/analytics/{projectId}/feedback"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
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.mintlify.com/v1/analytics/{projectId}/feedback")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.mintlify.com/v1/analytics/{projectId}/feedback")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"feedback": [
{
"id": "<string>",
"path": "<string>",
"comment": "<string>",
"createdAt": "<string>",
"source": "code_snippet",
"status": "pending",
"helpful": true,
"contact": "<string>"
}
],
"nextCursor": "<string>",
"hasMore": true
}{
"error": "<string>",
"details": [
{
"message": "<string>"
}
]
}{
"error": "<string>",
"details": [
{
"message": "<string>"
}
]
}Authorizations
Section titled “Authorizations”AuthorizationstringrequiredThe Authorization header expects a Bearer token. Use an admin API key. This is a server-side secret key. Generate one on the API keys page in your dashboard.
Path Parameters
Section titled “Path Parameters”projectIdstringrequiredQuery Parameters
Section titled “Query Parameters”dateFrom?stringExample: 2024-01-01
dateTo?stringExample: 2024-01-01
source?enum<string>Available options: code_snippet, contextual, agent, thumbs_only
status?stringlimit?numberRequired range: 1 <= x <= 100
cursor?stringResponse
Section titled “Response”200 — Feedback data with pagination
feedbackobject[]requiredList of feedback entries.
Show child attributes
idstringrequiredUnique feedback identifier.
pathstringrequiredThe path or URL to the source document.
commentstring | nullrequiredText of the user's feedback comment.
createdAtstring | nullrequiredTimestamp when the feedback was submitted.
sourceenum<string>requiredWhere the feedback originated. code_snippet is feedback on a code block, contextual is page-level feedback, agent is feedback submitted by a third-party AI agent, thumbs_only is a thumbs up/down vote.
Available options: code_snippet, contextual, agent, thumbs_only
statusenum<string>requiredCurrent review status of the feedback.
Available options: pending, in_progress, resolved, dismissed
helpfulbooleanrequiredWhether the user found the content helpful.
contactstring | nullrequiredEmail address the user provided for follow-up.
nextCursorstring | nullrequiredCursor to retrieve the next page of results. Null if no more results.
hasMorebooleanrequiredWhether additional results are available beyond this page.