{"openapi":"3.0.3","info":{"title":"OpenLogo API","version":"1.0.0","description":"Professional logo, company search, and structured brand-profile delivery. Publishable keys are restricted to the Logo API and explicit browser origins. Secret keys are server-side credentials.","contact":{"name":"OpenLogo security and API support","email":"hi@openlogo.dev"}},"servers":[{"url":"https://api.openlogo.dev","description":"Production"}],"tags":[{"name":"Logo"},{"name":"Search"},{"name":"Brand"}],"paths":{"/v1/logo/{lookup}":{"get":{"operationId":"getLogo","summary":"Retrieve a logo","tags":["Logo"],"security":[{"publishableKey":[]},{"secretKey":[]},{"headerKey":[]}],"parameters":[{"name":"lookup","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":253}},{"name":"token","in":"query","description":"Publishable key for browser image URLs. Secret keys are rejected from query strings.","schema":{"type":"string","pattern":"^ol_pk_"}},{"name":"type","in":"query","schema":{"type":"string","enum":["domain","name"],"default":"domain"}},{"name":"asset","in":"query","description":"Exact asset ID returned by the Brand API. When set, the original stored file is selected before optional transformations.","schema":{"type":"string","minLength":1,"maxLength":100,"pattern":"^[A-Za-z0-9_-]+$"}},{"name":"format","in":"query","schema":{"type":"string","enum":["svg","png","webp","jpg","jpeg"]}},{"name":"theme","in":"query","schema":{"type":"string","enum":["auto","light","dark"],"default":"auto"}},{"name":"size","in":"query","schema":{"type":"integer","minimum":16,"maximum":800}},{"name":"retina","in":"query","description":"Pixel-density multiplier. Query-string values are parsed as strings.","schema":{"type":"string","enum":["true","false","1","2","3"],"default":"1"}},{"name":"greyscale","in":"query","schema":{"type":"boolean","default":false}},{"name":"fallback","in":"query","schema":{"type":"string","enum":["404","monogram"],"default":"404"}},{"name":"download","in":"query","description":"Return Content-Disposition attachment with a sanitized OpenLogo filename.","schema":{"type":"boolean","default":false}}],"responses":{"200":{"description":"The asset, streamed from private OpenLogo object storage through the API boundary.","headers":{"ETag":{"schema":{"type":"string"}},"Content-Location":{"schema":{"type":"string","format":"uri"}},"Content-Disposition":{"schema":{"type":"string"}},"X-OpenLogo-Delivery":{"schema":{"type":"string","enum":["api.openlogo.dev"]}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"image/svg+xml":{"schema":{"type":"string","format":"binary"}},"image/png":{"schema":{"type":"string","format":"binary"}},"image/webp":{"schema":{"type":"string","format":"binary"}},"image/jpeg":{"schema":{"type":"string","format":"binary"}}}},"304":{"description":"The client cache is current."},"400":{"description":"One or more logo options are invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"The API key is missing, malformed, expired, or inactive.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The key lacks the required scope or allowed browser origin.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"404":{"description":"No matching logo was found.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"A request, key, or workspace quota was exceeded.","headers":{"Retry-After":{"schema":{"type":"integer"}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/search":{"get":{"operationId":"searchBrands","summary":"Search companies","tags":["Search"],"security":[{"secretKey":[]},{"headerKey":[]}],"parameters":[{"name":"q","in":"query","required":true,"schema":{"type":"string","minLength":2,"maxLength":100}},{"name":"strategy","in":"query","schema":{"type":"string","enum":["suggest","match"],"default":"suggest"}},{"name":"limit","in":"query","schema":{"type":"integer","minimum":1,"maximum":25,"default":10}}],"responses":{"200":{"description":"Matching companies.","content":{"application/json":{"schema":{"type":"object","required":["results"],"properties":{"results":{"type":"array","items":{"$ref":"#/components/schemas/SearchResult"}}}}}}},"400":{"description":"The query is invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"The API key is missing, malformed, expired, or inactive.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The key lacks the required scope or allowed browser origin.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"A request, key, or workspace quota was exceeded.","headers":{"Retry-After":{"schema":{"type":"integer"}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/brand/{domain}":{"get":{"operationId":"getBrandProfile","summary":"Retrieve a structured brand profile","tags":["Brand"],"security":[{"secretKey":[]},{"headerKey":[]}],"parameters":[{"name":"domain","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":253}}],"responses":{"200":{"description":"A ready brand profile.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandProfile"}}}},"202":{"description":"Brand extraction was queued.","headers":{"Location":{"schema":{"type":"string","format":"uri"}},"Retry-After":{"schema":{"type":"integer"}}},"content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"400":{"description":"The domain is invalid.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"401":{"description":"The API key is missing, malformed, expired, or inactive.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The key lacks the required scope or allowed browser origin.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"A request, key, or workspace quota was exceeded.","headers":{"Retry-After":{"schema":{"type":"integer"}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/brand-kit/{domain}":{"get":{"operationId":"getBrandKit","summary":"Retrieve verified brand assets and reusable tokens","tags":["Brand"],"security":[{"secretKey":[]},{"headerKey":[]}],"parameters":[{"name":"domain","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":253}}],"responses":{"200":{"description":"An evidence-backed Brand Kit snapshot.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandProfile"}}}},"202":{"description":"Brand extraction was queued.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"401":{"description":"The API key is missing, malformed, expired, or inactive.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The key lacks the required scope or allowed browser origin.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"A request, key, or workspace quota was exceeded.","headers":{"Retry-After":{"schema":{"type":"integer"}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}},"/v1/brand-context/{domain}":{"get":{"operationId":"getBrandContext","summary":"Retrieve evidence-backed company and product context","tags":["Brand"],"security":[{"secretKey":[]},{"headerKey":[]}],"parameters":[{"name":"domain","in":"path","required":true,"schema":{"type":"string","minLength":1,"maxLength":253}}],"responses":{"200":{"description":"A validated Brand Context snapshot.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandContext"}}}},"202":{"description":"Brand extraction and context generation were queued.","content":{"application/json":{"schema":{"type":"object","additionalProperties":true}}}},"401":{"description":"The API key is missing, malformed, expired, or inactive.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"403":{"description":"The key lacks the required scope or allowed browser origin.","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}},"429":{"description":"A request, key, or workspace quota was exceeded.","headers":{"Retry-After":{"schema":{"type":"integer"}},"X-Request-Id":{"schema":{"type":"string"}}},"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}}}}}}},"components":{"securitySchemes":{"publishableKey":{"type":"apiKey","in":"query","name":"token","description":"Browser-safe ol_pk_ credential, restricted by exact or wildcard HTTPS origins."},"secretKey":{"type":"http","scheme":"bearer","bearerFormat":"ol_sk_...","description":"Server-side secret. Never embed it in browser, mobile, source-control, logs, or URLs."},"headerKey":{"type":"apiKey","in":"header","name":"X-OpenLogo-Key"}},"schemas":{"ErrorResponse":{"type":"object","required":["error"],"properties":{"error":{"type":"object","required":["code","message"],"properties":{"code":{"type":"string"},"message":{"type":"string"},"details":{}}}}},"SearchResult":{"type":"object","required":["domain","name","logo"],"properties":{"domain":{"type":"string"},"name":{"type":"string"},"logo":{"type":"string","format":"uri"}},"additionalProperties":true},"BrandAsset":{"type":"object","required":["id","blobId","url","role","theme","format"],"properties":{"id":{"type":"string"},"blobId":{"type":"string"},"url":{"type":"string","format":"uri"},"role":{"type":"string","enum":["logo","brandmark","wordmark","lockup","app_icon","favicon","og_image","social_banner","other"]},"theme":{"type":"string","enum":["auto","light","dark"]},"format":{"type":"string"},"width":{"type":"integer","nullable":true},"height":{"type":"integer","nullable":true},"contentType":{"type":"string"},"bytes":{"type":"integer"},"checksumSha256":{"type":"string","nullable":true},"provenance":{"type":"object","additionalProperties":true},"updatedAt":{"type":"string","format":"date-time"}},"additionalProperties":true},"BrandProfile":{"type":"object","required":["domain","name","logo","brandmark","wordmark","favicon","openGraphImages","socialBanners","coverage","assets"],"properties":{"domain":{"type":"string"},"name":{"type":"string"},"description":{"type":"string","nullable":true},"logo":{"allOf":[{"$ref":"#/components/schemas/BrandAsset"}],"nullable":true},"brandmark":{"allOf":[{"$ref":"#/components/schemas/BrandAsset"}],"nullable":true},"wordmark":{"allOf":[{"$ref":"#/components/schemas/BrandAsset"}],"nullable":true},"favicon":{"allOf":[{"$ref":"#/components/schemas/BrandAsset"}],"nullable":true},"openGraphImages":{"type":"array","items":{"$ref":"#/components/schemas/BrandAsset"}},"socialBanners":{"type":"array","items":{"$ref":"#/components/schemas/BrandAsset"}},"assets":{"type":"array","items":{"$ref":"#/components/schemas/BrandAsset"}},"coverage":{"type":"array","items":{"type":"object","required":["role","status","count","checkedAt"],"properties":{"role":{"type":"string"},"status":{"type":"string","enum":["found","missing","blocked","not_public","not_checked"]},"reasonCode":{"type":"string","nullable":true},"reason":{"type":"string","nullable":true},"count":{"type":"integer"},"checkedAt":{"type":"string","format":"date-time"}}}}},"additionalProperties":true},"BrandContext":{"type":"object","required":["domain","name","context"],"properties":{"domain":{"type":"string"},"name":{"type":"string"},"context":{"type":"object","required":["status","data"],"properties":{"status":{"type":"string","enum":["pending","ready","failed","needs_review","stale"]},"data":{"type":"object","additionalProperties":true},"provider":{"type":"string","nullable":true},"model":{"type":"string","nullable":true},"evidenceHash":{"type":"string","nullable":true},"error":{"type":"object","nullable":true}}}},"additionalProperties":true}}}}