Gen-Endpoint

Free Comments & Reviews API — Mock REST API for Testing & Development

Social
3 Endpoints
Live & Active

Simulates blog and product comments, threaded replies, moderation flags, and rating submissions with full CRUD capabilities.

Internal API - Hosted by Gen-Endpoint

Interactive Live API Explorer

Explore, configure parameters, and execute live HTTP requests directly in your browser. All routes are active!
POST

/api/comments

Create new comment or review with rating.

Try it live in browser
GET

/api/comments/{resourceId}

Get comments for resource with threading and pagination. Replace {resourceId} with an actual ID.

Try it live in browser

Replace placeholders (e.g., {userId}) with actual values in the path above. You can also add/edit query parameters (e.g., ?key=value).

PUT

/api/comments/{commentId}/moderate

Moderate comment - approve, reject, or flag. Replace {commentId} with an actual ID.

Try it live in browser

Replace placeholders (e.g., {userId}) with actual values in the path above.

Code Integration Examples

Copy ready-to-use cURL commands and JavaScript Fetch snippets directly into your projects or testing tools.
Standard Fetch API (Browser & Node.js 18+)
// Free Comments & Reviews API - JavaScript Fetch Example
async function fetchCommentsReviewsAPI() {
  try {
    const response = await fetch('https://gen-endpoint.com/api/comments', {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
      },
      body: JSON.stringify({
  "resourceType": "post",
  "resourceId": "post_123",
  "content": "Great article! Very helpful.",
  "rating": 5,
  "parentId": null
}),
    });

    if (!response.ok) {
      throw new Error(`HTTP error! status: ${response.status}`);
    }

    const data = await response.json();
    console.log('Success:', data);
    return data;
  } catch (error) {
    console.error('Fetch error:', error);
  }
}

fetchCommentsReviewsAPI();

Sample JSON Response

{
  "id": "comment_456",
  "content": "Great article! Very helpful.",
  "author": {"id": "usr_2", "name": "Bob Builder"},
  "rating": 5,
  "status": "pending_moderation",
  "createdAt": "2024-08-16T12:00:00Z"
}

Common Developer Use Cases

How developers integrate the Comments & Reviews API during rapid frontend prototyping and automated testing.

Testing comment feed components and reply nesting.

Prototyping star rating submission forms.

Related Free REST APIs

Explore complementary mock endpoints to chain and test full application workflows.

Blog & CMS API

Content

Manage blog posts, categories, tags, content publishing, and SEO metadata.

View API

User Management API

Application

A comprehensive API for managing user accounts, including CRUD operations.

View API

Notification System API

Communication

Send emails, SMS, and push notifications with template support and delivery tracking.

View API

Frequently Asked Questions

Can I test nested replies?

Yes, comment objects include parentId references to simulate threaded conversations.