Hoppa till innehållet

Recensioner

Product reviews: read the approved ones, submit a new one. Submissions are anonymous-capable and go through moderation before they appear.

3 anrop GET POST Bas-URL https://api.erp.fluit.cloud/ecom

Autentisering, felkoder, rate limits, idempotens och paginering gäller alla anrop och står samlade under Kom igång.

GET /catalog/products/{idOrSlug}/reviews

Get product reviews

Returns a page of approved reviews plus a rating summary (average and distribution) covering all approved reviews for the product on this channel. Answers 404 ( ProductReview.Disabled ) when the channel has product reviews turned off; channel.features.productReviewsEnabled in the session says so in advance.

Sökvägsparametrar

Fält Typ
idOrSlug Krävs string

Frågeparametrar

Fält Typ
page integer
pageSize integer
sort string

Svar

200 ProductReviewsResponse
Fält Typ
hasMore boolean
items ProductReview[] · nullable
page integer
pageSize integer
summary ProductReviewSummary
429 Rate limit exceeded. Wait the number of seconds given in Retry-After. The body is problem-shaped application/json, not application/problem+json. This API sends no X-RateLimit-* headers — the quota is discovered here.
  • Retry-After — Seconds to wait before retrying.

Standardfel: 404 Felhantering

Exempel

curl
curl "https://api.erp.fluit.cloud/ecom/catalog/products/{idOrSlug}/reviews" \
  -H "X-Tenant-Id: $FLUIT_TENANT_ID" \
  -H "X-Channel: web"
Svar 200
{
  "hasMore": true,
  "items": [
    {
      "author": "string",
      "date": "2026-06-11T09:24:13.418",
      "id": "0f8b2c1e-4d3a-4b7e-9f10-2a6c5d8e1b44",
      "isVerifiedPurchase": true,
      "rating": 42,
      "text": "string",
      "title": "string"
    }
  ],
  "page": 1,
  "pageSize": 50,
  "summary": {
    "averageRating": "299.00",
    "distribution": [
      42
    ],
    "totalCount": 137
  }
}

Bas-URL https://api.erp.fluit.cloud/ecom. Svarsexemplet är genererat ur schemat: formen stämmer, värdena är påhittade.

POST /catalog/products/{idOrSlug}/reviews

Submit product review

Submits a review for a product on the current channel. The review is always created as pending and is not visible until a moderator approves it. Answers 404 ( ProductReview.Disabled ) when the channel has product reviews turned off ( channel.features.productReviewsEnabled ).

Sökvägsparametrar

Fält Typ
idOrSlug Krävs string

Body krävs

Fält Typ
authorEmail string · nullable
authorName string · nullable
body string · nullable
captchaToken string · nullable
formLoadedAtUnixMs integer · nullable
honeypot string · nullable
rating integer
title string · nullable

Svar

200 SubmitProductReviewResponse
Fält Typ
isVerifiedPurchase boolean
requiresModeration boolean
reviewId string(uuid)

Standardfel: 400 404 409 429 Felhantering

Exempel

curl
curl -X POST "https://api.erp.fluit.cloud/ecom/catalog/products/{idOrSlug}/reviews" \
  -H "Authorization: Bearer $SESSION_TOKEN" \
  -H "X-Tenant-Id: $FLUIT_TENANT_ID" \
  -H "X-Channel: web" \
  -H "Content-Type: application/json" \
  -d @body.json
Svar 200
{
  "isVerifiedPurchase": true,
  "requiresModeration": true,
  "reviewId": "0f8b2c1e-4d3a-4b7e-9f10-2a6c5d8e1b44"
}

Bas-URL https://api.erp.fluit.cloud/ecom. Svarsexemplet är genererat ur schemat: formen stämmer, värdena är påhittade.

GET /reviews/platform

Get the channel's review platform and rating

Returns the review platform the channel is connected to (Trustpilot), the shop's id there, its profile page, the platform's own widget (script and one template per style) and — when the channel uses the platform's API — the rating: score, stars and number of reviews.

Visa hela beskrivningen

Render the rating with the platform's widget: Trustpilot's brand guidelines allow only its own widgets (TrustBoxes) to show the TrustScore. The widget sets no cookies. The rating is refreshed at least hourly and is null when the platform did not answer. Answers 404 Channel.ReviewPlatformNotConnected when the channel has no review platform; widget is null until the channel has chosen its shop on the platform.

Stödjer ETag

Svar

200 EcomReviewPlatformResponse
Fält Typ
businessUnitId string · nullable
profileUrl string · nullable
provider string · nullable
rating ReviewPlatformRating
widget ReviewPlatformWidget
304 Tom body.
429 Rate limit exceeded. Wait the number of seconds given in Retry-After. The body is problem-shaped application/json, not application/problem+json. This API sends no X-RateLimit-* headers — the quota is discovered here.
  • Retry-After — Seconds to wait before retrying.

Standardfel: 404 Felhantering

Exempel

curl
curl "https://api.erp.fluit.cloud/ecom/reviews/platform" \
  -H "X-Tenant-Id: $FLUIT_TENANT_ID" \
  -H "X-Channel: web"
Svar 200
{
  "businessUnitId": "string",
  "profileUrl": "https://cdn.fluit.cloud/assets/widget-a-front.jpg",
  "provider": "string",
  "rating": {
    "fetchedAt": "2026-06-11T09:24:13.418",
    "reviewCount": 42,
    "score": "299.00",
    "stars": "299.00"
  },
  "widget": {
    "scriptUrl": "https://cdn.fluit.cloud/assets/widget-a-front.jpg",
    "templates": [
      {
        "height": 42,
        "style": "string",
        "templateId": "string"
      }
    ]
  }
}

Bas-URL https://api.erp.fluit.cloud/ecom. Svarsexemplet är genererat ur schemat: formen stämmer, värdena är påhittade.

Scheman

Objekten som gruppens anrop refererar till. Fälttabellerna ovan går ett steg djupt och länkar hit i stället för att upprepa samma schema på varje endpoint.

ProductReview

ProductReviewResponse
Fält Typ
author string · nullable
date string(date-time)
id string(uuid)
isVerifiedPurchase boolean
rating integer
text string · nullable
title string · nullable

ProductReviewSummary

ProductReviewSummaryResponse
Fält Typ
averageRating decimal · nullable
distribution integer[] · nullable
totalCount integer

ReviewPlatformRating

EcomReviewPlatformRatingResponse
Fält Typ
fetchedAt string(date-time)
reviewCount integer
score decimal
stars decimal

ReviewPlatformWidget

EcomReviewPlatformWidgetResponse
Fält Typ
scriptUrl string · nullable
templates ReviewWidgetTemplate[] · nullable

ReviewWidgetTemplate

EcomReviewWidgetTemplateResponse
Fält Typ
height integer
style string · nullable
templateId string · nullable