{"openapi":"3.1.0","info":{"title":"SMB Listings API","version":"1.0.0","description":"Search business-for-sale listings from public marketplaces and broker sites through one REST API and MCP server for AI agents. Asking price, revenue, cash flow and multiples, normalized. Pay per request; 250 free credits."},"servers":[{"url":"https://smblistings.ai/api/v1"}],"security":[{"apiKey":[]},{"bearer":[]}],"components":{"securitySchemes":{"apiKey":{"type":"apiKey","in":"header","name":"x-api-key"},"bearer":{"type":"http","scheme":"bearer"}},"schemas":{"Listing":{"type":"object","properties":{"id":{"type":"string","description":"Stable listing id"},"source":{"type":"string","description":"Where the listing was found"},"sourceId":{"type":"string"},"url":{"type":"string","format":"uri","description":"Original listing"},"title":{"type":"string"},"industry":{"type":["string","null"]},"location":{"type":["string","null"]},"askingPrice":{"type":["number","null"],"description":"USD"},"revenue":{"type":["number","null"],"description":"USD, annual"},"cashFlow":{"type":["number","null"],"description":"USD, annual profit / SDE"},"firstSeen":{"type":"string","format":"date-time"},"lastSeen":{"type":"string","format":"date-time"}},"required":["id","source","sourceId","url","title","firstSeen","lastSeen"]},"Error":{"type":"object","properties":{"error":{"type":"string"}}}}},"paths":{"/listings/search":{"get":{"operationId":"searchListings","summary":"Search businesses for sale (1 credit)","parameters":[{"name":"q","in":"query","required":false,"schema":{"description":"Words to match in the listing title","type":"string"}},{"name":"industry","in":"query","required":false,"schema":{"description":"Exact industry, e.g. 'Health and Beauty'","type":"string"}},{"name":"source","in":"query","required":false,"schema":{"description":"Only listings from this source (the `source` field of a listing)","type":"string"}},{"name":"location","in":"query","required":false,"schema":{"description":"Partial match on location, e.g. 'TX' or 'Canada'","type":"string"}},{"name":"minPrice","in":"query","required":false,"schema":{"description":"Minimum asking price, USD","type":"number"}},{"name":"maxPrice","in":"query","required":false,"schema":{"description":"Maximum asking price, USD","type":"number"}},{"name":"minCashFlow","in":"query","required":false,"schema":{"description":"Minimum annual cash flow / profit, USD","type":"number"}},{"name":"limit","in":"query","required":false,"schema":{"default":25,"description":"Results to return, 1-100","type":"integer","minimum":1,"maximum":100}},{"name":"offset","in":"query","required":false,"schema":{"default":0,"type":"integer","minimum":0,"maximum":9007199254740991}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Listing"}}}}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Out of credits","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/listings/new":{"get":{"operationId":"newListings","summary":"Listings first seen after a timestamp (1 credit)","parameters":[{"name":"since","in":"query","required":true,"schema":{"type":"string","format":"date-time"}}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/Listing"}}}}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Out of credits","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/listings/{id}":{"get":{"operationId":"getListing","summary":"Get one listing (1 credit)","parameters":[{"name":"id","in":"path","required":true,"schema":{"type":"string"},"description":"Listing id from search"}],"responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"data":{"$ref":"#/components/schemas/Listing"}}}}}},"401":{"description":"Missing or invalid API key","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"402":{"description":"Out of credits","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}},"404":{"description":"Not found","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}}}}}},"/account":{"get":{"operationId":"getAccount","summary":"Credit balance (free)","responses":{"200":{"description":"OK","content":{"application/json":{"schema":{"type":"object","properties":{"credits":{"type":"integer"}}}}}}}}}}}