API ยท v2.0.0
Build on the
Black Swan platform.
One unified API for vehicles, customers, ownership and connected-mobility controls. Integrate your dealership tools, fleet analytics, or partner apps in minutes.
Vehicles
Query the full catalog, inspect any VIN, manage state (lock, climate, charging).
GET /api/cars
GET /api/state
PATCH /api/cars/{vin}/state
Customers
List, search and inspect your customer base. Supports self sign-up flows.
GET /api/customers
GET /api/customers/{username}
POST /api/auth/signup
Dealerships
Manage the dealer network: register, look up and administer dealerships.
GET /api/dealers
POST /api/dealers
DELETE /api/dealers/{username}
Ownership & Fleet
Assign owners, transfer vehicles between fleets, reset ownership.
PATCH /api/cars/{vin}/owner
DELETE /api/cars/{vin}/owner
POST /api/cars/add-to-fleet
Quick start
Authenticate and list dealerships in three calls:
# 1. Authenticate curl -X POST https://dealer.chal.blackswantrainingcenter.com/api/auth/login \ -H "Content-Type: application/json" \ -d '{"role":"user","username":"linnea","password":"linnea"}' # 2. Capture the token, then call any authenticated endpoint export TOKEN=<token from step 1> curl https://dealer.chal.blackswantrainingcenter.com/api/dealers \ -H "Authorization: Bearer $TOKEN" # 3. List every vehicle on the platform curl https://dealer.chal.blackswantrainingcenter.com/api/cars \ -H "Authorization: Bearer $TOKEN"
Tip: all endpoints are interactive at /docs. Click Authorize and paste your Bearer token to try them live.