Widget API

Public JSON endpoint used by widget.js.

Read-only public API. No API key required for published review data.

Get widget data

Request
GET https://app.trustflowx.com/api/widget/{businessId}
Accept: application/json

Success response (200)

{
  "businessName": "Acme Plumbing",
  "branding": {},
  "logo": "https://...",
  "reviews": [
    {
      "reviewer_name": "Jane Doe",
      "reviewer_image": "https://...",
      "rating": 5,
      "text": "Great service!",
      "date": "2026-05-01",
      "is_verified": true
    }
  ]
}

Errors

404 — Business not found. 500 — Server error.

Custom integrations

You may build your own UI by fetching this endpoint from a server or client. Respect caching — reviews change after sync. For most sites, use the official embed script instead.

Widget by ID

Widget config (authenticated owner flows)
GET https://app.trustflowx.com/api/widgets/{widgetId}

Used internally for widget editor; requires owner session for private config.