API Reference
The Miniback API allows you to programmatically access and manage feedback and projects. The API provides comprehensive CRUD operations for both feedback and projects, with plan-based access control.
⚡ Quick Start
- Get API key: Project Settings → API Access → Generate Key
 - Test endpoint:
 curl -H "x-api-key: YOUR_KEY" https://your-domain.com/api/projects- See API Security Guide for best practices
 Plans: FREE (POST only) • STARTER (full CRUD, 10k calls/mo) • PRO (unlimited)
Plan-Based Access
| Plan | Access Level | Endpoints | Rate Limit | 
|---|---|---|---|
| FREE | Limited | POST feedback only | 300 calls/month | 
| STARTER | Full | All CRUD operations | 10,000 calls/month | 
| PRO | Full | All CRUD operations | Unlimited | 
Authentication
Getting Your API Key
- Sign in to your Miniback dashboard
 - Navigate to your project page
 - Scroll to the “API Access” section
 - Click “Generate API Key” if you don’t have one
 - Copy your API key (starts with 
mbk_) 
Using Your API Key
Header Authentication (Recommended):
curl -H "x-api-key: your_api_key_here" \
  https://your-domain.com/api/projects/PROJECT_ID/feedbackQuery Parameter Authentication:
curl "https://your-domain.com/api/projects/PROJECT_ID/feedback?api_key=your_api_key_here"Endpoints
Projects
List All Projects
Get all projects for the authenticated user.
GET /api/projectsAuthentication Required: API key (STARTER/PRO plans only)
Example Request:
curl -H "x-api-key: mbk_abc123..." \
  "https://your-domain.com/api/projects"Example Response:
{
  "data": [
    {
      "id": "proj_123",
      "name": "My Website",
      "slug": "my-website",
      "status": "ACTIVE",
      "createdAt": "2025-01-01T12:00:00.000Z",
      "updatedAt": "2025-01-01T12:00:00.000Z"
    }
  ]
}Get Project by ID
Get a specific project by ID.
GET /api/projects/{projectId}Authentication Required: API key (STARTER/PRO plans only)
Create Project
Create a new project.
POST /api/projectsAuthentication Required: API key (STARTER/PRO plans only)
Request Body:
{
  "name": "New Project",
  "slug": "new-project" // optional
}Update Project
Update an existing project.
PUT /api/projects/{projectId}Authentication Required: API key (STARTER/PRO plans only)
Request Body:
{
  "name": "Updated Project Name",
  "slug": "updated-slug" // optional
}Delete Project
Delete a project and all its feedback.
DELETE /api/projects/{projectId}Authentication Required: API key (STARTER/PRO plans only)
Note: This permanently deletes the project and all associated feedback.
Manage API Keys
Get or regenerate API key for a project.
GET /api/projects/{projectId}/api-key
POST /api/projects/{projectId}/api-keyAuthentication Required: API key (STARTER/PRO plans only)
Feedback
List All Feedback
Get all feedback across all projects for the authenticated user.
GET /api/feedbackAuthentication Required: Session (web UI) or API key (STARTER/PRO plans only)
Query Parameters:
projectorprojectSlug: Filter by specific projectstatus: Filter by status (NEW,REVIEWED,RESOLVED)source: Filter by source (WIDGET,API)search: Search in feedback messagesstart,end: Date range filter (ISO format)page: Page number (default: 1)pageSize: Items per page (default: 10, max: 100)
Example Request:
curl -H "x-api-key: mbk_abc123..." \
  "https://your-domain.com/api/feedback?status=NEW&pageSize=20"Get Feedback by ID
Get a specific feedback item by ID.
GET /api/feedback/{id}Authentication Required: API key (STARTER/PRO plans only)
Example Response:
{
  "data": {
    "id": "feedback_456",
    "message": "Great product! Love the new features.",
    "context": {
      "url": "https://example.com/page",
      "userAgent": "Mozilla/5.0..."
    },
    "status": "NEW",
    "source": "WIDGET",
    "createdAt": "2025-01-01T12:00:00.000Z",
    "updatedAt": "2025-01-01T12:00:00.000Z",
    "project": {
      "id": "proj_123",
      "name": "My Website",
      "slug": "my-website"
    }
  }
}Update Feedback Status
Update the status of a feedback item.
PUT /api/feedback/{id}Authentication Required: API key (STARTER/PRO plans only)
Request Body:
{
  "status": "RESOLVED"
}Valid Status Values:
NEWREVIEWEDRESOLVED
Delete Feedback
Delete a feedback item.
DELETE /api/feedback/{id}Authentication Required: API key (STARTER/PRO plans only)
Get Project Feedback
Retrieve feedback for a specific project.
GET /api/projects/{projectId}/feedbackQuery Parameters:
status(optional): Filter by status (NEW,REVIEWED,RESOLVED)limit(optional): Number of items to return (default: 50, max: 100)offset(optional): Number of items to skip for pagination (default: 0)
Example Request:
curl -H "x-api-key: mbk_abc123..." \
  "https://your-domain.com/api/projects/proj_123/feedback?status=NEW&limit=10"Example Response:
{
  "data": [
    {
      "id": "feedback_456",
      "message": "Great product! Love the new features.",
      "context": {
        "url": "https://example.com/page",
        "userAgent": "Mozilla/5.0...",
        "timestamp": "2025-01-01T12:00:00.000Z"
      },
      "status": "NEW",
      "createdAt": "2025-01-01T12:00:00.000Z"
    }
  ],
  "pagination": {
    "total": 42,
    "limit": 10,
    "offset": 0,
    "hasMore": true
  }
}Create Feedback
Submit new feedback to a project programmatically.
POST /api/projects/{projectId}/feedbackAuthentication Required: API key (all plans, including FREE)
Request Body:
{
  "message": "This is feedback about your product",
  "context": {
    "url": "https://example.com/page",
    "userAgent": "Mozilla/5.0...",
    "custom_field": "any additional data"
  }
}Required Fields:
message(string): The feedback message
Optional Fields:
context(object): Additional metadata about the feedback
Example Request:
curl -X POST \
  -H "x-api-key: mbk_abc123..." \
  -H "Content-Type: application/json" \
  -d '{"message": "Bug found on checkout page", "context": {"url": "https://example.com/checkout"}}' \
  https://your-domain.com/api/projects/proj_123/feedbackExample Response:
{
  "data": {
    "id": "feedback_789",
    "message": "Bug found on checkout page",
    "context": {
      "url": "https://example.com/checkout"
    },
    "status": "NEW",
    "createdAt": "2025-01-01T12:00:00.000Z"
  }
}Error Responses
401 Unauthorized
{
  "error": "API key is required. Provide it via 'x-api-key' header or 'api_key' query parameter."
}{
  "error": "GET requests are available on paid plans only. FREE plan users can only POST feedback. Upgrade to STARTER or PRO for full API access."
}403 Forbidden
{
  "error": "Invalid API key or project not found"
}{
  "error": "Project limit reached. Upgrade your plan to create more projects."
}404 Not Found
{
  "error": "Project not found"
}{
  "error": "Feedback not found"
}400 Bad Request
{
  "error": "Message is required and must be a string"
}500 Internal Server Error
{
  "error": "Internal server error"
}Rate Limits
Plan-based API limits:
- FREE Plan: 300 API calls per month (POST feedback only)
 - STARTER Plan: 10,000 API calls per month (all endpoints)
 - PRO Plan: Unlimited API calls (all endpoints)
 
Pagination
For endpoints that return multiple items, use the limit and offset parameters:
limit: Number of items per page (max: 100, default: 50)offset: Number of items to skiphasMore: Boolean indicating if there are more items
Example pagination:
# First page
GET /api/projects/proj_123/feedback?limit=25&offset=0
 
# Second page
GET /api/projects/proj_123/feedback?limit=25&offset=25
 
# Third page
GET /api/projects/proj_123/feedback?limit=25&offset=50Use Cases
Custom Dashboard
// Fetch recent feedback for dashboard
async function getFeedback() {
  const response = await fetch("/api/projects/proj_123/feedback?limit=10", {
    headers: {
      "x-api-key": "mbk_your_key_here",
    },
  });
  const data = await response.json();
  return data.data;
}Webhook Integration
// Submit feedback from your own form
async function submitFeedback(message, pageUrl) {
  const response = await fetch("/api/projects/proj_123/feedback", {
    method: "POST",
    headers: {
      "x-api-key": "mbk_your_key_here",
      "Content-Type": "application/json",
    },
    body: JSON.stringify({
      message,
      context: { url: pageUrl },
    }),
  });
  return response.json();
}Analytics Integration
import requests
 
# Python example for analytics
def get_feedback_stats():
    headers = {'x-api-key': 'mbk_your_key_here'}
 
    # Get all feedback statuses
    statuses = ['NEW', 'REVIEWED', 'RESOLVED']
    stats = {}
 
    for status in statuses:
        response = requests.get(
            f'/api/projects/proj_123/feedback?status={status}&limit=1',
            headers=headers
        )
        data = response.json()
        stats[status] = data['pagination']['total']
 
    return statsSecurity
- Keep your API key secure: Never expose it in client-side code
 - Use HTTPS: Always use HTTPS in production
 - Rotate keys: Regenerate API keys periodically
 - Monitor usage: Check your API usage in the dashboard
 
See the API Security Guide for detailed best practices.
Related Documentation
- API Security Best Practices - Secure API usage
 - Security - Domain restrictions and security features
 - Troubleshooting - Common issues and solutions
 
Need help? Contact support through your Miniback dashboard.