TBBN.Merchant Platform docs
WORKING

Offers

post/v1/offers

Create an offer. listingIdsA is the existing listing(s) being offered ON, owned by toSellerId; listingIdsB is the listing(s) offered IN EXCHANGE, owned by fromSellerId — see docs/business/conflict-resolution-log.md item 3.

Parameters

optional

Request body

FieldTypeRequired
fromSellerIdstring (uuid)yes
toSellerIdstring (uuid)yes
listingIdsAstring[]yes
listingIdsBstring[]yes
extraAmountOfferednumber
expiresAtstring (date-time)

Response (201)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]
get/v1/offers

List offers for a seller

Parameters

sellerIdqueryrequired
directionqueryoptional

Response (200)

get/v1/offers/{id}

Get an offer. A PENDING offer past its expiresAt is lazily transitioned to EXPIRED on read.

Parameters

idpathrequired

Response (200)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]
post/v1/offers/{id}/accept

Accept a PENDING offer — only the recipient (toSellerId) may accept. Does not create a trade session directly; trade-session-service reacts to the resulting offer.accepted event.

Parameters

idpathrequired
optional

Request body

FieldTypeRequired
actingSellerIdstring (uuid)yes

Response (201)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]
post/v1/offers/{id}/reject

Reject a PENDING offer — only the recipient (toSellerId) may reject

Parameters

idpathrequired
optional

Request body

FieldTypeRequired
actingSellerIdstring (uuid)yes

Response (201)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]
post/v1/offers/{id}/cancel

Cancel a DRAFT or PENDING offer — only the sender (fromSellerId) may cancel

Parameters

idpathrequired
optional

Request body

FieldTypeRequired
actingSellerIdstring (uuid)yes

Response (201)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]
post/v1/offers/{id}/counter

Counter a PENDING offer — only the recipient may counter. Creates a brand-new offer with sender/recipient roles swapped and moves the original offer to COUNTERED; the two are linked only via the offer.countered event, not a foreign key.

Parameters

idpathrequired
optional

Request body

FieldTypeRequired
actingSellerIdstring (uuid)yes
listingIdsAstring[]yes
listingIdsBstring[]yes
extraAmountOfferednumber
expiresAtstring (date-time)

Response (201)

FieldTypeRequired
idstring (uuid)
fromSellerIdstring (uuid)
toSellerIdstring (uuid)
statusDRAFT | PENDING | ACCEPTED | REJECTED | CANCELLED | EXPIRED | COUNTERED
extraAmountOfferednumbernull
expiresAtstring,null (date-time)
createdAtstring (date-time)
offerListingsAobject[]
offerListingsBobject[]