SellGate API

Feedback API

Manage customer reviews and feedback

Feedback API

Access customer feedback and reviews, including ratings and replies.

Endpoints Overview

MethodEndpointDescription
GET/v1/feedbackList all feedback
GET/v1/feedback/:idGet single feedback
POST/v1/feedback/:id/replyReply to feedback

List Feedback

GET /v1/feedback

Query Parameters

ParameterTypeDescription
pageintegerPage number (default: 1)
limitintegerItems per page (default: 25, max: 100)
ratingintegerFilter by rating (1-5)
has_replystringFilter by reply status (true/false)
product_idstringFilter by product ID

Response

{
  "data": [
    {
      "id": "fb_abc123",
      "rating": 5,
      "comment": "Great product, instant delivery!",
      "is_auto_feedback": false,
      "seller_reply": null,
      "seller_reply_at": null,
      "buyer_email": "customer@example.com",
      "order_id": "ord_xyz789",
      "product_id": "prod_def456",
      "product_name": "Premium License",
      "created_at": "2025-01-20T15:00:00Z"
    }
  ],
  "stats": {
    "total": 156,
    "average": 4.7,
    "positive": 140,
    "negative": 16,
    "needsReply": 12
  },
  "meta": {
    "total": 156,
    "limit": 25,
    "offset": 0
  }
}

Example Request

curl -X GET "https://api.sellgate.cc/v1/feedback?rating=5" \
  -H "Authorization: Bearer sg_live_your_api_key"

Filter Unreplied Feedback

curl -X GET "https://api.sellgate.cc/v1/feedback?has_reply=false" \
  -H "Authorization: Bearer sg_live_your_api_key"

Get Feedback

GET /v1/feedback/:id

Reply to Feedback

POST /v1/feedback/:id/reply

Request Body

{
  "reply": "Thank you for your kind words! We're glad you enjoyed the product."
}

Example Request

curl -X POST "https://api.sellgate.cc/v1/feedback/fb_abc123/reply" \
  -H "Authorization: Bearer sg_live_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "reply": "Thank you for your feedback!"
  }'

Feedback Stats

The list endpoint includes aggregate statistics:

FieldDescription
totalTotal number of reviews
averageAverage rating (1-5)
positiveReviews with rating >= 4
negativeReviews with rating < 4
needsReplyReviews without a seller reply

Feedback Object

FieldTypeDescription
idstringFeedback identifier
ratingintegerRating (1-5 stars)
commentstringCustomer comment
is_auto_feedbackbooleanWhether feedback was auto-generated
seller_replystringSeller's reply text
seller_reply_atstringReply timestamp
buyer_emailstringCustomer email
order_idstringAssociated order ID
product_idstringAssociated product ID
product_namestringProduct name
created_atstringSubmission timestamp

On this page