WORKING
Reputation
post
/v1/reputation/reviewsSubmit a 1-5 star review of a Merchant or a Space Branch — must be tied to a real completed trade session or Space booking the reviewer was actually a party to.
Request body
| Field | Type | Required |
|---|---|---|
| targetType | MERCHANT | SPACE_BRANCH | yes |
| merchantId | string (uuid) | — |
| branchId | string (uuid) | — |
| rating | integer | yes |
| comment | string | — |
| tradeSessionId | string (uuid) | — |
| spaceBookingId | string (uuid) | — |
Response (201)
| Field | Type | Required |
|---|---|---|
| id | string (uuid) | — |
| reviewerId | string (uuid) | — |
| targetType | MERCHANT | SPACE_BRANCH | — |
| merchantId | string,null (uuid) | — |
| branchId | string,null (uuid) | — |
| rating | integer | — |
| comment | stringnull | — |
| tradeSessionId | string,null (uuid) | — |
| spaceBookingId | string,null (uuid) | — |
| createdAt | string (date-time) | — |
get
/v1/reputation/merchants/{id}/reviewsA Merchant's reviews plus aggregate rating
Parameters
| id | path | required |
Response (200)
| Field | Type | Required |
|---|---|---|
| reviews | object[] | — |
| averageRating | numbernull | — |
| reviewCount | integer | — |
get
/v1/reputation/branches/{id}/reviewsA Space Branch's reviews plus aggregate rating
Parameters
| id | path | required |
Response (200)
| Field | Type | Required |
|---|---|---|
| reviews | object[] | — |
| averageRating | numbernull | — |
| reviewCount | integer | — |
get
/v1/reputation/businesses/{id}/reviews-summaryAggregate rating rolled up across every Merchant/Branch linked to a Business (direct Postgres read, no live cross-service call).
Parameters
| id | path | required |
Response (200)
| Field | Type | Required |
|---|---|---|
| averageRating | numbernull | — |
| reviewCount | integer | — |
get
/v1/reputation/sellers/{id}Get a seller's reputation score (0-100). New sellers start at the neutral baseline of 50 — the same default @tbbn/core-matching's reputationMatch factor uses when reputation data is absent, so Matching and Reputation never disagree about what "no track record yet" means.
Parameters
| id | path | required |
Response (200)
| Field | Type | Required |
|---|---|---|
| sellerId | string (uuid) | — |
| score | integer | — |