v1.0.0 FastAPI X-API-Key required

Search images and news with a locked-down REST API.

Query DuckDuckGo images and news, with filters for size, color, type, layout, license, region, and time. Pass a US street address and results are narrowed to ones that actually mention it. Search calls need a valid API key in the header — not in the URL.

Precise addresses

Send address. The street line is quoted and off-target results are dropped.

News & NYC projects

Recent news, plus a dated timeline of a project from NYC real-estate outlets with lead photos.

Filters that matter

Size, color, type, layout, license, time range, and region.

Header-only auth

Send X-API-Key. Query-string keys are rejected.

Rate limited

30 searches per minute per IP across images and news, plus a failed-auth cap.

Useful payloads

Image URLs and dimensions, article dates and sources, plus the exact query sent upstream.

Authentication

Every /api/search and /api/news call needs a key

Put the key in X-API-Key. The homepage and /health stay public. Ask javier@privatediningpros.com if you need access.

-H "X-API-Key: YOUR_API_KEY"

Live request

Try it

Runs against this server. Your key stays in the browser and is not stored.

Fill in a query, an address, or both.

Results will land here.

Reference

Endpoints

GET /api/search

Search images with query parameters. Requires X-API-Key.

POST /api/search

Same image search, JSON body. Requires X-API-Key.

GET /api/news

Search news with query parameters. Requires X-API-Key.

POST /api/news

Same news search, JSON body. Requires X-API-Key.

GET /api/project

Coverage of a NYC project by address and/or project name: dated articles and lead photos, newest first. Requires X-API-Key.

POST /api/project

Same project search, JSON body. Requires X-API-Key.

GET /health

Public liveness check for load balancers.

GET /api/info

Public JSON summary of endpoints and example calls.

Search parameters

Name Required Notes
queryOne of query / addressSearch keywords. Quote words to require that exact phrase.
addressOne of query / addressUS street address, e.g. 265 South Street Manhattan NY 10004. Sent upstream as "265 South Street" Manhattan NY.
strictNoDrop results that don't mention the address or quoted phrases. On by default with address.
projectProject search/api/project only. Development name, e.g. Two Bridges. Send with or instead of address.
sites / include_web / enrichNo/api/project only. Outlet domains to search, add an open-web search, and read each article's date and lead photo (all on by default).
max_resultsNo1–100, default 10
regionNous-en, uk-en, wt-wt
safesearchNooff, moderate, on
timelimitNod, w, m, y
backendNoImages: auto, bing, duckduckgo. News adds yahoo.
sizeNoImages only. Small, Medium, Large, Wallpaper
color / type_image / layout / license_imageNoImages only. Visual filters (these use the DuckDuckGo backend)
validate_imagesNoImages only. Check that image URLs are reachable

Quick start

Examples

curl -H "X-API-Key: YOUR_API_KEY" \
  "https://snapfeedapi.info/api/search?query=butterfly&max_results=5"
curl -X POST "https://snapfeedapi.info/api/search" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"query": "butterfly", "max_results": 5}'
curl -H "X-API-Key: YOUR_API_KEY" \
  "https://snapfeedapi.info/api/news?query=sun&timelimit=m&max_results=5"
curl -G -H "X-API-Key: YOUR_API_KEY" "https://snapfeedapi.info/api/search" \
  --data-urlencode "address=265 South Street Manhattan NY 10004"

curl -G -H "X-API-Key: YOUR_API_KEY" "https://snapfeedapi.info/api/news" \
  --data-urlencode "address=265 South Street Manhattan NY 10004" \
  --data-urlencode "query=construction"
curl -G -H "X-API-Key: YOUR_API_KEY" "https://snapfeedapi.info/api/project" \
  --data-urlencode "address=265 South Street Manhattan NY 10004" \
  --data-urlencode "project=Two Bridges"
fetch('https://snapfeedapi.info/api/search?query=butterfly&max_results=5', {
  headers: {
    'X-API-Key': 'YOUR_API_KEY'
  }
})

Responses

Both endpoints echo effective_query (what was sent upstream), the parsed address, and filtered_out (results dropped by strict mode).

GET /api/search

{
  "images": [
    {
      "url": "https://example.com/265-south-street.jpg",
      "title": "NEW YORK | 265 South Street | 73 floors",
      "thumbnail": "https://example.com/thumb.jpg",
      "dimensions": { "width": 1920, "height": 1080 },
      "source": "DuckDuckGo Search Images",
      "position": 1
    }
  ],
  "count": 1,
  "query": "265 South Street Manhattan NY 10004",
  "effective_query": "\"265 South Street\" Manhattan NY",
  "address": { "number": "265", "street": "South Street", "city": "Manhattan", "state": "NY", "zip_code": "10004" },
  "strict": true,
  "filtered_out": 16,
  "max_results": 10
}

GET /api/news

{
  "articles": [
    {
      "title": "Sun Life announces executive appointment",
      "body": "Sun Life Financial Inc. today announced...",
      "url": "https://example.com/news/sun-life",
      "image": "https://example.com/news/sun.jpg",
      "source": "Example Wire",
      "date": "2026-09-20T13:00:00+00:00",
      "domain": "example.com",
      "position": 1
    }
  ],
  "count": 1,
  "query": "sun",
  "effective_query": "sun",
  "address": null,
  "strict": false,
  "filtered_out": 0,
  "max_results": 5
}