Trade-ins and auctions

Trade-in intents, the offers partners make on them, and the auctions that put a vehicle out to several dealers.

Base URL
https://api.reportauto.eu

Trade-ins

A trade-in records a seller’s intent to trade a vehicle with a partner. Partners then bid on it with offers, and the seller accepts one.

Create a trade-in

POST/api/trade_in

Registers a trade-in for a partner, optionally bound to an existing request through request_id and session_key.

Authentication API key

Parameters

full_namestringRequired

Seller’s name.

phonestring

Seller’s phone number.

emailstring

Seller’s email address.

platestring

Registration plate of the vehicle.

country_codestring

Country, e.g. USA.

country_state_codestring

State, e.g. FL.

infostring

Free-text note from the seller.

partner_idintegerRequired

Partner the trade-in is offered to.

request_idinteger

Request to associate the trade-in with.

session_keystring

Session key of that request.

cURL
1curl -X POST "https://api.reportauto.eu/api/trade_in" \
2  -H "Authorization: API_KEY $CAROOM_API_KEY" \
3  -H "Content-Type: application/json" \
4  -d '{
5    "full_name": "Jamie Rivera",
6    "phone": "+37256781061",
7    "email": "jamie@example.com",
8    "info": "I want to test the car comes up",
9    "country_state_code": "FL",
10    "country_code": "USA",
11    "plate": "NEWUS",
12    "partner_id": 16,
13    "request_id": 1164,
14    "session_key": "ef651a9c-0d68-4fd3-a382-526741591ed3"
15  }'

Update a trade-in

PATCH/api/trade_in/:trade_in_id

Changes the price on a trade-in. A partner uses it to set the offered price; a seller uses it to state the price they expect.

Authentication API key

Path parameters

trade_in_idintegerRequired

ID of the trade-in.

Parameters

offer_pricestring

Price, as a decimal string.

infostring

Note attached to the price.

cURL
1curl -X PATCH "https://api.reportauto.eu/api/trade_in/77" \
2  -H "Authorization: API_KEY $CAROOM_API_KEY" \
3  -H "Content-Type: application/json" \
4  -d '{
5    "offer_price": "2345.99",
6    "info": "Best we can do this month"
7  }'

Submit an offer

POST/api/trade_in/:trade_in_id/offers

A partner bids on a trade-in. Offers carry an expiry and an optional comment, and can be conditional on the seller buying a new vehicle.

Authentication API key

Path parameters

trade_in_idintegerRequired

ID of the trade-in being bid on.

Parameters

valueintegerRequired

Amount offered.

partner_idintegerRequired

Partner making the offer.

expires_atstring

ISO 8601 timestamp when the offer lapses.

trade_for_newboolean

Whether the offer is conditional on trading for a new vehicle.

commentstring

Note shown to the seller.

cURL
1curl -X POST "https://api.reportauto.eu/api/trade_in/1000/offers" \
2  -H "Authorization: API_KEY $CAROOM_API_KEY" \
3  -H "Content-Type: application/json" \
4  -d '{
5    "trade_for_new": true,
6    "expires_at": "2020-10-08T15:30:00.000",
7    "value": 35690,
8    "comment": "This is a fair price",
9    "partner_id": 7
10  }'

Accept an offer

PATCH/api/trade_in/:trade_in_id/offers

The seller accepts an outstanding offer. Authorised by the session key rather than by an account, so it works straight from the link in the notification.

Authentication Session key

Path parameters

trade_in_idintegerRequired

ID of the trade-in.

Parameters

acceptbooleanRequired

True to accept the offer.

session_keystringRequired

Session key that authorises the seller.

cURL
1curl -X PATCH "https://api.reportauto.eu/api/trade_in/1340/offers" \
2  -H "Content-Type: application/json" \
3  -d '{
4    "accept": true,
5    "session_key": "b3c8d9df-9dc4-4221-907e-08517fe84829"
6  }'

Submit an auction offer

POST/api/public/offers

Places a bid in an auction using a dealer key, without an account session. Used by dealers bidding through a shared link.

Authentication Dealer key in the body

Parameters

dealer_keystringRequired

Key identifying the bidding dealer.

auction_idintegerRequired

Auction being bid in.

valueintegerRequired

Amount offered.

cURL
1curl -X POST "https://api.reportauto.eu/api/public/offers" \
2  -H "Content-Type: application/json" \
3  -d '{
4    "dealer_key": "41cfe3cb-2b42-4f5d-aea0-31a97f6b8dac",
5    "auction_id": 10,
6    "value": 3000
7  }'

Auctions

A partner can put a trade-in out to a set of dealers as a timed auction. Dealers bid through the public offers endpoint — see Trade-ins.

Create an auction

POST/api/auctions

Opens an auction on a trade-in for a named set of dealers. Start and end times default to now and thirty days out; neither may be in the past.

Authentication API key

Parameters

trade_in_idintegerRequired

Trade-in being auctioned.

partner_idintegerRequired

Partner running the auction — supplies the geometry and currency.

dealersarray of integers

Dealer IDs invited to bid.

end_timestring

ISO 8601 close time. Defaults to 30 days out.

start_timestring

ISO 8601 open time. Defaults to now.

min_bidinteger

Reserve price. Defaults to the expected price.

stepinteger

Minimum bid increment.

postcodeinteger

Location of the vehicle. Optional for a partner.

validityobject

How long the winning bid holds, as { days, miles }.

cURL
1curl -X POST "https://api.reportauto.eu/api/auctions" \
2  -H "Authorization: $CAROOM_API_KEY" \
3  -H "Content-Type: application/json" \
4  -d '{
5    "dealers": [53, 55],
6    "end_time": "2022-02-10T20:27:17.855Z",
7    "partner_id": 8,
8    "trade_in_id": 1503,
9    "validity": { "days": "3", "miles": 250 }
10  }'

Retrieve an auction as an invited dealer

GET/api/public/auctions/dealers/:dealer_key

The invited dealer’s view of an auction, opened straight from the link they were sent. The dealer key in the path is the credential — bids go to the public offers endpoint under Trade-ins.

Authentication Dealer key in the path

Path parameters

dealer_keystringRequired

Key identifying the invited dealer.

cURL
1curl "https://api.reportauto.eu/api/public/auctions/dealers/41cfe3cb-2b42-4f5d-aea0-31a97f6b8dac"

Retrieve an auction

GET/api/auctions/:auction_id

Returns the auction with its bids and current standing.

Authentication API key

Path parameters

auction_idintegerRequired

ID of the auction.

cURL
1curl "https://api.reportauto.eu/api/auctions/32" \
2  -H "Authorization: $CAROOM_API_KEY"