Accept a trade offer V2
PATCH/v2/offers/:Offer-ID/accept
Upon presentation of a trade offer, this endpoint facilitates the user's acceptance of the offer, effectively signalling their agreement to proceed with the trade under the specified conditions.
A user can only accept the newest offer created and it can be done within its validity (as defined in offer_validity & expires_at response parameters).
When a user submits a request to accept a trade offer, the platform immediately begins to process this request to finalise the trade.
However, there are instances when the processing cannot be completed within a short, predefined time frame (e.g. 10 seconds).
In such cases, rather than leaving the user uncertain of the request's status, the API responds with a 202 Accepted status code.
This response serves as an acknowledgment that the user's request has been successfully received and is in the queue for processing (in progress status), but it has not yet been finalised.
After receiving 202 Accepted, there are two strategic options to proceed:
- Retry sending the same request until you receive a
200 Offer has been acceptedstatus response - Check the offer status using the Offer Status endpoint
Request
Responses
- 200
- 202
- 401
- 403
- 406
- 409
- 410
- 422
- 429
- 500
- 503
Offer has been accepted
Accepted
Unauthorized
Forbidden
The external transaction already exists. / This offer exists and it has another external transaction id associated.
Offer already accepted / A newer offer was created / Offer previously failed
Offer expired / invalid offer id
Error
Too Many Requests
Response Headers
The rate limit ceiling for the current time window. Envoy may include multiple limits and window metadata.
50, 50;w=1The number of requests remaining in the current rate limit window.
0The number of seconds until the current rate limit window resets.
1Indicates the request was rate limited by the Envoy proxy.
trueError
Maintenance or Service unavailable