API Documentation

discava REST API – Search for local businesses worldwide

Base URL

https://discava.ai/api/v1

No authentication required. Rate limited to 500 requests per hour per IP.

SKILL.md

Add discava as a skill to your AI agent or chatbot.

Download

MCP Server (Remote)

Connect your AI agent directly via the Model Context Protocol.

MCP Server (Local)

Download, extract, run npm install && npx tsx server.ts

Download .zip

Scores

confidence_score (0–100)

Data quality score. Measures how complete and verified a business listing is (address, phone, website, opening hours, etc.).

demand_score (0–100)

Ranking score based on click-through rate. Calculated using Wilson's Lower Bound — a statistical method that estimates the true popularity of a business based on how often it is clicked relative to how often it appears in search results.

relevance_score (0.0–1.0)

Query-specific score returned with search results. Combines text match, quality signals, proximity, and data completeness.

Response Format

Every response follows this structure:

{
  "success": true,
  "data": { ... },
  "meta": {
    "request_id": "req_abc123"
  }
}

Endpoints

GET

/api/v1/search

Search for businesses. Returns results sorted by relevance score. Supports pagination.

Parameters

NameRequiredDescription
qNoSearch query (category name, business name, or keyword)
cityNoCity name (e.g. München, Hamburg)
countryYesISO country code (e.g. DE, AT, CH, US)
categoryNoCategory slug directly (e.g. plumber, restaurant)
limitNo1-50 (default: 20)
pageNoPage number (default: 1)
min_confidenceNoMinimum confidence score 0-100 (default: 0)
langNoLanguage for category labels: de or en (default: de)
lat, lonNoCoordinates for distance calculation
formatNojson (default) or html – returns interactive HTML cards with click tracking

Example

curl "https://discava.ai/api/v1/search?q=Klempner&city=Hamburg&country=DE&limit=1"

Response

{
  "success": true,
  "data": {
    "results": [{
      "id": "abc123",
      "name": "Klempner Müller",
      "slug": "klempner-mueller-hamburg",
      "category": "plumber",
      "category_label": "Klempner",
      "parent_category": "craftsman",
      "parent_category_label": "Handwerker",
      "city": "Hamburg",
      "country": "DE",
      "logo_url": "https://www.google.com/s2/favicons?domain=klempner-mueller.de&sz=64",
      "available_details": ["phone", "website", "opening_hours", "services"],
      "confidence_score": 65,
      "demand_score": 28,
      "relevance_score": 0.82
    }],
    "total": 44,
    "page": 1,
    "total_pages": 44,
    "limit": 1
  },
  "meta": { "request_id": "req_abc123" }
}

Check available_details to see what data exists,
then call GET /api/v1/business/{id} for full details.
GET

/api/v1/business/:id

Get full details for one or more businesses: address, phone, website, opening hours, services, payment methods, social links, logo, business image, and coordinates. Supports comma-separated IDs for batch requests. Add ?format=html for interactive HTML cards with click tracking.

# Single business
curl "https://discava.ai/api/v1/business/{id}"

# Batch (multiple IDs)
curl "https://discava.ai/api/v1/business/{id1},{id2},{id3}"
POST

/api/v1/feedback

Report data quality issues. Feedback is stored for monitoring but does not affect ranking scores. Only business_id and type are required. Use comment to describe the issue.

curl -X POST "https://discava.ai/api/v1/feedback" \
  -H "Content-Type: application/json" \
  -d '{"business_id":"xxx","type":"PHONE_INVALID","comment":"Number disconnected"}'

Feedback Types

POSITIVENEGATIVENOT_FOUNDPHONE_INVALIDWEB_INVALIDHOURS_WRONGDUPLICATE
GET

/api/v1/ranking

Top businesses by Demand Score (based on click-through rate). Filter by category, city, or country.

curl "https://discava.ai/api/v1/ranking?category=plumber&city=Hamburg&limit=10"
GET

/api/v1/suggest

Autocomplete suggestions for cities, categories, and business names. Useful for resolving user input before searching.

Parameters

NameRequiredDescription
qYesQuery (min. 2 characters)
typeNocity or query (default: query)
limitNo1-15 (default: 10)
curl "https://discava.ai/api/v1/suggest?type=city&q=Mün"
curl "https://discava.ai/api/v1/suggest?type=query&q=Klemp"
GET

/api/v1/health

Health check endpoint. Returns status and version.

discava – Das Branchenverzeichnis für KI